#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*/ __CrestApply2(int, int, long long);
int /*<<< orphan*/ __CrestBranch(int, int, int);
int /*<<< orphan*/ __CrestCall(int, int);
int /*<<< orphan*/ __CrestClearStack(int);
int /*<<< orphan*/ __CrestLoad(int, unsigned long, long long);
int /*<<< orphan*/ __CrestReturn(int);
int /*<<< orphan*/ __CrestStore(int, unsigned long);
int /*<<< orphan*/ printf(char const *);
void i(int a) {
  {
    __CrestCall(36, 4);
    __CrestStore(35, (unsigned long)(&a));
    {
      __CrestLoad(39, (unsigned long)(&a), (long long)a);
      __CrestLoad(38, (unsigned long)0, (long long)100);
      __CrestApply2(37, 12, (long long)(a == 100));
      if (a == 100) {
        __CrestBranch(40, 19, 1);
        printf((char const *__restrict)"100\n");
        __CrestClearStack(42);
      } else {
        __CrestBranch(41, 20, 0);
        printf((char const *__restrict)"not 100\n");
        __CrestClearStack(43);
      }
    }
    {
      __CrestReturn(44);
      return;
    }
  }
}


x86 assembly (clang, -O0):
<i>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x24,%edi
mov    $0x4,%esi
call   1080 <__CrestCall@plt>
lea    -0x4(%rbp),%rsi
mov    $0x23,%edi
call   1060 <__CrestStore@plt>
lea    -0x4(%rbp),%rsi
movslq -0x4(%rbp),%rdx
mov    $0x27,%edi
call   1090 <__CrestLoad@plt>
mov    $0x26,%edi
xor    %eax,%eax
mov    %eax,%esi
mov    $0x64,%edx
call   1090 <__CrestLoad@plt>
cmpl   $0x64,-0x4(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%eax
movslq %eax,%rdx
mov    $0x25,%edi
mov    $0xc,%esi
call   1030 <__CrestApply2@plt>
cmpl   $0x64,-0x4(%rbp)
jne    1224 <i+0xa4>
mov    $0x28,%edi
mov    $0x13,%esi
mov    $0x1,%edx
call   1050 <__CrestBranch@plt>
lea    0xdf4(%rip),%rdi
call   1040 <printf@plt>
mov    $0x2a,%edi
call   10a0 <__CrestClearStack@plt>
jmp    124b <i+0xcb>
mov    $0x29,%edi
mov    $0x14,%esi
xor    %edx,%edx
call   1050 <__CrestBranch@plt>
lea    0xdc4(%rip),%rdi
call   1040 <printf@plt>
mov    $0x2b,%edi
call   10a0 <__CrestClearStack@plt>
mov    $0x2c,%edi
call   1070 <__CrestReturn@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<i>:
push   %rbx
sub    $0x10,%rsp
mov    %edi,0xc(%rsp)
mov    $0x24,%edi
mov    $0x4,%esi
call   1080 <__CrestCall@plt>
lea    0xc(%rsp),%rbx
mov    $0x23,%edi
mov    %rbx,%rsi
call   1060 <__CrestStore@plt>
movslq 0xc(%rsp),%rdx
mov    $0x27,%edi
mov    %rbx,%rsi
call   1090 <__CrestLoad@plt>
mov    $0x64,%edx
mov    $0x26,%edi
xor    %esi,%esi
call   1090 <__CrestLoad@plt>
xor    %edx,%edx
cmpl   $0x64,0xc(%rsp)
sete   %dl
mov    $0x25,%edi
mov    $0xc,%esi
call   1030 <__CrestApply2@plt>
cmpl   $0x64,0xc(%rsp)
jne    120f <i+0x8f>
mov    $0x28,%edi
mov    $0x13,%esi
mov    $0x1,%edx
call   1050 <__CrestBranch@plt>
mov    $0x2a,%ebx
lea    0xdf7(%rip),%rdi
jmp    122c <i+0xac>
mov    $0x29,%edi
mov    $0x14,%esi
xor    %edx,%edx
call   1050 <__CrestBranch@plt>
mov    $0x2b,%ebx
lea    0xdd4(%rip),%rdi
call   1040 <puts@plt>
mov    %ebx,%edi
call   10a0 <__CrestClearStack@plt>
mov    $0x2c,%edi
call   1070 <__CrestReturn@plt>
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"100\0A\00"
@.str.1 = [9 x i8] c"not 100\0A\00"
define void @i(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @__CrestCall(i32 36, i32 4)
%4 = ptrtoint i32* %2 to i64
%5 = call i32 @__CrestStore(i32 35, i64 %4)
%6 = ptrtoint i32* %2 to i64
%7 = load i32, i32* %2
%8 = sext i32 %7 to i64
%9 = call i32 @__CrestLoad(i32 39, i64 %6, i64 %8)
%10 = call i32 @__CrestLoad(i32 38, i64 0, i64 100)
%11 = load i32, i32* %2
%12 = icmp eq i32 %11, 100
%13 = zext i1 %12 to i32
%14 = sext i32 %13 to i64
%15 = call i32 @__CrestApply2(i32 37, i32 12, i64 %14)
%16 = load i32, i32* %2
%17 = icmp eq i32 %16, 100
br i1 %17, label %18, label %22
18: ; preds = %1
%19 = call i32 @__CrestBranch(i32 40, i32 19, i32 1)
%20 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%21 = call i32 @__CrestClearStack(i32 42)
br label %26
22: ; preds = %1
%23 = call i32 @__CrestBranch(i32 41, i32 20, i32 0)
%24 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%25 = call i32 @__CrestClearStack(i32 43)
br label %26
26: ; preds = %22, %18
%27 = call i32 @__CrestReturn(i32 44)
ret void
}

LLVM IR (-O2):
@str = [8 x i8] c"not 100\00"
@str.2 = [4 x i8] c"100\00"
define void @i(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = tail call i32 @__CrestCall(i32 36, i32 4)
%4 = ptrtoint i32* %2 to i64
%5 = call i32 @__CrestStore(i32 35, i64 %4)
%6 = load i32, i32* %2
%7 = sext i32 %6 to i64
%8 = call i32 @__CrestLoad(i32 39, i64 %4, i64 %7)
%9 = call i32 @__CrestLoad(i32 38, i64 0, i64 100)
%10 = load i32, i32* %2
%11 = icmp eq i32 %10, 100
%12 = zext i1 %11 to i64
%13 = call i32 @__CrestApply2(i32 37, i32 12, i64 %12)
%14 = load i32, i32* %2
%15 = icmp eq i32 %14, 100
br i1 %15, label %16, label %18
16: ; preds = %1
%17 = call i32 @__CrestBranch(i32 40, i32 19, i32 1)
br label %20
18: ; preds = %1
%19 = call i32 @__CrestBranch(i32 41, i32 20, i32 0)
br label %20
20: ; preds = %18, %16
%21 = phi i8* [ getelementptr inbounds ([8 x i8], [8 x i8]* @str, i64 0, i64 0), %18 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.2, i64 0, i64 0), %16 ]
%22 = phi i32 [ 43, %18 ], [ 42, %16 ]
%23 = call i32 @puts(i8* dereferenceable(1) %21)
%24 = call i32 @__CrestClearStack(i32 %22)
%25 = call i32 @__CrestReturn(i32 44)
ret void
}