#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*/ print_int_array(int *, int);
int /*<<< orphan*/ printf(char *, long double);
int main() {
  unsigned int v0[10];
  int v1[5] = {1, 2, 3, 4, 5};
  long double v2[10] = {1.2, 2.3};
  double m0[2][3] = {{1.1, 1.2, 1.3}, {2.2, 2.3, 2.4}};
  printf("%d\n", v1[2]);
  printf("%d\n", *(v1 + 2));
  printf("%lf\n", v2[5]);
  print_int_array(v1, 4);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xee8(%rip),%eax
mov    %eax,-0x40(%rbp)
movaps 0xece(%rip),%xmm0
movaps %xmm0,-0x50(%rbp)
xorps  %xmm0,%xmm0
movaps %xmm0,-0x60(%rbp)
movaps %xmm0,-0x70(%rbp)
movaps %xmm0,-0x80(%rbp)
movaps %xmm0,-0x90(%rbp)
movaps %xmm0,-0xa0(%rbp)
movaps %xmm0,-0xb0(%rbp)
movaps %xmm0,-0xc0(%rbp)
movaps %xmm0,-0xd0(%rbp)
movaps %xmm0,-0xe0(%rbp)
movaps %xmm0,-0xf0(%rbp)
fldl   0xe74(%rip)
fstpt  -0xf0(%rbp)
fldl   0xe70(%rip)
fstpt  -0xe0(%rbp)
movaps %xmm0,-0x100(%rbp)
movaps %xmm0,-0x110(%rbp)
movaps %xmm0,-0x120(%rbp)
movabs $0x3ff199999999999a,%rax
99 f1 3f
mov    %rax,-0x120(%rbp)
movabs $0x3ff3333333333333,%rax
33 f3 3f
mov    %rax,-0x118(%rbp)
movabs $0x3ff4cccccccccccd,%rax
cc f4 3f
mov    %rax,-0x110(%rbp)
movabs $0x400199999999999a,%rax
99 01 40
mov    %rax,-0x108(%rbp)
movabs $0x4002666666666666,%rax
66 02 40
mov    %rax,-0x100(%rbp)
movabs $0x4003333333333333,%rax
33 03 40
mov    %rax,-0xf8(%rbp)
mov    -0x48(%rbp),%eax
mov    %eax,-0x128(%rbp)
fildl  -0x128(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
lea    0xdf0(%rip),%rdi
mov    %rdi,-0x130(%rbp)
call   1030 <printf@plt>
mov    -0x130(%rbp),%rdi
mov    -0x48(%rbp),%eax
mov    %eax,-0x124(%rbp)
fildl  -0x124(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
call   1030 <printf@plt>
fldt   -0xa0(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
lea    0xdb6(%rip),%rdi
call   1030 <printf@plt>
lea    -0x50(%rbp),%rdi
mov    $0x4,%esi
call   1040 <print_int_array@plt>
xor    %eax,%eax
add    $0x140,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x40,%rsp
mov    0xef5(%rip),%eax
mov    %eax,0x30(%rsp)
movaps 0xeda(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
flds   0xebf(%rip)
fld    %st(0)
fstpt  0x14(%rsp)
fstpt  (%rsp)
lea    0xed3(%rip),%rbx
mov    %rbx,%rdi
call   1030 <printf@plt>
fldt   0x14(%rsp)
fstpt  (%rsp)
mov    %rbx,%rdi
call   1030 <printf@plt>
fldz
fstpt  (%rsp)
lea    0xeb4(%rip),%rdi
call   1030 <printf@plt>
lea    0x20(%rsp),%rdi
mov    $0x4,%esi
call   1040 <print_int_array@plt>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.main.v1 = [5 x i32] [i32 1, i32 2, i32 3, i32 4, i32 5]
@.str = [4 x i8] c"%d\0A\00"
@.str.1 = [5 x i8] c"%lf\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [10 x i32]
%3 = alloca [5 x i32]
%4 = alloca [10 x x86_fp80]
%5 = alloca [2 x [3 x double]]
store i32 0, i32* %1
%6 = bitcast [5 x i32]* %3 to i8*
%7 = bitcast [10 x x86_fp80]* %4 to i8*
%8 = bitcast i8* %7 to <{ x86_fp80, x86_fp80, [8 x x86_fp80] }>*
%9 = getelementptr inbounds <{ x86_fp80, x86_fp80, [8 x x86_fp80] }>, <{ x86_fp80, x86_fp80, [8 x x86_fp80] }>* %8, i32 0, i32 0
store x86_fp80 0xK3FFF9999999999999800, x86_fp80* %9
%10 = getelementptr inbounds <{ x86_fp80, x86_fp80, [8 x x86_fp80] }>, <{ x86_fp80, x86_fp80, [8 x x86_fp80] }>* %8, i32 0, i32 1
store x86_fp80 0xK40009333333333333000, x86_fp80* %10
%11 = bitcast [2 x [3 x double]]* %5 to i8*
%12 = bitcast i8* %11 to [2 x [3 x double]]*
%13 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %12, i32 0, i32 0
%14 = getelementptr inbounds [3 x double], [3 x double]* %13, i32 0, i32 0
store double 1.100000e+00, double* %14
%15 = getelementptr inbounds [3 x double], [3 x double]* %13, i32 0, i32 1
store double 1.200000e+00, double* %15
%16 = getelementptr inbounds [3 x double], [3 x double]* %13, i32 0, i32 2
store double 1.300000e+00, double* %16
%17 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %12, i32 0, i32 1
%18 = getelementptr inbounds [3 x double], [3 x double]* %17, i32 0, i32 0
store double 2.200000e+00, double* %18
%19 = getelementptr inbounds [3 x double], [3 x double]* %17, i32 0, i32 1
store double 2.300000e+00, double* %19
%20 = getelementptr inbounds [3 x double], [3 x double]* %17, i32 0, i32 2
store double 2.400000e+00, double* %20
%21 = getelementptr inbounds [5 x i32], [5 x i32]* %3, i64 0, i64 2
%22 = load i32, i32* %21
%23 = sitofp i32 %22 to x86_fp80
%24 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), x86_fp80 %23)
%25 = getelementptr inbounds [5 x i32], [5 x i32]* %3, i64 0, i64 0
%26 = getelementptr inbounds i32, i32* %25, i64 2
%27 = load i32, i32* %26
%28 = sitofp i32 %27 to x86_fp80
%29 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), x86_fp80 %28)
%30 = getelementptr inbounds [10 x x86_fp80], [10 x x86_fp80]* %4, i64 0, i64 5
%31 = load x86_fp80, x86_fp80* %30
%32 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), x86_fp80 %31)
%33 = getelementptr inbounds [5 x i32], [5 x i32]* %3, i64 0, i64 0
%34 = call i32 @print_int_array(i32* %33, i32 4)
ret i32 0
}

LLVM IR (-O2):
@__const.main.v1 = [5 x i32] [i32 1, i32 2, i32 3, i32 4, i32 5]
@.str = [4 x i8] c"%d\0A\00"
@.str.1 = [5 x i8] c"%lf\0A\00"
define i32 @main() {
%1 = alloca [5 x i32]
%2 = bitcast [5 x i32]* %1 to i8*
%3 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), x86_fp80 0xK4000C000000000000000)
%4 = getelementptr inbounds [5 x i32], [5 x i32]* %1, i64 0, i64 0
%5 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), x86_fp80 0xK4000C000000000000000)
%6 = tail call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), x86_fp80 0xK00000000000000000000)
%7 = call i32 @print_int_array(i32* %4, i32 4)
ret i32 0
}