#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*/ printf(char *, char *);
int /*<<< orphan*/ puts(char *);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int integerA = 0;
  int integerB = 0;
  puts("Input two integers");
  printf("%s", "Give the First integer: ");
  scanf("%d", &integerA);
  printf("%s", "Give the Second integer: ");
  scanf("%d", &integerB);
  if (integerA > integerB)
    puts("The First integer is larger");
  if (integerB > integerA)
    puts("The Second integer is larger");
  if (integerA == integerB)
    puts("The two integers are equals");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
lea    0xeac(%rip),%rdi
call   1030 <puts@plt>
lea    0xeb3(%rip),%rdi
lea    0xeaf(%rip),%rsi
call   1040 <printf@plt>
lea    0xebc(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1050 <scanf@plt>
lea    0xe90(%rip),%rdi
lea    0xea8(%rip),%rsi
call   1040 <printf@plt>
lea    0xe99(%rip),%rdi
lea    -0xc(%rbp),%rsi
call   1050 <scanf@plt>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jle    11b7 <main+0x87>
lea    0xe9a(%rip),%rdi
call   1030 <puts@plt>
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
jle    11cf <main+0x9f>
lea    0xe9e(%rip),%rdi
call   1030 <puts@plt>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jne    11e7 <main+0xb7>
lea    0xea3(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
movl   $0x0,0x4(%rsp)
movl   $0x0,(%rsp)
lea    0xeb6(%rip),%rdi
call   1030 <puts@plt>
lea    0xebd(%rip),%r14
lea    0xeb9(%rip),%rsi
mov    %r14,%rdi
call   1040 <printf@plt>
lea    0xec3(%rip),%rbx
lea    0x4(%rsp),%rsi
mov    %rbx,%rdi
call   1050 <scanf@plt>
lea    0xeb2(%rip),%rsi
mov    %r14,%rdi
call   1040 <printf@plt>
mov    %rsp,%rsi
mov    %rbx,%rdi
call   1050 <scanf@plt>
mov    0x4(%rsp),%eax
mov    (%rsp),%ecx
cmp    %ecx,%eax
jg     11bc <main+0x8c>
cmp    %eax,%ecx
jg     11d3 <main+0xa3>
cmp    %ecx,%eax
jne    11b2 <main+0x82>
lea    0xed8(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
lea    0xe89(%rip),%rdi
call   1030 <puts@plt>
mov    (%rsp),%ecx
mov    0x4(%rsp),%eax
cmp    %eax,%ecx
jle    11a2 <main+0x72>
lea    0xe8e(%rip),%rdi
call   1030 <puts@plt>
mov    0x4(%rsp),%eax
mov    (%rsp),%ecx
cmp    %ecx,%eax
je     11a6 <main+0x76>
jmp    11b2 <main+0x82>

LLVM IR (-O0):
@.str = [19 x i8] c"Input two integers\00"
@.str.1 = [3 x i8] c"%s\00"
@.str.2 = [25 x i8] c"Give the First integer: \00"
@.str.3 = [3 x i8] c"%d\00"
@.str.4 = [26 x i8] c"Give the Second integer: \00"
@.str.5 = [28 x i8] c"The First integer is larger\00"
@.str.6 = [29 x i8] c"The Second integer is larger\00"
@.str.7 = [28 x i8] c"The two integers are equals\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %2
store i32 0, i32* %3
%4 = call i32 @puts(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.2, i64 0, i64 0))
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %2)
%7 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.4, i64 0, i64 0))
%8 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %3)
%9 = load i32, i32* %2
%10 = load i32, i32* %3
%11 = icmp sgt i32 %9, %10
br i1 %11, label %12, label %14
12: ; preds = %0
%13 = call i32 @puts(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.5, i64 0, i64 0))
br label %14
14: ; preds = %12, %0
%15 = load i32, i32* %3
%16 = load i32, i32* %2
%17 = icmp sgt i32 %15, %16
br i1 %17, label %18, label %20
18: ; preds = %14
%19 = call i32 @puts(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.6, i64 0, i64 0))
br label %20
20: ; preds = %18, %14
%21 = load i32, i32* %2
%22 = load i32, i32* %3
%23 = icmp eq i32 %21, %22
br i1 %23, label %24, label %26
24: ; preds = %20
%25 = call i32 @puts(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.7, i64 0, i64 0))
br label %26
26: ; preds = %24, %20
ret i32 0
}

LLVM IR (-O2):
@.str = [19 x i8] c"Input two integers\00"
@.str.1 = [3 x i8] c"%s\00"
@.str.2 = [25 x i8] c"Give the First integer: \00"
@.str.3 = [3 x i8] c"%d\00"
@.str.4 = [26 x i8] c"Give the Second integer: \00"
@.str.5 = [28 x i8] c"The First integer is larger\00"
@.str.6 = [29 x i8] c"The Second integer is larger\00"
@.str.7 = [28 x i8] c"The two integers are equals\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%4 = bitcast i32* %2 to i8*
store i32 0, i32* %2
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0))
%6 = tail call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.2, i64 0, i64 0))
%7 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %1)
%8 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.4, i64 0, i64 0))
%9 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %2)
%10 = load i32, i32* %1
%11 = load i32, i32* %2
%12 = icmp sgt i32 %10, %11
br i1 %12, label %13, label %17
13: ; preds = %0
%14 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str.5, i64 0, i64 0))
%15 = load i32, i32* %2
%16 = load i32, i32* %1
br label %17
17: ; preds = %13, %0
%18 = phi i32 [ %16, %13 ], [ %10, %0 ]
%19 = phi i32 [ %15, %13 ], [ %11, %0 ]
%20 = icmp sgt i32 %19, %18
br i1 %20, label %21, label %25
21: ; preds = %17
%22 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @.str.6, i64 0, i64 0))
%23 = load i32, i32* %1
%24 = load i32, i32* %2
br label %25
25: ; preds = %21, %17
%26 = phi i32 [ %24, %21 ], [ %19, %17 ]
%27 = phi i32 [ %23, %21 ], [ %18, %17 ]
%28 = icmp eq i32 %27, %26
br i1 %28, label %29, label %31
29: ; preds = %25
%30 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str.7, i64 0, i64 0))
br label %31
31: ; preds = %29, %25
ret i32 0
}