#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*/ printn(int);
int /*<<< orphan*/ putchar(char);
void main() {
  int x;
  for (x = -6; x != 7; x++) {
    if (x)
      printn(x);
  }
  putchar('\n');
  for (x = -6; x != 7; x++) {
    if (x)
      printn(x);
    else
      printn(45);
  }
  putchar('\n');
  x = -6;
  while (x) {
    printn(x);
    x++;
  }
  putchar('\n');
  x = -6;
  do {
    printn(x);
    x++;
  } while (x);
  putchar('\n');
  for (x = -6; x; x++) {
    printn(x);
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0xfffffffa,-0x4(%rbp)
cmpl   $0x7,-0x4(%rbp)
je     115e <main+0x3e>
cmpl   $0x0,-0x4(%rbp)
je     114b <main+0x2b>
mov    -0x4(%rbp),%edi
call   1030 <printn@plt>
jmp    1150 <main+0x30>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    112f <main+0xf>
mov    $0xa,%edi
call   1040 <putchar@plt>
movl   $0xfffffffa,-0x4(%rbp)
cmpl   $0x7,-0x4(%rbp)
je     11ad <main+0x8d>
cmpl   $0x0,-0x4(%rbp)
je     1190 <main+0x70>
mov    -0x4(%rbp),%edi
call   1030 <printn@plt>
jmp    119a <main+0x7a>
mov    $0x2d,%edi
call   1030 <printn@plt>
jmp    119f <main+0x7f>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    116f <main+0x4f>
mov    $0xa,%edi
call   1040 <putchar@plt>
movl   $0xfffffffa,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
je     11de <main+0xbe>
mov    -0x4(%rbp),%edi
call   1030 <printn@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    11be <main+0x9e>
mov    $0xa,%edi
call   1040 <putchar@plt>
movl   $0xfffffffa,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1030 <printn@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    11ef <main+0xcf>
mov    $0xa,%edi
call   1040 <putchar@plt>
movl   $0xfffffffa,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
je     123b <main+0x11b>
mov    -0x4(%rbp),%edi
call   1030 <printn@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    121b <main+0xfb>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0xfffffffa,%edi
call   1030 <printn@plt>
mov    $0xfffffffb,%edi
call   1030 <printn@plt>
mov    $0xfffffffc,%edi
call   1030 <printn@plt>
mov    $0xfffffffd,%edi
call   1030 <printn@plt>
mov    $0xfffffffe,%edi
call   1030 <printn@plt>
mov    $0xffffffff,%edi
call   1030 <printn@plt>
mov    $0x1,%edi
call   1030 <printn@plt>
mov    $0x2,%edi
call   1030 <printn@plt>
mov    $0x3,%edi
call   1030 <printn@plt>
mov    $0x4,%edi
call   1030 <printn@plt>
mov    $0x5,%edi
call   1030 <printn@plt>
mov    $0x6,%edi
call   1030 <printn@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    $0xfffffffa,%edi
call   1030 <printn@plt>
mov    $0xfffffffb,%edi
call   1030 <printn@plt>
mov    $0xfffffffc,%edi
call   1030 <printn@plt>
mov    $0xfffffffd,%edi
call   1030 <printn@plt>
mov    $0xfffffffe,%edi
call   1030 <printn@plt>
mov    $0xffffffff,%edi
call   1030 <printn@plt>
mov    $0x2d,%edi
call   1030 <printn@plt>
mov    $0x1,%edi
call   1030 <printn@plt>
mov    $0x2,%edi
call   1030 <printn@plt>
mov    $0x3,%edi
call   1030 <printn@plt>
mov    $0x4,%edi
call   1030 <printn@plt>
mov    $0x5,%edi
call   1030 <printn@plt>
mov    $0x6,%edi
call   1030 <printn@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    $0xfffffffa,%edi
call   1030 <printn@plt>
mov    $0xfffffffb,%edi
call   1030 <printn@plt>
mov    $0xfffffffc,%edi
call   1030 <printn@plt>
mov    $0xfffffffd,%edi
call   1030 <printn@plt>
mov    $0xfffffffe,%edi
call   1030 <printn@plt>
mov    $0xffffffff,%edi
call   1030 <printn@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    $0xfffffffa,%edi
call   1030 <printn@plt>
mov    $0xfffffffb,%edi
call   1030 <printn@plt>
mov    $0xfffffffc,%edi
call   1030 <printn@plt>
mov    $0xfffffffd,%edi
call   1030 <printn@plt>
mov    $0xfffffffe,%edi
call   1030 <printn@plt>
mov    $0xffffffff,%edi
call   1030 <printn@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    $0xfffffffa,%edi
call   1030 <printn@plt>
mov    $0xfffffffb,%edi
call   1030 <printn@plt>
mov    $0xfffffffc,%edi
call   1030 <printn@plt>
mov    $0xfffffffd,%edi
call   1030 <printn@plt>
mov    $0xfffffffe,%edi
call   1030 <printn@plt>
mov    $0xffffffff,%edi
pop    %rax
jmp    1030 <printn@plt>

LLVM IR (-O0):
define void @main() {
%1 = alloca i32
store i32 -6, i32* %1
br label %2
2: ; preds = %12, %0
%3 = load i32, i32* %1
%4 = icmp ne i32 %3, 7
br i1 %4, label %5, label %15
5: ; preds = %2
%6 = load i32, i32* %1
%7 = icmp ne i32 %6, 0
br i1 %7, label %8, label %11
8: ; preds = %5
%9 = load i32, i32* %1
%10 = call i32 @printn(i32 %9)
br label %11
11: ; preds = %8, %5
br label %12
12: ; preds = %11
%13 = load i32, i32* %1
%14 = add nsw i32 %13, 1
store i32 %14, i32* %1
br label %2
15: ; preds = %2
%16 = call i32 @putchar(i8 signext 10)
store i32 -6, i32* %1
br label %17
17: ; preds = %29, %15
%18 = load i32, i32* %1
%19 = icmp ne i32 %18, 7
br i1 %19, label %20, label %32
20: ; preds = %17
%21 = load i32, i32* %1
%22 = icmp ne i32 %21, 0
br i1 %22, label %23, label %26
23: ; preds = %20
%24 = load i32, i32* %1
%25 = call i32 @printn(i32 %24)
br label %28
26: ; preds = %20
%27 = call i32 @printn(i32 45)
br label %28
28: ; preds = %26, %23
br label %29
29: ; preds = %28
%30 = load i32, i32* %1
%31 = add nsw i32 %30, 1
store i32 %31, i32* %1
br label %17
32: ; preds = %17
%33 = call i32 @putchar(i8 signext 10)
store i32 -6, i32* %1
br label %34
34: ; preds = %37, %32
%35 = load i32, i32* %1
%36 = icmp ne i32 %35, 0
br i1 %36, label %37, label %42
37: ; preds = %34
%38 = load i32, i32* %1
%39 = call i32 @printn(i32 %38)
%40 = load i32, i32* %1
%41 = add nsw i32 %40, 1
store i32 %41, i32* %1
br label %34
42: ; preds = %34
%43 = call i32 @putchar(i8 signext 10)
store i32 -6, i32* %1
br label %44
44: ; preds = %49, %42
%45 = load i32, i32* %1
%46 = call i32 @printn(i32 %45)
%47 = load i32, i32* %1
%48 = add nsw i32 %47, 1
store i32 %48, i32* %1
br label %49
49: ; preds = %44
%50 = load i32, i32* %1
%51 = icmp ne i32 %50, 0
br i1 %51, label %44, label %52
52: ; preds = %49
%53 = call i32 @putchar(i8 signext 10)
store i32 -6, i32* %1
br label %54
54: ; preds = %60, %52
%55 = load i32, i32* %1
%56 = icmp ne i32 %55, 0
br i1 %56, label %57, label %63
57: ; preds = %54
%58 = load i32, i32* %1
%59 = call i32 @printn(i32 %58)
br label %60
60: ; preds = %57
%61 = load i32, i32* %1
%62 = add nsw i32 %61, 1
store i32 %62, i32* %1
br label %54
63: ; preds = %54
ret void
}

LLVM IR (-O2):
define void @main() {
%1 = tail call i32 @printn(i32 -6)
%2 = tail call i32 @printn(i32 -5)
%3 = tail call i32 @printn(i32 -4)
%4 = tail call i32 @printn(i32 -3)
%5 = tail call i32 @printn(i32 -2)
%6 = tail call i32 @printn(i32 -1)
%7 = tail call i32 @printn(i32 1)
%8 = tail call i32 @printn(i32 2)
%9 = tail call i32 @printn(i32 3)
%10 = tail call i32 @printn(i32 4)
%11 = tail call i32 @printn(i32 5)
%12 = tail call i32 @printn(i32 6)
%13 = tail call i32 @putchar(i8 signext 10)
%14 = tail call i32 @printn(i32 -6)
%15 = tail call i32 @printn(i32 -5)
%16 = tail call i32 @printn(i32 -4)
%17 = tail call i32 @printn(i32 -3)
%18 = tail call i32 @printn(i32 -2)
%19 = tail call i32 @printn(i32 -1)
%20 = tail call i32 @printn(i32 45)
%21 = tail call i32 @printn(i32 1)
%22 = tail call i32 @printn(i32 2)
%23 = tail call i32 @printn(i32 3)
%24 = tail call i32 @printn(i32 4)
%25 = tail call i32 @printn(i32 5)
%26 = tail call i32 @printn(i32 6)
%27 = tail call i32 @putchar(i8 signext 10)
%28 = tail call i32 @printn(i32 -6)
%29 = tail call i32 @printn(i32 -5)
%30 = tail call i32 @printn(i32 -4)
%31 = tail call i32 @printn(i32 -3)
%32 = tail call i32 @printn(i32 -2)
%33 = tail call i32 @printn(i32 -1)
%34 = tail call i32 @putchar(i8 signext 10)
%35 = tail call i32 @printn(i32 -6)
%36 = tail call i32 @printn(i32 -5)
%37 = tail call i32 @printn(i32 -4)
%38 = tail call i32 @printn(i32 -3)
%39 = tail call i32 @printn(i32 -2)
%40 = tail call i32 @printn(i32 -1)
%41 = tail call i32 @putchar(i8 signext 10)
%42 = tail call i32 @printn(i32 -6)
%43 = tail call i32 @printn(i32 -5)
%44 = tail call i32 @printn(i32 -4)
%45 = tail call i32 @printn(i32 -3)
%46 = tail call i32 @printn(i32 -2)
%47 = tail call i32 @printn(i32 -1)
ret void
}