#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 */
struct dirent {
  char *d_name;
};
typedef int /*<<< orphan*/ DIR;

/* Variables and functions */
int /*<<< orphan*/ closedir(int /*<<< orphan*/ *);
int /*<<< orphan*/ execlp(char *, char *, char *, char *, char *,
                          int /*<<< orphan*/ *);
int /*<<< orphan*/ exit(int);
scalar_t__ fork();
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ *opendir(char *);
int /*<<< orphan*/ printf(char *, ...);
struct dirent *readdir(int /*<<< orphan*/ *);
int /*<<< orphan*/ setbuf(int /*<<< orphan*/, int /*<<< orphan*/ *);
int /*<<< orphan*/ stderr;
int /*<<< orphan*/ stdout;
int /*<<< orphan*/ strcat(char *, char *);
scalar_t__ strcmp(char *, char *);
int /*<<< orphan*/ strcpy(char *, char *);
char *strtok(char *, char *);
int /*<<< orphan*/ wait(int /*<<< orphan*/ *);
int main(int argc, char *argv[]) {
  if (argc != 2) {
    printf("Usage: %s <dir>\n", argv[0]);
    exit(2);
  }
  setbuf(stdout, NULL);
  char word_d[80];
  strcpy(word_d, argv[1]);
  strcat(word_d, "words.txt");
  printf("+-------------------------------\n");
  printf("|Words dired: %s\n", word_d);
  DIR *dp;
  struct dirent *ep;
  dp = opendir(argv[1]);
  if (dp != NULL) {
    while ((ep = readdir(dp)) != NULL) {
      if (strcmp(ep->d_name, ".") == 0 || strcmp(ep->d_name, "..") == 0 ||
          strcmp(ep->d_name, "words.txt") == 0) {
        continue;
      }
      char temp[80];
      strcpy(temp, ep->d_name);
      char *pch;
      pch = strtok(temp, ".");
      char dired[80];
      strcpy(dired, argv[1]);
      strcat(dired, ep->d_name);
      printf("+-------------------------------\n");
      printf("|Dired: %s\n", dired);
      printf("+-------------------------------\n");
      printf("| executing \"sw %s %s %s\"\n", dired, pch, word_d);
      printf("|");
      if (fork() == 0) {
        execlp("./sw", "./sw", dired, pch, word_d, NULL);
        fprintf(stderr, "**ERROR** sw not executed **ERROR**\n");
        exit(3);
      }
      wait(NULL);
    }
    printf("+-------------------------------\n");
    (void)closedir(dp);
  } else
    fprintf(stderr, "Couldn't open the directory");
  exit(0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x120,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
je     1222 <main+0x42>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xdef(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    $0x2,%edi
call   10d0 <exit@plt>
mov    0x2daf(%rip),%rax
mov    (%rax),%edi
xor    %eax,%eax
mov    %eax,%esi
call   1050 <setbuf@plt>
lea    -0x60(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rsi
call   1030 <strcpy@plt>
lea    -0x60(%rbp),%rdi
lea    0xdc1(%rip),%rsi
call   10c0 <strcat@plt>
lea    0xdbf(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0x60(%rbp),%rsi
lea    0xdcf(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1040 <opendir@plt>
mov    %rax,-0x68(%rbp)
cmpq   $0x0,-0x68(%rbp)
je     143c <main+0x25c>
jmp    1296 <main+0xb6>
mov    -0x68(%rbp),%rdi
call   10a0 <readdir@plt>
mov    %rax,-0x70(%rbp)
cmp    $0x0,%rax
je     1420 <main+0x240>
mov    -0x70(%rbp),%rax
mov    (%rax),%rdi
lea    0xd95(%rip),%rsi
call   1080 <strcmp@plt>
cmp    $0x0,%rax
je     1304 <main+0x124>
mov    -0x70(%rbp),%rax
mov    (%rax),%rdi
lea    0xd77(%rip),%rsi
call   1080 <strcmp@plt>
cmp    $0x0,%rax
je     1304 <main+0x124>
mov    -0x70(%rbp),%rax
mov    (%rax),%rdi
lea    0xd1c(%rip),%rsi
call   1080 <strcmp@plt>
cmp    $0x0,%rax
jne    1309 <main+0x129>
jmp    1296 <main+0xb6>
lea    -0xc0(%rbp),%rdi
mov    -0x70(%rbp),%rax
mov    (%rax),%rsi
call   1030 <strcpy@plt>
lea    -0xc0(%rbp),%rdi
lea    0xd26(%rip),%rsi
call   10b0 <strtok@plt>
mov    %rax,-0xc8(%rbp)
lea    -0x120(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rsi
call   1030 <strcpy@plt>
lea    -0x120(%rbp),%rdi
mov    -0x70(%rbp),%rax
mov    (%rax),%rsi
call   10c0 <strcat@plt>
lea    0xcb7(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0x120(%rbp),%rsi
lea    0xcd9(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xc94(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0x120(%rbp),%rsi
mov    -0xc8(%rbp),%rdx
lea    -0x60(%rbp),%rcx
lea    0xcb7(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xcc4(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    $0x0,%al
call   1100 <fork@plt>
cmp    $0x0,%rax
jne    1412 <main+0x232>
lea    -0x120(%rbp),%rdx
mov    -0xc8(%rbp),%rcx
lea    -0x60(%rbp),%r8
lea    0xc95(%rip),%rsi
xor    %eax,%eax
mov    %eax,%r9d
mov    %rsi,%rdi
call   10e0 <execlp@plt>
mov    0x2be6(%rip),%rax
mov    (%rax),%edi
lea    0xc7d(%rip),%rsi
call   1090 <fprintf@plt>
mov    $0x3,%edi
call   10d0 <exit@plt>
xor    %eax,%eax
mov    %eax,%edi
call   10f0 <wait@plt>
jmp    1296 <main+0xb6>
lea    0xbf4(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x68(%rbp),%rdi
call   1070 <closedir@plt>
jmp    1451 <main+0x271>
mov    0x2b9d(%rip),%rax
mov    (%rax),%edi
lea    0xc59(%rip),%rsi
call   1090 <fprintf@plt>
xor    %edi,%edi
call   10d0 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x108,%rsp
mov    %rsi,%rbp
cmp    $0x2,%edi
jne    1290 <main+0x90>
mov    0x2db8(%rip),%rax
mov    (%rax),%edi
xor    %esi,%esi
call   1070 <setbuf@plt>
mov    0x8(%rbp),%rsi
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <strcpy@plt>
lea    0xdd0(%rip),%rsi
mov    %rbx,%rdi
call   10e0 <strcat@plt>
lea    0xe4d(%rip),%rdi
call   1050 <puts@plt>
lea    0xdbf(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1080 <printf@plt>
mov    0x8(%rbp),%rdi
call   1060 <opendir@plt>
test   %rax,%rax
jne    12ac <main+0xac>
mov    0x2d65(%rip),%rax
mov    (%rax),%edi
lea    0xdfd(%rip),%rsi
call   10b0 <fprintf@plt>
xor    %edi,%edi
call   10f0 <exit@plt>
mov    0x0(%rbp),%rsi
lea    0xd65(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    $0x2,%edi
call   10f0 <exit@plt>
mov    %rax,%r12
mov    %rbp,0x8(%rsp)
mov    %rax,%rdi
call   10c0 <readdir@plt>
test   %rax,%rax
jne    12dc <main+0xdc>
lea    0xdd5(%rip),%rdi
call   1050 <puts@plt>
mov    %r12,%rdi
call   1090 <closedir@plt>
xor    %edi,%edi
call   10f0 <exit@plt>
mov    %rax,%rbp
lea    0xd48(%rip),%r15
lea    0xd40(%rip),%r14
jmp    1300 <main+0x100>
nop
mov    %r12,%rdi
call   10c0 <readdir@plt>
mov    %rax,%rbp
test   %rax,%rax
je     12c1 <main+0xc1>
mov    0x0(%rbp),%rdi
mov    %r15,%rsi
call   10a0 <strcmp@plt>
test   %rax,%rax
je     12f0 <main+0xf0>
mov    0x0(%rbp),%rdi
mov    %r14,%rsi
call   10a0 <strcmp@plt>
test   %rax,%rax
je     12f0 <main+0xf0>
mov    0x0(%rbp),%rdi
lea    0xce4(%rip),%rsi
call   10a0 <strcmp@plt>
test   %rax,%rax
je     12f0 <main+0xf0>
mov    0x0(%rbp),%rsi
lea    0xb0(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <strcpy@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
call   10d0 <strtok@plt>
mov    %rax,%r13
mov    0x8(%rsp),%rax
mov    0x8(%rax),%rsi
lea    0x60(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <strcpy@plt>
mov    0x0(%rbp),%rsi
mov    %rbx,%rdi
call   10e0 <strcat@plt>
lea    0xd1b(%rip),%rbp
mov    %rbp,%rdi
call   1050 <puts@plt>
lea    0xc9f(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %rbp,%rdi
call   1050 <puts@plt>
lea    0xc92(%rip),%rdi
mov    %rbx,%rsi
mov    %r13,%rdx
lea    0x10(%rsp),%rcx
xor    %eax,%eax
call   1080 <printf@plt>
mov    $0x7c,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
call   1120 <fork@plt>
test   %rax,%rax
je     13de <main+0x1de>
xor    %edi,%edi
call   1110 <wait@plt>
jmp    12f0 <main+0xf0>
lea    0xc72(%rip),%rdi
lea    0x60(%rsp),%rdx
lea    0x10(%rsp),%r8
mov    %rdi,%rsi
mov    %r13,%rcx
xor    %r9d,%r9d
call   1100 <execlp@plt>
mov    0x2bdc(%rip),%rax
mov    (%rax),%edi
lea    0xc4f(%rip),%rsi
call   10b0 <fprintf@plt>
mov    $0x3,%edi
call   10f0 <exit@plt>

LLVM IR (-O0):
%struct.dirent = type { i8* }
@.str = [17 x i8] c"Usage: %s <dir>\0A\00"
@stdout = global i32 0
@.str.1 = [10 x i8] c"words.txt\00"
@.str.2 = [34 x i8] c"+-------------------------------\0A\00"
@.str.3 = [18 x i8] c"|Words dired: %s\0A\00"
@.str.4 = [2 x i8] c".\00"
@.str.5 = [3 x i8] c"..\00"
@.str.6 = [12 x i8] c"|Dired: %s\0A\00"
@.str.7 = [27 x i8] c"| executing \22sw %s %s %s\22\0A\00"
@.str.8 = [2 x i8] c"|\00"
@.str.9 = [5 x i8] c"./sw\00"
@stderr = global i32 0
@.str.10 = [37 x i8] c"**ERROR** sw not executed **ERROR**\0A\00"
@.str.11 = [28 x i8] c"Couldn't open the directory\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca [80 x i8]
%7 = alloca i32*
%8 = alloca %struct.dirent*
%9 = alloca [80 x i8]
%10 = alloca i8*
%11 = alloca [80 x i8]
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%12 = load i32, i32* %4
%13 = icmp ne i32 %12, 2
br i1 %13, label %14, label %20
14: ; preds = %2
%15 = load i8**, i8*** %5
%16 = getelementptr inbounds i8*, i8** %15, i64 0
%17 = load i8*, i8** %16
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i8* %17)
%19 = call i32 @exit(i32 2)
unreachable
20: ; preds = %2
%21 = load i32, i32* @stdout
%22 = call i32 @setbuf(i32 %21, i32* null)
%23 = getelementptr inbounds [80 x i8], [80 x i8]* %6, i64 0, i64 0
%24 = load i8**, i8*** %5
%25 = getelementptr inbounds i8*, i8** %24, i64 1
%26 = load i8*, i8** %25
%27 = call i32 @strcpy(i8* %23, i8* %26)
%28 = getelementptr inbounds [80 x i8], [80 x i8]* %6, i64 0, i64 0
%29 = call i32 @strcat(i8* %28, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%30 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.2, i64 0, i64 0))
%31 = getelementptr inbounds [80 x i8], [80 x i8]* %6, i64 0, i64 0
%32 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0), i8* %31)
%33 = load i8**, i8*** %5
%34 = getelementptr inbounds i8*, i8** %33, i64 1
%35 = load i8*, i8** %34
%36 = call i32* @opendir(i8* %35)
store i32* %36, i32** %7
%37 = load i32*, i32** %7
%38 = icmp ne i32* %37, null
br i1 %38, label %39, label %106
39: ; preds = %20
br label %40
40: ; preds = %100, %62, %39
%41 = load i32*, i32** %7
%42 = call %struct.dirent* @readdir(i32* %41)
store %struct.dirent* %42, %struct.dirent** %8
%43 = icmp ne %struct.dirent* %42, null
br i1 %43, label %44, label %102
44: ; preds = %40
%45 = load %struct.dirent*, %struct.dirent** %8
%46 = getelementptr inbounds %struct.dirent, %struct.dirent* %45, i32 0, i32 0
%47 = load i8*, i8** %46
%48 = call i64 @strcmp(i8* %47, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%49 = icmp eq i64 %48, 0
br i1 %49, label %62, label %50
50: ; preds = %44
%51 = load %struct.dirent*, %struct.dirent** %8
%52 = getelementptr inbounds %struct.dirent, %struct.dirent* %51, i32 0, i32 0
%53 = load i8*, i8** %52
%54 = call i64 @strcmp(i8* %53, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0))
%55 = icmp eq i64 %54, 0
br i1 %55, label %62, label %56
56: ; preds = %50
%57 = load %struct.dirent*, %struct.dirent** %8
%58 = getelementptr inbounds %struct.dirent, %struct.dirent* %57, i32 0, i32 0
%59 = load i8*, i8** %58
%60 = call i64 @strcmp(i8* %59, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%61 = icmp eq i64 %60, 0
br i1 %61, label %62, label %63
62: ; preds = %56, %50, %44
br label %40
63: ; preds = %56
%64 = getelementptr inbounds [80 x i8], [80 x i8]* %9, i64 0, i64 0
%65 = load %struct.dirent*, %struct.dirent** %8
%66 = getelementptr inbounds %struct.dirent, %struct.dirent* %65, i32 0, i32 0
%67 = load i8*, i8** %66
%68 = call i32 @strcpy(i8* %64, i8* %67)
%69 = getelementptr inbounds [80 x i8], [80 x i8]* %9, i64 0, i64 0
%70 = call i8* @strtok(i8* %69, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
store i8* %70, i8** %10
%71 = getelementptr inbounds [80 x i8], [80 x i8]* %11, i64 0, i64 0
%72 = load i8**, i8*** %5
%73 = getelementptr inbounds i8*, i8** %72, i64 1
%74 = load i8*, i8** %73
%75 = call i32 @strcpy(i8* %71, i8* %74)
%76 = getelementptr inbounds [80 x i8], [80 x i8]* %11, i64 0, i64 0
%77 = load %struct.dirent*, %struct.dirent** %8
%78 = getelementptr inbounds %struct.dirent, %struct.dirent* %77, i32 0, i32 0
%79 = load i8*, i8** %78
%80 = call i32 @strcat(i8* %76, i8* %79)
%81 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.2, i64 0, i64 0))
%82 = getelementptr inbounds [80 x i8], [80 x i8]* %11, i64 0, i64 0
%83 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.6, i64 0, i64 0), i8* %82)
%84 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.2, i64 0, i64 0))
%85 = getelementptr inbounds [80 x i8], [80 x i8]* %11, i64 0, i64 0
%86 = load i8*, i8** %10
%87 = getelementptr inbounds [80 x i8], [80 x i8]* %6, i64 0, i64 0
%88 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.7, i64 0, i64 0), i8* %85, i8* %86, i8* %87)
%89 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%90 = call i64 (...) @fork()
%91 = icmp eq i64 %90, 0
br i1 %91, label %92, label %100
92: ; preds = %63
%93 = getelementptr inbounds [80 x i8], [80 x i8]* %11, i64 0, i64 0
%94 = load i8*, i8** %10
%95 = getelementptr inbounds [80 x i8], [80 x i8]* %6, i64 0, i64 0
%96 = call i32 @execlp(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* %93, i8* %94, i8* %95, i32* null)
%97 = load i32, i32* @stderr
%98 = call i32 @fprintf(i32 %97, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.10, i64 0, i64 0))
%99 = call i32 @exit(i32 3)
unreachable
100: ; preds = %63
%101 = call i32 @wait(i32* null)
br label %40
102: ; preds = %40
%103 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.2, i64 0, i64 0))
%104 = load i32*, i32** %7
%105 = call i32 @closedir(i32* %104)
br label %109
106: ; preds = %20
%107 = load i32, i32* @stderr
%108 = call i32 @fprintf(i32 %107, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.11, i64 0, i64 0))
br label %109
109: ; preds = %106, %102
%110 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
%struct.dirent = type { i8* }
@.str = [17 x i8] c"Usage: %s <dir>\0A\00"
@stdout = global i32 0
@.str.1 = [10 x i8] c"words.txt\00"
@.str.3 = [18 x i8] c"|Words dired: %s\0A\00"
@.str.4 = [2 x i8] c".\00"
@.str.5 = [3 x i8] c"..\00"
@.str.6 = [12 x i8] c"|Dired: %s\0A\00"
@.str.7 = [27 x i8] c"| executing \22sw %s %s %s\22\0A\00"
@.str.9 = [5 x i8] c"./sw\00"
@stderr = global i32 0
@.str.10 = [37 x i8] c"**ERROR** sw not executed **ERROR**\0A\00"
@.str.11 = [28 x i8] c"Couldn't open the directory\00"
@str.14 = [33 x i8] c"+-------------------------------\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca [80 x i8]
%4 = alloca [80 x i8]
%5 = alloca [80 x i8]
%6 = icmp eq i32 %0, 2
br i1 %6, label %11, label %7
7: ; preds = %2
%8 = load i8*, i8** %1
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i8* %8)
%10 = tail call i32 @exit(i32 2)
unreachable
11: ; preds = %2
%12 = load i32, i32* @stdout
%13 = tail call i32 @setbuf(i32 %12, i32* null)
%14 = getelementptr inbounds [80 x i8], [80 x i8]* %3, i64 0, i64 0
%15 = getelementptr inbounds i8*, i8** %1, i64 1
%16 = load i8*, i8** %15
%17 = call i32 @strcpy(i8* %14, i8* %16)
%18 = call i32 @strcat(i8* %14, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%19 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.14, i64 0, i64 0))
%20 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0), i8* %14)
%21 = load i8*, i8** %15
%22 = call i32* @opendir(i8* %21)
%23 = icmp eq i32* %22, null
br i1 %23, label %72, label %24
24: ; preds = %11
%25 = call %struct.dirent* @readdir(i32* %22)
%26 = icmp eq %struct.dirent* %25, null
br i1 %26, label %69, label %27
27: ; preds = %24
%28 = getelementptr inbounds [80 x i8], [80 x i8]* %4, i64 0, i64 0
%29 = getelementptr inbounds [80 x i8], [80 x i8]* %5, i64 0, i64 0
br label %30
30: ; preds = %27, %44
%31 = phi %struct.dirent* [ %25, %27 ], [ %45, %44 ]
%32 = getelementptr inbounds %struct.dirent, %struct.dirent* %31, i64 0, i32 0
%33 = load i8*, i8** %32
%34 = call i64 @strcmp(i8* %33, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%35 = icmp eq i64 %34, 0
br i1 %35, label %44, label %36
36: ; preds = %30
%37 = load i8*, i8** %32
%38 = call i64 @strcmp(i8* %37, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0))
%39 = icmp eq i64 %38, 0
br i1 %39, label %44, label %40
40: ; preds = %36
%41 = load i8*, i8** %32
%42 = call i64 @strcmp(i8* %41, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%43 = icmp eq i64 %42, 0
br i1 %43, label %44, label %47
44: ; preds = %30, %36, %40, %67
%45 = call %struct.dirent* @readdir(i32* %22)
%46 = icmp eq %struct.dirent* %45, null
br i1 %46, label %69, label %30
47: ; preds = %40
%48 = load i8*, i8** %32
%49 = call i32 @strcpy(i8* %28, i8* %48)
%50 = call i8* @strtok(i8* %28, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%51 = load i8*, i8** %15
%52 = call i32 @strcpy(i8* %29, i8* %51)
%53 = load i8*, i8** %32
%54 = call i32 @strcat(i8* %29, i8* %53)
%55 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.14, i64 0, i64 0))
%56 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.6, i64 0, i64 0), i8* %29)
%57 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.14, i64 0, i64 0))
%58 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @.str.7, i64 0, i64 0), i8* %29, i8* %50, i8* %14)
%59 = call i32 @putchar(i32 124)
%60 = call i64 (...) @fork()
%61 = icmp eq i64 %60, 0
br i1 %61, label %62, label %67
62: ; preds = %47
%63 = call i32 @execlp(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* %29, i8* %50, i8* %14, i32* null)
%64 = load i32, i32* @stderr
%65 = call i32 @fprintf(i32 %64, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.10, i64 0, i64 0))
%66 = call i32 @exit(i32 3)
unreachable
67: ; preds = %47
%68 = call i32 @wait(i32* null)
br label %44
69: ; preds = %44, %24
%70 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.14, i64 0, i64 0))
%71 = call i32 @closedir(i32* %22)
br label %75
72: ; preds = %11
%73 = load i32, i32* @stderr
%74 = call i32 @fprintf(i32 %73, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.11, i64 0, i64 0))
br label %75
75: ; preds = %72, %69
%76 = call i32 @exit(i32 0)
unreachable
}