#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 */
typedef scalar_t__ pid_t;

/* Variables and functions */
int O_CREAT;
int O_TRUNC;
int O_WRONLY;
int /*<<< orphan*/ S_IRWXU;
scalar_t__ calloc(int, int);
int /*<<< orphan*/ dup2(int, int);
scalar_t__ execvp(char *, char **);
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/);
int fileno(int /*<<< orphan*/);
scalar_t__ fork();
int /*<<< orphan*/ free(char **);
int open(char *, int, int /*<<< orphan*/);
int /*<<< orphan*/ perror(char *);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ stderr;
int /*<<< orphan*/ stdin;
int /*<<< orphan*/ stdout;
scalar_t__ strcmp(char *, char *);
char *strtok(char *, char const *);
scalar_t__ wait(int *);
int main() {
  char input[2048];
  const char s[2] = "\n ";
  char *token;
  int myargc = 0;
  char **myargv;
  pid_t cpid = 0;
  int status = 0, error;
  int redir_stdout = 0;
  int redir_stdin = 0;
  int redir_stderr = 0;
  int pipe = 0;
  int compare;
  int fd;
  while (1) {
    dup2(fileno(stdout), fileno(stdout));
    dup2(fileno(stdin), fileno(stdin));
    dup2(fileno(stderr), fileno(stderr));
    myargv = (char **)calloc(20, sizeof(char *));
    myargc = 0;
    printf("netdom> ");
    fgets(input, 2048, stdin);
    token = strtok(input, s);
    while (token != NULL) {
      myargv[myargc++] = token;
      if (compare = strcmp(token, ">") == 0) {
        token = strtok(NULL, ">");
        while (token[0] == ' ') {
          token++;
        }
        dup2(open(token, O_CREAT | O_TRUNC | O_WRONLY, S_IRWXU), 1);
      }
      token = strtok(NULL, s);
    }
    if (strcmp(myargv[0], "exit") == 0) {
      printf("<3\n");
      exit(0);
    }
    if ((cpid = fork()) < 0) {
      perror("Error sporking process o_O\n");
      exit(1);
    }
    if (cpid == 0) {
      if (error = execvp(myargv[0], myargv) < 0) {
        perror("EXEC ERROR\n");
        exit(1);
      }
    } else {
      while (wait(&status) != cpid)
        ;
    }
    free(myargv);
  }
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x870,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xe07(%rip),%ax
mov    %ax,-0x812(%rbp)
movl   $0x0,-0x824(%rbp)
movq   $0x0,-0x838(%rbp)
movl   $0x0,-0x83c(%rbp)
movl   $0x0,-0x844(%rbp)
movl   $0x0,-0x848(%rbp)
movl   $0x0,-0x84c(%rbp)
movl   $0x0,-0x850(%rbp)
mov    0x2d6a(%rip),%rax
mov    (%rax),%edi
call   1090 <fileno@plt>
mov    %eax,-0x864(%rbp)
mov    0x2d56(%rip),%rax
mov    (%rax),%edi
call   1090 <fileno@plt>
mov    -0x864(%rbp),%edi
mov    %eax,%esi
call   1040 <dup2@plt>
mov    0x2d53(%rip),%rax
mov    (%rax),%edi
call   1090 <fileno@plt>
mov    %eax,-0x860(%rbp)
mov    0x2d3f(%rip),%rax
mov    (%rax),%edi
call   1090 <fileno@plt>
mov    -0x860(%rbp),%edi
mov    %eax,%esi
call   1040 <dup2@plt>
mov    0x2d14(%rip),%rax
mov    (%rax),%edi
call   1090 <fileno@plt>
mov    %eax,-0x85c(%rbp)
mov    0x2d00(%rip),%rax
mov    (%rax),%edi
call   1090 <fileno@plt>
mov    -0x85c(%rbp),%edi
mov    %eax,%esi
call   1040 <dup2@plt>
mov    $0x14,%edi
mov    $0x8,%esi
call   1070 <calloc@plt>
mov    %rax,-0x830(%rbp)
movl   $0x0,-0x824(%rbp)
lea    0xd07(%rip),%rdi
call   1050 <printf@plt>
lea    -0x810(%rbp),%rdi
mov    0x2cc2(%rip),%rax
mov    (%rax),%edx
mov    $0x800,%esi
call   1060 <fgets@plt>
lea    -0x810(%rbp),%rdi
lea    -0x812(%rbp),%rsi
call   10c0 <strtok@plt>
mov    %rax,-0x820(%rbp)
cmpq   $0x0,-0x820(%rbp)
je     1436 <main+0x256>
mov    -0x820(%rbp),%rdx
mov    -0x830(%rbp),%rax
mov    -0x824(%rbp),%ecx
mov    %ecx,%esi
add    $0x1,%esi
mov    %esi,-0x824(%rbp)
movslq %ecx,%rcx
mov    %rdx,(%rax,%rcx,8)
mov    -0x820(%rbp),%rdi
lea    0xc95(%rip),%rsi
call   1080 <strcmp@plt>
cmp    $0x0,%rax
sete   %al
mov    %al,%cl
and    $0x1,%cl
movzbl %cl,%ecx
mov    %ecx,-0x854(%rbp)
test   $0x1,%al
jne    139d <main+0x1bd>
jmp    141a <main+0x23a>
xor    %eax,%eax
mov    %eax,%edi
lea    0xc63(%rip),%rsi
call   10c0 <strtok@plt>
mov    %rax,-0x820(%rbp)
mov    -0x820(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x20,%eax
jne    13de <main+0x1fe>
mov    -0x820(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x820(%rbp)
jmp    13b4 <main+0x1d4>
mov    -0x820(%rbp),%rdi
mov    0x2c0c(%rip),%rax
mov    (%rax),%esi
mov    0x2bfb(%rip),%rax
or     (%rax),%esi
mov    0x2baa(%rip),%rax
or     (%rax),%esi
mov    0x2bd1(%rip),%rax
mov    (%rax),%edx
call   10a0 <open@plt>
mov    %eax,%edi
mov    $0x1,%esi
call   1040 <dup2@plt>
lea    -0x812(%rbp),%rsi
xor    %eax,%eax
mov    %eax,%edi
call   10c0 <strtok@plt>
mov    %rax,-0x820(%rbp)
jmp    1334 <main+0x154>
mov    -0x830(%rbp),%rax
mov    (%rax),%rdi
lea    0xbc6(%rip),%rsi
call   1080 <strcmp@plt>
cmp    $0x0,%rax
jne    1469 <main+0x289>
lea    0xbb5(%rip),%rdi
call   1050 <printf@plt>
xor    %edi,%edi
call   10e0 <exit@plt>
mov    $0x0,%al
call   1100 <fork@plt>
mov    %rax,-0x838(%rbp)
cmp    $0x0,%rax
jge    1497 <main+0x2b7>
lea    0xb8e(%rip),%rdi
call   10b0 <perror@plt>
mov    $0x1,%edi
call   10e0 <exit@plt>
cmpq   $0x0,-0x838(%rbp)
jne    14f8 <main+0x318>
mov    -0x830(%rbp),%rax
mov    (%rax),%rdi
mov    -0x830(%rbp),%rsi
call   10d0 <execvp@plt>
cmp    $0x0,%rax
setl   %al
mov    %al,%cl
and    $0x1,%cl
movzbl %cl,%ecx
mov    %ecx,-0x840(%rbp)
test   $0x1,%al
jne    14dd <main+0x2fd>
jmp    14f3 <main+0x313>
lea    0xb4e(%rip),%rdi
call   10b0 <perror@plt>
mov    $0x1,%edi
call   10e0 <exit@plt>
jmp    1520 <main+0x340>
jmp    14fd <main+0x31d>
lea    -0x83c(%rbp),%rdi
call   10f0 <wait@plt>
cmp    -0x838(%rbp),%rax
je     151b <main+0x33b>
jmp    14fd <main+0x31d>
jmp    1520 <main+0x340>
mov    -0x830(%rbp),%rdi
call   1030 <free@plt>
jmp    1247 <main+0x67>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x818,%rsp
movw   $0x200a,0xa(%rsp)
movl   $0x0,0xc(%rsp)
lea    0xa(%rsp),%r15
lea    0xc(%rsp),%r13
lea    0xde8(%rip),%rbp
jmp    124c <main+0x5c>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    (%r14),%rdi
mov    %r14,%rsi
call   10e0 <execvp@plt>
test   %rax,%rax
js     13ee <main+0x1fe>
mov    %r14,%rdi
call   1030 <free@plt>
mov    0x2d65(%rip),%r14
mov    (%r14),%edi
call   10a0 <fileno@plt>
mov    %eax,%ebx
mov    (%r14),%edi
call   10a0 <fileno@plt>
mov    %ebx,%edi
mov    %eax,%esi
call   1050 <dup2@plt>
mov    0x2d5b(%rip),%r12
mov    (%r12),%edi
call   10a0 <fileno@plt>
mov    %eax,%ebx
mov    (%r12),%edi
call   10a0 <fileno@plt>
mov    %ebx,%edi
mov    %eax,%esi
call   1050 <dup2@plt>
mov    0x2d27(%rip),%r14
mov    (%r14),%edi
call   10a0 <fileno@plt>
mov    %eax,%ebx
mov    (%r14),%edi
call   10a0 <fileno@plt>
mov    %ebx,%edi
mov    %eax,%esi
call   1050 <dup2@plt>
mov    $0x14,%edi
mov    $0x8,%esi
call   1080 <calloc@plt>
mov    %rax,%r14
lea    0xd33(%rip),%rdi
call   1060 <printf@plt>
mov    (%r12),%edx
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x800,%esi
call   1070 <fgets@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
call   10d0 <strtok@plt>
test   %rax,%rax
mov    0x2cfb(%rip),%r12
je     1390 <main+0x1a0>
xor    %ebx,%ebx
jmp    1323 <main+0x133>
nopw   0x0(%rax,%rax,1)
add    $0x1,%rbx
xor    %edi,%edi
mov    %r15,%rsi
call   10d0 <strtok@plt>
test   %rax,%rax
je     1390 <main+0x1a0>
mov    %rax,(%r14,%rbx,8)
mov    %rax,%rdi
mov    %rbp,%rsi
call   1090 <strcmp@plt>
test   %rax,%rax
jne    1310 <main+0x120>
xor    %edi,%edi
mov    %rbp,%rsi
call   10d0 <strtok@plt>
add    $0xffffffffffffffff,%rax
cs nopw 0x0(%rax,%rax,1)
nop
cmpb   $0x20,0x1(%rax)
lea    0x1(%rax),%rax
je     1350 <main+0x160>
mov    0x2c8f(%rip),%rcx
mov    (%rcx),%esi
or     (%r12),%esi
mov    0x2c3a(%rip),%rcx
or     (%rcx),%esi
mov    0x2c61(%rip),%rcx
mov    (%rcx),%edx
mov    %rax,%rdi
call   10b0 <open@plt>
mov    %eax,%edi
mov    $0x1,%esi
call   1050 <dup2@plt>
jmp    1310 <main+0x120>
nop
mov    (%r14),%rdi
lea    0xc71(%rip),%rsi
call   1090 <strcmp@plt>
test   %rax,%rax
je     13d2 <main+0x1e2>
xor    %eax,%eax
call   1110 <fork@plt>
test   %rax,%rax
js     13e5 <main+0x1f5>
mov    %rax,%r12
je     1230 <main+0x40>
nopl   0x0(%rax)
mov    %r13,%rdi
call   1100 <wait@plt>
cmp    %r12,%rax
jne    13c0 <main+0x1d0>
jmp    1244 <main+0x54>
lea    0xc5f(%rip),%rdi
call   1040 <puts@plt>
xor    %edi,%edi
call   10f0 <exit@plt>
lea    0xc24(%rip),%rdi
jmp    13f5 <main+0x205>
lea    0xc37(%rip),%rdi
call   10c0 <perror@plt>
mov    $0x1,%edi
call   10f0 <exit@plt>

LLVM IR (-O0):
@__const.main.s = [2 x i8] c"\0A "
@stdout = global i32 0
@stdin = global i32 0
@stderr = global i32 0
@.str = [9 x i8] c"netdom> \00"
@.str.1 = [2 x i8] c">\00"
@O_CREAT = global i32 0
@O_TRUNC = global i32 0
@O_WRONLY = global i32 0
@S_IRWXU = global i32 0
@.str.2 = [5 x i8] c"exit\00"
@.str.3 = [4 x i8] c"<3\0A\00"
@.str.4 = [28 x i8] c"Error sporking process o_O\0A\00"
@.str.5 = [12 x i8] c"EXEC ERROR\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [2048 x i8]
%3 = alloca [2 x i8]
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i8**
%7 = alloca i64
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
store i32 0, i32* %1
%16 = bitcast [2 x i8]* %3 to i8*
store i32 0, i32* %5
store i64 0, i64* %7
store i32 0, i32* %8
store i32 0, i32* %10
store i32 0, i32* %11
store i32 0, i32* %12
store i32 0, i32* %13
br label %17
17: ; preds = %0, %117
%18 = load i32, i32* @stdout
%19 = call i32 @fileno(i32 %18)
%20 = load i32, i32* @stdout
%21 = call i32 @fileno(i32 %20)
%22 = call i32 @dup2(i32 %19, i32 %21)
%23 = load i32, i32* @stdin
%24 = call i32 @fileno(i32 %23)
%25 = load i32, i32* @stdin
%26 = call i32 @fileno(i32 %25)
%27 = call i32 @dup2(i32 %24, i32 %26)
%28 = load i32, i32* @stderr
%29 = call i32 @fileno(i32 %28)
%30 = load i32, i32* @stderr
%31 = call i32 @fileno(i32 %30)
%32 = call i32 @dup2(i32 %29, i32 %31)
%33 = call i64 @calloc(i32 20, i32 8)
%34 = inttoptr i64 %33 to i8**
store i8** %34, i8*** %6
store i32 0, i32* %5
%35 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
%36 = getelementptr inbounds [2048 x i8], [2048 x i8]* %2, i64 0, i64 0
%37 = load i32, i32* @stdin
%38 = call i32 @fgets(i8* %36, i32 2048, i32 %37)
%39 = getelementptr inbounds [2048 x i8], [2048 x i8]* %2, i64 0, i64 0
%40 = getelementptr inbounds [2 x i8], [2 x i8]* %3, i64 0, i64 0
%41 = call i8* @strtok(i8* %39, i8* %40)
store i8* %41, i8** %4
br label %42
42: ; preds = %77, %17
%43 = load i8*, i8** %4
%44 = icmp ne i8* %43, null
br i1 %44, label %45, label %80
45: ; preds = %42
%46 = load i8*, i8** %4
%47 = load i8**, i8*** %6
%48 = load i32, i32* %5
%49 = add nsw i32 %48, 1
store i32 %49, i32* %5
%50 = sext i32 %48 to i64
%51 = getelementptr inbounds i8*, i8** %47, i64 %50
store i8* %46, i8** %51
%52 = load i8*, i8** %4
%53 = call i64 @strcmp(i8* %52, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%54 = icmp eq i64 %53, 0
%55 = zext i1 %54 to i32
store i32 %55, i32* %14
br i1 %54, label %56, label %77
56: ; preds = %45
%57 = call i8* @strtok(i8* null, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i8* %57, i8** %4
br label %58
58: ; preds = %64, %56
%59 = load i8*, i8** %4
%60 = getelementptr inbounds i8, i8* %59, i64 0
%61 = load i8, i8* %60
%62 = sext i8 %61 to i32
%63 = icmp eq i32 %62, 32
br i1 %63, label %64, label %67
64: ; preds = %58
%65 = load i8*, i8** %4
%66 = getelementptr inbounds i8, i8* %65, i32 1
store i8* %66, i8** %4
br label %58
67: ; preds = %58
%68 = load i8*, i8** %4
%69 = load i32, i32* @O_CREAT
%70 = load i32, i32* @O_TRUNC
%71 = or i32 %69, %70
%72 = load i32, i32* @O_WRONLY
%73 = or i32 %71, %72
%74 = load i32, i32* @S_IRWXU
%75 = call i32 @open(i8* %68, i32 %73, i32 %74)
%76 = call i32 @dup2(i32 %75, i32 1)
br label %77
77: ; preds = %67, %45
%78 = getelementptr inbounds [2 x i8], [2 x i8]* %3, i64 0, i64 0
%79 = call i8* @strtok(i8* null, i8* %78)
store i8* %79, i8** %4
br label %42
80: ; preds = %42
%81 = load i8**, i8*** %6
%82 = getelementptr inbounds i8*, i8** %81, i64 0
%83 = load i8*, i8** %82
%84 = call i64 @strcmp(i8* %83, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%85 = icmp eq i64 %84, 0
br i1 %85, label %86, label %89
86: ; preds = %80
%87 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%88 = call i32 @exit(i32 0)
unreachable
89: ; preds = %80
%90 = call i64 (...) @fork()
store i64 %90, i64* %7
%91 = icmp slt i64 %90, 0
br i1 %91, label %92, label %95
92: ; preds = %89
%93 = call i32 @perror(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.4, i64 0, i64 0))
%94 = call i32 @exit(i32 1)
unreachable
95: ; preds = %89
%96 = load i64, i64* %7
%97 = icmp eq i64 %96, 0
br i1 %97, label %98, label %110
98: ; preds = %95
%99 = load i8**, i8*** %6
%100 = getelementptr inbounds i8*, i8** %99, i64 0
%101 = load i8*, i8** %100
%102 = load i8**, i8*** %6
%103 = call i64 @execvp(i8* %101, i8** %102)
%104 = icmp slt i64 %103, 0
%105 = zext i1 %104 to i32
store i32 %105, i32* %9
br i1 %104, label %106, label %109
106: ; preds = %98
%107 = call i32 @perror(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.5, i64 0, i64 0))
%108 = call i32 @exit(i32 1)
unreachable
109: ; preds = %98
br label %117
110: ; preds = %95
br label %111
111: ; preds = %115, %110
%112 = call i64 @wait(i32* %8)
%113 = load i64, i64* %7
%114 = icmp ne i64 %112, %113
br i1 %114, label %115, label %116
115: ; preds = %111
br label %111
116: ; preds = %111
br label %117
117: ; preds = %116, %109
%118 = load i8**, i8*** %6
%119 = call i32 @free(i8** %118)
br label %17
}

LLVM IR (-O2):
@stdout = global i32 0
@stdin = global i32 0
@stderr = global i32 0
@.str = [9 x i8] c"netdom> \00"
@.str.1 = [2 x i8] c">\00"
@O_CREAT = global i32 0
@O_TRUNC = global i32 0
@O_WRONLY = global i32 0
@S_IRWXU = global i32 0
@.str.2 = [5 x i8] c"exit\00"
@.str.4 = [28 x i8] c"Error sporking process o_O\0A\00"
@.str.5 = [12 x i8] c"EXEC ERROR\0A\00"
@str = [3 x i8] c"<3\00"
define i32 @main() {
%1 = alloca [2048 x i8]
%2 = alloca i16
%3 = alloca i32
%4 = getelementptr inbounds [2048 x i8], [2048 x i8]* %1, i64 0, i64 0
%5 = bitcast i16* %2 to i8*
store i16 8202, i16* %2
%6 = bitcast i32* %3 to i8*
store i32 0, i32* %3
br label %7
7: ; preds = %81, %0
%8 = load i32, i32* @stdout
%9 = call i32 @fileno(i32 %8)
%10 = load i32, i32* @stdout
%11 = call i32 @fileno(i32 %10)
%12 = call i32 @dup2(i32 %9, i32 %11)
%13 = load i32, i32* @stdin
%14 = call i32 @fileno(i32 %13)
%15 = load i32, i32* @stdin
%16 = call i32 @fileno(i32 %15)
%17 = call i32 @dup2(i32 %14, i32 %16)
%18 = load i32, i32* @stderr
%19 = call i32 @fileno(i32 %18)
%20 = load i32, i32* @stderr
%21 = call i32 @fileno(i32 %20)
%22 = call i32 @dup2(i32 %19, i32 %21)
%23 = call i64 @calloc(i32 20, i32 8)
%24 = inttoptr i64 %23 to i8**
%25 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
%26 = load i32, i32* @stdin
%27 = call i32 @fgets(i8* %4, i32 2048, i32 %26)
%28 = call i8* @strtok(i8* %4, i8* %5)
%29 = icmp eq i8* %28, null
br i1 %29, label %56, label %30
30: ; preds = %7, %53
%31 = phi i64 [ %33, %53 ], [ 0, %7 ]
%32 = phi i8* [ %54, %53 ], [ %28, %7 ]
%33 = add nuw i64 %31, 1
%34 = getelementptr inbounds i8*, i8** %24, i64 %31
store i8* %32, i8** %34
%35 = call i64 @strcmp(i8* %32, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%36 = icmp eq i64 %35, 0
br i1 %36, label %37, label %53
37: ; preds = %30
%38 = call i8* @strtok(i8* null, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %39
39: ; preds = %39, %37
%40 = phi i8* [ %38, %37 ], [ %43, %39 ]
%41 = load i8, i8* %40
%42 = icmp eq i8 %41, 32
%43 = getelementptr inbounds i8, i8* %40, i64 1
br i1 %42, label %39, label %44
44: ; preds = %39
%45 = load i32, i32* @O_CREAT
%46 = load i32, i32* @O_TRUNC
%47 = or i32 %46, %45
%48 = load i32, i32* @O_WRONLY
%49 = or i32 %47, %48
%50 = load i32, i32* @S_IRWXU
%51 = call i32 @open(i8* %40, i32 %49, i32 %50)
%52 = call i32 @dup2(i32 %51, i32 1)
br label %53
53: ; preds = %44, %30
%54 = call i8* @strtok(i8* null, i8* %5)
%55 = icmp eq i8* %54, null
br i1 %55, label %56, label %30
56: ; preds = %53, %7
%57 = load i8*, i8** %24
%58 = call i64 @strcmp(i8* %57, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%59 = icmp eq i64 %58, 0
br i1 %59, label %60, label %63
60: ; preds = %56
%61 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @str, i64 0, i64 0))
%62 = call i32 @exit(i32 0)
unreachable
63: ; preds = %56
%64 = call i64 (...) @fork()
%65 = icmp slt i64 %64, 0
br i1 %65, label %66, label %69
66: ; preds = %63
%67 = call i32 @perror(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.4, i64 0, i64 0))
%68 = call i32 @exit(i32 1)
unreachable
69: ; preds = %63
%70 = icmp eq i64 %64, 0
br i1 %70, label %71, label %78
71: ; preds = %69
%72 = load i8*, i8** %24
%73 = call i64 @execvp(i8* %72, i8** %24)
%74 = icmp slt i64 %73, 0
br i1 %74, label %75, label %81
75: ; preds = %71
%76 = call i32 @perror(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.5, i64 0, i64 0))
%77 = call i32 @exit(i32 1)
unreachable
78: ; preds = %69, %78
%79 = call i64 @wait(i32* %3)
%80 = icmp eq i64 %79, %64
br i1 %80, label %81, label %78
81: ; preds = %78, %71
%82 = call i32 @free(i8** %24)
br label %7
}