#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 bytes(scalar_t__);
scalar_t__ double5();
int intbytes();
int longbytes();
scalar_t__ not3(int);
int shr32(int);
int main(int argc, char **argv) {
  if (intbytes() != sizeof(int))
    return 100;
  if (longbytes() != sizeof(long))
    return 100;
  if (not3(3))
    return 100;
  if (!not3(shr32(1)))
    return 100;
  if (bytes(not3(1)) != 1)
    return 100;
  if (double5() < 0)
    return 100;
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1040 <intbytes@plt>
cltq
cmp    $0x4,%rax
je     1195 <main+0x35>
movl   $0x64,-0x4(%rbp)
jmp    1246 <main+0xe6>
mov    $0x0,%al
call   1070 <longbytes@plt>
cltq
cmp    $0x8,%rax
je     11b4 <main+0x54>
movl   $0x64,-0x4(%rbp)
jmp    1246 <main+0xe6>
mov    $0x3,%edi
call   1060 <not3@plt>
cmp    $0x0,%rax
je     11d4 <main+0x74>
movl   $0x64,-0x4(%rbp)
jmp    1246 <main+0xe6>
mov    $0x1,%edi
call   1080 <shr32@plt>
mov    %eax,%edi
call   1060 <not3@plt>
cmp    $0x0,%rax
jne    11fb <main+0x9b>
movl   $0x64,-0x4(%rbp)
jmp    1246 <main+0xe6>
mov    $0x1,%edi
call   1060 <not3@plt>
mov    %rax,%rdi
call   1050 <bytes@plt>
cmp    $0x1,%eax
je     1222 <main+0xc2>
movl   $0x64,-0x4(%rbp)
jmp    1246 <main+0xe6>
mov    $0x0,%al
call   1030 <double5@plt>
cmp    $0x0,%rax
jge    123f <main+0xdf>
movl   $0x64,-0x4(%rbp)
jmp    1246 <main+0xe6>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
xor    %eax,%eax
call   1040 <intbytes@plt>
mov    $0x64,%ebx
cmp    $0x4,%eax
jne    118d <main+0x2d>
xor    %eax,%eax
call   1070 <longbytes@plt>
cmp    $0x8,%eax
jne    118d <main+0x2d>
mov    $0x3,%edi
call   1060 <not3@plt>
test   %rax,%rax
je     1191 <main+0x31>
mov    %ebx,%eax
pop    %rbx
ret
mov    $0x1,%edi
call   1080 <shr32@plt>
mov    %eax,%edi
call   1060 <not3@plt>
test   %rax,%rax
je     118d <main+0x2d>
mov    $0x1,%edi
call   1060 <not3@plt>
mov    %rax,%rdi
call   1050 <bytes@plt>
cmp    $0x1,%eax
jne    118d <main+0x2d>
xor    %eax,%eax
call   1030 <double5@plt>
mov    %rax,%rbx
sar    $0x3f,%rbx
and    $0x64,%ebx
jmp    118d <main+0x2d>

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = call i32 (...) @intbytes()
%7 = sext i32 %6 to i64
%8 = icmp ne i64 %7, 4
br i1 %8, label %9, label %10
9: ; preds = %2
store i32 100, i32* %3
br label %34
10: ; preds = %2
%11 = call i32 (...) @longbytes()
%12 = sext i32 %11 to i64
%13 = icmp ne i64 %12, 8
br i1 %13, label %14, label %15
14: ; preds = %10
store i32 100, i32* %3
br label %34
15: ; preds = %10
%16 = call i64 @not3(i32 3)
%17 = icmp ne i64 %16, 0
br i1 %17, label %18, label %19
18: ; preds = %15
store i32 100, i32* %3
br label %34
19: ; preds = %15
%20 = call i32 @shr32(i32 1)
%21 = call i64 @not3(i32 %20)
%22 = icmp ne i64 %21, 0
br i1 %22, label %24, label %23
23: ; preds = %19
store i32 100, i32* %3
br label %34
24: ; preds = %19
%25 = call i64 @not3(i32 1)
%26 = call i32 @bytes(i64 %25)
%27 = icmp ne i32 %26, 1
br i1 %27, label %28, label %29
28: ; preds = %24
store i32 100, i32* %3
br label %34
29: ; preds = %24
%30 = call i64 (...) @double5()
%31 = icmp slt i64 %30, 0
br i1 %31, label %32, label %33
32: ; preds = %29
store i32 100, i32* %3
br label %34
33: ; preds = %29
store i32 0, i32* %3
br label %34
34: ; preds = %33, %32, %28, %23, %18, %14, %9
%35 = load i32, i32* %3
ret i32 %35
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @intbytes()
%4 = icmp eq i32 %3, 4
br i1 %4, label %5, label %23
5: ; preds = %2
%6 = tail call i32 (...) @longbytes()
%7 = icmp eq i32 %6, 8
br i1 %7, label %8, label %23
8: ; preds = %5
%9 = tail call i64 @not3(i32 3)
%10 = icmp eq i64 %9, 0
br i1 %10, label %11, label %23
11: ; preds = %8
%12 = tail call i32 @shr32(i32 1)
%13 = tail call i64 @not3(i32 %12)
%14 = icmp eq i64 %13, 0
br i1 %14, label %23, label %15
15: ; preds = %11
%16 = tail call i64 @not3(i32 1)
%17 = tail call i32 @bytes(i64 %16)
%18 = icmp eq i32 %17, 1
br i1 %18, label %19, label %23
19: ; preds = %15
%20 = tail call i64 (...) @double5()
%21 = icmp slt i64 %20, 0
%22 = select i1 %21, i32 100, i32 0
br label %23
23: ; preds = %19, %15, %11, %8, %5, %2
%24 = phi i32 [ 100, %2 ], [ 100, %5 ], [ 100, %8 ], [ 100, %11 ], [ 100, %15 ], [ %22, %19 ]
ret i32 %24
}