#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, ...);
int main(void) {
  char dict[][15] = {{"aword"}, {"bword"}, {"cword"}};
  char dict2[] = "somestring";
  int i = {0};
  int j = 3.2;
  int k = {3.2};
  printf("j = %i\n", j);
  printf("k = %i\n", k);
  for (i = 0; i < 3; i++) {
    printf("dict[%i] = \"%s\"\n", i, dict[i]);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x40(%rbp),%rdi
lea    0xec6(%rip),%rsi
mov    $0x2d,%edx
call   1040 <memcpy@plt>
mov    0xee2(%rip),%rax
mov    %rax,-0x4b(%rbp)
mov    0xedf(%rip),%ax
mov    %ax,-0x43(%rbp)
mov    0xed7(%rip),%al
mov    %al,-0x41(%rbp)
movl   $0x0,-0x50(%rbp)
movl   $0x3,-0x54(%rbp)
movl   $0x3,-0x58(%rbp)
mov    -0x54(%rbp),%esi
lea    0xeb6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x58(%rbp),%esi
lea    0xead(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x50(%rbp)
cmpl   $0x3,-0x50(%rbp)
jge    11d9 <main+0xb9>
mov    -0x50(%rbp),%esi
movslq -0x50(%rbp),%rax
lea    -0x40(%rbp),%rdx
imul   $0xf,%rax,%rax
add    %rax,%rdx
lea    0xe84(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x50(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x50(%rbp)
jmp    11a1 <main+0x81>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x30,%rsp
movups 0xf01(%rip),%xmm0
movups %xmm0,0x1d(%rsp)
movaps 0xee8(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xecc(%rip),%xmm0
movaps %xmm0,(%rsp)
lea    0xeee(%rip),%rdi
mov    $0x3,%esi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xee3(%rip),%rdi
mov    $0x3,%esi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xed8(%rip),%rbx
mov    %rsp,%rdx
mov    %rbx,%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xf(%rsp),%rdx
mov    %rbx,%rdi
mov    $0x1,%esi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0x1e(%rsp),%rdx
mov    %rbx,%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.main.dict = [3 x [15 x i8]] [[15 x i8] c"aword\00\00\00\00\00\00\00\00\00\00", [15 x i8] c"bword\00\00\00\00\00\00\00\00\00\00", [15 x i8] c"cword\00\00\00\00\00\00\00\00\00\00"]
@__const.main.dict2 = [11 x i8] c"somestring\00"
@.str = [8 x i8] c"j = %i\0A\00"
@.str.1 = [8 x i8] c"k = %i\0A\00"
@.str.2 = [17 x i8] c"dict[%i] = \22%s\22\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [3 x [15 x i8]]
%3 = alloca [11 x i8]
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 0, i32* %1
%7 = bitcast [3 x [15 x i8]]* %2 to i8*
%8 = bitcast [11 x i8]* %3 to i8*
store i32 0, i32* %4
store i32 3, i32* %5
store i32 3, i32* %6
%9 = load i32, i32* %5
%10 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 %9)
%11 = load i32, i32* %6
%12 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i32 %11)
store i32 0, i32* %4
br label %13
13: ; preds = %23, %0
%14 = load i32, i32* %4
%15 = icmp slt i32 %14, 3
br i1 %15, label %16, label %26
16: ; preds = %13
%17 = load i32, i32* %4
%18 = load i32, i32* %4
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds [3 x [15 x i8]], [3 x [15 x i8]]* %2, i64 0, i64 %19
%21 = getelementptr inbounds [15 x i8], [15 x i8]* %20, i64 0, i64 0
%22 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i32 %17, i8* %21)
br label %23
23: ; preds = %16
%24 = load i32, i32* %4
%25 = add nsw i32 %24, 1
store i32 %25, i32* %4
br label %13
26: ; preds = %13
ret i32 0
}

LLVM IR (-O2):
@__const.main.dict = [3 x [15 x i8]] [[15 x i8] c"aword\00\00\00\00\00\00\00\00\00\00", [15 x i8] c"bword\00\00\00\00\00\00\00\00\00\00", [15 x i8] c"cword\00\00\00\00\00\00\00\00\00\00"]
@.str = [8 x i8] c"j = %i\0A\00"
@.str.1 = [8 x i8] c"k = %i\0A\00"
@.str.2 = [17 x i8] c"dict[%i] = \22%s\22\0A\00"
define i32 @main() {
%1 = alloca [3 x [15 x i8]]
%2 = getelementptr inbounds [3 x [15 x i8]], [3 x [15 x i8]]* %1, i64 0, i64 0, i64 0
%3 = tail call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 3)
%4 = tail call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i32 3)
%5 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i32 0, i8* %2)
%6 = getelementptr inbounds [3 x [15 x i8]], [3 x [15 x i8]]* %1, i64 0, i64 1, i64 0
%7 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i32 1, i8* %6)
%8 = getelementptr inbounds [3 x [15 x i8]], [3 x [15 x i8]]* %1, i64 0, i64 2, i64 0
%9 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i32 2, i8* %8)
ret i32 0
}