#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*/ getchar();
int /*<<< orphan*/ printf(char *, ...);
int main() {
  int x;
  int y;
  int array[8][8];
  for (x = 0; x < 8; x++) {
    for (y = 0; y < 8; y++) {
      array[x][y] = x * y;
    }
  }
  printf("Array Indicies:\n");
  for (x = 0; x < 8; x++) {
    for (y = 0; y < 8; y++) {
      printf("[%d][%d]=%d", x, y, array[x][y]);
    }
    printf("\n");
  }
  getchar();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x110,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
cmpl   $0x8,-0x8(%rbp)
jge    1195 <main+0x75>
movl   $0x0,-0xc(%rbp)
cmpl   $0x8,-0xc(%rbp)
jge    1182 <main+0x62>
mov    -0x8(%rbp),%edx
imul   -0xc(%rbp),%edx
movslq -0x8(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0xc(%rbp),%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    114a <main+0x2a>
jmp    1187 <main+0x67>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1139 <main+0x19>
lea    0xe64(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x8(%rbp)
cmpl   $0x8,-0x8(%rbp)
jge    121c <main+0xfc>
movl   $0x0,-0xc(%rbp)
cmpl   $0x8,-0xc(%rbp)
jge    1200 <main+0xe0>
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
movslq -0x8(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0xc(%rbp),%rcx
mov    (%rax,%rcx,4),%ecx
lea    0xe26(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    11bb <main+0x9b>
lea    0xe08(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    11aa <main+0x8a>
mov    $0x0,%al
call   1040 <getchar@plt>
mov    -0x4(%rbp),%eax
add    $0x110,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %rbx
sub    $0x100,%rsp
xorps  %xmm0,%xmm0
movaps %xmm0,0x10(%rsp)
movaps %xmm0,(%rsp)
movl   $0x0,0x20(%rsp)
movaps 0xe99(%rip),%xmm0
movups %xmm0,0x24(%rsp)
movaps 0xe9d(%rip),%xmm0
movups %xmm0,0x34(%rsp)
movaps 0xea1(%rip),%xmm0
movups %xmm0,0x44(%rsp)
movaps 0xea5(%rip),%xmm0
movups %xmm0,0x54(%rsp)
movaps 0xea9(%rip),%xmm0
movups %xmm0,0x64(%rsp)
movaps 0xead(%rip),%xmm0
movups %xmm0,0x74(%rsp)
movaps 0xeb1(%rip),%xmm0
movups %xmm0,0x84(%rsp)
movaps 0xeb2(%rip),%xmm0
movups %xmm0,0x94(%rsp)
movaps 0xeb3(%rip),%xmm0
movups %xmm0,0xa4(%rsp)
movaps 0xeb4(%rip),%xmm0
movups %xmm0,0xb4(%rsp)
movaps 0xeb5(%rip),%xmm0
movups %xmm0,0xc4(%rsp)
movaps 0xeb6(%rip),%xmm0
movups %xmm0,0xd4(%rsp)
movaps 0xeb7(%rip),%xmm0
movups %xmm0,0xe4(%rsp)
movabs $0x2a00000023,%rax
mov    %rax,0xf4(%rsp)
movl   $0x31,0xfc(%rsp)
lea    0xea7(%rip),%rdi
call   1040 <puts@plt>
lea    0x1c(%rsp),%r15
lea    0xe8a(%rip),%r14
xor    %ebx,%ebx
nopl   0x0(%rax,%rax,1)
mov    -0x1c(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
xor    %edx,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    -0x18(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x1,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    -0x14(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x2,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    -0x10(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x3,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    -0xc(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x4,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    -0x8(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x5,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    -0x4(%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x6,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    (%r15),%ecx
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x7,%edx
xor    %eax,%eax
call   1050 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x1,%rbx
add    $0x20,%r15
cmp    $0x8,%rbx
jne    1250 <main+0x110>
xor    %eax,%eax
call   1060 <getchar@plt>
xor    %eax,%eax
add    $0x100,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [17 x i8] c"Array Indicies:\0A\00"
@.str.1 = [12 x i8] c"[%d][%d]=%d\00"
@.str.2 = [2 x i8] c"\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca [8 x [8 x i32]]
store i32 0, i32* %1
store i32 0, i32* %2
br label %5
5: ; preds = %26, %0
%6 = load i32, i32* %2
%7 = icmp slt i32 %6, 8
br i1 %7, label %8, label %29
8: ; preds = %5
store i32 0, i32* %3
br label %9
9: ; preds = %22, %8
%10 = load i32, i32* %3
%11 = icmp slt i32 %10, 8
br i1 %11, label %12, label %25
12: ; preds = %9
%13 = load i32, i32* %2
%14 = load i32, i32* %3
%15 = mul nsw i32 %13, %14
%16 = load i32, i32* %2
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %4, i64 0, i64 %17
%19 = load i32, i32* %3
%20 = sext i32 %19 to i64
%21 = getelementptr inbounds [8 x i32], [8 x i32]* %18, i64 0, i64 %20
store i32 %15, i32* %21
br label %22
22: ; preds = %12
%23 = load i32, i32* %3
%24 = add nsw i32 %23, 1
store i32 %24, i32* %3
br label %9
25: ; preds = %9
br label %26
26: ; preds = %25
%27 = load i32, i32* %2
%28 = add nsw i32 %27, 1
store i32 %28, i32* %2
br label %5
29: ; preds = %5
%30 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %2
br label %31
31: ; preds = %54, %29
%32 = load i32, i32* %2
%33 = icmp slt i32 %32, 8
br i1 %33, label %34, label %57
34: ; preds = %31
store i32 0, i32* %3
br label %35
35: ; preds = %49, %34
%36 = load i32, i32* %3
%37 = icmp slt i32 %36, 8
br i1 %37, label %38, label %52
38: ; preds = %35
%39 = load i32, i32* %2
%40 = load i32, i32* %3
%41 = load i32, i32* %2
%42 = sext i32 %41 to i64
%43 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %4, i64 0, i64 %42
%44 = load i32, i32* %3
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [8 x i32], [8 x i32]* %43, i64 0, i64 %45
%47 = load i32, i32* %46
%48 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %39, i32 %40, i32 %47)
br label %49
49: ; preds = %38
%50 = load i32, i32* %3
%51 = add nsw i32 %50, 1
store i32 %51, i32* %3
br label %35
52: ; preds = %35
%53 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %54
54: ; preds = %52
%55 = load i32, i32* %2
%56 = add nsw i32 %55, 1
store i32 %56, i32* %2
br label %31
57: ; preds = %31
%58 = call i32 (...) @getchar()
%59 = load i32, i32* %1
ret i32 %59
}

LLVM IR (-O2):
@.str.1 = [12 x i8] c"[%d][%d]=%d\00"
@str = [16 x i8] c"Array Indicies:\00"
define i32 @main() {
%1 = alloca [8 x [8 x i32]]
%2 = bitcast [8 x [8 x i32]]* %1 to i8*
%3 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 1, i64 1
%4 = bitcast [8 x [8 x i32]]* %1 to i8*
%5 = bitcast i32* %3 to <4 x i32>*
store <4 x i32> <i32 1, i32 2, i32 3, i32 4>, <4 x i32>* %5
%6 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 1, i64 5
%7 = bitcast i32* %6 to <4 x i32>*
store <4 x i32> <i32 5, i32 6, i32 7, i32 0>, <4 x i32>* %7
%8 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 2, i64 1
%9 = bitcast i32* %8 to <4 x i32>*
store <4 x i32> <i32 2, i32 4, i32 6, i32 8>, <4 x i32>* %9
%10 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 2, i64 5
%11 = bitcast i32* %10 to <4 x i32>*
store <4 x i32> <i32 10, i32 12, i32 14, i32 0>, <4 x i32>* %11
%12 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 3, i64 1
%13 = bitcast i32* %12 to <4 x i32>*
store <4 x i32> <i32 3, i32 6, i32 9, i32 12>, <4 x i32>* %13
%14 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 3, i64 5
%15 = bitcast i32* %14 to <4 x i32>*
store <4 x i32> <i32 15, i32 18, i32 21, i32 0>, <4 x i32>* %15
%16 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 4, i64 1
%17 = bitcast i32* %16 to <4 x i32>*
store <4 x i32> <i32 4, i32 8, i32 12, i32 16>, <4 x i32>* %17
%18 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 4, i64 5
%19 = bitcast i32* %18 to <4 x i32>*
store <4 x i32> <i32 20, i32 24, i32 28, i32 0>, <4 x i32>* %19
%20 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 5, i64 1
%21 = bitcast i32* %20 to <4 x i32>*
store <4 x i32> <i32 5, i32 10, i32 15, i32 20>, <4 x i32>* %21
%22 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 5, i64 5
%23 = bitcast i32* %22 to <4 x i32>*
store <4 x i32> <i32 25, i32 30, i32 35, i32 0>, <4 x i32>* %23
%24 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 6, i64 1
%25 = bitcast i32* %24 to <4 x i32>*
store <4 x i32> <i32 6, i32 12, i32 18, i32 24>, <4 x i32>* %25
%26 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 6, i64 5
%27 = bitcast i32* %26 to <4 x i32>*
store <4 x i32> <i32 30, i32 36, i32 42, i32 0>, <4 x i32>* %27
%28 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 7, i64 1
%29 = bitcast i32* %28 to <4 x i32>*
store <4 x i32> <i32 7, i32 14, i32 21, i32 28>, <4 x i32>* %29
%30 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 7, i64 5
store i32 35, i32* %30
%31 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 7, i64 6
store i32 42, i32* %31
%32 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 7, i64 7
store i32 49, i32* %32
%33 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str, i64 0, i64 0))
br label %34
34: ; preds = %0, %34
%35 = phi i64 [ 0, %0 ], [ %62, %34 ]
%36 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 0
%37 = load i32, i32* %36
%38 = trunc i64 %35 to i32
%39 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 0, i32 %37)
%40 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 1
%41 = load i32, i32* %40
%42 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 1, i32 %41)
%43 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 2
%44 = load i32, i32* %43
%45 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 2, i32 %44)
%46 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 3
%47 = load i32, i32* %46
%48 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 3, i32 %47)
%49 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 4
%50 = load i32, i32* %49
%51 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 4, i32 %50)
%52 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 5
%53 = load i32, i32* %52
%54 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 5, i32 %53)
%55 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 6
%56 = load i32, i32* %55
%57 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 6, i32 %56)
%58 = getelementptr inbounds [8 x [8 x i32]], [8 x [8 x i32]]* %1, i64 0, i64 %35, i64 7
%59 = load i32, i32* %58
%60 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %38, i32 7, i32 %59)
%61 = tail call i32 @putchar(i32 10)
%62 = add nuw nsw i64 %35, 1
%63 = icmp eq i64 %62, 8
br i1 %63, label %64, label %34
64: ; preds = %34
%65 = tail call i32 (...) @getchar()
ret i32 0
}