#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*/ assert(int /*<<< orphan*/, char *);
int main_test() {
  int n0 = 455;
  int n1 = 387;
  int n2 = 59;
  int i = 0;
  int k = 0;
  while (i < n0) {
    i++;
    k++;
  }
  i = 0;
  while (i < n1) {
    i++;
    k++;
  }
  i = 0;
  while (i < n2) {
    i++;
    k++;
  }
  i = 0;
  while (i < n2) {
    i++;
    k--;
  }
  i = 0;
  while (i < n1) {
    i++;
    k--;
  }
  i = 0;
  while (i < n0) {
    if (!(k > 0))
      goto ERROR;
    i++;
    k--;
  }
ERROR:
  assert(0, "ERROR");
  return 0;
}


x86 assembly (clang, -O0):
<main_test>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x1c7,-0x4(%rbp)
movl   $0x183,-0x8(%rbp)
movl   $0x3b,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    115e <main_test+0x4e>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    113b <main_test+0x2b>
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1188 <main_test+0x78>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1165 <main_test+0x55>
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    11b2 <main_test+0xa2>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    118f <main_test+0x7f>
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    11dc <main_test+0xcc>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x14(%rbp)
jmp    11b9 <main_test+0xa9>
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1206 <main_test+0xf6>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x14(%rbp)
jmp    11e3 <main_test+0xd3>
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    123f <main_test+0x12f>
cmpl   $0x0,-0x14(%rbp)
jg     1228 <main_test+0x118>
jmp    1244 <main_test+0x134>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x14(%rbp)
jmp    120d <main_test+0xfd>
jmp    1244 <main_test+0x134>
xor    %edi,%edi
lea    0xdb3(%rip),%rsi
call   1030 <assert@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main_test>:
push   %rax
lea    0xee8(%rip),%rsi
xor    %edi,%edi
call   1030 <assert@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"ERROR\00"
define i32 @main_test() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 455, i32* %1
store i32 387, i32* %2
store i32 59, i32* %3
store i32 0, i32* %4
store i32 0, i32* %5
br label %6
6: ; preds = %10, %0
%7 = load i32, i32* %4
%8 = load i32, i32* %1
%9 = icmp slt i32 %7, %8
br i1 %9, label %10, label %15
10: ; preds = %6
%11 = load i32, i32* %4
%12 = add nsw i32 %11, 1
store i32 %12, i32* %4
%13 = load i32, i32* %5
%14 = add nsw i32 %13, 1
store i32 %14, i32* %5
br label %6
15: ; preds = %6
store i32 0, i32* %4
br label %16
16: ; preds = %20, %15
%17 = load i32, i32* %4
%18 = load i32, i32* %2
%19 = icmp slt i32 %17, %18
br i1 %19, label %20, label %25
20: ; preds = %16
%21 = load i32, i32* %4
%22 = add nsw i32 %21, 1
store i32 %22, i32* %4
%23 = load i32, i32* %5
%24 = add nsw i32 %23, 1
store i32 %24, i32* %5
br label %16
25: ; preds = %16
store i32 0, i32* %4
br label %26
26: ; preds = %30, %25
%27 = load i32, i32* %4
%28 = load i32, i32* %3
%29 = icmp slt i32 %27, %28
br i1 %29, label %30, label %35
30: ; preds = %26
%31 = load i32, i32* %4
%32 = add nsw i32 %31, 1
store i32 %32, i32* %4
%33 = load i32, i32* %5
%34 = add nsw i32 %33, 1
store i32 %34, i32* %5
br label %26
35: ; preds = %26
store i32 0, i32* %4
br label %36
36: ; preds = %40, %35
%37 = load i32, i32* %4
%38 = load i32, i32* %3
%39 = icmp slt i32 %37, %38
br i1 %39, label %40, label %45
40: ; preds = %36
%41 = load i32, i32* %4
%42 = add nsw i32 %41, 1
store i32 %42, i32* %4
%43 = load i32, i32* %5
%44 = add nsw i32 %43, -1
store i32 %44, i32* %5
br label %36
45: ; preds = %36
store i32 0, i32* %4
br label %46
46: ; preds = %50, %45
%47 = load i32, i32* %4
%48 = load i32, i32* %2
%49 = icmp slt i32 %47, %48
br i1 %49, label %50, label %55
50: ; preds = %46
%51 = load i32, i32* %4
%52 = add nsw i32 %51, 1
store i32 %52, i32* %4
%53 = load i32, i32* %5
%54 = add nsw i32 %53, -1
store i32 %54, i32* %5
br label %46
55: ; preds = %46
store i32 0, i32* %4
br label %56
56: ; preds = %64, %55
%57 = load i32, i32* %4
%58 = load i32, i32* %1
%59 = icmp slt i32 %57, %58
br i1 %59, label %60, label %69
60: ; preds = %56
%61 = load i32, i32* %5
%62 = icmp sgt i32 %61, 0
br i1 %62, label %64, label %63
63: ; preds = %60
br label %70
64: ; preds = %60
%65 = load i32, i32* %4
%66 = add nsw i32 %65, 1
store i32 %66, i32* %4
%67 = load i32, i32* %5
%68 = add nsw i32 %67, -1
store i32 %68, i32* %5
br label %56
69: ; preds = %56
br label %70
70: ; preds = %69, %63
%71 = call i32 @assert(i32 0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"ERROR\00"
define i32 @main_test() {
%1 = tail call i32 @assert(i32 0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 0
}