void display_controls() {
  char controls[][(46 - 2)] = {"w - move up",
                               "a - move left",
                               "s - move down",
                               "d - move right",
                               "you can use the arrow keys too",
                               "",
                               "8 - slower",
                               "9 - faster",
                               "0 - reset speed",
                               "p - pause the game"
                               "",
                               "press enter to go back to the menu .."};
  create_enter_dialog("CONTROLS", (const char *)controls, 11);
}


x86 assembly (clang, -O0):
<display_controls>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1f0,%rsp
lea    -0x1f0(%rbp),%rdi
lea    0xec7(%rip),%rsi
mov    $0x1e4,%edx
call   1030 <memcpy@plt>
lea    -0x1f0(%rbp),%rsi
lea    0x1093(%rip),%rdi
mov    $0xb,%edx
mov    $0x0,%al
call   1040 <create_enter_dialog@plt>
add    $0x1f0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<display_controls>:
push   %rbx
sub    $0x1f0,%rsp
lea    0xed1(%rip),%rsi
mov    %rsp,%rbx
mov    $0x1e4,%edx
mov    %rbx,%rdi
call   1030 <memcpy@plt>
lea    0x109e(%rip),%rdi
mov    %rbx,%rsi
mov    $0xb,%edx
xor    %eax,%eax
call   1040 <create_enter_dialog@plt>
add    $0x1f0,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.display_controls.controls = [11 x [44 x i8]] [[44 x i8] c"w - move up\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"a - move left\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"s - move down\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"d - move right\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"you can use the arrow keys too\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] zeroinitializer, [44 x i8] c"8 - slower\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"9 - faster\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"0 - reset speed\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"p - pause the game\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"press enter to go back to the menu ..\00\00\00\00\00\00\00"]
@.str = [9 x i8] c"CONTROLS\00"
define void @display_controls() {
%1 = alloca [11 x [44 x i8]]
%2 = bitcast [11 x [44 x i8]]* %1 to i8*
%3 = getelementptr inbounds [11 x [44 x i8]], [11 x [44 x i8]]* %1, i64 0, i64 0
%4 = bitcast [44 x i8]* %3 to i8*
%5 = call i32 (i8*, i8*, i32, ...) bitcast (i32 (...)* @create_enter_dialog to i32 (i8*, i8*, i32, ...)*)(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* %4, i32 11)
ret void
}

LLVM IR (-O2):
@__const.display_controls.controls = [11 x [44 x i8]] [[44 x i8] c"w - move up\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"a - move left\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"s - move down\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"d - move right\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"you can use the arrow keys too\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] zeroinitializer, [44 x i8] c"8 - slower\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"9 - faster\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"0 - reset speed\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"p - pause the game\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", [44 x i8] c"press enter to go back to the menu ..\00\00\00\00\00\00\00"]
@.str = [9 x i8] c"CONTROLS\00"
define void @display_controls() {
%1 = alloca [11 x [44 x i8]]
%2 = getelementptr inbounds [11 x [44 x i8]], [11 x [44 x i8]]* %1, i64 0, i64 0, i64 0
%3 = call i32 (i8*, i8*, i32, ...) bitcast (i32 (...)* @create_enter_dialog to i32 (i8*, i8*, i32, ...)*)(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* %2, i32 11)
ret void
}