#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*/ add_includedir(char *);
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ parse_sourcefile(char *);
int main(int argc, char *argv[]) {
  int i;
  add_includedir("/usr/include");
  add_includedir("/usr/local/include");
  for (i = 1; i < argc; i++)
    if (argv[i][0] == '-')
      switch (argv[i][1]) {
      case 'I':
        add_includedir(argv[i] + 2);
        break;
      }
    else
      parse_sourcefile(argv[i]);
  exit(0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xeb3(%rip),%rdi
call   1030 <add_includedir@plt>
lea    0xeb4(%rip),%rdi
call   1030 <add_includedir@plt>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11e3 <main+0xb3>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rax
movsbl (%rax),%eax
cmp    $0x2d,%eax
jne    11bf <main+0x8f>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rax
mov    0x1(%rax),%al
sub    $0x49,%al
jne    11ba <main+0x8a>
jmp    11a5 <main+0x75>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
add    $0x2,%rdi
call   1030 <add_includedir@plt>
jmp    11d0 <main+0xa0>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
call   1040 <parse_sourcefile@plt>
jmp    11d5 <main+0xa5>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1165 <main+0x35>
xor    %edi,%edi
call   1050 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
mov    %rsi,%r14
mov    %edi,%ebp
lea    0xec0(%rip),%rdi
call   1030 <add_includedir@plt>
lea    0xec1(%rip),%rdi
call   1030 <add_includedir@plt>
cmp    $0x2,%ebp
jl     1188 <main+0x58>
mov    %ebp,%ebp
mov    $0x1,%ebx
jmp    116e <main+0x3e>
nop
call   1040 <parse_sourcefile@plt>
add    $0x1,%rbx
cmp    %rbx,%rbp
je     1188 <main+0x58>
mov    (%r14,%rbx,8),%rdi
cmpb   $0x2d,(%rdi)
jne    1160 <main+0x30>
cmpb   $0x49,0x1(%rdi)
jne    1165 <main+0x35>
add    $0x2,%rdi
call   1030 <add_includedir@plt>
jmp    1165 <main+0x35>
xor    %edi,%edi
call   1050 <exit@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"/usr/include\00"
@.str.1 = [19 x i8] c"/usr/local/include\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = call i32 @add_includedir(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%8 = call i32 @add_includedir(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0))
store i32 1, i32* %6
br label %9
9: ; preds = %49, %2
%10 = load i32, i32* %6
%11 = load i32, i32* %4
%12 = icmp slt i32 %10, %11
br i1 %12, label %13, label %52
13: ; preds = %9
%14 = load i8**, i8*** %5
%15 = load i32, i32* %6
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds i8*, i8** %14, i64 %16
%18 = load i8*, i8** %17
%19 = getelementptr inbounds i8, i8* %18, i64 0
%20 = load i8, i8* %19
%21 = sext i8 %20 to i32
%22 = icmp eq i32 %21, 45
br i1 %22, label %23, label %41
23: ; preds = %13
%24 = load i8**, i8*** %5
%25 = load i32, i32* %6
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds i8*, i8** %24, i64 %26
%28 = load i8*, i8** %27
%29 = getelementptr inbounds i8, i8* %28, i64 1
%30 = load i8, i8* %29
%31 = sext i8 %30 to i32
switch i32 %31, label %40 [
i32 73, label %32
]
32: ; preds = %23
%33 = load i8**, i8*** %5
%34 = load i32, i32* %6
%35 = sext i32 %34 to i64
%36 = getelementptr inbounds i8*, i8** %33, i64 %35
%37 = load i8*, i8** %36
%38 = getelementptr inbounds i8, i8* %37, i64 2
%39 = call i32 @add_includedir(i8* %38)
br label %40
40: ; preds = %23, %32
br label %48
41: ; preds = %13
%42 = load i8**, i8*** %5
%43 = load i32, i32* %6
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds i8*, i8** %42, i64 %44
%46 = load i8*, i8** %45
%47 = call i32 @parse_sourcefile(i8* %46)
br label %48
48: ; preds = %41, %40
br label %49
49: ; preds = %48
%50 = load i32, i32* %6
%51 = add nsw i32 %50, 1
store i32 %51, i32* %6
br label %9
52: ; preds = %9
%53 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@.str = [13 x i8] c"/usr/include\00"
@.str.1 = [19 x i8] c"/usr/local/include\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = tail call i32 @add_includedir(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 @add_includedir(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0))
%5 = icmp sgt i32 %0, 1
br i1 %5, label %6, label %26
6: ; preds = %2
%7 = zext i32 %0 to i64
br label %8
8: ; preds = %6, %23
%9 = phi i64 [ 1, %6 ], [ %24, %23 ]
%10 = getelementptr inbounds i8*, i8** %1, i64 %9
%11 = load i8*, i8** %10
%12 = load i8, i8* %11
%13 = icmp eq i8 %12, 45
br i1 %13, label %14, label %21
14: ; preds = %8
%15 = getelementptr inbounds i8, i8* %11, i64 1
%16 = load i8, i8* %15
%17 = icmp eq i8 %16, 73
br i1 %17, label %18, label %23
18: ; preds = %14
%19 = getelementptr inbounds i8, i8* %11, i64 2
%20 = tail call i32 @add_includedir(i8* %19)
br label %23
21: ; preds = %8
%22 = tail call i32 @parse_sourcefile(i8* %11)
br label %23
23: ; preds = %21, %14, %18
%24 = add nuw nsw i64 %9, 1
%25 = icmp eq i64 %24, %7
br i1 %25, label %26, label %8
26: ; preds = %23, %2
%27 = tail call i32 @exit(i32 0)
unreachable
}