int main() {
  unsigned int SIZE = 3;
  int i = 38;
  int j = 38;
  int k = 38;
  int key = 38;
  int v[SIZE];
  for (j = 1; j < SIZE; j++) {
    key = -2139095040;
    i = 0;
    while ((i >= 0) && (v[i] > key)) {
      if (i < 2) {
        v[i + 1] = v[i];
      }
      i = -1;
    }
    v[i + 1] = key;
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x3,-0x8(%rbp)
movl   $0x26,-0xc(%rbp)
movl   $0x26,-0x10(%rbp)
movl   $0x26,-0x14(%rbp)
movl   $0x26,-0x18(%rbp)
mov    -0x8(%rbp),%eax
mov    %rsp,%rcx
mov    %rcx,-0x20(%rbp)
lea    0xf(,%rax,4),%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x30(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x28(%rbp)
movl   $0x1,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0x8(%rbp),%eax
jae    11fb <main+0xfb>
movl   $0x80800000,-0x18(%rbp)
movl   $0x0,-0xc(%rbp)
xor    %eax,%eax
cmpl   $0x0,-0xc(%rbp)
mov    %al,-0x31(%rbp)
jl     119d <main+0x9d>
mov    -0x30(%rbp),%rax
movslq -0xc(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
cmp    -0x18(%rbp),%eax
setg   %al
mov    %al,-0x31(%rbp)
mov    -0x31(%rbp),%al
test   $0x1,%al
jne    11ad <main+0xad>
jmp    11da <main+0xda>
cmpl   $0x2,-0xc(%rbp)
jge    11ce <main+0xce>
mov    -0x30(%rbp),%rax
movslq -0xc(%rbp),%rcx
mov    (%rax,%rcx,4),%edx
mov    -0xc(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
mov    %edx,(%rax,%rcx,4)
movl   $0xffffffff,-0xc(%rbp)
jmp    117a <main+0x7a>
mov    -0x30(%rbp),%rax
mov    -0x18(%rbp),%edx
mov    -0xc(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1160 <main+0x60>
movl   $0x0,-0x4(%rbp)
mov    -0x20(%rbp),%rax
mov    %rax,%rsp
mov    -0x4(%rbp),%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
xor    %eax,%eax
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i8*
%8 = alloca i64
store i32 0, i32* %1
store i32 3, i32* %2
store i32 38, i32* %3
store i32 38, i32* %4
store i32 38, i32* %5
store i32 38, i32* %6
%9 = load i32, i32* %2
%10 = zext i32 %9 to i64
%11 = call i8* @llvm.stacksave()
store i8* %11, i8** %7
%12 = alloca i32, i64 %10
store i64 %10, i64* %8
store i32 1, i32* %4
br label %13
13: ; preds = %49, %0
%14 = load i32, i32* %4
%15 = load i32, i32* %2
%16 = icmp ult i32 %14, %15
br i1 %16, label %17, label %52
17: ; preds = %13
store i32 -2139095040, i32* %6
store i32 0, i32* %3
br label %18
18: ; preds = %42, %17
%19 = load i32, i32* %3
%20 = icmp sge i32 %19, 0
br i1 %20, label %21, label %28
21: ; preds = %18
%22 = load i32, i32* %3
%23 = sext i32 %22 to i64
%24 = getelementptr inbounds i32, i32* %12, i64 %23
%25 = load i32, i32* %24
%26 = load i32, i32* %6
%27 = icmp sgt i32 %25, %26
br label %28
28: ; preds = %21, %18
%29 = phi i1 [ false, %18 ], [ %27, %21 ]
br i1 %29, label %30, label %43
30: ; preds = %28
%31 = load i32, i32* %3
%32 = icmp slt i32 %31, 2
br i1 %32, label %33, label %42
33: ; preds = %30
%34 = load i32, i32* %3
%35 = sext i32 %34 to i64
%36 = getelementptr inbounds i32, i32* %12, i64 %35
%37 = load i32, i32* %36
%38 = load i32, i32* %3
%39 = add nsw i32 %38, 1
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds i32, i32* %12, i64 %40
store i32 %37, i32* %41
br label %42
42: ; preds = %33, %30
store i32 -1, i32* %3
br label %18
43: ; preds = %28
%44 = load i32, i32* %6
%45 = load i32, i32* %3
%46 = add nsw i32 %45, 1
%47 = sext i32 %46 to i64
%48 = getelementptr inbounds i32, i32* %12, i64 %47
store i32 %44, i32* %48
br label %49
49: ; preds = %43
%50 = load i32, i32* %4
%51 = add nsw i32 %50, 1
store i32 %51, i32* %4
br label %13
52: ; preds = %13
store i32 0, i32* %1
%53 = load i8*, i8** %7
%54 = load i32, i32* %1
ret i32 %54
}

LLVM IR (-O2):
define i32 @main() {
ret i32 0
}