#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*/ loopNoAfterThought(int);
int /*<<< orphan*/ loopNoCondition(int);
int /*<<< orphan*/ loopNoInitialization(int);
int /*<<< orphan*/ print_string(char *);
void main(void) {
  print_string("Should get 3 2 1 0 -1\n");
  loopNoInitialization(3);
  loopNoInitialization(-1);
  print_string("\n");
  print_string("Should get 3 2 1 0 -1\n");
  loopNoCondition(3);
  loopNoCondition(-1);
  print_string("\n");
  print_string("Should get 3 2 1 0 -1\n");
  loopNoAfterThought(3);
  loopNoAfterThought(-1);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
lea    0xeb5(%rip),%rdi
call   1050 <print_string@plt>
mov    $0x3,%edi
call   1030 <loopNoInitialization@plt>
mov    $0xffffffff,%edi
call   1030 <loopNoInitialization@plt>
lea    0xeaa(%rip),%rdi
call   1050 <print_string@plt>
lea    0xe89(%rip),%rdi
call   1050 <print_string@plt>
mov    $0x3,%edi
call   1060 <loopNoCondition@plt>
mov    $0xffffffff,%edi
call   1060 <loopNoCondition@plt>
lea    0xe7e(%rip),%rdi
call   1050 <print_string@plt>
lea    0xe5d(%rip),%rdi
call   1050 <print_string@plt>
mov    $0x3,%edi
call   1040 <loopNoAfterThought@plt>
mov    $0xffffffff,%edi
call   1040 <loopNoAfterThought@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
lea    0xeb5(%rip),%r14
mov    %r14,%rdi
call   1050 <print_string@plt>
mov    $0x3,%edi
call   1030 <loopNoInitialization@plt>
mov    $0xffffffff,%edi
call   1030 <loopNoInitialization@plt>
lea    0xea7(%rip),%rbx
mov    %rbx,%rdi
call   1050 <print_string@plt>
mov    %r14,%rdi
call   1050 <print_string@plt>
mov    $0x3,%edi
call   1060 <loopNoCondition@plt>
mov    $0xffffffff,%edi
call   1060 <loopNoCondition@plt>
mov    %rbx,%rdi
call   1050 <print_string@plt>
mov    %r14,%rdi
call   1050 <print_string@plt>
mov    $0x3,%edi
call   1040 <loopNoAfterThought@plt>
mov    $0xffffffff,%edi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <loopNoAfterThought@plt>

LLVM IR (-O0):
@.str = [23 x i8] c"Should get 3 2 1 0 -1\0A\00"
@.str.1 = [2 x i8] c"\0A\00"
define void @main() {
%1 = call i32 @print_string(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @loopNoInitialization(i32 3)
%3 = call i32 @loopNoInitialization(i32 -1)
%4 = call i32 @print_string(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%5 = call i32 @print_string(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0))
%6 = call i32 @loopNoCondition(i32 3)
%7 = call i32 @loopNoCondition(i32 -1)
%8 = call i32 @print_string(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%9 = call i32 @print_string(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0))
%10 = call i32 @loopNoAfterThought(i32 3)
%11 = call i32 @loopNoAfterThought(i32 -1)
ret void
}

LLVM IR (-O2):
@.str = [23 x i8] c"Should get 3 2 1 0 -1\0A\00"
@.str.1 = [2 x i8] c"\0A\00"
define void @main() {
%1 = tail call i32 @print_string(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @loopNoInitialization(i32 3)
%3 = tail call i32 @loopNoInitialization(i32 -1)
%4 = tail call i32 @print_string(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%5 = tail call i32 @print_string(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0))
%6 = tail call i32 @loopNoCondition(i32 3)
%7 = tail call i32 @loopNoCondition(i32 -1)
%8 = tail call i32 @print_string(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%9 = tail call i32 @print_string(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0))
%10 = tail call i32 @loopNoAfterThought(i32 3)
%11 = tail call i32 @loopNoAfterThought(i32 -1)
ret void
}