; LLVM IR from christoskaramou/PhasmaEngine :: PhasmaEditor/Include/TinyFileDialogs (tinyfiledialogs)

; 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"

@tinyfd_verbose = external dso_local global i32, align 4
@tinyfd_silent = external dso_local global i32, align 4
@tinyfd_response = external dso_local global [1024 x i8], align 16
@.str.8 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [75 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.66 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.70 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [16 x i8], align 1
@_ZL12gPython2Name = external hidden global [16 x i8], align 16
@.str.74 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.76 = external hidden unnamed_addr constant [120 x i8], align 1
@.str.87 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.88 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.92 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.95 = external hidden unnamed_addr constant [16 x i8], align 1
@_ZL12gPython3Name = external hidden global [16 x i8], align 16
@.str.120 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.121 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.122 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.123 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.124 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.125 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.129 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.130 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.177 = external hidden unnamed_addr constant [1 x i8], align 1
@.str.181 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.257 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.258 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.261 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.263 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.264 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.265 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.266 = external hidden unnamed_addr constant [71 x i8], align 1
@.str.268 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.269 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.270 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.271 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.272 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.273 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.274 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.276 = external hidden unnamed_addr constant [89 x i8], align 1
@.str.279 = external hidden unnamed_addr constant [75 x i8], align 1
@.str.280 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.281 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.282 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.283 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.284 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.285 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.286 = external hidden unnamed_addr constant [58 x i8], align 1
@.str.287 = external hidden unnamed_addr constant [23 x i8], align 1
@_ZZ21tinyfd_openFileDialogE5lBuff = external hidden global [32768 x i8], align 16
@.str.289 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.290 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.291 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.292 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.293 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.294 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.295 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.296 = external hidden unnamed_addr constant [36 x i8], align 1
@.str.297 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.298 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.299 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.300 = external hidden unnamed_addr constant [64 x i8], align 1
@.str.301 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.302 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.303 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.304 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.305 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.306 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.307 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.308 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.309 = external hidden unnamed_addr constant [154 x i8], align 1
@.str.310 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.311 = external hidden unnamed_addr constant [156 x i8], align 1
@.str.312 = external hidden unnamed_addr constant [10 x i8], align 1

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

; Function Attrs: nounwind willreturn memory(read)
declare i64 @strlen(ptr noundef) #1

; Function Attrs: nounwind
declare ptr @strcpy(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) #0

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL16osascriptPresentv() #3

declare i32 @printf(ptr noundef, ...) #4

declare noalias ptr @popen(ptr noundef, ptr noundef) #4

declare i32 @pclose(ptr noundef) #4

; Function Attrs: nounwind willreturn memory(read)
declare i32 @strcmp(ptr noundef, ptr noundef) #1

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL12osx9orBetterv() #3

; Function Attrs: nounwind
declare ptr @strcat(ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14kdialogPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL13zenityPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL17matedialogPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL20shellementaryPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL12qarmaPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14zenity3Presentv() #3

; Function Attrs: nounwind
declare ptr @getenv(ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14gdialogPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14xdialogPresentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL15tkinter2Presentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL17isTerminalRunningv() #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZL8isDarwinv() #5

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL15tkinter3Presentv() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL10dialogNamev() #3

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL12terminalNamev() #3

declare ptr @fgets(ptr noundef, i32 noundef, ptr noundef) #4

; Function Attrs: mustprogress uwtable
declare dso_local ptr @tinyfd_inputBox(ptr noundef, ptr noundef, ptr noundef) #3

; Function Attrs: nounwind willreturn memory(read)
declare noundef ptr @strchr(ptr noundef, i32 noundef) #1

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL10fileExistsPKc(ptr noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef, ptr noundef) #5

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef ptr @_ZL11getLastNamePcPKc(ptr noundef, ptr noundef) #5

; Function Attrs: mustprogress uwtable
define dso_local ptr @tinyfd_openFileDialog(ptr noundef %0, ptr noundef %1, i32 noundef %2, ptr noundef %3, ptr noundef %4, i32 noundef %5) #3 {
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i32, align 4
  %14 = alloca [1024 x i8], align 16
  %15 = alloca [1024 x i8], align 16
  %16 = alloca i32, align 4
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  store ptr %0, ptr %8, align 8, !tbaa !5
  store ptr %1, ptr %9, align 8, !tbaa !5
  store i32 %2, ptr %10, align 4, !tbaa !9
  store ptr %3, ptr %11, align 8, !tbaa !5
  store ptr %4, ptr %12, align 8, !tbaa !5
  store i32 %5, ptr %13, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1024, ptr %14) #6
  call void @llvm.lifetime.start.p0(i64 1024, ptr %15) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #6
  store i32 0, ptr %20, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #6
  store i32 0, ptr %21, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #6
  store i32 0, ptr %22, align 4, !tbaa !9
  store i8 0, ptr @_ZZ21tinyfd_openFileDialogE5lBuff, align 16, !tbaa !11
  %24 = call noundef i32 @_ZL16osascriptPresentv()
  %25 = icmp ne i32 %24, 0
  br i1 %25, label %26, label %155

26:                                               ; preds = %6
  %27 = load ptr, ptr %8, align 8, !tbaa !5
  %28 = icmp ne ptr %27, null
  br i1 %28, label %29, label %35

29:                                               ; preds = %26
  %30 = load ptr, ptr %8, align 8, !tbaa !5
  %31 = call i32 @strcmp(ptr noundef %30, ptr noundef @.str.10) #7
  %32 = icmp ne i32 %31, 0
  br i1 %32, label %35, label %33

33:                                               ; preds = %29
  %34 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.11) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

35:                                               ; preds = %29, %26
  %36 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %37 = call ptr @strcpy(ptr noundef %36, ptr noundef @.str.12) #6
  %38 = call noundef i32 @_ZL12osx9orBetterv()
  %39 = icmp ne i32 %38, 0
  br i1 %39, label %43, label %40

40:                                               ; preds = %35
  %41 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %42 = call ptr @strcat(ptr noundef %41, ptr noundef @.str.13) #6
  br label %43

43:                                               ; preds = %40, %35
  %44 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %45 = call ptr @strcat(ptr noundef %44, ptr noundef @.str.289) #6
  %46 = load i32, ptr %13, align 4, !tbaa !9
  %47 = icmp ne i32 %46, 0
  br i1 %47, label %51, label %48

48:                                               ; preds = %43
  %49 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %50 = call ptr @strcat(ptr noundef %49, ptr noundef @.str.290) #6
  br label %54

51:                                               ; preds = %43
  %52 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %53 = call ptr @strcat(ptr noundef %52, ptr noundef @.str.291) #6
  br label %54

54:                                               ; preds = %51, %48
  %55 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %56 = call ptr @strcat(ptr noundef %55, ptr noundef @.str.292) #6
  %57 = load ptr, ptr %8, align 8, !tbaa !5
  %58 = icmp ne ptr %57, null
  br i1 %58, label %59, label %71

59:                                               ; preds = %54
  %60 = load ptr, ptr %8, align 8, !tbaa !5
  %61 = call i64 @strlen(ptr noundef %60) #7
  %62 = icmp ne i64 %61, 0
  br i1 %62, label %63, label %71

63:                                               ; preds = %59
  %64 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %65 = call ptr @strcat(ptr noundef %64, ptr noundef @.str.257) #6
  %66 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %67 = load ptr, ptr %8, align 8, !tbaa !5
  %68 = call ptr @strcat(ptr noundef %66, ptr noundef %67) #6
  %69 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %70 = call ptr @strcat(ptr noundef %69, ptr noundef @.str.15) #6
  br label %71

71:                                               ; preds = %63, %59, %54
  %72 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %73 = load ptr, ptr %9, align 8, !tbaa !5
  %74 = call noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef %72, ptr noundef %73)
  %75 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %76 = call i64 @strlen(ptr noundef %75) #7
  %77 = icmp ne i64 %76, 0
  br i1 %77, label %78, label %86

78:                                               ; preds = %71
  %79 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %80 = call ptr @strcat(ptr noundef %79, ptr noundef @.str.258) #6
  %81 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %82 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %83 = call ptr @strcat(ptr noundef %81, ptr noundef %82) #6
  %84 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %85 = call ptr @strcat(ptr noundef %84, ptr noundef @.str.15) #6
  br label %86

86:                                               ; preds = %78, %71
  %87 = load i32, ptr %10, align 4, !tbaa !9
  %88 = icmp sgt i32 %87, 0
  br i1 %88, label %89, label %123

89:                                               ; preds = %86
  %90 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %91 = call ptr @strcat(ptr noundef %90, ptr noundef @.str.293) #6
  %92 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %93 = load ptr, ptr %11, align 8, !tbaa !5
  %94 = getelementptr inbounds ptr, ptr %93, i64 0
  %95 = load ptr, ptr %94, align 8, !tbaa !5
  %96 = getelementptr inbounds i8, ptr %95, i64 2
  %97 = call ptr @strcat(ptr noundef %92, ptr noundef %96) #6
  %98 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %99 = call ptr @strcat(ptr noundef %98, ptr noundef @.str.47) #6
  store i32 1, ptr %16, align 4, !tbaa !9
  br label %100

100:                                              ; preds = %117, %89
  %101 = load i32, ptr %16, align 4, !tbaa !9
  %102 = load i32, ptr %10, align 4, !tbaa !9
  %103 = icmp slt i32 %101, %102
  br i1 %103, label %104, label %120

104:                                              ; preds = %100
  %105 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %106 = call ptr @strcat(ptr noundef %105, ptr noundef @.str.294) #6
  %107 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %108 = load ptr, ptr %11, align 8, !tbaa !5
  %109 = load i32, ptr %16, align 4, !tbaa !9
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds ptr, ptr %108, i64 %110
  %112 = load ptr, ptr %111, align 8, !tbaa !5
  %113 = getelementptr inbounds i8, ptr %112, i64 2
  %114 = call ptr @strcat(ptr noundef %107, ptr noundef %113) #6
  %115 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %116 = call ptr @strcat(ptr noundef %115, ptr noundef @.str.47) #6
  br label %117

117:                                              ; preds = %104
  %118 = load i32, ptr %16, align 4, !tbaa !9
  %119 = add nsw i32 %118, 1
  store i32 %119, ptr %16, align 4, !tbaa !9
  br label %100, !llvm.loop !12

120:                                              ; preds = %100
  %121 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %122 = call ptr @strcat(ptr noundef %121, ptr noundef @.str.295) #6
  br label %123

123:                                              ; preds = %120, %86
  %124 = load i32, ptr %13, align 4, !tbaa !9
  %125 = icmp ne i32 %124, 0
  br i1 %125, label %126, label %141

126:                                              ; preds = %123
  %127 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %128 = call ptr @strcat(ptr noundef %127, ptr noundef @.str.296) #6
  %129 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %130 = call ptr @strcat(ptr noundef %129, ptr noundef @.str.297) #6
  %131 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %132 = call ptr @strcat(ptr noundef %131, ptr noundef @.str.298) #6
  %133 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %134 = call ptr @strcat(ptr noundef %133, ptr noundef @.str.299) #6
  %135 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %136 = call ptr @strcat(ptr noundef %135, ptr noundef @.str.300) #6
  %137 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %138 = call ptr @strcat(ptr noundef %137, ptr noundef @.str.301) #6
  %139 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %140 = call ptr @strcat(ptr noundef %139, ptr noundef @.str.302) #6
  br label %144

141:                                              ; preds = %123
  %142 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %143 = call ptr @strcat(ptr noundef %142, ptr noundef @.str.35) #6
  br label %144

144:                                              ; preds = %141, %126
  %145 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %146 = call ptr @strcat(ptr noundef %145, ptr noundef @.str.37) #6
  %147 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %148 = call ptr @strcat(ptr noundef %147, ptr noundef @.str.39) #6
  %149 = call noundef i32 @_ZL12osx9orBetterv()
  %150 = icmp ne i32 %149, 0
  br i1 %150, label %154, label %151

151:                                              ; preds = %144
  %152 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %153 = call ptr @strcat(ptr noundef %152, ptr noundef @.str.40) #6
  br label %154

154:                                              ; preds = %151, %144
  br label %896

155:                                              ; preds = %6
  %156 = call noundef i32 @_ZL14kdialogPresentv()
  %157 = icmp ne i32 %156, 0
  br i1 %157, label %158, label %265

158:                                              ; preds = %155
  %159 = load ptr, ptr %8, align 8, !tbaa !5
  %160 = icmp ne ptr %159, null
  br i1 %160, label %161, label %167

161:                                              ; preds = %158
  %162 = load ptr, ptr %8, align 8, !tbaa !5
  %163 = call i32 @strcmp(ptr noundef %162, ptr noundef @.str.10) #7
  %164 = icmp ne i32 %163, 0
  br i1 %164, label %167, label %165

165:                                              ; preds = %161
  %166 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.41) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

167:                                              ; preds = %161, %158
  store i32 1, ptr %20, align 4, !tbaa !9
  %168 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %169 = call ptr @strcpy(ptr noundef %168, ptr noundef @.str.41) #6
  %170 = call noundef i32 @_ZL14kdialogPresentv()
  %171 = icmp eq i32 %170, 2
  br i1 %171, label %172, label %175

172:                                              ; preds = %167
  %173 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %174 = call ptr @strcat(ptr noundef %173, ptr noundef @.str.42) #6
  br label %175

175:                                              ; preds = %172, %167
  %176 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %177 = call ptr @strcat(ptr noundef %176, ptr noundef @.str.303) #6
  %178 = load ptr, ptr %9, align 8, !tbaa !5
  %179 = icmp ne ptr %178, null
  br i1 %179, label %180, label %201

180:                                              ; preds = %175
  %181 = load ptr, ptr %9, align 8, !tbaa !5
  %182 = call i64 @strlen(ptr noundef %181) #7
  %183 = icmp ne i64 %182, 0
  br i1 %183, label %184, label %201

184:                                              ; preds = %180
  %185 = load ptr, ptr %9, align 8, !tbaa !5
  %186 = getelementptr inbounds i8, ptr %185, i64 0
  %187 = load i8, ptr %186, align 1, !tbaa !11
  %188 = sext i8 %187 to i32
  %189 = icmp ne i32 %188, 47
  br i1 %189, label %190, label %193

190:                                              ; preds = %184
  %191 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %192 = call ptr @strcat(ptr noundef %191, ptr noundef @.str.261) #6
  br label %193

193:                                              ; preds = %190, %184
  %194 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %195 = call ptr @strcat(ptr noundef %194, ptr noundef @.str.47) #6
  %196 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %197 = load ptr, ptr %9, align 8, !tbaa !5
  %198 = call ptr @strcat(ptr noundef %196, ptr noundef %197) #6
  %199 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %200 = call ptr @strcat(ptr noundef %199, ptr noundef @.str.47) #6
  br label %204

201:                                              ; preds = %180, %175
  %202 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %203 = call ptr @strcat(ptr noundef %202, ptr noundef @.str.261) #6
  br label %204

204:                                              ; preds = %201, %193
  %205 = load i32, ptr %10, align 4, !tbaa !9
  %206 = icmp sgt i32 %205, 0
  br i1 %206, label %207, label %243

207:                                              ; preds = %204
  %208 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %209 = call ptr @strcat(ptr noundef %208, ptr noundef @.str.46) #6
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %210

210:                                              ; preds = %224, %207
  %211 = load i32, ptr %16, align 4, !tbaa !9
  %212 = load i32, ptr %10, align 4, !tbaa !9
  %213 = icmp slt i32 %211, %212
  br i1 %213, label %214, label %227

214:                                              ; preds = %210
  %215 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %216 = load ptr, ptr %11, align 8, !tbaa !5
  %217 = load i32, ptr %16, align 4, !tbaa !9
  %218 = sext i32 %217 to i64
  %219 = getelementptr inbounds ptr, ptr %216, i64 %218
  %220 = load ptr, ptr %219, align 8, !tbaa !5
  %221 = call ptr @strcat(ptr noundef %215, ptr noundef %220) #6
  %222 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %223 = call ptr @strcat(ptr noundef %222, ptr noundef @.str.125) #6
  br label %224

224:                                              ; preds = %214
  %225 = load i32, ptr %16, align 4, !tbaa !9
  %226 = add nsw i32 %225, 1
  store i32 %226, ptr %16, align 4, !tbaa !9
  br label %210, !llvm.loop !14

227:                                              ; preds = %210
  %228 = load ptr, ptr %12, align 8, !tbaa !5
  %229 = icmp ne ptr %228, null
  br i1 %229, label %230, label %240

230:                                              ; preds = %227
  %231 = load ptr, ptr %12, align 8, !tbaa !5
  %232 = call i64 @strlen(ptr noundef %231) #7
  %233 = icmp ne i64 %232, 0
  br i1 %233, label %234, label %240

234:                                              ; preds = %230
  %235 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %236 = call ptr @strcat(ptr noundef %235, ptr noundef @.str.181) #6
  %237 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %238 = load ptr, ptr %12, align 8, !tbaa !5
  %239 = call ptr @strcat(ptr noundef %237, ptr noundef %238) #6
  br label %240

240:                                              ; preds = %234, %230, %227
  %241 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %242 = call ptr @strcat(ptr noundef %241, ptr noundef @.str.47) #6
  br label %243

243:                                              ; preds = %240, %204
  %244 = load i32, ptr %13, align 4, !tbaa !9
  %245 = icmp ne i32 %244, 0
  br i1 %245, label %246, label %249

246:                                              ; preds = %243
  %247 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %248 = call ptr @strcat(ptr noundef %247, ptr noundef @.str.304) #6
  br label %249

249:                                              ; preds = %246, %243
  %250 = load ptr, ptr %8, align 8, !tbaa !5
  %251 = icmp ne ptr %250, null
  br i1 %251, label %252, label %264

252:                                              ; preds = %249
  %253 = load ptr, ptr %8, align 8, !tbaa !5
  %254 = call i64 @strlen(ptr noundef %253) #7
  %255 = icmp ne i64 %254, 0
  br i1 %255, label %256, label %264

256:                                              ; preds = %252
  %257 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %258 = call ptr @strcat(ptr noundef %257, ptr noundef @.str.49) #6
  %259 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %260 = load ptr, ptr %8, align 8, !tbaa !5
  %261 = call ptr @strcat(ptr noundef %259, ptr noundef %260) #6
  %262 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %263 = call ptr @strcat(ptr noundef %262, ptr noundef @.str.47) #6
  br label %264

264:                                              ; preds = %256, %252, %249
  br label %895

265:                                              ; preds = %155
  %266 = call noundef i32 @_ZL13zenityPresentv()
  %267 = icmp ne i32 %266, 0
  br i1 %267, label %277, label %268

268:                                              ; preds = %265
  %269 = call noundef i32 @_ZL17matedialogPresentv()
  %270 = icmp ne i32 %269, 0
  br i1 %270, label %277, label %271

271:                                              ; preds = %268
  %272 = call noundef i32 @_ZL20shellementaryPresentv()
  %273 = icmp ne i32 %272, 0
  br i1 %273, label %277, label %274

274:                                              ; preds = %271
  %275 = call noundef i32 @_ZL12qarmaPresentv()
  %276 = icmp ne i32 %275, 0
  br i1 %276, label %277, label %435

277:                                              ; preds = %274, %271, %268, %265
  %278 = call noundef i32 @_ZL13zenityPresentv()
  %279 = icmp ne i32 %278, 0
  br i1 %279, label %280, label %301

280:                                              ; preds = %277
  %281 = load ptr, ptr %8, align 8, !tbaa !5
  %282 = icmp ne ptr %281, null
  br i1 %282, label %283, label %289

283:                                              ; preds = %280
  %284 = load ptr, ptr %8, align 8, !tbaa !5
  %285 = call i32 @strcmp(ptr noundef %284, ptr noundef @.str.10) #7
  %286 = icmp ne i32 %285, 0
  br i1 %286, label %289, label %287

287:                                              ; preds = %283
  %288 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.52) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

289:                                              ; preds = %283, %280
  %290 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %291 = call ptr @strcpy(ptr noundef %290, ptr noundef @.str.52) #6
  %292 = call noundef i32 @_ZL14zenity3Presentv()
  %293 = icmp sge i32 %292, 4
  br i1 %293, label %294, label %300

294:                                              ; preds = %289
  %295 = call ptr @getenv(ptr noundef @.str.54) #6
  %296 = icmp ne ptr %295, null
  br i1 %296, label %300, label %297

297:                                              ; preds = %294
  %298 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %299 = call ptr @strcat(ptr noundef %298, ptr noundef @.str.55) #6
  br label %300

300:                                              ; preds = %297, %294, %289
  br label %351

301:                                              ; preds = %277
  %302 = call noundef i32 @_ZL17matedialogPresentv()
  %303 = icmp ne i32 %302, 0
  br i1 %303, label %304, label %316

304:                                              ; preds = %301
  %305 = load ptr, ptr %8, align 8, !tbaa !5
  %306 = icmp ne ptr %305, null
  br i1 %306, label %307, label %313

307:                                              ; preds = %304
  %308 = load ptr, ptr %8, align 8, !tbaa !5
  %309 = call i32 @strcmp(ptr noundef %308, ptr noundef @.str.10) #7
  %310 = icmp ne i32 %309, 0
  br i1 %310, label %313, label %311

311:                                              ; preds = %307
  %312 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.56) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

313:                                              ; preds = %307, %304
  %314 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %315 = call ptr @strcpy(ptr noundef %314, ptr noundef @.str.56) #6
  br label %350

316:                                              ; preds = %301
  %317 = call noundef i32 @_ZL20shellementaryPresentv()
  %318 = icmp ne i32 %317, 0
  br i1 %318, label %319, label %331

319:                                              ; preds = %316
  %320 = load ptr, ptr %8, align 8, !tbaa !5
  %321 = icmp ne ptr %320, null
  br i1 %321, label %322, label %328

322:                                              ; preds = %319
  %323 = load ptr, ptr %8, align 8, !tbaa !5
  %324 = call i32 @strcmp(ptr noundef %323, ptr noundef @.str.10) #7
  %325 = icmp ne i32 %324, 0
  br i1 %325, label %328, label %326

326:                                              ; preds = %322
  %327 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.58) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

328:                                              ; preds = %322, %319
  %329 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %330 = call ptr @strcpy(ptr noundef %329, ptr noundef @.str.58) #6
  br label %349

331:                                              ; preds = %316
  %332 = load ptr, ptr %8, align 8, !tbaa !5
  %333 = icmp ne ptr %332, null
  br i1 %333, label %334, label %340

334:                                              ; preds = %331
  %335 = load ptr, ptr %8, align 8, !tbaa !5
  %336 = call i32 @strcmp(ptr noundef %335, ptr noundef @.str.10) #7
  %337 = icmp ne i32 %336, 0
  br i1 %337, label %340, label %338

338:                                              ; preds = %334
  %339 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.60) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

340:                                              ; preds = %334, %331
  %341 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %342 = call ptr @strcpy(ptr noundef %341, ptr noundef @.str.60) #6
  %343 = call ptr @getenv(ptr noundef @.str.54) #6
  %344 = icmp ne ptr %343, null
  br i1 %344, label %348, label %345

345:                                              ; preds = %340
  %346 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %347 = call ptr @strcat(ptr noundef %346, ptr noundef @.str.42) #6
  br label %348

348:                                              ; preds = %345, %340
  br label %349

349:                                              ; preds = %348, %328
  br label %350

350:                                              ; preds = %349, %313
  br label %351

351:                                              ; preds = %350, %300
  %352 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %353 = call ptr @strcat(ptr noundef %352, ptr noundef @.str.305) #6
  %354 = load i32, ptr %13, align 4, !tbaa !9
  %355 = icmp ne i32 %354, 0
  br i1 %355, label %356, label %359

356:                                              ; preds = %351
  %357 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %358 = call ptr @strcat(ptr noundef %357, ptr noundef @.str.306) #6
  br label %359

359:                                              ; preds = %356, %351
  %360 = load ptr, ptr %8, align 8, !tbaa !5
  %361 = icmp ne ptr %360, null
  br i1 %361, label %362, label %374

362:                                              ; preds = %359
  %363 = load ptr, ptr %8, align 8, !tbaa !5
  %364 = call i64 @strlen(ptr noundef %363) #7
  %365 = icmp ne i64 %364, 0
  br i1 %365, label %366, label %374

366:                                              ; preds = %362
  %367 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %368 = call ptr @strcat(ptr noundef %367, ptr noundef @.str.66) #6
  %369 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %370 = load ptr, ptr %8, align 8, !tbaa !5
  %371 = call ptr @strcat(ptr noundef %369, ptr noundef %370) #6
  %372 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %373 = call ptr @strcat(ptr noundef %372, ptr noundef @.str.47) #6
  br label %374

374:                                              ; preds = %366, %362, %359
  %375 = load ptr, ptr %9, align 8, !tbaa !5
  %376 = icmp ne ptr %375, null
  br i1 %376, label %377, label %389

377:                                              ; preds = %374
  %378 = load ptr, ptr %9, align 8, !tbaa !5
  %379 = call i64 @strlen(ptr noundef %378) #7
  %380 = icmp ne i64 %379, 0
  br i1 %380, label %381, label %389

381:                                              ; preds = %377
  %382 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %383 = call ptr @strcat(ptr noundef %382, ptr noundef @.str.263) #6
  %384 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %385 = load ptr, ptr %9, align 8, !tbaa !5
  %386 = call ptr @strcat(ptr noundef %384, ptr noundef %385) #6
  %387 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %388 = call ptr @strcat(ptr noundef %387, ptr noundef @.str.47) #6
  br label %389

389:                                              ; preds = %381, %377, %374
  %390 = load i32, ptr %10, align 4, !tbaa !9
  %391 = icmp sgt i32 %390, 0
  br i1 %391, label %392, label %428

392:                                              ; preds = %389
  %393 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %394 = call ptr @strcat(ptr noundef %393, ptr noundef @.str.264) #6
  %395 = load ptr, ptr %12, align 8, !tbaa !5
  %396 = icmp ne ptr %395, null
  br i1 %396, label %397, label %407

397:                                              ; preds = %392
  %398 = load ptr, ptr %12, align 8, !tbaa !5
  %399 = call i64 @strlen(ptr noundef %398) #7
  %400 = icmp ne i64 %399, 0
  br i1 %400, label %401, label %407

401:                                              ; preds = %397
  %402 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %403 = load ptr, ptr %12, align 8, !tbaa !5
  %404 = call ptr @strcat(ptr noundef %402, ptr noundef %403) #6
  %405 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %406 = call ptr @strcat(ptr noundef %405, ptr noundef @.str.181) #6
  br label %407

407:                                              ; preds = %401, %397, %392
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %408

408:                                              ; preds = %422, %407
  %409 = load i32, ptr %16, align 4, !tbaa !9
  %410 = load i32, ptr %10, align 4, !tbaa !9
  %411 = icmp slt i32 %409, %410
  br i1 %411, label %412, label %425

412:                                              ; preds = %408
  %413 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %414 = load ptr, ptr %11, align 8, !tbaa !5
  %415 = load i32, ptr %16, align 4, !tbaa !9
  %416 = sext i32 %415 to i64
  %417 = getelementptr inbounds ptr, ptr %414, i64 %416
  %418 = load ptr, ptr %417, align 8, !tbaa !5
  %419 = call ptr @strcat(ptr noundef %413, ptr noundef %418) #6
  %420 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %421 = call ptr @strcat(ptr noundef %420, ptr noundef @.str.125) #6
  br label %422

422:                                              ; preds = %412
  %423 = load i32, ptr %16, align 4, !tbaa !9
  %424 = add nsw i32 %423, 1
  store i32 %424, ptr %16, align 4, !tbaa !9
  br label %408, !llvm.loop !15

425:                                              ; preds = %408
  %426 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %427 = call ptr @strcat(ptr noundef %426, ptr noundef @.str.265) #6
  br label %428

428:                                              ; preds = %425, %389
  %429 = load i32, ptr @tinyfd_silent, align 4, !tbaa !9
  %430 = icmp ne i32 %429, 0
  br i1 %430, label %431, label %434

431:                                              ; preds = %428
  %432 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %433 = call ptr @strcat(ptr noundef %432, ptr noundef @.str.70) #6
  br label %434

434:                                              ; preds = %431, %428
  br label %894

435:                                              ; preds = %274
  %436 = call noundef i32 @_ZL15tkinter2Presentv()
  %437 = icmp ne i32 %436, 0
  br i1 %437, label %438, label %591

438:                                              ; preds = %435
  %439 = load ptr, ptr %8, align 8, !tbaa !5
  %440 = icmp ne ptr %439, null
  br i1 %440, label %441, label %447

441:                                              ; preds = %438
  %442 = load ptr, ptr %8, align 8, !tbaa !5
  %443 = call i32 @strcmp(ptr noundef %442, ptr noundef @.str.10) #7
  %444 = icmp ne i32 %443, 0
  br i1 %444, label %447, label %445

445:                                              ; preds = %441
  %446 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.73) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

447:                                              ; preds = %441, %438
  %448 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %449 = call ptr @strcpy(ptr noundef %448, ptr noundef @_ZL12gPython2Name) #6
  %450 = call noundef i32 @_ZL17isTerminalRunningv()
  %451 = icmp ne i32 %450, 0
  br i1 %451, label %458, label %452

452:                                              ; preds = %447
  %453 = call noundef i32 @_ZL8isDarwinv()
  %454 = icmp ne i32 %453, 0
  br i1 %454, label %455, label %458

455:                                              ; preds = %452
  %456 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %457 = call ptr @strcat(ptr noundef %456, ptr noundef @.str.74) #6
  br label %458

458:                                              ; preds = %455, %452, %447
  %459 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %460 = call ptr @strcat(ptr noundef %459, ptr noundef @.str.266) #6
  %461 = call noundef i32 @_ZL8isDarwinv()
  %462 = icmp ne i32 %461, 0
  br i1 %462, label %463, label %466

463:                                              ; preds = %458
  %464 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %465 = call ptr @strcat(ptr noundef %464, ptr noundef @.str.76) #6
  br label %466

466:                                              ; preds = %463, %458
  %467 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %468 = call ptr @strcat(ptr noundef %467, ptr noundef @.str.307) #6
  %469 = load i32, ptr %13, align 4, !tbaa !9
  %470 = icmp ne i32 %469, 0
  br i1 %470, label %471, label %474

471:                                              ; preds = %466
  %472 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %473 = call ptr @strcat(ptr noundef %472, ptr noundef @.str.308) #6
  br label %474

474:                                              ; preds = %471, %466
  %475 = load ptr, ptr %8, align 8, !tbaa !5
  %476 = icmp ne ptr %475, null
  br i1 %476, label %477, label %489

477:                                              ; preds = %474
  %478 = load ptr, ptr %8, align 8, !tbaa !5
  %479 = call i64 @strlen(ptr noundef %478) #7
  %480 = icmp ne i64 %479, 0
  br i1 %480, label %481, label %489

481:                                              ; preds = %477
  %482 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %483 = call ptr @strcat(ptr noundef %482, ptr noundef @.str.88) #6
  %484 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %485 = load ptr, ptr %8, align 8, !tbaa !5
  %486 = call ptr @strcat(ptr noundef %484, ptr noundef %485) #6
  %487 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %488 = call ptr @strcat(ptr noundef %487, ptr noundef @.str.87) #6
  br label %489

489:                                              ; preds = %481, %477, %474
  %490 = load ptr, ptr %9, align 8, !tbaa !5
  %491 = icmp ne ptr %490, null
  br i1 %491, label %492, label %527

492:                                              ; preds = %489
  %493 = load ptr, ptr %9, align 8, !tbaa !5
  %494 = call i64 @strlen(ptr noundef %493) #7
  %495 = icmp ne i64 %494, 0
  br i1 %495, label %496, label %527

496:                                              ; preds = %492
  %497 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %498 = load ptr, ptr %9, align 8, !tbaa !5
  %499 = call noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef %497, ptr noundef %498)
  %500 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %501 = call i64 @strlen(ptr noundef %500) #7
  %502 = icmp ne i64 %501, 0
  br i1 %502, label %503, label %511

503:                                              ; preds = %496
  %504 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %505 = call ptr @strcat(ptr noundef %504, ptr noundef @.str.268) #6
  %506 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %507 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %508 = call ptr @strcat(ptr noundef %506, ptr noundef %507) #6
  %509 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %510 = call ptr @strcat(ptr noundef %509, ptr noundef @.str.87) #6
  br label %511

511:                                              ; preds = %503, %496
  %512 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %513 = load ptr, ptr %9, align 8, !tbaa !5
  %514 = call noundef ptr @_ZL11getLastNamePcPKc(ptr noundef %512, ptr noundef %513)
  %515 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %516 = call i64 @strlen(ptr noundef %515) #7
  %517 = icmp ne i64 %516, 0
  br i1 %517, label %518, label %526

518:                                              ; preds = %511
  %519 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %520 = call ptr @strcat(ptr noundef %519, ptr noundef @.str.269) #6
  %521 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %522 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %523 = call ptr @strcat(ptr noundef %521, ptr noundef %522) #6
  %524 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %525 = call ptr @strcat(ptr noundef %524, ptr noundef @.str.87) #6
  br label %526

526:                                              ; preds = %518, %511
  br label %527

527:                                              ; preds = %526, %492, %489
  %528 = load i32, ptr %10, align 4, !tbaa !9
  %529 = icmp sgt i32 %528, 1
  br i1 %529, label %546, label %530

530:                                              ; preds = %527
  %531 = load i32, ptr %10, align 4, !tbaa !9
  %532 = icmp eq i32 %531, 1
  br i1 %532, label %533, label %588

533:                                              ; preds = %530
  %534 = load ptr, ptr %11, align 8, !tbaa !5
  %535 = getelementptr inbounds ptr, ptr %534, i64 0
  %536 = load ptr, ptr %535, align 8, !tbaa !5
  %537 = load ptr, ptr %11, align 8, !tbaa !5
  %538 = getelementptr inbounds ptr, ptr %537, i64 0
  %539 = load ptr, ptr %538, align 8, !tbaa !5
  %540 = call i64 @strlen(ptr noundef %539) #7
  %541 = sub i64 %540, 1
  %542 = getelementptr inbounds i8, ptr %536, i64 %541
  %543 = load i8, ptr %542, align 1, !tbaa !11
  %544 = sext i8 %543 to i32
  %545 = icmp ne i32 %544, 42
  br i1 %545, label %546, label %588

546:                                              ; preds = %533, %527
  %547 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %548 = call ptr @strcat(ptr noundef %547, ptr noundef @.str.270) #6
  %549 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %550 = call ptr @strcat(ptr noundef %549, ptr noundef @.str.271) #6
  %551 = load ptr, ptr %12, align 8, !tbaa !5
  %552 = icmp ne ptr %551, null
  br i1 %552, label %553, label %561

553:                                              ; preds = %546
  %554 = load ptr, ptr %12, align 8, !tbaa !5
  %555 = call i64 @strlen(ptr noundef %554) #7
  %556 = icmp ne i64 %555, 0
  br i1 %556, label %557, label %561

557:                                              ; preds = %553
  %558 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %559 = load ptr, ptr %12, align 8, !tbaa !5
  %560 = call ptr @strcat(ptr noundef %558, ptr noundef %559) #6
  br label %561

561:                                              ; preds = %557, %553, %546
  %562 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %563 = call ptr @strcat(ptr noundef %562, ptr noundef @.str.272) #6
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %564

564:                                              ; preds = %580, %561
  %565 = load i32, ptr %16, align 4, !tbaa !9
  %566 = load i32, ptr %10, align 4, !tbaa !9
  %567 = icmp slt i32 %565, %566
  br i1 %567, label %568, label %583

568:                                              ; preds = %564
  %569 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %570 = call ptr @strcat(ptr noundef %569, ptr noundef @.str.92) #6
  %571 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %572 = load ptr, ptr %11, align 8, !tbaa !5
  %573 = load i32, ptr %16, align 4, !tbaa !9
  %574 = sext i32 %573 to i64
  %575 = getelementptr inbounds ptr, ptr %572, i64 %574
  %576 = load ptr, ptr %575, align 8, !tbaa !5
  %577 = call ptr @strcat(ptr noundef %571, ptr noundef %576) #6
  %578 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %579 = call ptr @strcat(ptr noundef %578, ptr noundef @.str.87) #6
  br label %580

580:                                              ; preds = %568
  %581 = load i32, ptr %16, align 4, !tbaa !9
  %582 = add nsw i32 %581, 1
  store i32 %582, ptr %16, align 4, !tbaa !9
  br label %564, !llvm.loop !16

583:                                              ; preds = %564
  %584 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %585 = call ptr @strcat(ptr noundef %584, ptr noundef @.str.273) #6
  %586 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %587 = call ptr @strcat(ptr noundef %586, ptr noundef @.str.274) #6
  br label %588

588:                                              ; preds = %583, %533, %530
  %589 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %590 = call ptr @strcat(ptr noundef %589, ptr noundef @.str.309) #6
  br label %893

591:                                              ; preds = %435
  %592 = call noundef i32 @_ZL15tkinter3Presentv()
  %593 = icmp ne i32 %592, 0
  br i1 %593, label %594, label %732

594:                                              ; preds = %591
  %595 = load ptr, ptr %8, align 8, !tbaa !5
  %596 = icmp ne ptr %595, null
  br i1 %596, label %597, label %603

597:                                              ; preds = %594
  %598 = load ptr, ptr %8, align 8, !tbaa !5
  %599 = call i32 @strcmp(ptr noundef %598, ptr noundef @.str.10) #7
  %600 = icmp ne i32 %599, 0
  br i1 %600, label %603, label %601

601:                                              ; preds = %597
  %602 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.95) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

603:                                              ; preds = %597, %594
  %604 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %605 = call ptr @strcpy(ptr noundef %604, ptr noundef @_ZL12gPython3Name) #6
  %606 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %607 = call ptr @strcat(ptr noundef %606, ptr noundef @.str.276) #6
  %608 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %609 = call ptr @strcat(ptr noundef %608, ptr noundef @.str.310) #6
  %610 = load i32, ptr %13, align 4, !tbaa !9
  %611 = icmp ne i32 %610, 0
  br i1 %611, label %612, label %615

612:                                              ; preds = %603
  %613 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %614 = call ptr @strcat(ptr noundef %613, ptr noundef @.str.308) #6
  br label %615

615:                                              ; preds = %612, %603
  %616 = load ptr, ptr %8, align 8, !tbaa !5
  %617 = icmp ne ptr %616, null
  br i1 %617, label %618, label %630

618:                                              ; preds = %615
  %619 = load ptr, ptr %8, align 8, !tbaa !5
  %620 = call i64 @strlen(ptr noundef %619) #7
  %621 = icmp ne i64 %620, 0
  br i1 %621, label %622, label %630

622:                                              ; preds = %618
  %623 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %624 = call ptr @strcat(ptr noundef %623, ptr noundef @.str.88) #6
  %625 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %626 = load ptr, ptr %8, align 8, !tbaa !5
  %627 = call ptr @strcat(ptr noundef %625, ptr noundef %626) #6
  %628 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %629 = call ptr @strcat(ptr noundef %628, ptr noundef @.str.87) #6
  br label %630

630:                                              ; preds = %622, %618, %615
  %631 = load ptr, ptr %9, align 8, !tbaa !5
  %632 = icmp ne ptr %631, null
  br i1 %632, label %633, label %668

633:                                              ; preds = %630
  %634 = load ptr, ptr %9, align 8, !tbaa !5
  %635 = call i64 @strlen(ptr noundef %634) #7
  %636 = icmp ne i64 %635, 0
  br i1 %636, label %637, label %668

637:                                              ; preds = %633
  %638 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %639 = load ptr, ptr %9, align 8, !tbaa !5
  %640 = call noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef %638, ptr noundef %639)
  %641 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %642 = call i64 @strlen(ptr noundef %641) #7
  %643 = icmp ne i64 %642, 0
  br i1 %643, label %644, label %652

644:                                              ; preds = %637
  %645 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %646 = call ptr @strcat(ptr noundef %645, ptr noundef @.str.268) #6
  %647 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %648 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %649 = call ptr @strcat(ptr noundef %647, ptr noundef %648) #6
  %650 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %651 = call ptr @strcat(ptr noundef %650, ptr noundef @.str.87) #6
  br label %652

652:                                              ; preds = %644, %637
  %653 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %654 = load ptr, ptr %9, align 8, !tbaa !5
  %655 = call noundef ptr @_ZL11getLastNamePcPKc(ptr noundef %653, ptr noundef %654)
  %656 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %657 = call i64 @strlen(ptr noundef %656) #7
  %658 = icmp ne i64 %657, 0
  br i1 %658, label %659, label %667

659:                                              ; preds = %652
  %660 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %661 = call ptr @strcat(ptr noundef %660, ptr noundef @.str.269) #6
  %662 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %663 = getelementptr inbounds [1024 x i8], ptr %15, i64 0, i64 0
  %664 = call ptr @strcat(ptr noundef %662, ptr noundef %663) #6
  %665 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %666 = call ptr @strcat(ptr noundef %665, ptr noundef @.str.87) #6
  br label %667

667:                                              ; preds = %659, %652
  br label %668

668:                                              ; preds = %667, %633, %630
  %669 = load i32, ptr %10, align 4, !tbaa !9
  %670 = icmp sgt i32 %669, 1
  br i1 %670, label %687, label %671

671:                                              ; preds = %668
  %672 = load i32, ptr %10, align 4, !tbaa !9
  %673 = icmp eq i32 %672, 1
  br i1 %673, label %674, label %729

674:                                              ; preds = %671
  %675 = load ptr, ptr %11, align 8, !tbaa !5
  %676 = getelementptr inbounds ptr, ptr %675, i64 0
  %677 = load ptr, ptr %676, align 8, !tbaa !5
  %678 = load ptr, ptr %11, align 8, !tbaa !5
  %679 = getelementptr inbounds ptr, ptr %678, i64 0
  %680 = load ptr, ptr %679, align 8, !tbaa !5
  %681 = call i64 @strlen(ptr noundef %680) #7
  %682 = sub i64 %681, 1
  %683 = getelementptr inbounds i8, ptr %677, i64 %682
  %684 = load i8, ptr %683, align 1, !tbaa !11
  %685 = sext i8 %684 to i32
  %686 = icmp ne i32 %685, 42
  br i1 %686, label %687, label %729

687:                                              ; preds = %674, %668
  %688 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %689 = call ptr @strcat(ptr noundef %688, ptr noundef @.str.270) #6
  %690 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %691 = call ptr @strcat(ptr noundef %690, ptr noundef @.str.271) #6
  %692 = load ptr, ptr %12, align 8, !tbaa !5
  %693 = icmp ne ptr %692, null
  br i1 %693, label %694, label %702

694:                                              ; preds = %687
  %695 = load ptr, ptr %12, align 8, !tbaa !5
  %696 = call i64 @strlen(ptr noundef %695) #7
  %697 = icmp ne i64 %696, 0
  br i1 %697, label %698, label %702

698:                                              ; preds = %694
  %699 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %700 = load ptr, ptr %12, align 8, !tbaa !5
  %701 = call ptr @strcat(ptr noundef %699, ptr noundef %700) #6
  br label %702

702:                                              ; preds = %698, %694, %687
  %703 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %704 = call ptr @strcat(ptr noundef %703, ptr noundef @.str.272) #6
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %705

705:                                              ; preds = %721, %702
  %706 = load i32, ptr %16, align 4, !tbaa !9
  %707 = load i32, ptr %10, align 4, !tbaa !9
  %708 = icmp slt i32 %706, %707
  br i1 %708, label %709, label %724

709:                                              ; preds = %705
  %710 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %711 = call ptr @strcat(ptr noundef %710, ptr noundef @.str.92) #6
  %712 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %713 = load ptr, ptr %11, align 8, !tbaa !5
  %714 = load i32, ptr %16, align 4, !tbaa !9
  %715 = sext i32 %714 to i64
  %716 = getelementptr inbounds ptr, ptr %713, i64 %715
  %717 = load ptr, ptr %716, align 8, !tbaa !5
  %718 = call ptr @strcat(ptr noundef %712, ptr noundef %717) #6
  %719 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %720 = call ptr @strcat(ptr noundef %719, ptr noundef @.str.87) #6
  br label %721

721:                                              ; preds = %709
  %722 = load i32, ptr %16, align 4, !tbaa !9
  %723 = add nsw i32 %722, 1
  store i32 %723, ptr %16, align 4, !tbaa !9
  br label %705, !llvm.loop !17

724:                                              ; preds = %705
  %725 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %726 = call ptr @strcat(ptr noundef %725, ptr noundef @.str.273) #6
  %727 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %728 = call ptr @strcat(ptr noundef %727, ptr noundef @.str.274) #6
  br label %729

729:                                              ; preds = %724, %674, %671
  %730 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %731 = call ptr @strcat(ptr noundef %730, ptr noundef @.str.311) #6
  br label %892

732:                                              ; preds = %591
  %733 = call noundef i32 @_ZL14xdialogPresentv()
  %734 = icmp ne i32 %733, 0
  br i1 %734, label %738, label %735

735:                                              ; preds = %732
  %736 = call noundef ptr @_ZL10dialogNamev()
  %737 = icmp ne ptr %736, null
  br i1 %737, label %738, label %872

738:                                              ; preds = %735, %732
  %739 = call noundef i32 @_ZL14xdialogPresentv()
  %740 = icmp ne i32 %739, 0
  br i1 %740, label %741, label %753

741:                                              ; preds = %738
  %742 = load ptr, ptr %8, align 8, !tbaa !5
  %743 = icmp ne ptr %742, null
  br i1 %743, label %744, label %750

744:                                              ; preds = %741
  %745 = load ptr, ptr %8, align 8, !tbaa !5
  %746 = call i32 @strcmp(ptr noundef %745, ptr noundef @.str.10) #7
  %747 = icmp ne i32 %746, 0
  br i1 %747, label %750, label %748

748:                                              ; preds = %744
  %749 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.120) #6
  store ptr inttoptr (i64 1 to ptr), ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

750:                                              ; preds = %744, %741
  store i32 1, ptr %21, align 4, !tbaa !9
  %751 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %752 = call ptr @strcpy(ptr noundef %751, ptr noundef @.str.121) #6
  br label %789

753:                                              ; preds = %738
  %754 = call noundef i32 @_ZL17isTerminalRunningv()
  %755 = icmp ne i32 %754, 0
  br i1 %755, label %756, label %768

756:                                              ; preds = %753
  %757 = load ptr, ptr %8, align 8, !tbaa !5
  %758 = icmp ne ptr %757, null
  br i1 %758, label %759, label %765

759:                                              ; preds = %756
  %760 = load ptr, ptr %8, align 8, !tbaa !5
  %761 = call i32 @strcmp(ptr noundef %760, ptr noundef @.str.10) #7
  %762 = icmp ne i32 %761, 0
  br i1 %762, label %765, label %763

763:                                              ; preds = %759
  %764 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.122) #6
  store ptr null, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

765:                                              ; preds = %759, %756
  %766 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %767 = call ptr @strcpy(ptr noundef %766, ptr noundef @.str.123) #6
  br label %788

768:                                              ; preds = %753
  %769 = load ptr, ptr %8, align 8, !tbaa !5
  %770 = icmp ne ptr %769, null
  br i1 %770, label %771, label %777

771:                                              ; preds = %768
  %772 = load ptr, ptr %8, align 8, !tbaa !5
  %773 = call i32 @strcmp(ptr noundef %772, ptr noundef @.str.10) #7
  %774 = icmp ne i32 %773, 0
  br i1 %774, label %777, label %775

775:                                              ; preds = %771
  %776 = call ptr @strcpy(ptr noundef @tinyfd_response, ptr noundef @.str.122) #6
  store ptr null, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

777:                                              ; preds = %771, %768
  store i32 1, ptr %22, align 4, !tbaa !9
  %778 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %779 = call noundef ptr @_ZL12terminalNamev()
  %780 = call ptr @strcpy(ptr noundef %778, ptr noundef %779) #6
  %781 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %782 = call ptr @strcat(ptr noundef %781, ptr noundef @.str.124) #6
  %783 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %784 = call noundef ptr @_ZL10dialogNamev()
  %785 = call ptr @strcat(ptr noundef %783, ptr noundef %784) #6
  %786 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %787 = call ptr @strcat(ptr noundef %786, ptr noundef @.str.125) #6
  br label %788

788:                                              ; preds = %777, %765
  br label %789

789:                                              ; preds = %788, %750
  %790 = load ptr, ptr %8, align 8, !tbaa !5
  %791 = icmp ne ptr %790, null
  br i1 %791, label %792, label %804

792:                                              ; preds = %789
  %793 = load ptr, ptr %8, align 8, !tbaa !5
  %794 = call i64 @strlen(ptr noundef %793) #7
  %795 = icmp ne i64 %794, 0
  br i1 %795, label %796, label %804

796:                                              ; preds = %792
  %797 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %798 = call ptr @strcat(ptr noundef %797, ptr noundef @.str.129) #6
  %799 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %800 = load ptr, ptr %8, align 8, !tbaa !5
  %801 = call ptr @strcat(ptr noundef %799, ptr noundef %800) #6
  %802 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %803 = call ptr @strcat(ptr noundef %802, ptr noundef @.str.15) #6
  br label %804

804:                                              ; preds = %796, %792, %789
  %805 = call noundef i32 @_ZL14xdialogPresentv()
  %806 = icmp ne i32 %805, 0
  br i1 %806, label %817, label %807

807:                                              ; preds = %804
  %808 = call noundef i32 @_ZL14gdialogPresentv()
  %809 = icmp ne i32 %808, 0
  br i1 %809, label %817, label %810

810:                                              ; preds = %807
  %811 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %812 = call ptr @strcat(ptr noundef %811, ptr noundef @.str.130) #6
  %813 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %814 = call ptr @strcat(ptr noundef %813, ptr noundef @.str.279) #6
  %815 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %816 = call ptr @strcat(ptr noundef %815, ptr noundef @.str.15) #6
  br label %817

817:                                              ; preds = %810, %807, %804
  %818 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %819 = call ptr @strcat(ptr noundef %818, ptr noundef @.str.280) #6
  %820 = load ptr, ptr %9, align 8, !tbaa !5
  %821 = icmp ne ptr %820, null
  br i1 %821, label %822, label %837

822:                                              ; preds = %817
  %823 = load ptr, ptr %9, align 8, !tbaa !5
  %824 = call i64 @strlen(ptr noundef %823) #7
  %825 = icmp ne i64 %824, 0
  br i1 %825, label %826, label %837

826:                                              ; preds = %822
  %827 = load ptr, ptr %9, align 8, !tbaa !5
  %828 = call noundef ptr @strchr(ptr noundef %827, i32 noundef 47) #7
  %829 = icmp ne ptr %828, null
  br i1 %829, label %833, label %830

830:                                              ; preds = %826
  %831 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %832 = call ptr @strcat(ptr noundef %831, ptr noundef @.str.281) #6
  br label %833

833:                                              ; preds = %830, %826
  %834 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %835 = load ptr, ptr %9, align 8, !tbaa !5
  %836 = call ptr @strcat(ptr noundef %834, ptr noundef %835) #6
  br label %853

837:                                              ; preds = %822, %817
  %838 = call noundef i32 @_ZL17isTerminalRunningv()
  %839 = icmp ne i32 %838, 0
  br i1 %839, label %849, label %840

840:                                              ; preds = %837
  %841 = load i32, ptr %21, align 4, !tbaa !9
  %842 = icmp ne i32 %841, 0
  br i1 %842, label %849, label %843

843:                                              ; preds = %840
  %844 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %845 = call ptr @getenv(ptr noundef @.str.282) #6
  %846 = call ptr @strcat(ptr noundef %844, ptr noundef %845) #6
  %847 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %848 = call ptr @strcat(ptr noundef %847, ptr noundef @.str.283) #6
  br label %852

849:                                              ; preds = %840, %837
  %850 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %851 = call ptr @strcat(ptr noundef %850, ptr noundef @.str.281) #6
  br label %852

852:                                              ; preds = %849, %843
  br label %853

853:                                              ; preds = %852, %833
  %854 = load i32, ptr %21, align 4, !tbaa !9
  %855 = icmp ne i32 %854, 0
  br i1 %855, label %856, label %859

856:                                              ; preds = %853
  %857 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %858 = call ptr @strcat(ptr noundef %857, ptr noundef @.str.284) #6
  br label %871

859:                                              ; preds = %853
  %860 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %861 = call ptr @strcat(ptr noundef %860, ptr noundef @.str.285) #6
  %862 = load i32, ptr %22, align 4, !tbaa !9
  %863 = icmp ne i32 %862, 0
  br i1 %863, label %864, label %867

864:                                              ; preds = %859
  %865 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %866 = call ptr @strcat(ptr noundef %865, ptr noundef @.str.286) #6
  br label %870

867:                                              ; preds = %859
  %868 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %869 = call ptr @strcat(ptr noundef %868, ptr noundef @.str.287) #6
  br label %870

870:                                              ; preds = %867, %864
  br label %871

871:                                              ; preds = %870, %856
  br label %891

872:                                              ; preds = %735
  %873 = load ptr, ptr %8, align 8, !tbaa !5
  %874 = icmp ne ptr %873, null
  br i1 %874, label %875, label %882

875:                                              ; preds = %872
  %876 = load ptr, ptr %8, align 8, !tbaa !5
  %877 = call i32 @strcmp(ptr noundef %876, ptr noundef @.str.10) #7
  %878 = icmp ne i32 %877, 0
  br i1 %878, label %882, label %879

879:                                              ; preds = %875
  %880 = load ptr, ptr %8, align 8, !tbaa !5
  %881 = call ptr @tinyfd_inputBox(ptr noundef %880, ptr noundef null, ptr noundef null)
  store ptr %881, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

882:                                              ; preds = %875, %872
  %883 = load ptr, ptr %8, align 8, !tbaa !5
  %884 = call ptr @tinyfd_inputBox(ptr noundef %883, ptr noundef @.str.312, ptr noundef @.str.177)
  store ptr %884, ptr %19, align 8, !tbaa !5
  %885 = load ptr, ptr %19, align 8, !tbaa !5
  %886 = call noundef i32 @_ZL10fileExistsPKc(ptr noundef %885)
  %887 = icmp ne i32 %886, 0
  br i1 %887, label %889, label %888

888:                                              ; preds = %882
  store ptr null, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

889:                                              ; preds = %882
  %890 = load ptr, ptr %19, align 8, !tbaa !5
  store ptr %890, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

891:                                              ; preds = %871
  br label %892

892:                                              ; preds = %891, %729
  br label %893

893:                                              ; preds = %892, %588
  br label %894

894:                                              ; preds = %893, %434
  br label %895

895:                                              ; preds = %894, %264
  br label %896

896:                                              ; preds = %895, %154
  %897 = load i32, ptr @tinyfd_verbose, align 4, !tbaa !9
  %898 = icmp ne i32 %897, 0
  br i1 %898, label %899, label %902

899:                                              ; preds = %896
  %900 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %901 = call i32 (ptr, ...) @printf(ptr noundef @.str.8, ptr noundef %900)
  br label %902

902:                                              ; preds = %899, %896
  %903 = getelementptr inbounds [1024 x i8], ptr %14, i64 0, i64 0
  %904 = call noalias ptr @popen(ptr noundef %903, ptr noundef @.str.9)
  store ptr %904, ptr %17, align 8, !tbaa !5
  %905 = icmp ne ptr %904, null
  br i1 %905, label %907, label %906

906:                                              ; preds = %902
  store ptr null, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

907:                                              ; preds = %902
  store i8 0, ptr @_ZZ21tinyfd_openFileDialogE5lBuff, align 16, !tbaa !11
  store ptr @_ZZ21tinyfd_openFileDialogE5lBuff, ptr %18, align 8, !tbaa !5
  br label %908

908:                                              ; preds = %913, %907
  %909 = load ptr, ptr %18, align 8, !tbaa !5
  %910 = load ptr, ptr %17, align 8, !tbaa !5
  %911 = call ptr @fgets(ptr noundef %909, i32 noundef 32768, ptr noundef %910)
  %912 = icmp ne ptr %911, null
  br i1 %912, label %913, label %918

913:                                              ; preds = %908
  %914 = load ptr, ptr %18, align 8, !tbaa !5
  %915 = call i64 @strlen(ptr noundef %914) #7
  %916 = load ptr, ptr %18, align 8, !tbaa !5
  %917 = getelementptr inbounds i8, ptr %916, i64 %915
  store ptr %917, ptr %18, align 8, !tbaa !5
  br label %908, !llvm.loop !18

918:                                              ; preds = %908
  %919 = load ptr, ptr %17, align 8, !tbaa !5
  %920 = call i32 @pclose(ptr noundef %919)
  %921 = call i64 @strlen(ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff) #7
  %922 = sub i64 %921, 1
  %923 = getelementptr inbounds [32768 x i8], ptr @_ZZ21tinyfd_openFileDialogE5lBuff, i64 0, i64 %922
  %924 = load i8, ptr %923, align 1, !tbaa !11
  %925 = sext i8 %924 to i32
  %926 = icmp eq i32 %925, 10
  br i1 %926, label %927, label %931

927:                                              ; preds = %918
  %928 = call i64 @strlen(ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff) #7
  %929 = sub i64 %928, 1
  %930 = getelementptr inbounds [32768 x i8], ptr @_ZZ21tinyfd_openFileDialogE5lBuff, i64 0, i64 %929
  store i8 0, ptr %930, align 1, !tbaa !11
  br label %931

931:                                              ; preds = %927, %918
  %932 = load i32, ptr %20, align 4, !tbaa !9
  %933 = icmp ne i32 %932, 0
  br i1 %933, label %934, label %945

934:                                              ; preds = %931
  %935 = load i32, ptr %13, align 4, !tbaa !9
  %936 = icmp ne i32 %935, 0
  br i1 %936, label %937, label %945

937:                                              ; preds = %934
  store ptr @_ZZ21tinyfd_openFileDialogE5lBuff, ptr %18, align 8, !tbaa !5
  br label %938

938:                                              ; preds = %942, %937
  %939 = load ptr, ptr %18, align 8, !tbaa !5
  %940 = call noundef ptr @strchr(ptr noundef %939, i32 noundef 10) #7
  store ptr %940, ptr %18, align 8, !tbaa !5
  %941 = icmp ne ptr %940, null
  br i1 %941, label %942, label %944

942:                                              ; preds = %938
  %943 = load ptr, ptr %18, align 8, !tbaa !5
  store i8 124, ptr %943, align 1, !tbaa !11
  br label %938, !llvm.loop !19

944:                                              ; preds = %938
  br label %945

945:                                              ; preds = %944, %934, %931
  %946 = call i64 @strlen(ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff) #7
  %947 = icmp ne i64 %946, 0
  br i1 %947, label %949, label %948

948:                                              ; preds = %945
  store ptr null, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

949:                                              ; preds = %945
  %950 = load i32, ptr %13, align 4, !tbaa !9
  %951 = icmp ne i32 %950, 0
  br i1 %951, label %952, label %957

952:                                              ; preds = %949
  %953 = call noundef ptr @strchr(ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff, i32 noundef 124) #7
  %954 = icmp ne ptr %953, null
  br i1 %954, label %955, label %957

955:                                              ; preds = %952
  %956 = call noundef ptr @_ZL16ensureFilesExistPcPKc(ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff, ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff)
  store ptr %956, ptr %19, align 8, !tbaa !5
  br label %963

957:                                              ; preds = %952, %949
  %958 = call noundef i32 @_ZL10fileExistsPKc(ptr noundef @_ZZ21tinyfd_openFileDialogE5lBuff)
  %959 = icmp ne i32 %958, 0
  br i1 %959, label %960, label %961

960:                                              ; preds = %957
  store ptr @_ZZ21tinyfd_openFileDialogE5lBuff, ptr %19, align 8, !tbaa !5
  br label %962

961:                                              ; preds = %957
  store ptr null, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

962:                                              ; preds = %960
  br label %963

963:                                              ; preds = %962, %955
  %964 = load ptr, ptr %19, align 8, !tbaa !5
  store ptr %964, ptr %7, align 8
  store i32 1, ptr %23, align 4
  br label %965

965:                                              ; preds = %963, %961, %948, %906, %889, %888, %879, %775, %763, %748, %601, %445, %338, %326, %311, %287, %165, %33
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  call void @llvm.lifetime.end.p0(i64 1024, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 1024, ptr %14) #6
  %966 = load ptr, ptr %7, align 8
  ret ptr %966
}

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL16ensureFilesExistPcPKc(ptr noundef, ptr noundef) #3

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nounwind willreturn memory(read) "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 #2 = { nounwind "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 = { mustprogress 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 #4 = { "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 #5 = { mustprogress 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 #6 = { nounwind }
attributes #7 = { nounwind willreturn memory(read) }

!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++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}
!14 = distinct !{!14, !13}
!15 = distinct !{!15, !13}
!16 = distinct !{!16, !13}
!17 = distinct !{!17, !13}
!18 = distinct !{!18, !13}
!19 = distinct !{!19, !13}


; 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"

@tinyfd_verbose = external dso_local local_unnamed_addr global i32, align 4
@tinyfd_silent = external dso_local local_unnamed_addr global i32, align 4
@tinyfd_response = external dso_local global [1024 x i8], align 16
@.str.8 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [75 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.66 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.70 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [16 x i8], align 1
@_ZL12gPython2Name = external hidden global [16 x i8], align 16
@.str.74 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.76 = external hidden unnamed_addr constant [120 x i8], align 1
@.str.87 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.88 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.92 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.95 = external hidden unnamed_addr constant [16 x i8], align 1
@_ZL12gPython3Name = external hidden global [16 x i8], align 16
@.str.120 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.121 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.122 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.123 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.124 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.125 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.129 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.130 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.177 = external hidden unnamed_addr constant [1 x i8], align 1
@.str.181 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.257 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.258 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.261 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.263 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.264 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.265 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.266 = external hidden unnamed_addr constant [71 x i8], align 1
@.str.268 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.269 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.270 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.271 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.272 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.273 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.274 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.276 = external hidden unnamed_addr constant [89 x i8], align 1
@.str.279 = external hidden unnamed_addr constant [75 x i8], align 1
@.str.280 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.281 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.282 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.283 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.284 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.285 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.286 = external hidden unnamed_addr constant [58 x i8], align 1
@.str.287 = external hidden unnamed_addr constant [23 x i8], align 1
@_ZZ21tinyfd_openFileDialogE5lBuff = external hidden global [32768 x i8], align 16
@.str.289 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.290 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.291 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.292 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.293 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.294 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.295 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.296 = external hidden unnamed_addr constant [36 x i8], align 1
@.str.297 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.298 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.299 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.300 = external hidden unnamed_addr constant [64 x i8], align 1
@.str.301 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.302 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.303 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.304 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.305 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.306 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.307 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.308 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.309 = external hidden unnamed_addr constant [154 x i8], align 1
@.str.310 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.311 = external hidden unnamed_addr constant [156 x i8], align 1
@.str.312 = external hidden unnamed_addr constant [10 x i8], align 1

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare i64 @strlen(ptr nocapture noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: readwrite)
declare ptr @strcpy(ptr noalias noundef returned writeonly, ptr noalias nocapture noundef readonly) 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) #0

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL16osascriptPresentv() local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #4

; Function Attrs: nofree nounwind
declare noalias noundef ptr @popen(ptr nocapture noundef readonly, ptr nocapture noundef readonly) local_unnamed_addr #4

; Function Attrs: nofree nounwind
declare noundef i32 @pclose(ptr nocapture noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare i32 @strcmp(ptr nocapture noundef, ptr nocapture noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL12osx9orBetterv() local_unnamed_addr #3

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: readwrite)
declare ptr @strcat(ptr noalias noundef returned, ptr noalias nocapture noundef readonly) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14kdialogPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL13zenityPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL17matedialogPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL20shellementaryPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL12qarmaPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14zenity3Presentv() local_unnamed_addr #3

; Function Attrs: nofree nounwind memory(read)
declare noundef ptr @getenv(ptr nocapture noundef) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14gdialogPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL14xdialogPresentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL15tkinter2Presentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL17isTerminalRunningv() local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZL8isDarwinv() local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL15tkinter3Presentv() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL10dialogNamev() local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL12terminalNamev() local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef ptr @fgets(ptr noundef, i32 noundef, ptr nocapture noundef) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare dso_local ptr @tinyfd_inputBox(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare noundef ptr @strchr(ptr noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL10fileExistsPKc(ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef, ptr noundef) local_unnamed_addr #6

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef ptr @_ZL11getLastNamePcPKc(ptr noundef, ptr noundef) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
define dso_local ptr @tinyfd_openFileDialog(ptr noundef %0, ptr noundef %1, i32 noundef %2, ptr nocapture noundef readonly %3, ptr noundef readonly %4, i32 noundef %5) local_unnamed_addr #3 {
  %7 = alloca [1024 x i8], align 16
  %8 = alloca [1024 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 1024, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 1024, ptr nonnull %8) #7
  store i8 0, ptr @_ZZ21tinyfd_openFileDialogE5lBuff, align 16, !tbaa !5
  %9 = tail call noundef i32 @_ZL16osascriptPresentv()
  %.not = icmp eq i32 %9, 0
  br i1 %.not, label %63, label %10

10:                                               ; preds = %6
  %.not267 = icmp eq ptr %0, null
  br i1 %.not267, label %15, label %11

11:                                               ; preds = %10
  %12 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not268 = icmp eq i32 %12, 0
  br i1 %.not268, label %13, label %15

13:                                               ; preds = %11
  %14 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.11) #7
  br label %411

15:                                               ; preds = %11, %10
  %16 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.12) #7
  %17 = call noundef i32 @_ZL12osx9orBetterv()
  %.not269 = icmp eq i32 %17, 0
  br i1 %.not269, label %18, label %20

18:                                               ; preds = %15
  %19 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.13) #7
  br label %20

20:                                               ; preds = %18, %15
  %21 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.289) #7
  %.not270 = icmp eq i32 %5, 0
  %.str.290..str.291 = select i1 %.not270, ptr @.str.290, ptr @.str.291
  %22 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.290..str.291) #7
  %23 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.292) #7
  br i1 %.not267, label %29, label %24

24:                                               ; preds = %20
  %char0271 = load i8, ptr %0, align 1
  %.not272 = icmp eq i8 %char0271, 0
  br i1 %.not272, label %29, label %25

25:                                               ; preds = %24
  %26 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.257) #7
  %27 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %0) #7
  %28 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.15) #7
  br label %29

29:                                               ; preds = %25, %24, %20
  %30 = call noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef nonnull %8, ptr noundef %1)
  %char0273 = load i8, ptr %8, align 16
  %.not274 = icmp eq i8 %char0273, 0
  br i1 %.not274, label %35, label %31

31:                                               ; preds = %29
  %32 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.258) #7
  %33 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %8) #7
  %34 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.15) #7
  br label %35

35:                                               ; preds = %31, %29
  %36 = icmp sgt i32 %2, 0
  br i1 %36, label %37, label %50

37:                                               ; preds = %35
  %38 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.293) #7
  %39 = load ptr, ptr %3, align 8, !tbaa !8
  %40 = getelementptr inbounds i8, ptr %39, i64 2
  %41 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %40) #7
  %42 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.47) #7
  %.not305 = icmp eq i32 %2, 1
  br i1 %.not305, label %._crit_edge, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %37
  %wide.trip.count = zext nneg i32 %2 to i64
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 1, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %43 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.294) #7
  %44 = getelementptr inbounds ptr, ptr %3, i64 %indvars.iv
  %45 = load ptr, ptr %44, align 8, !tbaa !8
  %46 = getelementptr inbounds i8, ptr %45, i64 2
  %47 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %46) #7
  %48 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.47) #7
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !10

._crit_edge:                                      ; preds = %.lr.ph, %37
  %49 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.295) #7
  br label %50

50:                                               ; preds = %._crit_edge, %35
  br i1 %.not270, label %58, label %51

51:                                               ; preds = %50
  %52 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.296) #7
  %53 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.297) #7
  %54 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.298) #7
  %55 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.299) #7
  %56 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.300) #7
  %57 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.301) #7
  br label %58

58:                                               ; preds = %50, %51
  %.str.35.sink = phi ptr [ @.str.302, %51 ], [ @.str.35, %50 ]
  %59 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.35.sink) #7
  %60 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.37) #7
  %61 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.39) #7
  %62 = call noundef i32 @_ZL12osx9orBetterv()
  %.not275 = icmp eq i32 %62, 0
  br i1 %.not275, label %.sink.split, label %380

63:                                               ; preds = %6
  %64 = tail call noundef i32 @_ZL14kdialogPresentv()
  %.not166 = icmp ne i32 %64, 0
  br i1 %.not166, label %65, label %106

65:                                               ; preds = %63
  %.not255 = icmp eq ptr %0, null
  br i1 %.not255, label %70, label %66

66:                                               ; preds = %65
  %67 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not256 = icmp eq i32 %67, 0
  br i1 %.not256, label %68, label %70

68:                                               ; preds = %66
  %69 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.41) #7
  br label %411

70:                                               ; preds = %66, %65
  %71 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.41) #7
  %72 = call noundef i32 @_ZL14kdialogPresentv()
  %73 = icmp eq i32 %72, 2
  br i1 %73, label %74, label %76

74:                                               ; preds = %70
  %75 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.42) #7
  br label %76

76:                                               ; preds = %74, %70
  %77 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.303) #7
  %.not257 = icmp eq ptr %1, null
  br i1 %.not257, label %84, label %78

78:                                               ; preds = %76
  %char0258 = load i8, ptr %1, align 1
  switch i8 %char0258, label %79 [
    i8 0, label %84
    i8 47, label %81
  ]

79:                                               ; preds = %78
  %80 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.261) #7
  br label %81

81:                                               ; preds = %78, %79
  %82 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.47) #7
  %83 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %1) #7
  br label %84

84:                                               ; preds = %76, %78, %81
  %.str.261.sink = phi ptr [ @.str.47, %81 ], [ @.str.261, %78 ], [ @.str.261, %76 ]
  %85 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.261.sink) #7
  %86 = icmp sgt i32 %2, 0
  br i1 %86, label %87, label %101

87:                                               ; preds = %84
  %88 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.46) #7
  %wide.trip.count310 = zext nneg i32 %2 to i64
  br label %89

89:                                               ; preds = %87, %89
  %indvars.iv307 = phi i64 [ 0, %87 ], [ %indvars.iv.next308, %89 ]
  %90 = getelementptr inbounds ptr, ptr %3, i64 %indvars.iv307
  %91 = load ptr, ptr %90, align 8, !tbaa !8
  %92 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %91) #7
  %93 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.125) #7
  %indvars.iv.next308 = add nuw nsw i64 %indvars.iv307, 1
  %exitcond311.not = icmp eq i64 %indvars.iv.next308, %wide.trip.count310
  br i1 %exitcond311.not, label %94, label %89, !llvm.loop !12

94:                                               ; preds = %89
  %.not261 = icmp eq ptr %4, null
  br i1 %.not261, label %99, label %95

95:                                               ; preds = %94
  %char0262 = load i8, ptr %4, align 1
  %.not263 = icmp eq i8 %char0262, 0
  br i1 %.not263, label %99, label %96

96:                                               ; preds = %95
  %97 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.181) #7
  %98 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %4) #7
  br label %99

99:                                               ; preds = %96, %95, %94
  %100 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.47) #7
  br label %101

101:                                              ; preds = %99, %84
  %.not264 = icmp eq i32 %5, 0
  br i1 %.not264, label %104, label %102

102:                                              ; preds = %101
  %103 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.304) #7
  br label %104

104:                                              ; preds = %102, %101
  br i1 %.not255, label %380, label %105

105:                                              ; preds = %104
  %char0265 = load i8, ptr %0, align 1
  %.not266 = icmp eq i8 %char0265, 0
  br i1 %.not266, label %380, label %.sink.split.sink.split.sink.split

106:                                              ; preds = %63
  %107 = tail call noundef i32 @_ZL13zenityPresentv()
  %.not167 = icmp eq i32 %107, 0
  br i1 %.not167, label %108, label %114

108:                                              ; preds = %106
  %109 = tail call noundef i32 @_ZL17matedialogPresentv()
  %.not168 = icmp eq i32 %109, 0
  br i1 %.not168, label %110, label %114

110:                                              ; preds = %108
  %111 = tail call noundef i32 @_ZL20shellementaryPresentv()
  %.not169 = icmp eq i32 %111, 0
  br i1 %.not169, label %112, label %114

112:                                              ; preds = %110
  %113 = tail call noundef i32 @_ZL12qarmaPresentv()
  %.not170 = icmp eq i32 %113, 0
  br i1 %.not170, label %188, label %114

114:                                              ; preds = %112, %110, %108, %106
  %115 = tail call noundef i32 @_ZL13zenityPresentv()
  %.not231 = icmp eq i32 %115, 0
  br i1 %.not231, label %129, label %116

116:                                              ; preds = %114
  %.not241 = icmp eq ptr %0, null
  br i1 %.not241, label %121, label %117

117:                                              ; preds = %116
  %118 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not242 = icmp eq i32 %118, 0
  br i1 %.not242, label %119, label %121

119:                                              ; preds = %117
  %120 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.52) #7
  br label %411

121:                                              ; preds = %117, %116
  %122 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.52) #7
  %123 = call noundef i32 @_ZL14zenity3Presentv()
  %124 = icmp sgt i32 %123, 3
  br i1 %124, label %125, label %157

125:                                              ; preds = %121
  %126 = call ptr @getenv(ptr noundef nonnull @.str.54) #7
  %.not243 = icmp eq ptr %126, null
  br i1 %.not243, label %127, label %157

127:                                              ; preds = %125
  %128 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.55) #7
  br label %157

129:                                              ; preds = %114
  %130 = tail call noundef i32 @_ZL17matedialogPresentv()
  %.not232 = icmp eq i32 %130, 0
  br i1 %.not232, label %138, label %131

131:                                              ; preds = %129
  %.not239 = icmp eq ptr %0, null
  br i1 %.not239, label %136, label %132

132:                                              ; preds = %131
  %133 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not240 = icmp eq i32 %133, 0
  br i1 %.not240, label %134, label %136

134:                                              ; preds = %132
  %135 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.56) #7
  br label %411

136:                                              ; preds = %132, %131
  %137 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.56) #7
  br label %157

138:                                              ; preds = %129
  %139 = tail call noundef i32 @_ZL20shellementaryPresentv()
  %.not233 = icmp eq i32 %139, 0
  %.not234 = icmp eq ptr %0, null
  br i1 %.not233, label %147, label %140

140:                                              ; preds = %138
  br i1 %.not234, label %145, label %141

141:                                              ; preds = %140
  %142 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not238 = icmp eq i32 %142, 0
  br i1 %.not238, label %143, label %145

143:                                              ; preds = %141
  %144 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.58) #7
  br label %411

145:                                              ; preds = %141, %140
  %146 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.58) #7
  br label %157

147:                                              ; preds = %138
  br i1 %.not234, label %152, label %148

148:                                              ; preds = %147
  %149 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not235 = icmp eq i32 %149, 0
  br i1 %.not235, label %150, label %152

150:                                              ; preds = %148
  %151 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.60) #7
  br label %411

152:                                              ; preds = %148, %147
  %153 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.60) #7
  %154 = call ptr @getenv(ptr noundef nonnull @.str.54) #7
  %.not236 = icmp eq ptr %154, null
  br i1 %.not236, label %155, label %157

155:                                              ; preds = %152
  %156 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.42) #7
  br label %157

157:                                              ; preds = %136, %152, %155, %145, %121, %125, %127
  %158 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.305) #7
  %.not244 = icmp eq i32 %5, 0
  br i1 %.not244, label %161, label %159

159:                                              ; preds = %157
  %160 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.306) #7
  br label %161

161:                                              ; preds = %159, %157
  %.not245 = icmp eq ptr %0, null
  br i1 %.not245, label %167, label %162

162:                                              ; preds = %161
  %char0246 = load i8, ptr %0, align 1
  %.not247 = icmp eq i8 %char0246, 0
  br i1 %.not247, label %167, label %163

163:                                              ; preds = %162
  %164 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.66) #7
  %165 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %0) #7
  %166 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.47) #7
  br label %167

167:                                              ; preds = %163, %162, %161
  %.not248 = icmp eq ptr %1, null
  br i1 %.not248, label %173, label %168

168:                                              ; preds = %167
  %char0249 = load i8, ptr %1, align 1
  %.not250 = icmp eq i8 %char0249, 0
  br i1 %.not250, label %173, label %169

169:                                              ; preds = %168
  %170 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.263) #7
  %171 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %1) #7
  %172 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.47) #7
  br label %173

173:                                              ; preds = %169, %168, %167
  %174 = icmp sgt i32 %2, 0
  br i1 %174, label %175, label %186

175:                                              ; preds = %173
  %176 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.264) #7
  %.not251 = icmp eq ptr %4, null
  br i1 %.not251, label %.lr.ph288.preheader, label %177

177:                                              ; preds = %175
  %char0252 = load i8, ptr %4, align 1
  %.not253 = icmp eq i8 %char0252, 0
  br i1 %.not253, label %.lr.ph288.preheader, label %178

178:                                              ; preds = %177
  %179 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %4) #7
  %180 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.181) #7
  br label %.lr.ph288.preheader

.lr.ph288.preheader:                              ; preds = %175, %177, %178
  %wide.trip.count315 = zext nneg i32 %2 to i64
  br label %.lr.ph288

.lr.ph288:                                        ; preds = %.lr.ph288.preheader, %.lr.ph288
  %indvars.iv312 = phi i64 [ 0, %.lr.ph288.preheader ], [ %indvars.iv.next313, %.lr.ph288 ]
  %181 = getelementptr inbounds ptr, ptr %3, i64 %indvars.iv312
  %182 = load ptr, ptr %181, align 8, !tbaa !8
  %183 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %182) #7
  %184 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.125) #7
  %indvars.iv.next313 = add nuw nsw i64 %indvars.iv312, 1
  %exitcond316.not = icmp eq i64 %indvars.iv.next313, %wide.trip.count315
  br i1 %exitcond316.not, label %._crit_edge289, label %.lr.ph288, !llvm.loop !13

._crit_edge289:                                   ; preds = %.lr.ph288
  %185 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.265) #7
  br label %186

186:                                              ; preds = %._crit_edge289, %173
  %187 = load i32, ptr @tinyfd_silent, align 4, !tbaa !14
  %.not254 = icmp eq i32 %187, 0
  br i1 %.not254, label %380, label %.sink.split

188:                                              ; preds = %112
  %189 = tail call noundef i32 @_ZL15tkinter2Presentv()
  %.not171 = icmp eq i32 %189, 0
  br i1 %.not171, label %253, label %190

190:                                              ; preds = %188
  %.not212 = icmp eq ptr %0, null
  br i1 %.not212, label %195, label %191

191:                                              ; preds = %190
  %192 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not213 = icmp eq i32 %192, 0
  br i1 %.not213, label %193, label %195

193:                                              ; preds = %191
  %194 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.73) #7
  br label %411

195:                                              ; preds = %191, %190
  %196 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @_ZL12gPython2Name) #7
  %197 = call noundef i32 @_ZL17isTerminalRunningv()
  %.not214 = icmp eq i32 %197, 0
  br i1 %.not214, label %198, label %202

198:                                              ; preds = %195
  %199 = call noundef i32 @_ZL8isDarwinv()
  %.not215 = icmp eq i32 %199, 0
  br i1 %.not215, label %202, label %200

200:                                              ; preds = %198
  %201 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.74) #7
  br label %202

202:                                              ; preds = %200, %198, %195
  %203 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.266) #7
  %204 = call noundef i32 @_ZL8isDarwinv()
  %.not216 = icmp eq i32 %204, 0
  br i1 %.not216, label %207, label %205

205:                                              ; preds = %202
  %206 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.76) #7
  br label %207

207:                                              ; preds = %205, %202
  %208 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.307) #7
  %.not217 = icmp eq i32 %5, 0
  br i1 %.not217, label %211, label %209

209:                                              ; preds = %207
  %210 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.308) #7
  br label %211

211:                                              ; preds = %209, %207
  br i1 %.not212, label %217, label %212

212:                                              ; preds = %211
  %char0218 = load i8, ptr %0, align 1
  %.not219 = icmp eq i8 %char0218, 0
  br i1 %.not219, label %217, label %213

213:                                              ; preds = %212
  %214 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.88) #7
  %215 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %0) #7
  %216 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  br label %217

217:                                              ; preds = %213, %212, %211
  %.not220 = icmp eq ptr %1, null
  br i1 %.not220, label %231, label %218

218:                                              ; preds = %217
  %char0221 = load i8, ptr %1, align 1
  %.not222 = icmp eq i8 %char0221, 0
  br i1 %.not222, label %231, label %219

219:                                              ; preds = %218
  %220 = call noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef nonnull %8, ptr noundef nonnull %1)
  %char0223 = load i8, ptr %8, align 16
  %.not224 = icmp eq i8 %char0223, 0
  br i1 %.not224, label %225, label %221

221:                                              ; preds = %219
  %222 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.268) #7
  %223 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %8) #7
  %224 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  br label %225

225:                                              ; preds = %221, %219
  %226 = call noundef ptr @_ZL11getLastNamePcPKc(ptr noundef nonnull %8, ptr noundef nonnull %1)
  %char0225 = load i8, ptr %8, align 16
  %.not226 = icmp eq i8 %char0225, 0
  br i1 %.not226, label %231, label %227

227:                                              ; preds = %225
  %228 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.269) #7
  %229 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %8) #7
  %230 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  br label %231

231:                                              ; preds = %225, %227, %218, %217
  %232 = icmp sgt i32 %2, 1
  br i1 %232, label %241, label %233

233:                                              ; preds = %231
  %234 = icmp eq i32 %2, 1
  br i1 %234, label %235, label %.sink.split

235:                                              ; preds = %233
  %236 = load ptr, ptr %3, align 8, !tbaa !8
  %237 = call i64 @strlen(ptr noundef nonnull dereferenceable(1) %236) #8
  %238 = getelementptr i8, ptr %236, i64 %237
  %239 = getelementptr i8, ptr %238, i64 -1
  %240 = load i8, ptr %239, align 1, !tbaa !5
  %.not227 = icmp eq i8 %240, 42
  br i1 %.not227, label %.sink.split, label %241

241:                                              ; preds = %235, %231
  %242 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.270) #7
  %243 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.271) #7
  %.not228 = icmp eq ptr %4, null
  br i1 %.not228, label %.lr.ph292.preheader, label %244

244:                                              ; preds = %241
  %char0229 = load i8, ptr %4, align 1
  %.not230 = icmp eq i8 %char0229, 0
  br i1 %.not230, label %.lr.ph292.preheader, label %245

245:                                              ; preds = %244
  %246 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %4) #7
  br label %.lr.ph292.preheader

.lr.ph292.preheader:                              ; preds = %241, %244, %245
  %247 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.272) #7
  %wide.trip.count320 = zext nneg i32 %2 to i64
  br label %.lr.ph292

.lr.ph292:                                        ; preds = %.lr.ph292.preheader, %.lr.ph292
  %indvars.iv317 = phi i64 [ 0, %.lr.ph292.preheader ], [ %indvars.iv.next318, %.lr.ph292 ]
  %248 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.92) #7
  %249 = getelementptr inbounds ptr, ptr %3, i64 %indvars.iv317
  %250 = load ptr, ptr %249, align 8, !tbaa !8
  %251 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %250) #7
  %252 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  %indvars.iv.next318 = add nuw nsw i64 %indvars.iv317, 1
  %exitcond321.not = icmp eq i64 %indvars.iv.next318, %wide.trip.count320
  br i1 %exitcond321.not, label %.sink.split.sink.split.sink.split, label %.lr.ph292, !llvm.loop !16

253:                                              ; preds = %188
  %254 = tail call noundef i32 @_ZL15tkinter3Presentv()
  %.not172 = icmp eq i32 %254, 0
  br i1 %.not172, label %308, label %255

255:                                              ; preds = %253
  %.not196 = icmp eq ptr %0, null
  br i1 %.not196, label %260, label %256

256:                                              ; preds = %255
  %257 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not197 = icmp eq i32 %257, 0
  br i1 %.not197, label %258, label %260

258:                                              ; preds = %256
  %259 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.95) #7
  br label %411

260:                                              ; preds = %256, %255
  %261 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @_ZL12gPython3Name) #7
  %262 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.276) #7
  %263 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.310) #7
  %.not198 = icmp eq i32 %5, 0
  br i1 %.not198, label %266, label %264

264:                                              ; preds = %260
  %265 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.308) #7
  br label %266

266:                                              ; preds = %264, %260
  br i1 %.not196, label %272, label %267

267:                                              ; preds = %266
  %char0199 = load i8, ptr %0, align 1
  %.not200 = icmp eq i8 %char0199, 0
  br i1 %.not200, label %272, label %268

268:                                              ; preds = %267
  %269 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.88) #7
  %270 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %0) #7
  %271 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  br label %272

272:                                              ; preds = %268, %267, %266
  %.not201 = icmp eq ptr %1, null
  br i1 %.not201, label %286, label %273

273:                                              ; preds = %272
  %char0202 = load i8, ptr %1, align 1
  %.not203 = icmp eq i8 %char0202, 0
  br i1 %.not203, label %286, label %274

274:                                              ; preds = %273
  %275 = call noundef ptr @_ZL24getPathWithoutFinalSlashPcPKc(ptr noundef nonnull %8, ptr noundef nonnull %1)
  %char0204 = load i8, ptr %8, align 16
  %.not205 = icmp eq i8 %char0204, 0
  br i1 %.not205, label %280, label %276

276:                                              ; preds = %274
  %277 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.268) #7
  %278 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %8) #7
  %279 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  br label %280

280:                                              ; preds = %276, %274
  %281 = call noundef ptr @_ZL11getLastNamePcPKc(ptr noundef nonnull %8, ptr noundef nonnull %1)
  %char0206 = load i8, ptr %8, align 16
  %.not207 = icmp eq i8 %char0206, 0
  br i1 %.not207, label %286, label %282

282:                                              ; preds = %280
  %283 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.269) #7
  %284 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %8) #7
  %285 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  br label %286

286:                                              ; preds = %280, %282, %273, %272
  %287 = icmp sgt i32 %2, 1
  br i1 %287, label %296, label %288

288:                                              ; preds = %286
  %289 = icmp eq i32 %2, 1
  br i1 %289, label %290, label %.sink.split

290:                                              ; preds = %288
  %291 = load ptr, ptr %3, align 8, !tbaa !8
  %292 = call i64 @strlen(ptr noundef nonnull dereferenceable(1) %291) #8
  %293 = getelementptr i8, ptr %291, i64 %292
  %294 = getelementptr i8, ptr %293, i64 -1
  %295 = load i8, ptr %294, align 1, !tbaa !5
  %.not208 = icmp eq i8 %295, 42
  br i1 %.not208, label %.sink.split, label %296

296:                                              ; preds = %290, %286
  %297 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.270) #7
  %298 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.271) #7
  %.not209 = icmp eq ptr %4, null
  br i1 %.not209, label %.lr.ph296.preheader, label %299

299:                                              ; preds = %296
  %char0210 = load i8, ptr %4, align 1
  %.not211 = icmp eq i8 %char0210, 0
  br i1 %.not211, label %.lr.ph296.preheader, label %300

300:                                              ; preds = %299
  %301 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %4) #7
  br label %.lr.ph296.preheader

.lr.ph296.preheader:                              ; preds = %296, %299, %300
  %302 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.272) #7
  %wide.trip.count325 = zext nneg i32 %2 to i64
  br label %.lr.ph296

.lr.ph296:                                        ; preds = %.lr.ph296.preheader, %.lr.ph296
  %indvars.iv322 = phi i64 [ 0, %.lr.ph296.preheader ], [ %indvars.iv.next323, %.lr.ph296 ]
  %303 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.92) #7
  %304 = getelementptr inbounds ptr, ptr %3, i64 %indvars.iv322
  %305 = load ptr, ptr %304, align 8, !tbaa !8
  %306 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %305) #7
  %307 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.87) #7
  %indvars.iv.next323 = add nuw nsw i64 %indvars.iv322, 1
  %exitcond326.not = icmp eq i64 %indvars.iv.next323, %wide.trip.count325
  br i1 %exitcond326.not, label %.sink.split.sink.split.sink.split, label %.lr.ph296, !llvm.loop !17

308:                                              ; preds = %253
  %309 = tail call noundef i32 @_ZL14xdialogPresentv()
  %.not173 = icmp eq i32 %309, 0
  br i1 %.not173, label %310, label %312

310:                                              ; preds = %308
  %311 = tail call noundef ptr @_ZL10dialogNamev()
  %.not174 = icmp eq ptr %311, null
  br i1 %.not174, label %369, label %312

312:                                              ; preds = %310, %308
  %313 = tail call noundef i32 @_ZL14xdialogPresentv()
  %.not178.not = icmp eq i32 %313, 0
  br i1 %.not178.not, label %321, label %314

314:                                              ; preds = %312
  %.not184 = icmp eq ptr %0, null
  br i1 %.not184, label %319, label %315

315:                                              ; preds = %314
  %316 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not185 = icmp eq i32 %316, 0
  br i1 %.not185, label %317, label %319

317:                                              ; preds = %315
  %318 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.120) #7
  br label %411

319:                                              ; preds = %315, %314
  %320 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.121) #7
  br label %342

321:                                              ; preds = %312
  %322 = tail call noundef i32 @_ZL17isTerminalRunningv()
  %.not179 = icmp eq i32 %322, 0
  %.not180 = icmp eq ptr %0, null
  br i1 %.not179, label %330, label %323

323:                                              ; preds = %321
  br i1 %.not180, label %328, label %324

324:                                              ; preds = %323
  %325 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not183 = icmp eq i32 %325, 0
  br i1 %.not183, label %326, label %328

326:                                              ; preds = %324
  %327 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.122) #7
  br label %411

328:                                              ; preds = %324, %323
  %329 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.123) #7
  br label %342

330:                                              ; preds = %321
  br i1 %.not180, label %335, label %331

331:                                              ; preds = %330
  %332 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not181 = icmp eq i32 %332, 0
  br i1 %.not181, label %333, label %335

333:                                              ; preds = %331
  %334 = tail call ptr @strcpy(ptr noundef nonnull dereferenceable(1) @tinyfd_response, ptr noundef nonnull dereferenceable(1) @.str.122) #7
  br label %411

335:                                              ; preds = %331, %330
  %336 = tail call noundef ptr @_ZL12terminalNamev()
  %337 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %336) #7
  %338 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.124) #7
  %339 = call noundef ptr @_ZL10dialogNamev()
  %340 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %339) #7
  %341 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.125) #7
  br label %342

342:                                              ; preds = %328, %335, %319
  %.not195 = phi ptr [ @.str.287, %319 ], [ @.str.287, %328 ], [ @.str.286, %335 ]
  %.not186 = icmp eq ptr %0, null
  br i1 %.not186, label %348, label %343

343:                                              ; preds = %342
  %char0 = load i8, ptr %0, align 1
  %.not187 = icmp eq i8 %char0, 0
  br i1 %.not187, label %348, label %344

344:                                              ; preds = %343
  %345 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.129) #7
  %346 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %0) #7
  %347 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.15) #7
  br label %348

348:                                              ; preds = %344, %343, %342
  %349 = call noundef i32 @_ZL14xdialogPresentv()
  %.not188 = icmp eq i32 %349, 0
  br i1 %.not188, label %350, label %356

350:                                              ; preds = %348
  %351 = call noundef i32 @_ZL14gdialogPresentv()
  %.not189 = icmp eq i32 %351, 0
  br i1 %.not189, label %352, label %356

352:                                              ; preds = %350
  %353 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.130) #7
  %354 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.279) #7
  %355 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.15) #7
  br label %356

356:                                              ; preds = %352, %350, %348
  %357 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.280) #7
  %.not190 = icmp eq ptr %1, null
  br i1 %.not190, label %361, label %358

358:                                              ; preds = %356
  %char0191 = load i8, ptr %1, align 1
  %.not192 = icmp eq i8 %char0191, 0
  br i1 %.not192, label %361, label %359

359:                                              ; preds = %358
  %360 = call noundef ptr @strchr(ptr noundef nonnull dereferenceable(1) %1, i32 noundef 47) #8
  %.not193 = icmp eq ptr %360, null
  br i1 %.not193, label %.sink.split327, label %367

361:                                              ; preds = %358, %356
  %362 = call noundef i32 @_ZL17isTerminalRunningv()
  %363 = or i32 %362, %313
  %or.cond.not = icmp eq i32 %363, 0
  br i1 %or.cond.not, label %364, label %367

364:                                              ; preds = %361
  %365 = call ptr @getenv(ptr noundef nonnull @.str.282) #7
  br label %.sink.split327

.sink.split327:                                   ; preds = %359, %364
  %.str.281.sink = phi ptr [ %365, %364 ], [ @.str.281, %359 ]
  %.str.283.sink.ph = phi ptr [ @.str.283, %364 ], [ %1, %359 ]
  %366 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.281.sink) #7
  br label %367

367:                                              ; preds = %.sink.split327, %361, %359
  %.str.283.sink = phi ptr [ %1, %359 ], [ @.str.281, %361 ], [ %.str.283.sink.ph, %.sink.split327 ]
  %368 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.283.sink) #7
  br i1 %.not178.not, label %.sink.split.sink.split, label %.sink.split

369:                                              ; preds = %310
  %.not175 = icmp eq ptr %0, null
  br i1 %.not175, label %374, label %370

370:                                              ; preds = %369
  %371 = tail call i32 @strcmp(ptr noundef nonnull dereferenceable(1) %0, ptr noundef nonnull dereferenceable(1) @.str.10) #8
  %.not176 = icmp eq i32 %371, 0
  br i1 %.not176, label %372, label %374

372:                                              ; preds = %370
  %373 = tail call ptr @tinyfd_inputBox(ptr noundef nonnull %0, ptr noundef null, ptr noundef null)
  br label %411

374:                                              ; preds = %370, %369
  %375 = tail call ptr @tinyfd_inputBox(ptr noundef %0, ptr noundef nonnull @.str.312, ptr noundef nonnull @.str.177)
  %376 = tail call noundef i32 @_ZL10fileExistsPKc(ptr noundef %375)
  %.not177 = icmp eq i32 %376, 0
  %. = select i1 %.not177, ptr null, ptr %375
  br label %411

.sink.split.sink.split.sink.split:                ; preds = %.lr.ph292, %.lr.ph296, %105
  %.str.49.sink = phi ptr [ @.str.49, %105 ], [ @.str.273, %.lr.ph296 ], [ @.str.273, %.lr.ph292 ]
  %.str.285.sink.ph = phi ptr [ %0, %105 ], [ @.str.274, %.lr.ph296 ], [ @.str.274, %.lr.ph292 ]
  %.str.47.sink.ph.ph = phi ptr [ @.str.47, %105 ], [ @.str.311, %.lr.ph296 ], [ @.str.309, %.lr.ph292 ]
  %377 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.49.sink) #7
  br label %.sink.split.sink.split

.sink.split.sink.split:                           ; preds = %.sink.split.sink.split.sink.split, %367
  %.str.285.sink = phi ptr [ @.str.285, %367 ], [ %.str.285.sink.ph, %.sink.split.sink.split.sink.split ]
  %.str.47.sink.ph = phi ptr [ %.not195, %367 ], [ %.str.47.sink.ph.ph, %.sink.split.sink.split.sink.split ]
  %.ph.ph = phi i1 [ false, %367 ], [ %.not166, %.sink.split.sink.split.sink.split ]
  %378 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.285.sink) #7
  br label %.sink.split

.sink.split:                                      ; preds = %.sink.split.sink.split, %367, %288, %290, %233, %235, %186, %58
  %.str.47.sink = phi ptr [ @.str.40, %58 ], [ @.str.70, %186 ], [ @.str.309, %235 ], [ @.str.309, %233 ], [ @.str.311, %290 ], [ @.str.311, %288 ], [ @.str.284, %367 ], [ %.str.47.sink.ph, %.sink.split.sink.split ]
  %.ph = phi i1 [ false, %58 ], [ false, %186 ], [ false, %235 ], [ false, %233 ], [ false, %290 ], [ false, %288 ], [ false, %367 ], [ %.ph.ph, %.sink.split.sink.split ]
  %379 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) %.str.47.sink) #7
  br label %380

380:                                              ; preds = %.sink.split, %105, %104, %186, %58
  %381 = phi i1 [ false, %58 ], [ true, %105 ], [ true, %104 ], [ false, %186 ], [ %.ph, %.sink.split ]
  %382 = load i32, ptr @tinyfd_verbose, align 4, !tbaa !14
  %.not276 = icmp eq i32 %382, 0
  br i1 %.not276, label %385, label %383

383:                                              ; preds = %380
  %384 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.8, ptr noundef nonnull %7)
  br label %385

385:                                              ; preds = %383, %380
  %386 = call noalias ptr @popen(ptr noundef nonnull %7, ptr noundef nonnull @.str.9)
  %.not277 = icmp eq ptr %386, null
  br i1 %.not277, label %411, label %387

387:                                              ; preds = %385
  store i8 0, ptr @_ZZ21tinyfd_openFileDialogE5lBuff, align 16, !tbaa !5
  %388 = call ptr @fgets(ptr noundef nonnull @_ZZ21tinyfd_openFileDialogE5lBuff, i32 noundef 32768, ptr noundef nonnull %386)
  %.not278298 = icmp eq ptr %388, null
  br i1 %.not278298, label %._crit_edge302, label %.lr.ph301

.lr.ph301:                                        ; preds = %387, %.lr.ph301
  %.0141299 = phi ptr [ %390, %.lr.ph301 ], [ @_ZZ21tinyfd_openFileDialogE5lBuff, %387 ]
  %389 = call i64 @strlen(ptr noundef nonnull dereferenceable(1) %.0141299) #8
  %390 = getelementptr inbounds i8, ptr %.0141299, i64 %389
  %391 = call ptr @fgets(ptr noundef %390, i32 noundef 32768, ptr noundef nonnull %386)
  %.not278 = icmp eq ptr %391, null
  br i1 %.not278, label %._crit_edge302, label %.lr.ph301, !llvm.loop !18

._crit_edge302:                                   ; preds = %.lr.ph301, %387
  %392 = call i32 @pclose(ptr noundef nonnull %386)
  %393 = call i64 @strlen(ptr noundef nonnull dereferenceable(1) @_ZZ21tinyfd_openFileDialogE5lBuff) #8
  %394 = add i64 %393, -1
  %395 = getelementptr inbounds [32768 x i8], ptr @_ZZ21tinyfd_openFileDialogE5lBuff, i64 0, i64 %394
  %396 = load i8, ptr %395, align 1, !tbaa !5
  %397 = icmp eq i8 %396, 10
  br i1 %397, label %398, label %399

398:                                              ; preds = %._crit_edge302
  store i8 0, ptr %395, align 1, !tbaa !5
  br label %399

399:                                              ; preds = %398, %._crit_edge302
  %400 = icmp ne i32 %5, 0
  %or.cond3 = and i1 %400, %381
  br i1 %or.cond3, label %.preheader, label %.loopexit

.preheader:                                       ; preds = %399
  %401 = call noundef ptr @strchr(ptr noundef nonnull dereferenceable(1) @_ZZ21tinyfd_openFileDialogE5lBuff, i32 noundef 10) #8
  %.not279303 = icmp eq ptr %401, null
  br i1 %.not279303, label %.loopexit, label %.lr.ph304

.lr.ph304:                                        ; preds = %.preheader, %.lr.ph304
  %402 = phi ptr [ %403, %.lr.ph304 ], [ %401, %.preheader ]
  store i8 124, ptr %402, align 1, !tbaa !5
  %403 = call noundef ptr @strchr(ptr noundef nonnull dereferenceable(1) %402, i32 noundef 10) #8
  %.not279 = icmp eq ptr %403, null
  br i1 %.not279, label %.loopexit, label %.lr.ph304, !llvm.loop !19

.loopexit:                                        ; preds = %.lr.ph304, %.preheader, %399
  %char0280 = load i8, ptr @_ZZ21tinyfd_openFileDialogE5lBuff, align 16
  %.not281 = icmp eq i8 %char0280, 0
  br i1 %.not281, label %411, label %404

404:                                              ; preds = %.loopexit
  br i1 %400, label %405, label %409

405:                                              ; preds = %404
  %406 = call noundef ptr @strchr(ptr noundef nonnull dereferenceable(1) @_ZZ21tinyfd_openFileDialogE5lBuff, i32 noundef 124) #8
  %.not282 = icmp eq ptr %406, null
  br i1 %.not282, label %409, label %407

407:                                              ; preds = %405
  %408 = call noundef ptr @_ZL16ensureFilesExistPcPKc(ptr noundef nonnull @_ZZ21tinyfd_openFileDialogE5lBuff, ptr noundef nonnull @_ZZ21tinyfd_openFileDialogE5lBuff)
  br label %411

409:                                              ; preds = %405, %404
  %410 = call noundef i32 @_ZL10fileExistsPKc(ptr noundef nonnull @_ZZ21tinyfd_openFileDialogE5lBuff)
  %.not283 = icmp eq i32 %410, 0
  %spec.select = select i1 %.not283, ptr null, ptr @_ZZ21tinyfd_openFileDialogE5lBuff
  br label %411

411:                                              ; preds = %409, %407, %.loopexit, %385, %374, %372, %333, %326, %317, %258, %193, %150, %143, %134, %119, %68, %13
  %.0142 = phi ptr [ inttoptr (i64 1 to ptr), %13 ], [ inttoptr (i64 1 to ptr), %68 ], [ inttoptr (i64 1 to ptr), %119 ], [ inttoptr (i64 1 to ptr), %134 ], [ inttoptr (i64 1 to ptr), %143 ], [ inttoptr (i64 1 to ptr), %150 ], [ inttoptr (i64 1 to ptr), %193 ], [ inttoptr (i64 1 to ptr), %258 ], [ inttoptr (i64 1 to ptr), %317 ], [ null, %326 ], [ null, %333 ], [ %373, %372 ], [ %., %374 ], [ null, %385 ], [ null, %.loopexit ], [ %408, %407 ], [ %spec.select, %409 ]
  call void @llvm.lifetime.end.p0(i64 1024, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 1024, ptr nonnull %7) #7
  ret ptr %.0142
}

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL16ensureFilesExistPcPKc(ptr noundef, ptr noundef) local_unnamed_addr #3

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nofree nounwind willreturn memory(argmem: read) "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 #2 = { mustprogress nofree nounwind willreturn memory(argmem: readwrite) "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 = { mustprogress 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 #4 = { nofree nounwind "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 #5 = { nofree nounwind memory(read) "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 #6 = { mustprogress 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 #7 = { nounwind }
attributes #8 = { nounwind willreturn memory(read) }

!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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"any pointer", !6, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}
!13 = distinct !{!13, !11}
!14 = !{!15, !15, i64 0}
!15 = !{!"int", !6, i64 0}
!16 = distinct !{!16, !11}
!17 = distinct !{!17, !11}
!18 = distinct !{!18, !11}
!19 = distinct !{!19, !11}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SROAPass,SimplifyCFGPass,TailCallElimPass