; LLVM IR from mlcommons/tiny :: benchmark/interface/Middlewares/ST/filex/common/src (fx_directory_rename)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.FX_DIR_ENTRY_STRUCT = type { ptr, [13 x i8], i32, i32, i8, i8, i8, i32, i32, i32, i32, i32, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64 }
%struct.FX_MEDIA_STRUCT = type { i64, ptr, ptr, i64, i32, i64, ptr, ptr, i64, i64, i32, i32, i32, i64, i64, i32, i32, i32, i32, i32, i32, i32, i32, i32, i64, i32, i64, i64, i32, i64, i64, ptr, i32, i32, ptr, i64, i64, i64, i32, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, i64, ptr, ptr, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, %struct.TX_MUTEX_STRUCT, i32, %struct.FX_DIR_ENTRY_STRUCT, %struct.FX_DIR_ENTRY_STRUCT, [256 x i8], [256 x i8], %struct.FX_PATH_STRUCT, [16 x %struct.FX_FAT_CACHE_ENTRY_STRUCT], [128 x i8], i64, [1024 x i8], [256 x %struct.FX_CACHED_SECTOR_STRUCT], i64, i64, i64, i64, i8 }
%struct.TX_MUTEX_STRUCT = type { i64, ptr, i32, ptr, i32, i32, ptr, i32, ptr, ptr, i32, ptr, ptr }
%struct.FX_PATH_STRUCT = type { %struct.FX_DIR_ENTRY_STRUCT, [256 x i8], [256 x i8], i64 }
%struct.FX_FAT_CACHE_ENTRY_STRUCT = type { i64, i64, i64 }
%struct.FX_CACHED_SECTOR_STRUCT = type { ptr, i64, i8, i8, i8, i8, ptr }

; Function Attrs: nounwind uwtable
define dso_local i32 @_fx_directory_rename(ptr noundef %0, ptr noundef %1, ptr noundef %2) #0 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %struct.FX_DIR_ENTRY_STRUCT, align 8
  %10 = alloca %struct.FX_DIR_ENTRY_STRUCT, align 8
  %11 = alloca %struct.FX_DIR_ENTRY_STRUCT, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i64, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i8, align 1
  %16 = alloca i8, align 1
  %17 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 136, ptr %9) #3
  call void @llvm.lifetime.start.p0(i64 136, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 136, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %16) #3
  %18 = load ptr, ptr %5, align 8, !tbaa !5
  %19 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %18, i32 0, i32 68
  %20 = load i64, ptr %19, align 8, !tbaa !9
  %21 = add i64 %20, 1
  store i64 %21, ptr %19, align 8, !tbaa !9
  %22 = load ptr, ptr %5, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %22, i32 0, i32 122
  %24 = getelementptr inbounds [1024 x i8], ptr %23, i64 0, i64 0
  %25 = getelementptr inbounds i8, ptr %24, i64 256
  %26 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 0
  store ptr %25, ptr %26, align 8, !tbaa !17
  %27 = load ptr, ptr %5, align 8, !tbaa !5
  %28 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %27, i32 0, i32 122
  %29 = getelementptr inbounds [1024 x i8], ptr %28, i64 0, i64 0
  %30 = getelementptr inbounds i8, ptr %29, i64 512
  %31 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 0
  store ptr %30, ptr %31, align 8, !tbaa !17
  %32 = load ptr, ptr %5, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %32, i32 0, i32 122
  %34 = getelementptr inbounds [1024 x i8], ptr %33, i64 0, i64 0
  %35 = getelementptr inbounds i8, ptr %34, i64 768
  %36 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %11, i32 0, i32 0
  store ptr %35, ptr %36, align 8, !tbaa !17
  %37 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 1
  %38 = getelementptr inbounds [13 x i8], ptr %37, i64 0, i64 0
  store i8 0, ptr %38, align 8, !tbaa !18
  %39 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 1
  %40 = getelementptr inbounds [13 x i8], ptr %39, i64 0, i64 0
  store i8 0, ptr %40, align 8, !tbaa !18
  %41 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %11, i32 0, i32 1
  %42 = getelementptr inbounds [13 x i8], ptr %41, i64 0, i64 0
  store i8 0, ptr %42, align 8, !tbaa !18
  store i64 0, ptr %13, align 8, !tbaa !19
  %43 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %43, ptr %14, align 8, !tbaa !5
  br label %44

44:                                               ; preds = %77, %3
  %45 = load ptr, ptr %14, align 8, !tbaa !5
  %46 = load i8, ptr %45, align 1, !tbaa !18
  %47 = sext i8 %46 to i32
  %48 = icmp ne i32 %47, 0
  br i1 %48, label %49, label %52

49:                                               ; preds = %44
  %50 = load i64, ptr %13, align 8, !tbaa !19
  %51 = icmp ult i64 %50, 256
  br label %52

52:                                               ; preds = %49, %44
  %53 = phi i1 [ false, %44 ], [ %51, %49 ]
  br i1 %53, label %54, label %80

54:                                               ; preds = %52
  %55 = load ptr, ptr %14, align 8, !tbaa !5
  %56 = load i8, ptr %55, align 1, !tbaa !18
  %57 = sext i8 %56 to i32
  %58 = icmp eq i32 %57, 92
  br i1 %58, label %64, label %59

59:                                               ; preds = %54
  %60 = load ptr, ptr %14, align 8, !tbaa !5
  %61 = load i8, ptr %60, align 1, !tbaa !18
  %62 = sext i8 %61 to i32
  %63 = icmp eq i32 %62, 47
  br i1 %63, label %64, label %65

64:                                               ; preds = %59, %54
  store i64 0, ptr %13, align 8, !tbaa !19
  br label %77

65:                                               ; preds = %59
  %66 = load ptr, ptr %14, align 8, !tbaa !5
  %67 = load i8, ptr %66, align 1, !tbaa !18
  %68 = sext i8 %67 to i32
  %69 = icmp ne i32 %68, 32
  br i1 %69, label %73, label %70

70:                                               ; preds = %65
  %71 = load i64, ptr %13, align 8, !tbaa !19
  %72 = icmp ne i64 %71, 0
  br i1 %72, label %73, label %76

73:                                               ; preds = %70, %65
  %74 = load i64, ptr %13, align 8, !tbaa !19
  %75 = add i64 %74, 1
  store i64 %75, ptr %13, align 8, !tbaa !19
  br label %76

76:                                               ; preds = %73, %70
  br label %77

77:                                               ; preds = %76, %64
  %78 = load ptr, ptr %14, align 8, !tbaa !5
  %79 = getelementptr inbounds i8, ptr %78, i32 1
  store ptr %79, ptr %14, align 8, !tbaa !5
  br label %44, !llvm.loop !20

80:                                               ; preds = %52
  %81 = load i64, ptr %13, align 8, !tbaa !19
  %82 = icmp eq i64 %81, 0
  br i1 %82, label %86, label %83

83:                                               ; preds = %80
  %84 = load i64, ptr %13, align 8, !tbaa !19
  %85 = icmp uge i64 %84, 256
  br i1 %85, label %86, label %87

86:                                               ; preds = %83, %80
  store i32 12, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

87:                                               ; preds = %83
  %88 = load ptr, ptr %5, align 8, !tbaa !5
  %89 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %88, i32 0, i32 0
  %90 = load i64, ptr %89, align 8, !tbaa !22
  %91 = icmp ne i64 %90, 1296385097
  br i1 %91, label %92, label %93

92:                                               ; preds = %87
  store i32 17, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

93:                                               ; preds = %87
  %94 = load ptr, ptr %5, align 8, !tbaa !5
  %95 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %94, i32 0, i32 0
  %96 = load i64, ptr %95, align 8, !tbaa !22
  %97 = icmp ne i64 %96, 1296385097
  br i1 %97, label %98, label %99

98:                                               ; preds = %93
  store i32 17, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

99:                                               ; preds = %93
  %100 = load ptr, ptr %5, align 8, !tbaa !5
  %101 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %100, i32 0, i32 112
  %102 = call i32 @_tx_mutex_get(ptr noundef %101, i64 noundef 4294967295)
  %103 = icmp ne i32 %102, 0
  br i1 %103, label %104, label %105

104:                                              ; preds = %99
  store i32 17, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

105:                                              ; preds = %99
  br label %106

106:                                              ; preds = %105
  %107 = load ptr, ptr %5, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %107, i32 0, i32 40
  %109 = load i32, ptr %108, align 8, !tbaa !23
  %110 = icmp ne i32 %109, 0
  br i1 %110, label %111, label %115

111:                                              ; preds = %106
  %112 = load ptr, ptr %5, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %112, i32 0, i32 112
  %114 = call i32 @_tx_mutex_put(ptr noundef %113)
  store i32 35, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

115:                                              ; preds = %106
  %116 = load ptr, ptr %5, align 8, !tbaa !5
  %117 = load ptr, ptr %6, align 8, !tbaa !5
  %118 = call i32 @_fx_directory_search(ptr noundef %116, ptr noundef %117, ptr noundef %9, ptr noundef %11, ptr noundef null)
  store i32 %118, ptr %8, align 4, !tbaa !24
  %119 = load i32, ptr %8, align 4, !tbaa !24
  %120 = icmp ne i32 %119, 0
  br i1 %120, label %121, label %126

121:                                              ; preds = %115
  %122 = load ptr, ptr %5, align 8, !tbaa !5
  %123 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %122, i32 0, i32 112
  %124 = call i32 @_tx_mutex_put(ptr noundef %123)
  %125 = load i32, ptr %8, align 4, !tbaa !24
  store i32 %125, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

126:                                              ; preds = %115
  %127 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 4
  %128 = load i8, ptr %127, align 8, !tbaa !25
  %129 = zext i8 %128 to i32
  %130 = and i32 %129, 16
  %131 = icmp ne i32 %130, 0
  br i1 %131, label %136, label %132

132:                                              ; preds = %126
  %133 = load ptr, ptr %5, align 8, !tbaa !5
  %134 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %133, i32 0, i32 112
  %135 = call i32 @_tx_mutex_put(ptr noundef %134)
  store i32 14, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

136:                                              ; preds = %126
  %137 = load ptr, ptr %5, align 8, !tbaa !5
  %138 = load ptr, ptr %7, align 8, !tbaa !5
  %139 = call i32 @_fx_directory_search(ptr noundef %137, ptr noundef %138, ptr noundef %10, ptr noundef %11, ptr noundef %12)
  store i32 %139, ptr %8, align 4, !tbaa !24
  %140 = load i32, ptr %8, align 4, !tbaa !24
  %141 = icmp eq i32 %140, 0
  br i1 %141, label %142, label %205

142:                                              ; preds = %136
  store i64 0, ptr %13, align 8, !tbaa !19
  br label %143

143:                                              ; preds = %191, %142
  %144 = load ptr, ptr %6, align 8, !tbaa !5
  %145 = load i64, ptr %13, align 8, !tbaa !19
  %146 = getelementptr inbounds i8, ptr %144, i64 %145
  %147 = load i8, ptr %146, align 1, !tbaa !18
  store i8 %147, ptr %15, align 1, !tbaa !18
  %148 = load i8, ptr %15, align 1, !tbaa !18
  %149 = sext i8 %148 to i32
  %150 = icmp sge i32 %149, 97
  br i1 %150, label %151, label %160

151:                                              ; preds = %143
  %152 = load i8, ptr %15, align 1, !tbaa !18
  %153 = sext i8 %152 to i32
  %154 = icmp sle i32 %153, 122
  br i1 %154, label %155, label %160

155:                                              ; preds = %151
  %156 = load i8, ptr %15, align 1, !tbaa !18
  %157 = sext i8 %156 to i32
  %158 = sub nsw i32 %157, 32
  %159 = trunc i32 %158 to i8
  store i8 %159, ptr %15, align 1, !tbaa !18
  br label %160

160:                                              ; preds = %155, %151, %143
  %161 = load ptr, ptr %7, align 8, !tbaa !5
  %162 = load i64, ptr %13, align 8, !tbaa !19
  %163 = getelementptr inbounds i8, ptr %161, i64 %162
  %164 = load i8, ptr %163, align 1, !tbaa !18
  store i8 %164, ptr %16, align 1, !tbaa !18
  %165 = load i8, ptr %16, align 1, !tbaa !18
  %166 = sext i8 %165 to i32
  %167 = icmp sge i32 %166, 97
  br i1 %167, label %168, label %177

168:                                              ; preds = %160
  %169 = load i8, ptr %16, align 1, !tbaa !18
  %170 = sext i8 %169 to i32
  %171 = icmp sle i32 %170, 122
  br i1 %171, label %172, label %177

172:                                              ; preds = %168
  %173 = load i8, ptr %16, align 1, !tbaa !18
  %174 = sext i8 %173 to i32
  %175 = sub nsw i32 %174, 32
  %176 = trunc i32 %175 to i8
  store i8 %176, ptr %16, align 1, !tbaa !18
  br label %177

177:                                              ; preds = %172, %168, %160
  %178 = load i8, ptr %15, align 1, !tbaa !18
  %179 = sext i8 %178 to i32
  %180 = load i8, ptr %16, align 1, !tbaa !18
  %181 = sext i8 %180 to i32
  %182 = icmp ne i32 %179, %181
  br i1 %182, label %187, label %183

183:                                              ; preds = %177
  %184 = load i8, ptr %15, align 1, !tbaa !18
  %185 = sext i8 %184 to i32
  %186 = icmp eq i32 %185, 0
  br i1 %186, label %187, label %188

187:                                              ; preds = %183, %177
  br label %194

188:                                              ; preds = %183
  %189 = load i64, ptr %13, align 8, !tbaa !19
  %190 = add i64 %189, 1
  store i64 %190, ptr %13, align 8, !tbaa !19
  br label %191

191:                                              ; preds = %188
  %192 = load i64, ptr %13, align 8, !tbaa !19
  %193 = icmp ult i64 %192, 255
  br i1 %193, label %143, label %194, !llvm.loop !26

194:                                              ; preds = %191, %187
  %195 = load i8, ptr %15, align 1, !tbaa !18
  %196 = sext i8 %195 to i32
  %197 = load i8, ptr %16, align 1, !tbaa !18
  %198 = sext i8 %197 to i32
  %199 = icmp ne i32 %196, %198
  br i1 %199, label %200, label %204

200:                                              ; preds = %194
  %201 = load ptr, ptr %5, align 8, !tbaa !5
  %202 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %201, i32 0, i32 112
  %203 = call i32 @_tx_mutex_put(ptr noundef %202)
  store i32 11, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

204:                                              ; preds = %194
  br label %205

205:                                              ; preds = %204, %136
  %206 = load ptr, ptr %12, align 8, !tbaa !5
  %207 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 0
  %208 = load ptr, ptr %207, align 8, !tbaa !17
  %209 = getelementptr inbounds i8, ptr %208, i64 0
  %210 = call ptr @_fx_directory_name_extract(ptr noundef %206, ptr noundef %209)
  %211 = icmp ne ptr %210, null
  br i1 %211, label %212, label %216

212:                                              ; preds = %205
  %213 = load ptr, ptr %5, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %213, i32 0, i32 112
  %215 = call i32 @_tx_mutex_put(ptr noundef %214)
  store i32 12, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

216:                                              ; preds = %205
  %217 = load ptr, ptr %5, align 8, !tbaa !5
  %218 = call i32 @_fx_directory_free_search(ptr noundef %217, ptr noundef %11, ptr noundef %10)
  store i32 %218, ptr %8, align 4, !tbaa !24
  %219 = load i32, ptr %8, align 4, !tbaa !24
  %220 = icmp ne i32 %219, 0
  br i1 %220, label %221, label %226

221:                                              ; preds = %216
  %222 = load ptr, ptr %5, align 8, !tbaa !5
  %223 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %222, i32 0, i32 112
  %224 = call i32 @_tx_mutex_put(ptr noundef %223)
  %225 = load i32, ptr %8, align 4, !tbaa !24
  store i32 %225, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

226:                                              ; preds = %216
  %227 = load ptr, ptr %12, align 8, !tbaa !5
  %228 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 0
  %229 = load ptr, ptr %228, align 8, !tbaa !17
  %230 = getelementptr inbounds i8, ptr %229, i64 0
  %231 = call ptr @_fx_directory_name_extract(ptr noundef %227, ptr noundef %230)
  %232 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 2
  %233 = load i32, ptr %232, align 8, !tbaa !27
  %234 = icmp ne i32 %233, 0
  br i1 %234, label %235, label %238

235:                                              ; preds = %226
  %236 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 1
  %237 = getelementptr inbounds [13 x i8], ptr %236, i64 0, i64 0
  store i8 0, ptr %237, align 8, !tbaa !18
  br label %238

238:                                              ; preds = %235, %226
  %239 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 4
  %240 = load i8, ptr %239, align 8, !tbaa !25
  %241 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 4
  store i8 %240, ptr %241, align 8, !tbaa !25
  %242 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 12
  %243 = load i64, ptr %242, align 8, !tbaa !28
  %244 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 12
  store i64 %243, ptr %244, align 8, !tbaa !28
  %245 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 13
  %246 = load i64, ptr %245, align 8, !tbaa !29
  %247 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 13
  store i64 %246, ptr %247, align 8, !tbaa !29
  %248 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 5
  %249 = load i8, ptr %248, align 1, !tbaa !30
  %250 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 5
  store i8 %249, ptr %250, align 1, !tbaa !30
  %251 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 6
  %252 = load i8, ptr %251, align 2, !tbaa !31
  %253 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 6
  store i8 %252, ptr %253, align 2, !tbaa !31
  %254 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 7
  %255 = load i32, ptr %254, align 4, !tbaa !32
  %256 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 7
  store i32 %255, ptr %256, align 4, !tbaa !32
  %257 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 8
  %258 = load i32, ptr %257, align 8, !tbaa !33
  %259 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 8
  store i32 %258, ptr %259, align 8, !tbaa !33
  %260 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 9
  %261 = load i32, ptr %260, align 4, !tbaa !34
  %262 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 9
  store i32 %261, ptr %262, align 4, !tbaa !34
  %263 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 10
  %264 = load i32, ptr %263, align 8, !tbaa !35
  %265 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 10
  store i32 %264, ptr %265, align 8, !tbaa !35
  %266 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 11
  %267 = load i32, ptr %266, align 4, !tbaa !36
  %268 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 11
  store i32 %267, ptr %268, align 4, !tbaa !36
  %269 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 0
  %270 = load ptr, ptr %269, align 8, !tbaa !17
  %271 = getelementptr inbounds i8, ptr %270, i64 0
  %272 = load i8, ptr %271, align 1, !tbaa !18
  %273 = sext i8 %272 to i32
  %274 = icmp eq i32 %273, 46
  br i1 %274, label %275, label %281

275:                                              ; preds = %238
  %276 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %10, i32 0, i32 4
  %277 = load i8, ptr %276, align 8, !tbaa !25
  %278 = zext i8 %277 to i32
  %279 = or i32 %278, 2
  %280 = trunc i32 %279 to i8
  store i8 %280, ptr %276, align 8, !tbaa !25
  br label %281

281:                                              ; preds = %275, %238
  %282 = load ptr, ptr %5, align 8, !tbaa !5
  %283 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %282, i32 0, i32 117
  %284 = getelementptr inbounds [256 x i8], ptr %283, i64 0, i64 0
  store i8 0, ptr %284, align 8, !tbaa !18
  %285 = load ptr, ptr %5, align 8, !tbaa !5
  %286 = call i32 @_fx_directory_entry_write(ptr noundef %285, ptr noundef %10)
  store i32 %286, ptr %8, align 4, !tbaa !24
  %287 = load i32, ptr %8, align 4, !tbaa !24
  %288 = icmp ne i32 %287, 0
  br i1 %288, label %289, label %294

289:                                              ; preds = %281
  %290 = load ptr, ptr %5, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %290, i32 0, i32 112
  %292 = call i32 @_tx_mutex_put(ptr noundef %291)
  %293 = load i32, ptr %8, align 4, !tbaa !24
  store i32 %293, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

294:                                              ; preds = %281
  %295 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 0
  %296 = load ptr, ptr %295, align 8, !tbaa !17
  %297 = getelementptr inbounds i8, ptr %296, i64 0
  store i8 -27, ptr %297, align 1, !tbaa !18
  %298 = getelementptr inbounds %struct.FX_DIR_ENTRY_STRUCT, ptr %9, i32 0, i32 1
  %299 = getelementptr inbounds [13 x i8], ptr %298, i64 0, i64 0
  store i8 -27, ptr %299, align 8, !tbaa !18
  %300 = load ptr, ptr %5, align 8, !tbaa !5
  %301 = call i32 @_fx_directory_entry_write(ptr noundef %300, ptr noundef %9)
  store i32 %301, ptr %8, align 4, !tbaa !24
  %302 = load ptr, ptr %5, align 8, !tbaa !5
  %303 = getelementptr inbounds %struct.FX_MEDIA_STRUCT, ptr %302, i32 0, i32 112
  %304 = call i32 @_tx_mutex_put(ptr noundef %303)
  %305 = load i32, ptr %8, align 4, !tbaa !24
  store i32 %305, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %306

306:                                              ; preds = %294, %289, %221, %212, %200, %132, %121, %111, %104, %98, %92, %86
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 136, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 136, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 136, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  %307 = load i32, ptr %4, align 4
  ret i32 %307
}

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

declare i32 @_tx_mutex_get(ptr noundef, i64 noundef) #2

declare i32 @_tx_mutex_put(ptr noundef) #2

declare i32 @_fx_directory_search(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare ptr @_fx_directory_name_extract(ptr noundef, ptr noundef) #2

declare i32 @_fx_directory_free_search(ptr noundef, ptr noundef, ptr noundef) #2

declare i32 @_fx_directory_entry_write(ptr noundef, ptr noundef) #2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 472}
!10 = !{!"FX_MEDIA_STRUCT", !11, i64 0, !6, i64 8, !6, i64 16, !11, i64 24, !12, i64 32, !11, i64 40, !6, i64 48, !6, i64 56, !11, i64 64, !11, i64 72, !12, i64 80, !12, i64 84, !12, i64 88, !13, i64 96, !11, i64 104, !12, i64 112, !12, i64 116, !12, i64 120, !12, i64 124, !12, i64 128, !12, i64 132, !12, i64 136, !12, i64 140, !12, i64 144, !11, i64 152, !12, i64 160, !11, i64 168, !11, i64 176, !12, i64 184, !11, i64 192, !11, i64 200, !6, i64 208, !12, i64 216, !12, i64 220, !6, i64 224, !11, i64 232, !11, i64 240, !11, i64 248, !12, i64 256, !12, i64 260, !12, i64 264, !12, i64 268, !12, i64 272, !12, i64 276, !12, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !11, i64 320, !6, i64 328, !6, i64 336, !11, i64 344, !11, i64 352, !11, i64 360, !11, i64 368, !11, i64 376, !11, i64 384, !11, i64 392, !11, i64 400, !11, i64 408, !11, i64 416, !11, i64 424, !11, i64 432, !11, i64 440, !11, i64 448, !11, i64 456, !11, i64 464, !11, i64 472, !11, i64 480, !11, i64 488, !11, i64 496, !11, i64 504, !11, i64 512, !11, i64 520, !11, i64 528, !11, i64 536, !11, i64 544, !11, i64 552, !11, i64 560, !11, i64 568, !11, i64 576, !11, i64 584, !11, i64 592, !11, i64 600, !11, i64 608, !11, i64 616, !11, i64 624, !11, i64 632, !11, i64 640, !11, i64 648, !11, i64 656, !11, i64 664, !11, i64 672, !11, i64 680, !11, i64 688, !11, i64 696, !11, i64 704, !11, i64 712, !11, i64 720, !11, i64 728, !11, i64 736, !11, i64 744, !11, i64 752, !11, i64 760, !11, i64 768, !11, i64 776, !11, i64 784, !11, i64 792, !11, i64 800, !11, i64 808, !11, i64 816, !14, i64 824, !12, i64 920, !15, i64 928, !15, i64 1064, !7, i64 1200, !7, i64 1456, !16, i64 1712, !7, i64 2368, !7, i64 2752, !11, i64 2880, !7, i64 2888, !7, i64 3912, !11, i64 12104, !11, i64 12112, !11, i64 12120, !11, i64 12128, !7, i64 12136}
!11 = !{!"long", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!"long long", !7, i64 0}
!14 = !{!"TX_MUTEX_STRUCT", !11, i64 0, !6, i64 8, !12, i64 16, !6, i64 24, !12, i64 32, !12, i64 36, !6, i64 40, !12, i64 48, !6, i64 56, !6, i64 64, !12, i64 72, !6, i64 80, !6, i64 88}
!15 = !{!"FX_DIR_ENTRY_STRUCT", !6, i64 0, !7, i64 8, !12, i64 24, !12, i64 28, !7, i64 32, !7, i64 33, !7, i64 34, !12, i64 36, !12, i64 40, !12, i64 44, !12, i64 48, !12, i64 52, !11, i64 56, !13, i64 64, !13, i64 72, !11, i64 80, !11, i64 88, !11, i64 96, !11, i64 104, !13, i64 112, !11, i64 120, !13, i64 128}
!16 = !{!"FX_PATH_STRUCT", !15, i64 0, !7, i64 136, !7, i64 392, !11, i64 648}
!17 = !{!15, !6, i64 0}
!18 = !{!7, !7, i64 0}
!19 = !{!11, !11, i64 0}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!10, !11, i64 0}
!23 = !{!10, !12, i64 264}
!24 = !{!12, !12, i64 0}
!25 = !{!15, !7, i64 32}
!26 = distinct !{!26, !21}
!27 = !{!15, !12, i64 24}
!28 = !{!15, !11, i64 56}
!29 = !{!15, !13, i64 64}
!30 = !{!15, !7, i64 33}
!31 = !{!15, !7, i64 34}
!32 = !{!15, !12, i64 36}
!33 = !{!15, !12, i64 40}
!34 = !{!15, !12, i64 44}
!35 = !{!15, !12, i64 48}
!36 = !{!15, !12, i64 52}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.FX_DIR_ENTRY_STRUCT = type { ptr, [13 x i8], i32, i32, i8, i8, i8, i32, i32, i32, i32, i32, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64 }

; Function Attrs: nounwind uwtable
define dso_local i32 @_fx_directory_rename(ptr noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #0 {
  %4 = alloca %struct.FX_DIR_ENTRY_STRUCT, align 8
  %5 = alloca %struct.FX_DIR_ENTRY_STRUCT, align 8
  %6 = alloca %struct.FX_DIR_ENTRY_STRUCT, align 8
  %7 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 136, ptr nonnull %4) #3
  call void @llvm.lifetime.start.p0(i64 136, ptr nonnull %5) #3
  call void @llvm.lifetime.start.p0(i64 136, ptr nonnull %6) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #3
  %8 = getelementptr inbounds i8, ptr %0, i64 472
  %9 = load i64, ptr %8, align 8, !tbaa !5
  %10 = add i64 %9, 1
  store i64 %10, ptr %8, align 8, !tbaa !5
  %11 = getelementptr inbounds i8, ptr %0, i64 3144
  store ptr %11, ptr %4, align 8, !tbaa !16
  %12 = getelementptr inbounds i8, ptr %0, i64 3400
  store ptr %12, ptr %5, align 8, !tbaa !16
  %13 = getelementptr inbounds i8, ptr %0, i64 3656
  store ptr %13, ptr %6, align 8, !tbaa !16
  %14 = getelementptr inbounds i8, ptr %4, i64 8
  store i8 0, ptr %14, align 8, !tbaa !17
  %15 = getelementptr inbounds i8, ptr %5, i64 8
  store i8 0, ptr %15, align 8, !tbaa !17
  %16 = getelementptr inbounds i8, ptr %6, i64 8
  store i8 0, ptr %16, align 8, !tbaa !17
  %17 = load i8, ptr %2, align 1, !tbaa !17
  %.not99 = icmp eq i8 %17, 0
  br i1 %.not99, label %._crit_edge.thread, label %.lr.ph

.lr.ph:                                           ; preds = %3, %23
  %18 = phi i8 [ %25, %23 ], [ %17, %3 ]
  %.07398 = phi ptr [ %24, %23 ], [ %2, %3 ]
  %.07497 = phi i64 [ %.1, %23 ], [ 0, %3 ]
  switch i8 %18, label %19 [
    i8 92, label %23
    i8 47, label %23
  ]

19:                                               ; preds = %.lr.ph
  %20 = icmp ne i8 %18, 32
  %21 = icmp ne i64 %.07497, 0
  %or.cond = select i1 %20, i1 true, i1 %21
  %22 = add nuw nsw i64 %.07497, 1
  %spec.select = select i1 %or.cond, i64 %22, i64 0
  br label %23

23:                                               ; preds = %19, %.lr.ph, %.lr.ph
  %.1 = phi i64 [ 0, %.lr.ph ], [ 0, %.lr.ph ], [ %spec.select, %19 ]
  %24 = getelementptr inbounds i8, ptr %.07398, i64 1
  %25 = load i8, ptr %24, align 1, !tbaa !17
  %26 = icmp ne i8 %25, 0
  %27 = icmp ult i64 %.1, 256
  %28 = select i1 %26, i1 %27, i1 false
  br i1 %28, label %.lr.ph, label %._crit_edge, !llvm.loop !18

._crit_edge:                                      ; preds = %23
  %29 = add nsw i64 %.1, -256
  %30 = icmp ult i64 %29, -255
  br i1 %30, label %._crit_edge.thread, label %31

31:                                               ; preds = %._crit_edge
  %32 = load i64, ptr %0, align 8, !tbaa !20
  %.not = icmp eq i64 %32, 1296385097
  br i1 %.not, label %33, label %._crit_edge.thread

33:                                               ; preds = %31
  %34 = getelementptr inbounds i8, ptr %0, i64 824
  %35 = tail call i32 @_tx_mutex_get(ptr noundef nonnull %34, i64 noundef 4294967295) #3
  %.not83 = icmp eq i32 %35, 0
  br i1 %.not83, label %36, label %._crit_edge.thread

36:                                               ; preds = %33
  %37 = getelementptr inbounds i8, ptr %0, i64 264
  %38 = load i32, ptr %37, align 8, !tbaa !21
  %.not84 = icmp eq i32 %38, 0
  br i1 %.not84, label %41, label %39

39:                                               ; preds = %36
  %40 = tail call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

41:                                               ; preds = %36
  %42 = call i32 @_fx_directory_search(ptr noundef nonnull %0, ptr noundef %1, ptr noundef nonnull %4, ptr noundef nonnull %6, ptr noundef null) #3
  %.not85 = icmp eq i32 %42, 0
  br i1 %.not85, label %45, label %43

43:                                               ; preds = %41
  %44 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

45:                                               ; preds = %41
  %46 = getelementptr inbounds i8, ptr %4, i64 32
  %47 = load i8, ptr %46, align 8, !tbaa !22
  %48 = and i8 %47, 16
  %.not86 = icmp eq i8 %48, 0
  br i1 %.not86, label %49, label %51

49:                                               ; preds = %45
  %50 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

51:                                               ; preds = %45
  %52 = call i32 @_fx_directory_search(ptr noundef nonnull %0, ptr noundef nonnull %2, ptr noundef nonnull %5, ptr noundef nonnull %6, ptr noundef nonnull %7) #3
  %53 = icmp eq i32 %52, 0
  br i1 %53, label %.preheader, label %70

.preheader:                                       ; preds = %51, %.preheader
  %.2 = phi i64 [ %64, %.preheader ], [ 0, %51 ]
  %54 = getelementptr inbounds i8, ptr %1, i64 %.2
  %55 = load i8, ptr %54, align 1, !tbaa !17
  %56 = add i8 %55, -97
  %or.cond6 = icmp ult i8 %56, 26
  %57 = add nsw i8 %55, -32
  %spec.select91 = select i1 %or.cond6, i8 %57, i8 %55
  %58 = getelementptr inbounds i8, ptr %2, i64 %.2
  %59 = load i8, ptr %58, align 1, !tbaa !17
  %60 = add i8 %59, -97
  %or.cond9 = icmp ult i8 %60, 26
  %61 = add nsw i8 %59, -32
  %.0 = select i1 %or.cond9, i8 %61, i8 %59
  %62 = icmp eq i8 %spec.select91, %.0
  %63 = icmp ne i8 %spec.select91, 0
  %64 = add nuw nsw i64 %.2, 1
  %65 = icmp ult i64 %.2, 254
  %66 = and i1 %65, %63
  %or.cond93 = and i1 %66, %62
  br i1 %or.cond93, label %.preheader, label %67, !llvm.loop !23

67:                                               ; preds = %.preheader
  br i1 %62, label %70, label %68

68:                                               ; preds = %67
  %69 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

70:                                               ; preds = %67, %51
  %71 = load ptr, ptr %7, align 8, !tbaa !24
  %72 = load ptr, ptr %5, align 8, !tbaa !16
  %73 = call ptr @_fx_directory_name_extract(ptr noundef %71, ptr noundef %72) #3
  %.not87 = icmp eq ptr %73, null
  br i1 %.not87, label %76, label %74

74:                                               ; preds = %70
  %75 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

76:                                               ; preds = %70
  %77 = call i32 @_fx_directory_free_search(ptr noundef nonnull %0, ptr noundef nonnull %6, ptr noundef nonnull %5) #3
  %.not88 = icmp eq i32 %77, 0
  br i1 %.not88, label %80, label %78

78:                                               ; preds = %76
  %79 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

80:                                               ; preds = %76
  %81 = load ptr, ptr %7, align 8, !tbaa !24
  %82 = load ptr, ptr %5, align 8, !tbaa !16
  %83 = call ptr @_fx_directory_name_extract(ptr noundef %81, ptr noundef %82) #3
  %84 = getelementptr inbounds i8, ptr %5, i64 24
  %85 = load i32, ptr %84, align 8, !tbaa !25
  %.not89 = icmp eq i32 %85, 0
  br i1 %.not89, label %87, label %86

86:                                               ; preds = %80
  store i8 0, ptr %15, align 8, !tbaa !17
  br label %87

87:                                               ; preds = %86, %80
  %88 = load i8, ptr %46, align 8, !tbaa !22
  %89 = getelementptr inbounds i8, ptr %5, i64 32
  store i8 %88, ptr %89, align 8, !tbaa !22
  %90 = getelementptr inbounds i8, ptr %4, i64 56
  %91 = getelementptr inbounds i8, ptr %5, i64 56
  %92 = load <2 x i64>, ptr %90, align 8, !tbaa !17
  store <2 x i64> %92, ptr %91, align 8, !tbaa !17
  %93 = getelementptr inbounds i8, ptr %4, i64 33
  %94 = load i8, ptr %93, align 1, !tbaa !26
  %95 = getelementptr inbounds i8, ptr %5, i64 33
  store i8 %94, ptr %95, align 1, !tbaa !26
  %96 = getelementptr inbounds i8, ptr %4, i64 34
  %97 = load i8, ptr %96, align 2, !tbaa !27
  %98 = getelementptr inbounds i8, ptr %5, i64 34
  store i8 %97, ptr %98, align 2, !tbaa !27
  %99 = getelementptr inbounds i8, ptr %4, i64 36
  %100 = getelementptr inbounds i8, ptr %5, i64 36
  %101 = load <4 x i32>, ptr %99, align 4, !tbaa !28
  store <4 x i32> %101, ptr %100, align 4, !tbaa !28
  %102 = getelementptr inbounds i8, ptr %4, i64 52
  %103 = load i32, ptr %102, align 4, !tbaa !29
  %104 = getelementptr inbounds i8, ptr %5, i64 52
  store i32 %103, ptr %104, align 4, !tbaa !29
  %105 = load ptr, ptr %5, align 8, !tbaa !16
  %106 = load i8, ptr %105, align 1, !tbaa !17
  %107 = icmp eq i8 %106, 46
  br i1 %107, label %108, label %110

108:                                              ; preds = %87
  %109 = or i8 %88, 2
  store i8 %109, ptr %89, align 8, !tbaa !22
  br label %110

110:                                              ; preds = %108, %87
  %111 = getelementptr inbounds i8, ptr %0, i64 1456
  store i8 0, ptr %111, align 8, !tbaa !17
  %112 = call i32 @_fx_directory_entry_write(ptr noundef nonnull %0, ptr noundef nonnull %5) #3
  %.not90 = icmp eq i32 %112, 0
  br i1 %.not90, label %115, label %113

113:                                              ; preds = %110
  %114 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

115:                                              ; preds = %110
  %116 = load ptr, ptr %4, align 8, !tbaa !16
  store i8 -27, ptr %116, align 1, !tbaa !17
  store i8 -27, ptr %14, align 8, !tbaa !17
  %117 = call i32 @_fx_directory_entry_write(ptr noundef nonnull %0, ptr noundef nonnull %4) #3
  %118 = call i32 @_tx_mutex_put(ptr noundef nonnull %34) #3
  br label %._crit_edge.thread

._crit_edge.thread:                               ; preds = %3, %33, %31, %._crit_edge, %115, %113, %78, %74, %68, %49, %43, %39
  %.075 = phi i32 [ 35, %39 ], [ %42, %43 ], [ 11, %68 ], [ 12, %74 ], [ %77, %78 ], [ %112, %113 ], [ %117, %115 ], [ 14, %49 ], [ 12, %._crit_edge ], [ 17, %31 ], [ 17, %33 ], [ 12, %3 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #3
  call void @llvm.lifetime.end.p0(i64 136, ptr nonnull %6) #3
  call void @llvm.lifetime.end.p0(i64 136, ptr nonnull %5) #3
  call void @llvm.lifetime.end.p0(i64 136, ptr nonnull %4) #3
  ret i32 %.075
}

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

declare i32 @_tx_mutex_get(ptr noundef, i64 noundef) local_unnamed_addr #2

declare i32 @_tx_mutex_put(ptr noundef) local_unnamed_addr #2

declare i32 @_fx_directory_search(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare ptr @_fx_directory_name_extract(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @_fx_directory_free_search(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @_fx_directory_entry_write(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 472}
!6 = !{!"FX_MEDIA_STRUCT", !7, i64 0, !10, i64 8, !10, i64 16, !7, i64 24, !11, i64 32, !7, i64 40, !10, i64 48, !10, i64 56, !7, i64 64, !7, i64 72, !11, i64 80, !11, i64 84, !11, i64 88, !12, i64 96, !7, i64 104, !11, i64 112, !11, i64 116, !11, i64 120, !11, i64 124, !11, i64 128, !11, i64 132, !11, i64 136, !11, i64 140, !11, i64 144, !7, i64 152, !11, i64 160, !7, i64 168, !7, i64 176, !11, i64 184, !7, i64 192, !7, i64 200, !10, i64 208, !11, i64 216, !11, i64 220, !10, i64 224, !7, i64 232, !7, i64 240, !7, i64 248, !11, i64 256, !11, i64 260, !11, i64 264, !11, i64 268, !11, i64 272, !11, i64 276, !11, i64 280, !10, i64 288, !10, i64 296, !10, i64 304, !10, i64 312, !7, i64 320, !10, i64 328, !10, i64 336, !7, i64 344, !7, i64 352, !7, i64 360, !7, i64 368, !7, i64 376, !7, i64 384, !7, i64 392, !7, i64 400, !7, i64 408, !7, i64 416, !7, i64 424, !7, i64 432, !7, i64 440, !7, i64 448, !7, i64 456, !7, i64 464, !7, i64 472, !7, i64 480, !7, i64 488, !7, i64 496, !7, i64 504, !7, i64 512, !7, i64 520, !7, i64 528, !7, i64 536, !7, i64 544, !7, i64 552, !7, i64 560, !7, i64 568, !7, i64 576, !7, i64 584, !7, i64 592, !7, i64 600, !7, i64 608, !7, i64 616, !7, i64 624, !7, i64 632, !7, i64 640, !7, i64 648, !7, i64 656, !7, i64 664, !7, i64 672, !7, i64 680, !7, i64 688, !7, i64 696, !7, i64 704, !7, i64 712, !7, i64 720, !7, i64 728, !7, i64 736, !7, i64 744, !7, i64 752, !7, i64 760, !7, i64 768, !7, i64 776, !7, i64 784, !7, i64 792, !7, i64 800, !7, i64 808, !7, i64 816, !13, i64 824, !11, i64 920, !14, i64 928, !14, i64 1064, !8, i64 1200, !8, i64 1456, !15, i64 1712, !8, i64 2368, !8, i64 2752, !7, i64 2880, !8, i64 2888, !8, i64 3912, !7, i64 12104, !7, i64 12112, !7, i64 12120, !7, i64 12128, !8, i64 12136}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!"long long", !8, i64 0}
!13 = !{!"TX_MUTEX_STRUCT", !7, i64 0, !10, i64 8, !11, i64 16, !10, i64 24, !11, i64 32, !11, i64 36, !10, i64 40, !11, i64 48, !10, i64 56, !10, i64 64, !11, i64 72, !10, i64 80, !10, i64 88}
!14 = !{!"FX_DIR_ENTRY_STRUCT", !10, i64 0, !8, i64 8, !11, i64 24, !11, i64 28, !8, i64 32, !8, i64 33, !8, i64 34, !11, i64 36, !11, i64 40, !11, i64 44, !11, i64 48, !11, i64 52, !7, i64 56, !12, i64 64, !12, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !12, i64 112, !7, i64 120, !12, i64 128}
!15 = !{!"FX_PATH_STRUCT", !14, i64 0, !8, i64 136, !8, i64 392, !7, i64 648}
!16 = !{!14, !10, i64 0}
!17 = !{!8, !8, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = !{!6, !7, i64 0}
!21 = !{!6, !11, i64 264}
!22 = !{!14, !8, i64 32}
!23 = distinct !{!23, !19}
!24 = !{!10, !10, i64 0}
!25 = !{!14, !11, i64 24}
!26 = !{!14, !8, i64 33}
!27 = !{!14, !8, i64 34}
!28 = !{!11, !11, i64 0}
!29 = !{!14, !11, i64 52}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass