#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 */
typedef struct TYPE_8__ TYPE_2__;
typedef struct TYPE_7__ TYPE_1__;

/* Type definitions */
struct TYPE_8__ {
  int fts_options;
  TYPE_1__ *fts_child;
  TYPE_1__ *fts_cur;
};
struct TYPE_7__ {
  scalar_t__ fts_info;
  scalar_t__ fts_level;
  char *fts_accpath;
  struct TYPE_7__ *fts_link;
};
typedef TYPE_1__ FTSENT;
typedef TYPE_2__ FTS;

/* Variables and functions */
scalar_t__ EINVAL;
scalar_t__ FTS_D;
scalar_t__ FTS_INIT;
int FTS_NAMEONLY;
int FTS_NOCHDIR;
scalar_t__ FTS_ROOTLEVEL;
int FTS_STOP;
int O_RDONLY;
int /*<<< orphan*/ close(int);
scalar_t__ errno;
scalar_t__ fchdir(int);
void *fts_build(TYPE_2__ *, int);
int /*<<< orphan*/ fts_lfree(TYPE_1__ *);
int open(char *, int, int /*<<< orphan*/);
FTSENT *fts_children(FTS *sp, int instr) {
  FTSENT *p;
  int fd;
  ;
  if (instr && instr != FTS_NAMEONLY) {
    errno = EINVAL;
    return (NULL);
  }
  p = sp->fts_cur;
  errno = 0;
  if ((sp->fts_options & (FTS_STOP)))
    return (NULL);
  if (p->fts_info == FTS_INIT)
    return (p->fts_link);
  if (p->fts_info != FTS_D)
    return (NULL);
  if (sp->fts_child)
    fts_lfree(sp->fts_child);
  if (instr == FTS_NAMEONLY) {
    (sp->fts_options |= (FTS_NAMEONLY));
    instr = 2;
  } else
    instr = 1;
  if (p->fts_level != FTS_ROOTLEVEL || p->fts_accpath[0] == '/' ||
      (sp->fts_options & (FTS_NOCHDIR)))
    return (sp->fts_child = fts_build(sp, instr));
  if ((fd = open(".", O_RDONLY | 0, 0)) == -1)
    return (sp->fts_child = NULL);
  sp->fts_child = fts_build(sp, instr);
  if (fchdir(fd)) {
    (void)close(fd);
    return (NULL);
  }
  (void)close(fd);
  return (sp->fts_child);
}


x86 assembly (clang, -O0):
<fts_children>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
je     119c <fts_children+0x4c>
mov    -0x14(%rbp),%eax
mov    0x2e45(%rip),%rcx
cmp    (%rcx),%eax
je     119c <fts_children+0x4c>
mov    0x2e26(%rip),%rax
mov    (%rax),%rcx
mov    0x2e3c(%rip),%rax
mov    %rcx,(%rax)
movq   $0x0,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rax
mov    %rax,-0x20(%rbp)
mov    0x2e19(%rip),%rax
movq   $0x0,(%rax)
mov    -0x10(%rbp),%rax
mov    (%rax),%eax
mov    0x2ddd(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     11db <fts_children+0x8b>
movq   $0x0,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    -0x20(%rbp),%rax
mov    (%rax),%rax
mov    0x2dc7(%rip),%rcx
cmp    (%rcx),%rax
jne    1203 <fts_children+0xb3>
mov    -0x20(%rbp),%rax
mov    0x18(%rax),%rax
mov    %rax,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    -0x20(%rbp),%rax
mov    (%rax),%rax
mov    0x2dc7(%rip),%rcx
cmp    (%rcx),%rax
je     1227 <fts_children+0xd7>
movq   $0x0,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    -0x10(%rbp),%rax
cmpq   $0x0,0x8(%rax)
je     1243 <fts_children+0xf3>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1040 <fts_lfree@plt>
mov    -0x14(%rbp),%eax
mov    0x2d6b(%rip),%rcx
cmp    (%rcx),%eax
jne    1272 <fts_children+0x122>
mov    0x2d5c(%rip),%rax
mov    (%rax),%ecx
mov    -0x10(%rbp),%rax
or     (%rax),%ecx
mov    %ecx,(%rax)
movl   $0x2,-0x14(%rbp)
jmp    1279 <fts_children+0x129>
movl   $0x1,-0x14(%rbp)
mov    -0x20(%rbp),%rax
mov    0x8(%rax),%rax
mov    0x2d60(%rip),%rcx
cmp    (%rcx),%rax
jne    12bd <fts_children+0x16d>
mov    -0x20(%rbp),%rax
mov    0x10(%rax),%rax
movsbl (%rax),%eax
cmp    $0x2f,%eax
je     12bd <fts_children+0x16d>
mov    -0x10(%rbp),%rax
mov    (%rax),%eax
mov    0x2d0e(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     12da <fts_children+0x18a>
mov    -0x10(%rbp),%rdi
mov    -0x14(%rbp),%esi
call   1070 <fts_build@plt>
mov    -0x10(%rbp),%rcx
mov    %rax,0x8(%rcx)
mov    %rax,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    0x2cff(%rip),%rax
mov    (%rax),%esi
or     $0x0,%esi
lea    0xd13(%rip),%rdi
xor    %edx,%edx
call   1060 <open@plt>
mov    %eax,-0x24(%rbp)
cmp    $0xffffffff,%eax
jne    1319 <fts_children+0x1c9>
mov    -0x10(%rbp),%rax
movq   $0x0,0x8(%rax)
movq   $0x0,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    -0x10(%rbp),%rdi
mov    -0x14(%rbp),%esi
call   1070 <fts_build@plt>
mov    %rax,%rcx
mov    -0x10(%rbp),%rax
mov    %rcx,0x8(%rax)
mov    -0x24(%rbp),%edi
call   1050 <fchdir@plt>
cmp    $0x0,%rax
je     1357 <fts_children+0x207>
mov    -0x24(%rbp),%edi
call   1030 <close@plt>
movq   $0x0,-0x8(%rbp)
jmp    136b <fts_children+0x21b>
mov    -0x24(%rbp),%edi
call   1030 <close@plt>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fts_children>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
mov    %esi,%ebp
mov    %rdi,%r12
mov    0x2e54(%rip),%rbx
mov    (%rbx),%eax
test   %esi,%esi
je     1184 <fts_children+0x34>
cmp    %ebp,%eax
je     1184 <fts_children+0x34>
mov    0x2e33(%rip),%rax
mov    (%rax),%rax
mov    0x2e49(%rip),%rcx
mov    %rax,(%rcx)
jmp    11a6 <fts_children+0x56>
mov    0x10(%r12),%r15
mov    0x2e38(%rip),%rcx
movq   $0x0,(%rcx)
mov    0x2e02(%rip),%rcx
mov    (%rcx),%ecx
test   %ecx,(%r12)
je     11b1 <fts_children+0x61>
xor    %eax,%eax
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret
mov    (%r15),%rcx
mov    0x2df5(%rip),%rdx
cmp    (%rdx),%rcx
jne    11c6 <fts_children+0x76>
mov    0x18(%r15),%rax
jmp    11a8 <fts_children+0x58>
mov    0x2e0b(%rip),%rdx
cmp    (%rdx),%rcx
jne    11a6 <fts_children+0x56>
mov    0x8(%r12),%rdi
test   %rdi,%rdi
je     11e3 <fts_children+0x93>
call   1040 <fts_lfree@plt>
mov    (%rbx),%eax
mov    $0x1,%r14d
cmp    %ebp,%eax
jne    11f7 <fts_children+0xa7>
or     %ebp,(%r12)
mov    $0x2,%r14d
mov    0x8(%r15),%rax
mov    0x2de6(%rip),%rcx
cmp    (%rcx),%rax
jne    121f <fts_children+0xcf>
mov    0x10(%r15),%rax
cmpb   $0x2f,(%rax)
je     121f <fts_children+0xcf>
mov    0x2da9(%rip),%rax
mov    (%rax),%eax
test   %eax,(%r12)
je     1234 <fts_children+0xe4>
mov    %r12,%rdi
mov    %r14d,%esi
call   1070 <fts_build@plt>
mov    %rax,0x8(%r12)
jmp    11a8 <fts_children+0x58>
mov    0x2da5(%rip),%rax
mov    (%rax),%esi
lea    0xdbc(%rip),%rdi
xor    %edx,%edx
call   1060 <open@plt>
cmp    $0xffffffff,%eax
je     1286 <fts_children+0x136>
mov    %eax,%ebp
mov    %r12,%rdi
mov    %r14d,%esi
call   1070 <fts_build@plt>
mov    %rax,0x8(%r12)
mov    %ebp,%edi
call   1050 <fchdir@plt>
mov    %rax,%r14
mov    %ebp,%edi
call   1030 <close@plt>
test   %r14,%r14
jne    11a6 <fts_children+0x56>
mov    0x8(%r12),%rax
jmp    11a8 <fts_children+0x58>
movq   $0x0,0x8(%r12)
jmp    11a6 <fts_children+0x56>

LLVM IR (-O0):
%struct.TYPE_7__ = type { i64, i64, i8*, %struct.TYPE_7__* }
%struct.TYPE_8__ = type { i32, %struct.TYPE_7__*, %struct.TYPE_7__* }
@FTS_NAMEONLY = global i32 0
@EINVAL = global i64 0
@errno = global i64 0
@FTS_STOP = global i32 0
@FTS_INIT = global i64 0
@FTS_D = global i64 0
@FTS_ROOTLEVEL = global i64 0
@FTS_NOCHDIR = global i32 0
@.str = [2 x i8] c".\00"
@O_RDONLY = global i32 0
define %struct.TYPE_7__* @fts_children(%struct.TYPE_8__* %0, i32 %1) {
%3 = alloca %struct.TYPE_7__*
%4 = alloca %struct.TYPE_8__*
%5 = alloca i32
%6 = alloca %struct.TYPE_7__*
%7 = alloca i32
store %struct.TYPE_8__* %0, %struct.TYPE_8__** %4
store i32 %1, i32* %5
%8 = load i32, i32* %5
%9 = icmp ne i32 %8, 0
br i1 %9, label %10, label %16
10: ; preds = %2
%11 = load i32, i32* %5
%12 = load i32, i32* @FTS_NAMEONLY
%13 = icmp ne i32 %11, %12
br i1 %13, label %14, label %16
14: ; preds = %10
%15 = load i64, i64* @EINVAL
store i64 %15, i64* @errno
store %struct.TYPE_7__* null, %struct.TYPE_7__** %3
br label %120
16: ; preds = %10, %2
%17 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%18 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %17, i32 0, i32 2
%19 = load %struct.TYPE_7__*, %struct.TYPE_7__** %18
store %struct.TYPE_7__* %19, %struct.TYPE_7__** %6
store i64 0, i64* @errno
%20 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%21 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %20, i32 0, i32 0
%22 = load i32, i32* %21
%23 = load i32, i32* @FTS_STOP
%24 = and i32 %22, %23
%25 = icmp ne i32 %24, 0
br i1 %25, label %26, label %27
26: ; preds = %16
store %struct.TYPE_7__* null, %struct.TYPE_7__** %3
br label %120
27: ; preds = %16
%28 = load %struct.TYPE_7__*, %struct.TYPE_7__** %6
%29 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %28, i32 0, i32 0
%30 = load i64, i64* %29
%31 = load i64, i64* @FTS_INIT
%32 = icmp eq i64 %30, %31
br i1 %32, label %33, label %37
33: ; preds = %27
%34 = load %struct.TYPE_7__*, %struct.TYPE_7__** %6
%35 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %34, i32 0, i32 3
%36 = load %struct.TYPE_7__*, %struct.TYPE_7__** %35
store %struct.TYPE_7__* %36, %struct.TYPE_7__** %3
br label %120
37: ; preds = %27
%38 = load %struct.TYPE_7__*, %struct.TYPE_7__** %6
%39 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %38, i32 0, i32 0
%40 = load i64, i64* %39
%41 = load i64, i64* @FTS_D
%42 = icmp ne i64 %40, %41
br i1 %42, label %43, label %44
43: ; preds = %37
store %struct.TYPE_7__* null, %struct.TYPE_7__** %3
br label %120
44: ; preds = %37
%45 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%46 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %45, i32 0, i32 1
%47 = load %struct.TYPE_7__*, %struct.TYPE_7__** %46
%48 = icmp ne %struct.TYPE_7__* %47, null
br i1 %48, label %49, label %54
49: ; preds = %44
%50 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%51 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %50, i32 0, i32 1
%52 = load %struct.TYPE_7__*, %struct.TYPE_7__** %51
%53 = call i32 @fts_lfree(%struct.TYPE_7__* %52)
br label %54
54: ; preds = %49, %44
%55 = load i32, i32* %5
%56 = load i32, i32* @FTS_NAMEONLY
%57 = icmp eq i32 %55, %56
br i1 %57, label %58, label %64
58: ; preds = %54
%59 = load i32, i32* @FTS_NAMEONLY
%60 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%61 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %60, i32 0, i32 0
%62 = load i32, i32* %61
%63 = or i32 %62, %59
store i32 %63, i32* %61
store i32 2, i32* %5
br label %65
64: ; preds = %54
store i32 1, i32* %5
br label %65
65: ; preds = %64, %58
%66 = load %struct.TYPE_7__*, %struct.TYPE_7__** %6
%67 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %66, i32 0, i32 1
%68 = load i64, i64* %67
%69 = load i64, i64* @FTS_ROOTLEVEL
%70 = icmp ne i64 %68, %69
br i1 %70, label %86, label %71
71: ; preds = %65
%72 = load %struct.TYPE_7__*, %struct.TYPE_7__** %6
%73 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %72, i32 0, i32 2
%74 = load i8*, i8** %73
%75 = getelementptr inbounds i8, i8* %74, i64 0
%76 = load i8, i8* %75
%77 = sext i8 %76 to i32
%78 = icmp eq i32 %77, 47
br i1 %78, label %86, label %79
79: ; preds = %71
%80 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%81 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %80, i32 0, i32 0
%82 = load i32, i32* %81
%83 = load i32, i32* @FTS_NOCHDIR
%84 = and i32 %82, %83
%85 = icmp ne i32 %84, 0
br i1 %85, label %86, label %93
86: ; preds = %79, %71, %65
%87 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%88 = load i32, i32* %5
%89 = call i8* @fts_build(%struct.TYPE_8__* %87, i32 %88)
%90 = bitcast i8* %89 to %struct.TYPE_7__*
%91 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%92 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %91, i32 0, i32 1
store %struct.TYPE_7__* %90, %struct.TYPE_7__** %92
store %struct.TYPE_7__* %90, %struct.TYPE_7__** %3
br label %120
93: ; preds = %79
%94 = load i32, i32* @O_RDONLY
%95 = or i32 %94, 0
%96 = call i32 @open(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i32 %95, i32 0)
store i32 %96, i32* %7
%97 = icmp eq i32 %96, -1
br i1 %97, label %98, label %101
98: ; preds = %93
%99 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%100 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %99, i32 0, i32 1
store %struct.TYPE_7__* null, %struct.TYPE_7__** %100
store %struct.TYPE_7__* null, %struct.TYPE_7__** %3
br label %120
101: ; preds = %93
%102 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%103 = load i32, i32* %5
%104 = call i8* @fts_build(%struct.TYPE_8__* %102, i32 %103)
%105 = bitcast i8* %104 to %struct.TYPE_7__*
%106 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%107 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %106, i32 0, i32 1
store %struct.TYPE_7__* %105, %struct.TYPE_7__** %107
%108 = load i32, i32* %7
%109 = call i64 @fchdir(i32 %108)
%110 = icmp ne i64 %109, 0
br i1 %110, label %111, label %114
111: ; preds = %101
%112 = load i32, i32* %7
%113 = call i32 @close(i32 %112)
store %struct.TYPE_7__* null, %struct.TYPE_7__** %3
br label %120
114: ; preds = %101
%115 = load i32, i32* %7
%116 = call i32 @close(i32 %115)
%117 = load %struct.TYPE_8__*, %struct.TYPE_8__** %4
%118 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %117, i32 0, i32 1
%119 = load %struct.TYPE_7__*, %struct.TYPE_7__** %118
store %struct.TYPE_7__* %119, %struct.TYPE_7__** %3
br label %120
120: ; preds = %114, %111, %98, %86, %43, %33, %26, %14
%121 = load %struct.TYPE_7__*, %struct.TYPE_7__** %3
ret %struct.TYPE_7__* %121
}

LLVM IR (-O2):
%struct.TYPE_7__ = type { i64, i64, i8*, %struct.TYPE_7__* }
%struct.TYPE_8__ = type { i32, %struct.TYPE_7__*, %struct.TYPE_7__* }
@FTS_NAMEONLY = global i32 0
@EINVAL = global i64 0
@errno = global i64 0
@FTS_STOP = global i32 0
@FTS_INIT = global i64 0
@FTS_D = global i64 0
@FTS_ROOTLEVEL = global i64 0
@FTS_NOCHDIR = global i32 0
@.str = [2 x i8] c".\00"
@O_RDONLY = global i32 0
define %struct.TYPE_7__* @fts_children(%struct.TYPE_8__* %0, i32 %1) {
%3 = icmp eq i32 %1, 0
%4 = load i32, i32* @FTS_NAMEONLY
%5 = icmp eq i32 %4, %1
%6 = select i1 %3, i1 true, i1 %5
br i1 %6, label %9, label %7
7: ; preds = %2
%8 = load i64, i64* @EINVAL
store i64 %8, i64* @errno
br label %74
9: ; preds = %2
%10 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %0, i64 0, i32 2
%11 = load %struct.TYPE_7__*, %struct.TYPE_7__** %10
store i64 0, i64* @errno
%12 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %0, i64 0, i32 0
%13 = load i32, i32* %12
%14 = load i32, i32* @FTS_STOP
%15 = and i32 %14, %13
%16 = icmp eq i32 %15, 0
br i1 %16, label %17, label %74
17: ; preds = %9
%18 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %11, i64 0, i32 0
%19 = load i64, i64* %18
%20 = load i64, i64* @FTS_INIT
%21 = icmp eq i64 %19, %20
br i1 %21, label %22, label %25
22: ; preds = %17
%23 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %11, i64 0, i32 3
%24 = load %struct.TYPE_7__*, %struct.TYPE_7__** %23
br label %74
25: ; preds = %17
%26 = load i64, i64* @FTS_D
%27 = icmp eq i64 %19, %26
br i1 %27, label %28, label %74
28: ; preds = %25
%29 = getelementptr inbounds %struct.TYPE_8__, %struct.TYPE_8__* %0, i64 0, i32 1
%30 = load %struct.TYPE_7__*, %struct.TYPE_7__** %29
%31 = icmp eq %struct.TYPE_7__* %30, null
br i1 %31, label %35, label %32
32: ; preds = %28
%33 = tail call i32 @fts_lfree(%struct.TYPE_7__* %30)
%34 = load i32, i32* @FTS_NAMEONLY
br label %35
35: ; preds = %32, %28
%36 = phi i32 [ %34, %32 ], [ %4, %28 ]
%37 = icmp eq i32 %36, %1
br i1 %37, label %38, label %41
38: ; preds = %35
%39 = load i32, i32* %12
%40 = or i32 %39, %1
store i32 %40, i32* %12
br label %41
41: ; preds = %35, %38
%42 = phi i32 [ 2, %38 ], [ 1, %35 ]
%43 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %11, i64 0, i32 1
%44 = load i64, i64* %43
%45 = load i64, i64* @FTS_ROOTLEVEL
%46 = icmp eq i64 %44, %45
br i1 %46, label %47, label %57
47: ; preds = %41
%48 = getelementptr inbounds %struct.TYPE_7__, %struct.TYPE_7__* %11, i64 0, i32 2
%49 = load i8*, i8** %48
%50 = load i8, i8* %49
%51 = icmp eq i8 %50, 47
br i1 %51, label %57, label %52
52: ; preds = %47
%53 = load i32, i32* %12
%54 = load i32, i32* @FTS_NOCHDIR
%55 = and i32 %54, %53
%56 = icmp eq i32 %55, 0
br i1 %56, label %61, label %57
57: ; preds = %52, %47, %41
%58 = tail call i8* @fts_build(%struct.TYPE_8__* %0, i32 %42)
%59 = bitcast i8* %58 to %struct.TYPE_7__*
%60 = bitcast %struct.TYPE_7__** %29 to i8**
store i8* %58, i8** %60
br label %74
61: ; preds = %52
%62 = load i32, i32* @O_RDONLY
%63 = tail call i32 @open(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i32 %62, i32 0)
%64 = icmp eq i32 %63, -1
br i1 %64, label %65, label %66
65: ; preds = %61
store %struct.TYPE_7__* null, %struct.TYPE_7__** %29
br label %74
66: ; preds = %61
%67 = tail call i8* @fts_build(%struct.TYPE_8__* %0, i32 %42)
%68 = bitcast %struct.TYPE_7__** %29 to i8**
store i8* %67, i8** %68
%69 = tail call i64 @fchdir(i32 %63)
%70 = icmp eq i64 %69, 0
%71 = tail call i32 @close(i32 %63)
br i1 %70, label %72, label %74
72: ; preds = %66
%73 = load %struct.TYPE_7__*, %struct.TYPE_7__** %29
br label %74
74: ; preds = %66, %25, %9, %72, %65, %57, %22, %7
%75 = phi %struct.TYPE_7__* [ null, %7 ], [ %24, %22 ], [ %59, %57 ], [ null, %65 ], [ %73, %72 ], [ null, %9 ], [ null, %25 ], [ null, %66 ]
ret %struct.TYPE_7__* %75
}