#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*/ abort();
int f1(int);
int f2(int);
int main() {
  int a = 0xaaaaaaaa;
  int b = 0x55555555;
  int c;
  c = f1(a);
  if (c != 0xfd6a052c)
    abort();
  c = f1(b);
  if (c != 0x295FAD4)
    abort();
  c = f2(a);
  if (c != 0xfee44b5c)
    abort();
  c = f2(b);
  if (c != 0x11bb4a4)
    abort();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0xaaaaaaaa,-0x8(%rbp)
movl   $0x55555555,-0xc(%rbp)
mov    -0x8(%rbp),%edi
call   1050 <f1@plt>
mov    %eax,-0x10(%rbp)
cmpl   $0xfd6a052c,-0x10(%rbp)
je     116c <main+0x3c>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%edi
call   1050 <f1@plt>
mov    %eax,-0x10(%rbp)
cmpl   $0x295fad4,-0x10(%rbp)
je     118b <main+0x5b>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0x8(%rbp),%edi
call   1030 <f2@plt>
mov    %eax,-0x10(%rbp)
cmpl   $0xfee44b5c,-0x10(%rbp)
je     11aa <main+0x7a>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%edi
call   1030 <f2@plt>
mov    %eax,-0x10(%rbp)
cmpl   $0x11bb4a4,-0x10(%rbp)
je     11c9 <main+0x99>
mov    $0x0,%al
call   1040 <abort@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0xaaaaaaaa,%edi
call   1050 <f1@plt>
cmp    $0xfd6a052c,%eax
jne    1179 <main+0x49>
mov    $0x55555555,%edi
call   1050 <f1@plt>
cmp    $0x295fad4,%eax
jne    1179 <main+0x49>
mov    $0xaaaaaaaa,%edi
call   1030 <f2@plt>
cmp    $0xfee44b5c,%eax
jne    1179 <main+0x49>
mov    $0x55555555,%edi
call   1030 <f2@plt>
cmp    $0x11bb4a4,%eax
jne    1179 <main+0x49>
xor    %eax,%eax
pop    %rcx
ret
xor    %eax,%eax
call   1040 <abort@plt>

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 0, i32* %1
store i32 -1431655766, i32* %2
store i32 1431655765, i32* %3
%5 = load i32, i32* %2
%6 = call i32 @f1(i32 %5)
store i32 %6, i32* %4
%7 = load i32, i32* %4
%8 = icmp ne i32 %7, -43383508
br i1 %8, label %9, label %11
9: ; preds = %0
%10 = call i32 (...) @abort()
unreachable
11: ; preds = %0
%12 = load i32, i32* %3
%13 = call i32 @f1(i32 %12)
store i32 %13, i32* %4
%14 = load i32, i32* %4
%15 = icmp ne i32 %14, 43383508
br i1 %15, label %16, label %18
16: ; preds = %11
%17 = call i32 (...) @abort()
unreachable
18: ; preds = %11
%19 = load i32, i32* %2
%20 = call i32 @f2(i32 %19)
store i32 %20, i32* %4
%21 = load i32, i32* %4
%22 = icmp ne i32 %21, -18592932
br i1 %22, label %23, label %25
23: ; preds = %18
%24 = call i32 (...) @abort()
unreachable
25: ; preds = %18
%26 = load i32, i32* %3
%27 = call i32 @f2(i32 %26)
store i32 %27, i32* %4
%28 = load i32, i32* %4
%29 = icmp ne i32 %28, 18592932
br i1 %29, label %30, label %32
30: ; preds = %25
%31 = call i32 (...) @abort()
unreachable
32: ; preds = %25
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @f1(i32 -1431655766)
%2 = icmp eq i32 %1, -43383508
br i1 %2, label %5, label %3
3: ; preds = %0
%4 = tail call i32 (...) @abort()
unreachable
5: ; preds = %0
%6 = tail call i32 @f1(i32 1431655765)
%7 = icmp eq i32 %6, 43383508
br i1 %7, label %10, label %8
8: ; preds = %5
%9 = tail call i32 (...) @abort()
unreachable
10: ; preds = %5
%11 = tail call i32 @f2(i32 -1431655766)
%12 = icmp eq i32 %11, -18592932
br i1 %12, label %15, label %13
13: ; preds = %10
%14 = tail call i32 (...) @abort()
unreachable
15: ; preds = %10
%16 = tail call i32 @f2(i32 1431655765)
%17 = icmp eq i32 %16, 18592932
br i1 %17, label %20, label %18
18: ; preds = %15
%19 = tail call i32 (...) @abort()
unreachable
20: ; preds = %15
ret i32 0
}