; LLVM IR from mkazhdan/DMG :: Util/PNG (pngtest)

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

%struct.png_struct_def = type { [1 x %struct.__jmp_buf_tag], ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i8, i8, i64, i64, i64, %struct.z_stream_s, ptr, i64, i32, i32, i32, i32, i32, i64, i64, i64, i64, i64, i64, i64, i64, ptr, ptr, ptr, ptr, ptr, ptr, %struct.png_row_info_struct, i64, i64, ptr, i16, i16, [5 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i16, i8, float, %struct.png_color_16_struct, %struct.png_color_16_struct, ptr, i64, i64, i32, float, float, ptr, ptr, ptr, ptr, ptr, ptr, %struct.png_color_8_struct, %struct.png_color_8_struct, ptr, %struct.png_color_16_struct, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i64, i64, i64, i64, i64, i64, i32, i32, i64, i64, ptr, ptr, ptr, ptr, ptr, i8, i8, ptr, ptr, ptr, ptr, ptr, ptr, i64, ptr, ptr, i32, ptr, i8, i16, i16, i16, i64, i64, i8, i8, i64, i64, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i8, i64, i64, %struct.png_unknown_chunk_t, i64, i64 }
%struct.__jmp_buf_tag = type { [8 x i64], i32, %struct.__sigset_t }
%struct.__sigset_t = type { [16 x i64] }
%struct.z_stream_s = type { ptr, i32, i64, ptr, i32, i64, ptr, ptr, ptr, ptr, ptr, i32, i64, i64 }
%struct.png_row_info_struct = type { i64, i64, i8, i8, i8, i8 }
%struct.png_color_8_struct = type { i8, i8, i8, i8, i8 }
%struct.png_color_16_struct = type { i8, i16, i16, i16, i16 }
%struct.png_unknown_chunk_t = type { [5 x i8], ptr, i64, i8 }
%struct.png_info_struct = type { i64, i64, i64, i64, ptr, i16, i16, i8, i8, i8, i8, i8, i8, i8, i8, [8 x i8], float, i8, i32, i32, ptr, %struct.png_time_struct, %struct.png_color_8_struct, ptr, %struct.png_color_16_struct, %struct.png_color_16_struct, i64, i64, i8, i64, i64, i8, ptr, float, float, float, float, float, float, float, float, ptr, i64, i64, ptr, ptr, i8, i8, i64, ptr, i64, ptr, ptr, i64, i8, ptr, i64, i8, double, double, ptr, ptr, ptr, i64, i64, i64, i64, i64, i64, i64, i64, i64 }
%struct.png_time_struct = type { i16, i8, i8, i8, i8, i8 }

@stdout = external global ptr, align 8
@filters_used = external hidden global [256 x i64], align 16
@zero_samples = external hidden global i64, align 8
@test_one_file.fpin = external hidden global ptr, align 8
@test_one_file.fpout = external hidden global ptr, align 8
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [30 x i8], align 1
@status_dots_requested = external hidden global i32, align 4
@tIME_string = external hidden global [30 x i8], align 16
@tIME_chunk_present = external hidden global i32, align 4
@verbose = external hidden global i32, align 4
@.str.11 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [42 x i8], align 1
@wrote_question = external hidden global i32, align 4
@.str.14 = external hidden unnamed_addr constant [68 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [54 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [32 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local void @read_row_callback(ptr noundef, i64 noundef, i32 noundef) #0

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #1

; Function Attrs: nounwind uwtable
declare dso_local void @write_row_callback(ptr noundef, i64 noundef, i32 noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @count_filters(ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @count_zero_samples(ptr noundef, ptr noundef, ptr noundef) #0

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

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

; Function Attrs: nounwind uwtable
define dso_local i32 @test_one_file(ptr noundef %0, ptr noundef %1) #0 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca [256 x i8], align 16
  %21 = alloca [256 x i8], align 16
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i64, align 8
  %28 = alloca i64, align 8
  %29 = alloca i64, align 8
  %30 = alloca i64, align 8
  %31 = alloca i64, align 8
  %32 = alloca i64, align 8
  %33 = alloca i64, align 8
  %34 = alloca i64, align 8
  %35 = alloca i64, align 8
  %36 = alloca ptr, align 8
  %37 = alloca ptr, align 8
  %38 = alloca i64, align 8
  %39 = alloca i32, align 4
  %40 = alloca i32, align 4
  %41 = alloca ptr, align 8
  %42 = alloca i32, align 4
  %43 = alloca ptr, align 8
  %44 = alloca ptr, align 8
  %45 = alloca i64, align 8
  %46 = alloca i64, align 8
  %47 = alloca i32, align 4
  %48 = alloca ptr, align 8
  %49 = alloca ptr, align 8
  %50 = alloca ptr, align 8
  %51 = alloca i64, align 8
  %52 = alloca i64, align 8
  %53 = alloca i32, align 4
  %54 = alloca i32, align 4
  %55 = alloca i64, align 8
  %56 = alloca i64, align 8
  %57 = alloca i32, align 4
  %58 = alloca ptr, align 8
  %59 = alloca i32, align 4
  %60 = alloca double, align 8
  %61 = alloca double, align 8
  %62 = alloca ptr, align 8
  %63 = alloca i32, align 4
  %64 = alloca ptr, align 8
  %65 = alloca ptr, align 8
  %66 = alloca i32, align 4
  %67 = alloca ptr, align 8
  %68 = alloca i32, align 4
  %69 = alloca ptr, align 8
  %70 = alloca i32, align 4
  %71 = alloca i64, align 8
  %72 = alloca ptr, align 8
  %73 = alloca i32, align 4
  %74 = alloca ptr, align 8
  %75 = alloca ptr, align 8
  %76 = alloca i32, align 4
  %77 = alloca i64, align 8
  %78 = alloca i64, align 8
  %79 = alloca i64, align 8
  %80 = alloca i64, align 8
  %81 = alloca i64, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #7
  call void @llvm.lifetime.start.p0(i64 256, ptr %20) #7
  call void @llvm.lifetime.start.p0(i64 256, ptr %21) #7
  store ptr null, ptr %12, align 8, !tbaa !5
  %82 = load ptr, ptr %4, align 8, !tbaa !5
  %83 = call noalias ptr @fopen(ptr noundef %82, ptr noundef @.str.4)
  store ptr %83, ptr @test_one_file.fpin, align 8, !tbaa !5
  %84 = icmp eq ptr %83, null
  br i1 %84, label %85, label %89

85:                                               ; preds = %2
  %86 = load ptr, ptr @stdout, align 8, !tbaa !5
  %87 = load ptr, ptr %4, align 8, !tbaa !5
  %88 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %86, ptr noundef @.str.5, ptr noundef %87) #7
  store i32 1, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

89:                                               ; preds = %2
  %90 = load ptr, ptr %5, align 8, !tbaa !5
  %91 = call noalias ptr @fopen(ptr noundef %90, ptr noundef @.str.6)
  store ptr %91, ptr @test_one_file.fpout, align 8, !tbaa !5
  %92 = icmp eq ptr %91, null
  br i1 %92, label %93, label %99

93:                                               ; preds = %89
  %94 = load ptr, ptr @stdout, align 8, !tbaa !5
  %95 = load ptr, ptr %5, align 8, !tbaa !5
  %96 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %94, ptr noundef @.str.7, ptr noundef %95) #7
  %97 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %98 = call i32 @fclose(ptr noundef %97)
  store i32 1, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

99:                                               ; preds = %89
  %100 = call ptr @png_create_read_struct(ptr noundef @.str.8, ptr noundef null, ptr noundef null, ptr noundef null)
  store ptr %100, ptr %6, align 8, !tbaa !5
  %101 = load ptr, ptr %6, align 8, !tbaa !5
  %102 = load ptr, ptr %4, align 8, !tbaa !5
  call void @png_set_error_fn(ptr noundef %101, ptr noundef %102, ptr noundef @pngtest_error, ptr noundef @pngtest_warning)
  %103 = call ptr @png_create_write_struct(ptr noundef @.str.8, ptr noundef null, ptr noundef null, ptr noundef null)
  store ptr %103, ptr %9, align 8, !tbaa !5
  %104 = load ptr, ptr %9, align 8, !tbaa !5
  %105 = load ptr, ptr %4, align 8, !tbaa !5
  call void @png_set_error_fn(ptr noundef %104, ptr noundef %105, ptr noundef @pngtest_error, ptr noundef @pngtest_warning)
  %106 = load ptr, ptr %6, align 8, !tbaa !5
  %107 = call ptr @png_create_info_struct(ptr noundef %106)
  store ptr %107, ptr %7, align 8, !tbaa !5
  %108 = load ptr, ptr %6, align 8, !tbaa !5
  %109 = call ptr @png_create_info_struct(ptr noundef %108)
  store ptr %109, ptr %8, align 8, !tbaa !5
  %110 = load ptr, ptr %9, align 8, !tbaa !5
  %111 = call ptr @png_create_info_struct(ptr noundef %110)
  store ptr %111, ptr %10, align 8, !tbaa !5
  %112 = load ptr, ptr %9, align 8, !tbaa !5
  %113 = call ptr @png_create_info_struct(ptr noundef %112)
  store ptr %113, ptr %11, align 8, !tbaa !5
  %114 = load ptr, ptr %6, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.png_struct_def, ptr %114, i32 0, i32 0
  %116 = getelementptr inbounds [1 x %struct.__jmp_buf_tag], ptr %115, i64 0, i64 0
  %117 = call i32 @_setjmp(ptr noundef %116) #8
  %118 = icmp ne i32 %117, 0
  br i1 %118, label %119, label %131

119:                                              ; preds = %99
  %120 = load ptr, ptr @stdout, align 8, !tbaa !5
  %121 = load ptr, ptr %4, align 8, !tbaa !5
  %122 = load ptr, ptr %5, align 8, !tbaa !5
  %123 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %120, ptr noundef @.str.9, ptr noundef %121, ptr noundef %122) #7
  %124 = load ptr, ptr %6, align 8, !tbaa !5
  %125 = load ptr, ptr %12, align 8, !tbaa !5
  call void @png_free(ptr noundef %124, ptr noundef %125)
  call void @png_destroy_read_struct(ptr noundef %6, ptr noundef %7, ptr noundef %8)
  %126 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_destroy_info_struct(ptr noundef %126, ptr noundef %11)
  call void @png_destroy_write_struct(ptr noundef %9, ptr noundef %10)
  %127 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %128 = call i32 @fclose(ptr noundef %127)
  %129 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %130 = call i32 @fclose(ptr noundef %129)
  store i32 1, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

131:                                              ; preds = %99
  %132 = load ptr, ptr %9, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.png_struct_def, ptr %132, i32 0, i32 0
  %134 = getelementptr inbounds [1 x %struct.__jmp_buf_tag], ptr %133, i64 0, i64 0
  %135 = call i32 @_setjmp(ptr noundef %134) #8
  %136 = icmp ne i32 %135, 0
  br i1 %136, label %137, label %147

137:                                              ; preds = %131
  %138 = load ptr, ptr @stdout, align 8, !tbaa !5
  %139 = load ptr, ptr %4, align 8, !tbaa !5
  %140 = load ptr, ptr %5, align 8, !tbaa !5
  %141 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %138, ptr noundef @.str.10, ptr noundef %139, ptr noundef %140) #7
  call void @png_destroy_read_struct(ptr noundef %6, ptr noundef %7, ptr noundef %8)
  %142 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_destroy_info_struct(ptr noundef %142, ptr noundef %11)
  call void @png_destroy_write_struct(ptr noundef %9, ptr noundef %10)
  %143 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %144 = call i32 @fclose(ptr noundef %143)
  %145 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %146 = call i32 @fclose(ptr noundef %145)
  store i32 1, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

147:                                              ; preds = %131
  %148 = load ptr, ptr %6, align 8, !tbaa !5
  %149 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  call void @png_init_io(ptr noundef %148, ptr noundef %149)
  %150 = load ptr, ptr %9, align 8, !tbaa !5
  %151 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  call void @png_init_io(ptr noundef %150, ptr noundef %151)
  %152 = load i32, ptr @status_dots_requested, align 4, !tbaa !9
  %153 = icmp eq i32 %152, 1
  br i1 %153, label %154, label %157

154:                                              ; preds = %147
  %155 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_set_write_status_fn(ptr noundef %155, ptr noundef @write_row_callback)
  %156 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_set_read_status_fn(ptr noundef %156, ptr noundef @read_row_callback)
  br label %160

157:                                              ; preds = %147
  %158 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_set_write_status_fn(ptr noundef %158, ptr noundef null)
  %159 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_set_read_status_fn(ptr noundef %159, ptr noundef null)
  br label %160

160:                                              ; preds = %157, %154
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #7
  store i32 0, ptr %23, align 4, !tbaa !9
  br label %161

161:                                              ; preds = %168, %160
  %162 = load i32, ptr %23, align 4, !tbaa !9
  %163 = icmp slt i32 %162, 256
  br i1 %163, label %164, label %171

164:                                              ; preds = %161
  %165 = load i32, ptr %23, align 4, !tbaa !9
  %166 = sext i32 %165 to i64
  %167 = getelementptr inbounds [256 x i64], ptr @filters_used, i64 0, i64 %166
  store i64 0, ptr %167, align 8, !tbaa !11
  br label %168

168:                                              ; preds = %164
  %169 = load i32, ptr %23, align 4, !tbaa !9
  %170 = add nsw i32 %169, 1
  store i32 %170, ptr %23, align 4, !tbaa !9
  br label %161, !llvm.loop !13

171:                                              ; preds = %161
  %172 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_set_read_user_transform_fn(ptr noundef %172, ptr noundef @count_filters)
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #7
  store i64 0, ptr @zero_samples, align 8, !tbaa !11
  %173 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_set_write_user_transform_fn(ptr noundef %173, ptr noundef @count_zero_samples)
  %174 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_set_keep_unknown_chunks(ptr noundef %174, i32 noundef 3, ptr noundef null, i32 noundef 0)
  %175 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_set_keep_unknown_chunks(ptr noundef %175, i32 noundef 2, ptr noundef null, i32 noundef 0)
  %176 = load ptr, ptr %6, align 8, !tbaa !5
  %177 = load ptr, ptr %7, align 8, !tbaa !5
  call void @png_read_info(ptr noundef %176, ptr noundef %177)
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #7
  %178 = load ptr, ptr %6, align 8, !tbaa !5
  %179 = load ptr, ptr %7, align 8, !tbaa !5
  %180 = call i64 @png_get_IHDR(ptr noundef %178, ptr noundef %179, ptr noundef %14, ptr noundef %15, ptr noundef %18, ptr noundef %19, ptr noundef %24, ptr noundef %25, ptr noundef %26)
  %181 = icmp ne i64 %180, 0
  br i1 %181, label %182, label %192

182:                                              ; preds = %171
  %183 = load ptr, ptr %9, align 8, !tbaa !5
  %184 = load ptr, ptr %10, align 8, !tbaa !5
  %185 = load i64, ptr %14, align 8, !tbaa !11
  %186 = load i64, ptr %15, align 8, !tbaa !11
  %187 = load i32, ptr %18, align 4, !tbaa !9
  %188 = load i32, ptr %19, align 4, !tbaa !9
  %189 = load i32, ptr %24, align 4, !tbaa !9
  %190 = load i32, ptr %25, align 4, !tbaa !9
  %191 = load i32, ptr %26, align 4, !tbaa !9
  call void @png_set_IHDR(ptr noundef %183, ptr noundef %184, i64 noundef %185, i64 noundef %186, i32 noundef %187, i32 noundef %188, i32 noundef %189, i32 noundef %190, i32 noundef %191)
  br label %192

192:                                              ; preds = %182, %171
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #7
  %193 = load ptr, ptr %6, align 8, !tbaa !5
  %194 = load ptr, ptr %7, align 8, !tbaa !5
  %195 = call i64 @png_get_cHRM_fixed(ptr noundef %193, ptr noundef %194, ptr noundef %27, ptr noundef %28, ptr noundef %29, ptr noundef %30, ptr noundef %31, ptr noundef %32, ptr noundef %33, ptr noundef %34)
  %196 = icmp ne i64 %195, 0
  br i1 %196, label %197, label %208

197:                                              ; preds = %192
  %198 = load ptr, ptr %9, align 8, !tbaa !5
  %199 = load ptr, ptr %10, align 8, !tbaa !5
  %200 = load i64, ptr %27, align 8, !tbaa !11
  %201 = load i64, ptr %28, align 8, !tbaa !11
  %202 = load i64, ptr %29, align 8, !tbaa !11
  %203 = load i64, ptr %30, align 8, !tbaa !11
  %204 = load i64, ptr %31, align 8, !tbaa !11
  %205 = load i64, ptr %32, align 8, !tbaa !11
  %206 = load i64, ptr %33, align 8, !tbaa !11
  %207 = load i64, ptr %34, align 8, !tbaa !11
  call void @png_set_cHRM_fixed(ptr noundef %198, ptr noundef %199, i64 noundef %200, i64 noundef %201, i64 noundef %202, i64 noundef %203, i64 noundef %204, i64 noundef %205, i64 noundef %206, i64 noundef %207)
  br label %208

208:                                              ; preds = %197, %192
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #7
  %209 = load ptr, ptr %6, align 8, !tbaa !5
  %210 = load ptr, ptr %7, align 8, !tbaa !5
  %211 = call i64 @png_get_gAMA_fixed(ptr noundef %209, ptr noundef %210, ptr noundef %35)
  %212 = icmp ne i64 %211, 0
  br i1 %212, label %213, label %217

213:                                              ; preds = %208
  %214 = load ptr, ptr %9, align 8, !tbaa !5
  %215 = load ptr, ptr %10, align 8, !tbaa !5
  %216 = load i64, ptr %35, align 8, !tbaa !11
  call void @png_set_gAMA_fixed(ptr noundef %214, ptr noundef %215, i64 noundef %216)
  br label %217

217:                                              ; preds = %213, %208
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %36) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %39) #7
  %218 = load ptr, ptr %6, align 8, !tbaa !5
  %219 = load ptr, ptr %7, align 8, !tbaa !5
  %220 = call i64 @png_get_iCCP(ptr noundef %218, ptr noundef %219, ptr noundef %36, ptr noundef %39, ptr noundef %37, ptr noundef %38)
  %221 = icmp ne i64 %220, 0
  br i1 %221, label %222, label %229

222:                                              ; preds = %217
  %223 = load ptr, ptr %9, align 8, !tbaa !5
  %224 = load ptr, ptr %10, align 8, !tbaa !5
  %225 = load ptr, ptr %36, align 8, !tbaa !5
  %226 = load i32, ptr %39, align 4, !tbaa !9
  %227 = load ptr, ptr %37, align 8, !tbaa !5
  %228 = load i64, ptr %38, align 8, !tbaa !11
  call void @png_set_iCCP(ptr noundef %223, ptr noundef %224, ptr noundef %225, i32 noundef %226, ptr noundef %227, i64 noundef %228)
  br label %229

229:                                              ; preds = %222, %217
  call void @llvm.lifetime.end.p0(i64 4, ptr %39) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %40) #7
  %230 = load ptr, ptr %6, align 8, !tbaa !5
  %231 = load ptr, ptr %7, align 8, !tbaa !5
  %232 = call i64 @png_get_sRGB(ptr noundef %230, ptr noundef %231, ptr noundef %40)
  %233 = icmp ne i64 %232, 0
  br i1 %233, label %234, label %238

234:                                              ; preds = %229
  %235 = load ptr, ptr %9, align 8, !tbaa !5
  %236 = load ptr, ptr %10, align 8, !tbaa !5
  %237 = load i32, ptr %40, align 4, !tbaa !9
  call void @png_set_sRGB(ptr noundef %235, ptr noundef %236, i32 noundef %237)
  br label %238

238:                                              ; preds = %234, %229
  call void @llvm.lifetime.end.p0(i64 4, ptr %40) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %42) #7
  %239 = load ptr, ptr %6, align 8, !tbaa !5
  %240 = load ptr, ptr %7, align 8, !tbaa !5
  %241 = call i64 @png_get_PLTE(ptr noundef %239, ptr noundef %240, ptr noundef %41, ptr noundef %42)
  %242 = icmp ne i64 %241, 0
  br i1 %242, label %243, label %248

243:                                              ; preds = %238
  %244 = load ptr, ptr %9, align 8, !tbaa !5
  %245 = load ptr, ptr %10, align 8, !tbaa !5
  %246 = load ptr, ptr %41, align 8, !tbaa !5
  %247 = load i32, ptr %42, align 4, !tbaa !9
  call void @png_set_PLTE(ptr noundef %244, ptr noundef %245, ptr noundef %246, i32 noundef %247)
  br label %248

248:                                              ; preds = %243, %238
  call void @llvm.lifetime.end.p0(i64 4, ptr %42) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %43) #7
  %249 = load ptr, ptr %6, align 8, !tbaa !5
  %250 = load ptr, ptr %7, align 8, !tbaa !5
  %251 = call i64 @png_get_bKGD(ptr noundef %249, ptr noundef %250, ptr noundef %43)
  %252 = icmp ne i64 %251, 0
  br i1 %252, label %253, label %257

253:                                              ; preds = %248
  %254 = load ptr, ptr %9, align 8, !tbaa !5
  %255 = load ptr, ptr %10, align 8, !tbaa !5
  %256 = load ptr, ptr %43, align 8, !tbaa !5
  call void @png_set_bKGD(ptr noundef %254, ptr noundef %255, ptr noundef %256)
  br label %257

257:                                              ; preds = %253, %248
  call void @llvm.lifetime.end.p0(i64 8, ptr %43) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %44) #7
  %258 = load ptr, ptr %6, align 8, !tbaa !5
  %259 = load ptr, ptr %7, align 8, !tbaa !5
  %260 = call i64 @png_get_hIST(ptr noundef %258, ptr noundef %259, ptr noundef %44)
  %261 = icmp ne i64 %260, 0
  br i1 %261, label %262, label %266

262:                                              ; preds = %257
  %263 = load ptr, ptr %9, align 8, !tbaa !5
  %264 = load ptr, ptr %10, align 8, !tbaa !5
  %265 = load ptr, ptr %44, align 8, !tbaa !5
  call void @png_set_hIST(ptr noundef %263, ptr noundef %264, ptr noundef %265)
  br label %266

266:                                              ; preds = %262, %257
  call void @llvm.lifetime.end.p0(i64 8, ptr %44) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %45) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %46) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %47) #7
  %267 = load ptr, ptr %6, align 8, !tbaa !5
  %268 = load ptr, ptr %7, align 8, !tbaa !5
  %269 = call i64 @png_get_oFFs(ptr noundef %267, ptr noundef %268, ptr noundef %45, ptr noundef %46, ptr noundef %47)
  %270 = icmp ne i64 %269, 0
  br i1 %270, label %271, label %277

271:                                              ; preds = %266
  %272 = load ptr, ptr %9, align 8, !tbaa !5
  %273 = load ptr, ptr %10, align 8, !tbaa !5
  %274 = load i64, ptr %45, align 8, !tbaa !11
  %275 = load i64, ptr %46, align 8, !tbaa !11
  %276 = load i32, ptr %47, align 4, !tbaa !9
  call void @png_set_oFFs(ptr noundef %272, ptr noundef %273, i64 noundef %274, i64 noundef %275, i32 noundef %276)
  br label %277

277:                                              ; preds = %271, %266
  call void @llvm.lifetime.end.p0(i64 4, ptr %47) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %46) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %45) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %48) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %49) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %50) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %51) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %52) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %53) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %54) #7
  %278 = load ptr, ptr %6, align 8, !tbaa !5
  %279 = load ptr, ptr %7, align 8, !tbaa !5
  %280 = call i64 @png_get_pCAL(ptr noundef %278, ptr noundef %279, ptr noundef %48, ptr noundef %51, ptr noundef %52, ptr noundef %53, ptr noundef %54, ptr noundef %49, ptr noundef %50)
  %281 = icmp ne i64 %280, 0
  br i1 %281, label %282, label %292

282:                                              ; preds = %277
  %283 = load ptr, ptr %9, align 8, !tbaa !5
  %284 = load ptr, ptr %10, align 8, !tbaa !5
  %285 = load ptr, ptr %48, align 8, !tbaa !5
  %286 = load i64, ptr %51, align 8, !tbaa !11
  %287 = load i64, ptr %52, align 8, !tbaa !11
  %288 = load i32, ptr %53, align 4, !tbaa !9
  %289 = load i32, ptr %54, align 4, !tbaa !9
  %290 = load ptr, ptr %49, align 8, !tbaa !5
  %291 = load ptr, ptr %50, align 8, !tbaa !5
  call void @png_set_pCAL(ptr noundef %283, ptr noundef %284, ptr noundef %285, i64 noundef %286, i64 noundef %287, i32 noundef %288, i32 noundef %289, ptr noundef %290, ptr noundef %291)
  br label %292

292:                                              ; preds = %282, %277
  call void @llvm.lifetime.end.p0(i64 4, ptr %54) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %53) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %52) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %51) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %50) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %49) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %48) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %55) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %56) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %57) #7
  %293 = load ptr, ptr %6, align 8, !tbaa !5
  %294 = load ptr, ptr %7, align 8, !tbaa !5
  %295 = call i64 @png_get_pHYs(ptr noundef %293, ptr noundef %294, ptr noundef %55, ptr noundef %56, ptr noundef %57)
  %296 = icmp ne i64 %295, 0
  br i1 %296, label %297, label %303

297:                                              ; preds = %292
  %298 = load ptr, ptr %9, align 8, !tbaa !5
  %299 = load ptr, ptr %10, align 8, !tbaa !5
  %300 = load i64, ptr %55, align 8, !tbaa !11
  %301 = load i64, ptr %56, align 8, !tbaa !11
  %302 = load i32, ptr %57, align 4, !tbaa !9
  call void @png_set_pHYs(ptr noundef %298, ptr noundef %299, i64 noundef %300, i64 noundef %301, i32 noundef %302)
  br label %303

303:                                              ; preds = %297, %292
  call void @llvm.lifetime.end.p0(i64 4, ptr %57) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %56) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %55) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %58) #7
  %304 = load ptr, ptr %6, align 8, !tbaa !5
  %305 = load ptr, ptr %7, align 8, !tbaa !5
  %306 = call i64 @png_get_sBIT(ptr noundef %304, ptr noundef %305, ptr noundef %58)
  %307 = icmp ne i64 %306, 0
  br i1 %307, label %308, label %312

308:                                              ; preds = %303
  %309 = load ptr, ptr %9, align 8, !tbaa !5
  %310 = load ptr, ptr %10, align 8, !tbaa !5
  %311 = load ptr, ptr %58, align 8, !tbaa !5
  call void @png_set_sBIT(ptr noundef %309, ptr noundef %310, ptr noundef %311)
  br label %312

312:                                              ; preds = %308, %303
  call void @llvm.lifetime.end.p0(i64 8, ptr %58) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %59) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %60) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %61) #7
  %313 = load ptr, ptr %6, align 8, !tbaa !5
  %314 = load ptr, ptr %7, align 8, !tbaa !5
  %315 = call i64 @png_get_sCAL(ptr noundef %313, ptr noundef %314, ptr noundef %59, ptr noundef %60, ptr noundef %61)
  %316 = icmp ne i64 %315, 0
  br i1 %316, label %317, label %323

317:                                              ; preds = %312
  %318 = load ptr, ptr %9, align 8, !tbaa !5
  %319 = load ptr, ptr %10, align 8, !tbaa !5
  %320 = load i32, ptr %59, align 4, !tbaa !9
  %321 = load double, ptr %60, align 8, !tbaa !15
  %322 = load double, ptr %61, align 8, !tbaa !15
  call void @png_set_sCAL(ptr noundef %318, ptr noundef %319, i32 noundef %320, double noundef %321, double noundef %322)
  br label %323

323:                                              ; preds = %317, %312
  call void @llvm.lifetime.end.p0(i64 8, ptr %61) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %60) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %59) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %62) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %63) #7
  %324 = load ptr, ptr %6, align 8, !tbaa !5
  %325 = load ptr, ptr %7, align 8, !tbaa !5
  %326 = call i64 @png_get_text(ptr noundef %324, ptr noundef %325, ptr noundef %62, ptr noundef %63)
  %327 = icmp ugt i64 %326, 0
  br i1 %327, label %328, label %333

328:                                              ; preds = %323
  %329 = load ptr, ptr %9, align 8, !tbaa !5
  %330 = load ptr, ptr %10, align 8, !tbaa !5
  %331 = load ptr, ptr %62, align 8, !tbaa !5
  %332 = load i32, ptr %63, align 4, !tbaa !9
  call void @png_set_text(ptr noundef %329, ptr noundef %330, ptr noundef %331, i32 noundef %332)
  br label %333

333:                                              ; preds = %328, %323
  call void @llvm.lifetime.end.p0(i64 4, ptr %63) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %62) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %64) #7
  %334 = load ptr, ptr %6, align 8, !tbaa !5
  %335 = load ptr, ptr %7, align 8, !tbaa !5
  %336 = call i64 @png_get_tIME(ptr noundef %334, ptr noundef %335, ptr noundef %64)
  %337 = icmp ne i64 %336, 0
  br i1 %337, label %338, label %347

338:                                              ; preds = %333
  %339 = load ptr, ptr %9, align 8, !tbaa !5
  %340 = load ptr, ptr %10, align 8, !tbaa !5
  %341 = load ptr, ptr %64, align 8, !tbaa !5
  call void @png_set_tIME(ptr noundef %339, ptr noundef %340, ptr noundef %341)
  %342 = load ptr, ptr %6, align 8, !tbaa !5
  %343 = load ptr, ptr %64, align 8, !tbaa !5
  %344 = call ptr @png_convert_to_rfc1123(ptr noundef %342, ptr noundef %343)
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 @tIME_string, ptr align 1 %344, i64 30, i1 false)
  store i8 0, ptr getelementptr inbounds ([30 x i8], ptr @tIME_string, i64 0, i64 29), align 1, !tbaa !17
  %345 = load i32, ptr @tIME_chunk_present, align 4, !tbaa !9
  %346 = add nsw i32 %345, 1
  store i32 %346, ptr @tIME_chunk_present, align 4, !tbaa !9
  br label %347

347:                                              ; preds = %338, %333
  call void @llvm.lifetime.end.p0(i64 8, ptr %64) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %65) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %66) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %67) #7
  %348 = load ptr, ptr %6, align 8, !tbaa !5
  %349 = load ptr, ptr %7, align 8, !tbaa !5
  %350 = call i64 @png_get_tRNS(ptr noundef %348, ptr noundef %349, ptr noundef %65, ptr noundef %66, ptr noundef %67)
  %351 = icmp ne i64 %350, 0
  br i1 %351, label %352, label %404

352:                                              ; preds = %347
  call void @llvm.lifetime.start.p0(i64 4, ptr %68) #7
  %353 = load ptr, ptr %7, align 8, !tbaa !5
  %354 = getelementptr inbounds %struct.png_info_struct, ptr %353, i32 0, i32 7
  %355 = load i8, ptr %354, align 4, !tbaa !18
  %356 = zext i8 %355 to i32
  %357 = shl i32 1, %356
  store i32 %357, ptr %68, align 4, !tbaa !9
  %358 = load ptr, ptr %7, align 8, !tbaa !5
  %359 = getelementptr inbounds %struct.png_info_struct, ptr %358, i32 0, i32 8
  %360 = load i8, ptr %359, align 1, !tbaa !25
  %361 = zext i8 %360 to i32
  %362 = icmp eq i32 %361, 0
  br i1 %362, label %363, label %370

363:                                              ; preds = %352
  %364 = load ptr, ptr %67, align 8, !tbaa !5
  %365 = getelementptr inbounds %struct.png_color_16_struct, ptr %364, i32 0, i32 4
  %366 = load i16, ptr %365, align 2, !tbaa !26
  %367 = zext i16 %366 to i32
  %368 = load i32, ptr %68, align 4, !tbaa !9
  %369 = icmp sgt i32 %367, %368
  br i1 %369, label %403, label %370

370:                                              ; preds = %363, %352
  %371 = load ptr, ptr %7, align 8, !tbaa !5
  %372 = getelementptr inbounds %struct.png_info_struct, ptr %371, i32 0, i32 8
  %373 = load i8, ptr %372, align 1, !tbaa !25
  %374 = zext i8 %373 to i32
  %375 = icmp eq i32 %374, 2
  br i1 %375, label %376, label %397

376:                                              ; preds = %370
  %377 = load ptr, ptr %67, align 8, !tbaa !5
  %378 = getelementptr inbounds %struct.png_color_16_struct, ptr %377, i32 0, i32 1
  %379 = load i16, ptr %378, align 2, !tbaa !27
  %380 = zext i16 %379 to i32
  %381 = load i32, ptr %68, align 4, !tbaa !9
  %382 = icmp sgt i32 %380, %381
  br i1 %382, label %403, label %383

383:                                              ; preds = %376
  %384 = load ptr, ptr %67, align 8, !tbaa !5
  %385 = getelementptr inbounds %struct.png_color_16_struct, ptr %384, i32 0, i32 2
  %386 = load i16, ptr %385, align 2, !tbaa !28
  %387 = zext i16 %386 to i32
  %388 = load i32, ptr %68, align 4, !tbaa !9
  %389 = icmp sgt i32 %387, %388
  br i1 %389, label %403, label %390

390:                                              ; preds = %383
  %391 = load ptr, ptr %67, align 8, !tbaa !5
  %392 = getelementptr inbounds %struct.png_color_16_struct, ptr %391, i32 0, i32 3
  %393 = load i16, ptr %392, align 2, !tbaa !29
  %394 = zext i16 %393 to i32
  %395 = load i32, ptr %68, align 4, !tbaa !9
  %396 = icmp sgt i32 %394, %395
  br i1 %396, label %403, label %397

397:                                              ; preds = %390, %370
  %398 = load ptr, ptr %9, align 8, !tbaa !5
  %399 = load ptr, ptr %10, align 8, !tbaa !5
  %400 = load ptr, ptr %65, align 8, !tbaa !5
  %401 = load i32, ptr %66, align 4, !tbaa !9
  %402 = load ptr, ptr %67, align 8, !tbaa !5
  call void @png_set_tRNS(ptr noundef %398, ptr noundef %399, ptr noundef %400, i32 noundef %401, ptr noundef %402)
  br label %403

403:                                              ; preds = %397, %390, %383, %376, %363
  call void @llvm.lifetime.end.p0(i64 4, ptr %68) #7
  br label %404

404:                                              ; preds = %403, %347
  call void @llvm.lifetime.end.p0(i64 8, ptr %67) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %66) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %65) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %69) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %70) #7
  %405 = load ptr, ptr %6, align 8, !tbaa !5
  %406 = load ptr, ptr %7, align 8, !tbaa !5
  %407 = call i64 @png_get_unknown_chunks(ptr noundef %405, ptr noundef %406, ptr noundef %69)
  %408 = trunc i64 %407 to i32
  store i32 %408, ptr %70, align 4, !tbaa !9
  %409 = load i32, ptr %70, align 4, !tbaa !9
  %410 = icmp ne i32 %409, 0
  br i1 %410, label %411, label %436

411:                                              ; preds = %404
  call void @llvm.lifetime.start.p0(i64 8, ptr %71) #7
  %412 = load ptr, ptr %9, align 8, !tbaa !5
  %413 = load ptr, ptr %10, align 8, !tbaa !5
  %414 = load ptr, ptr %69, align 8, !tbaa !5
  %415 = load i32, ptr %70, align 4, !tbaa !9
  call void @png_set_unknown_chunks(ptr noundef %412, ptr noundef %413, ptr noundef %414, i32 noundef %415)
  store i64 0, ptr %71, align 8, !tbaa !11
  br label %416

416:                                              ; preds = %432, %411
  %417 = load i64, ptr %71, align 8, !tbaa !11
  %418 = load i32, ptr %70, align 4, !tbaa !9
  %419 = sext i32 %418 to i64
  %420 = icmp ult i64 %417, %419
  br i1 %420, label %421, label %435

421:                                              ; preds = %416
  %422 = load ptr, ptr %9, align 8, !tbaa !5
  %423 = load ptr, ptr %10, align 8, !tbaa !5
  %424 = load i64, ptr %71, align 8, !tbaa !11
  %425 = trunc i64 %424 to i32
  %426 = load ptr, ptr %69, align 8, !tbaa !5
  %427 = load i64, ptr %71, align 8, !tbaa !11
  %428 = getelementptr inbounds %struct.png_unknown_chunk_t, ptr %426, i64 %427
  %429 = getelementptr inbounds %struct.png_unknown_chunk_t, ptr %428, i32 0, i32 3
  %430 = load i8, ptr %429, align 8, !tbaa !30
  %431 = zext i8 %430 to i32
  call void @png_set_unknown_chunk_location(ptr noundef %422, ptr noundef %423, i32 noundef %425, i32 noundef %431)
  br label %432

432:                                              ; preds = %421
  %433 = load i64, ptr %71, align 8, !tbaa !11
  %434 = add i64 %433, 1
  store i64 %434, ptr %71, align 8, !tbaa !11
  br label %416, !llvm.loop !32

435:                                              ; preds = %416
  call void @llvm.lifetime.end.p0(i64 8, ptr %71) #7
  br label %436

436:                                              ; preds = %435, %404
  call void @llvm.lifetime.end.p0(i64 4, ptr %70) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %69) #7
  %437 = load ptr, ptr %9, align 8, !tbaa !5
  %438 = load ptr, ptr %10, align 8, !tbaa !5
  call void @png_write_info(ptr noundef %437, ptr noundef %438)
  %439 = load ptr, ptr %6, align 8, !tbaa !5
  %440 = load ptr, ptr %6, align 8, !tbaa !5
  %441 = load ptr, ptr %7, align 8, !tbaa !5
  %442 = call i64 @png_get_rowbytes(ptr noundef %440, ptr noundef %441)
  %443 = call ptr @png_malloc(ptr noundef %439, i64 noundef %442)
  store ptr %443, ptr %12, align 8, !tbaa !5
  %444 = load ptr, ptr %6, align 8, !tbaa !5
  %445 = call i32 @png_set_interlace_handling(ptr noundef %444)
  store i32 %445, ptr %16, align 4, !tbaa !9
  %446 = load ptr, ptr %9, align 8, !tbaa !5
  %447 = call i32 @png_set_interlace_handling(ptr noundef %446)
  store i32 0, ptr %17, align 4, !tbaa !9
  br label %448

448:                                              ; preds = %464, %436
  %449 = load i32, ptr %17, align 4, !tbaa !9
  %450 = load i32, ptr %16, align 4, !tbaa !9
  %451 = icmp slt i32 %449, %450
  br i1 %451, label %452, label %467

452:                                              ; preds = %448
  store i64 0, ptr %13, align 8, !tbaa !11
  br label %453

453:                                              ; preds = %460, %452
  %454 = load i64, ptr %13, align 8, !tbaa !11
  %455 = load i64, ptr %15, align 8, !tbaa !11
  %456 = icmp ult i64 %454, %455
  br i1 %456, label %457, label %463

457:                                              ; preds = %453
  %458 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_read_rows(ptr noundef %458, ptr noundef %12, ptr noundef null, i64 noundef 1)
  %459 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_write_rows(ptr noundef %459, ptr noundef %12, i64 noundef 1)
  br label %460

460:                                              ; preds = %457
  %461 = load i64, ptr %13, align 8, !tbaa !11
  %462 = add i64 %461, 1
  store i64 %462, ptr %13, align 8, !tbaa !11
  br label %453, !llvm.loop !33

463:                                              ; preds = %453
  br label %464

464:                                              ; preds = %463
  %465 = load i32, ptr %17, align 4, !tbaa !9
  %466 = add nsw i32 %465, 1
  store i32 %466, ptr %17, align 4, !tbaa !9
  br label %448, !llvm.loop !34

467:                                              ; preds = %448
  %468 = load ptr, ptr %6, align 8, !tbaa !5
  %469 = load ptr, ptr %7, align 8, !tbaa !5
  call void @png_free_data(ptr noundef %468, ptr noundef %469, i64 noundef 512, i32 noundef -1)
  %470 = load ptr, ptr %9, align 8, !tbaa !5
  %471 = load ptr, ptr %10, align 8, !tbaa !5
  call void @png_free_data(ptr noundef %470, ptr noundef %471, i64 noundef 512, i32 noundef -1)
  %472 = load ptr, ptr %6, align 8, !tbaa !5
  %473 = load ptr, ptr %8, align 8, !tbaa !5
  call void @png_read_end(ptr noundef %472, ptr noundef %473)
  call void @llvm.lifetime.start.p0(i64 8, ptr %72) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %73) #7
  %474 = load ptr, ptr %6, align 8, !tbaa !5
  %475 = load ptr, ptr %8, align 8, !tbaa !5
  %476 = call i64 @png_get_text(ptr noundef %474, ptr noundef %475, ptr noundef %72, ptr noundef %73)
  %477 = icmp ugt i64 %476, 0
  br i1 %477, label %478, label %483

478:                                              ; preds = %467
  %479 = load ptr, ptr %9, align 8, !tbaa !5
  %480 = load ptr, ptr %11, align 8, !tbaa !5
  %481 = load ptr, ptr %72, align 8, !tbaa !5
  %482 = load i32, ptr %73, align 4, !tbaa !9
  call void @png_set_text(ptr noundef %479, ptr noundef %480, ptr noundef %481, i32 noundef %482)
  br label %483

483:                                              ; preds = %478, %467
  call void @llvm.lifetime.end.p0(i64 4, ptr %73) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %72) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %74) #7
  %484 = load ptr, ptr %6, align 8, !tbaa !5
  %485 = load ptr, ptr %8, align 8, !tbaa !5
  %486 = call i64 @png_get_tIME(ptr noundef %484, ptr noundef %485, ptr noundef %74)
  %487 = icmp ne i64 %486, 0
  br i1 %487, label %488, label %497

488:                                              ; preds = %483
  %489 = load ptr, ptr %9, align 8, !tbaa !5
  %490 = load ptr, ptr %11, align 8, !tbaa !5
  %491 = load ptr, ptr %74, align 8, !tbaa !5
  call void @png_set_tIME(ptr noundef %489, ptr noundef %490, ptr noundef %491)
  %492 = load ptr, ptr %6, align 8, !tbaa !5
  %493 = load ptr, ptr %74, align 8, !tbaa !5
  %494 = call ptr @png_convert_to_rfc1123(ptr noundef %492, ptr noundef %493)
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 @tIME_string, ptr align 1 %494, i64 30, i1 false)
  store i8 0, ptr getelementptr inbounds ([30 x i8], ptr @tIME_string, i64 0, i64 29), align 1, !tbaa !17
  %495 = load i32, ptr @tIME_chunk_present, align 4, !tbaa !9
  %496 = add nsw i32 %495, 1
  store i32 %496, ptr @tIME_chunk_present, align 4, !tbaa !9
  br label %497

497:                                              ; preds = %488, %483
  call void @llvm.lifetime.end.p0(i64 8, ptr %74) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %75) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %76) #7
  %498 = load ptr, ptr %6, align 8, !tbaa !5
  %499 = load ptr, ptr %8, align 8, !tbaa !5
  %500 = call i64 @png_get_unknown_chunks(ptr noundef %498, ptr noundef %499, ptr noundef %75)
  %501 = trunc i64 %500 to i32
  store i32 %501, ptr %76, align 4, !tbaa !9
  %502 = load i32, ptr %76, align 4, !tbaa !9
  %503 = icmp ne i32 %502, 0
  br i1 %503, label %504, label %529

504:                                              ; preds = %497
  call void @llvm.lifetime.start.p0(i64 8, ptr %77) #7
  %505 = load ptr, ptr %9, align 8, !tbaa !5
  %506 = load ptr, ptr %11, align 8, !tbaa !5
  %507 = load ptr, ptr %75, align 8, !tbaa !5
  %508 = load i32, ptr %76, align 4, !tbaa !9
  call void @png_set_unknown_chunks(ptr noundef %505, ptr noundef %506, ptr noundef %507, i32 noundef %508)
  store i64 0, ptr %77, align 8, !tbaa !11
  br label %509

509:                                              ; preds = %525, %504
  %510 = load i64, ptr %77, align 8, !tbaa !11
  %511 = load i32, ptr %76, align 4, !tbaa !9
  %512 = sext i32 %511 to i64
  %513 = icmp ult i64 %510, %512
  br i1 %513, label %514, label %528

514:                                              ; preds = %509
  %515 = load ptr, ptr %9, align 8, !tbaa !5
  %516 = load ptr, ptr %11, align 8, !tbaa !5
  %517 = load i64, ptr %77, align 8, !tbaa !11
  %518 = trunc i64 %517 to i32
  %519 = load ptr, ptr %75, align 8, !tbaa !5
  %520 = load i64, ptr %77, align 8, !tbaa !11
  %521 = getelementptr inbounds %struct.png_unknown_chunk_t, ptr %519, i64 %520
  %522 = getelementptr inbounds %struct.png_unknown_chunk_t, ptr %521, i32 0, i32 3
  %523 = load i8, ptr %522, align 8, !tbaa !30
  %524 = zext i8 %523 to i32
  call void @png_set_unknown_chunk_location(ptr noundef %515, ptr noundef %516, i32 noundef %518, i32 noundef %524)
  br label %525

525:                                              ; preds = %514
  %526 = load i64, ptr %77, align 8, !tbaa !11
  %527 = add i64 %526, 1
  store i64 %527, ptr %77, align 8, !tbaa !11
  br label %509, !llvm.loop !35

528:                                              ; preds = %509
  call void @llvm.lifetime.end.p0(i64 8, ptr %77) #7
  br label %529

529:                                              ; preds = %528, %497
  call void @llvm.lifetime.end.p0(i64 4, ptr %76) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %75) #7
  %530 = load ptr, ptr %9, align 8, !tbaa !5
  %531 = load ptr, ptr %11, align 8, !tbaa !5
  call void @png_write_end(ptr noundef %530, ptr noundef %531)
  %532 = load i32, ptr @verbose, align 4, !tbaa !9
  %533 = icmp ne i32 %532, 0
  br i1 %533, label %534, label %545

534:                                              ; preds = %529
  call void @llvm.lifetime.start.p0(i64 8, ptr %78) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %79) #7
  %535 = load ptr, ptr %9, align 8, !tbaa !5
  %536 = load ptr, ptr %10, align 8, !tbaa !5
  %537 = call i64 @png_get_image_width(ptr noundef %535, ptr noundef %536)
  store i64 %537, ptr %78, align 8, !tbaa !11
  %538 = load ptr, ptr %9, align 8, !tbaa !5
  %539 = load ptr, ptr %10, align 8, !tbaa !5
  %540 = call i64 @png_get_image_height(ptr noundef %538, ptr noundef %539)
  store i64 %540, ptr %79, align 8, !tbaa !11
  %541 = load ptr, ptr @stdout, align 8, !tbaa !5
  %542 = load i64, ptr %78, align 8, !tbaa !11
  %543 = load i64, ptr %79, align 8, !tbaa !11
  %544 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %541, ptr noundef @.str.11, i64 noundef %542, i64 noundef %543) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %79) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %78) #7
  br label %545

545:                                              ; preds = %534, %529
  %546 = load ptr, ptr %6, align 8, !tbaa !5
  %547 = load ptr, ptr %12, align 8, !tbaa !5
  call void @png_free(ptr noundef %546, ptr noundef %547)
  store ptr null, ptr %12, align 8, !tbaa !5
  call void @png_destroy_read_struct(ptr noundef %6, ptr noundef %7, ptr noundef %8)
  %548 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_destroy_info_struct(ptr noundef %548, ptr noundef %11)
  call void @png_destroy_write_struct(ptr noundef %9, ptr noundef %10)
  %549 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %550 = call i32 @fclose(ptr noundef %549)
  %551 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %552 = call i32 @fclose(ptr noundef %551)
  %553 = load ptr, ptr %4, align 8, !tbaa !5
  %554 = call noalias ptr @fopen(ptr noundef %553, ptr noundef @.str.4)
  store ptr %554, ptr @test_one_file.fpin, align 8, !tbaa !5
  %555 = icmp eq ptr %554, null
  br i1 %555, label %556, label %560

556:                                              ; preds = %545
  %557 = load ptr, ptr @stdout, align 8, !tbaa !5
  %558 = load ptr, ptr %4, align 8, !tbaa !5
  %559 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %557, ptr noundef @.str.12, ptr noundef %558) #7
  store i32 1, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

560:                                              ; preds = %545
  %561 = load ptr, ptr %5, align 8, !tbaa !5
  %562 = call noalias ptr @fopen(ptr noundef %561, ptr noundef @.str.4)
  store ptr %562, ptr @test_one_file.fpout, align 8, !tbaa !5
  %563 = icmp eq ptr %562, null
  br i1 %563, label %564, label %570

564:                                              ; preds = %560
  %565 = load ptr, ptr @stdout, align 8, !tbaa !5
  %566 = load ptr, ptr %5, align 8, !tbaa !5
  %567 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %565, ptr noundef @.str.12, ptr noundef %566) #7
  %568 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %569 = call i32 @fclose(ptr noundef %568)
  store i32 1, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

570:                                              ; preds = %560
  br label %571

571:                                              ; preds = %634, %570
  call void @llvm.lifetime.start.p0(i64 8, ptr %80) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %81) #7
  %572 = getelementptr inbounds [256 x i8], ptr %20, i64 0, i64 0
  %573 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %574 = call i64 @fread(ptr noundef %572, i64 noundef 1, i64 noundef 1, ptr noundef %573)
  store i64 %574, ptr %80, align 8, !tbaa !11
  %575 = getelementptr inbounds [256 x i8], ptr %21, i64 0, i64 0
  %576 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %577 = call i64 @fread(ptr noundef %575, i64 noundef 1, i64 noundef 1, ptr noundef %576)
  store i64 %577, ptr %81, align 8, !tbaa !11
  %578 = load i64, ptr %80, align 8, !tbaa !11
  %579 = load i64, ptr %81, align 8, !tbaa !11
  %580 = icmp ne i64 %578, %579
  br i1 %580, label %581, label %601

581:                                              ; preds = %571
  %582 = load ptr, ptr @stdout, align 8, !tbaa !5
  %583 = load ptr, ptr %4, align 8, !tbaa !5
  %584 = load ptr, ptr %5, align 8, !tbaa !5
  %585 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %582, ptr noundef @.str.13, ptr noundef %583, ptr noundef %584) #7
  %586 = load i32, ptr @wrote_question, align 4, !tbaa !9
  %587 = icmp eq i32 %586, 0
  br i1 %587, label %588, label %596

588:                                              ; preds = %581
  %589 = load ptr, ptr @stdout, align 8, !tbaa !5
  %590 = load ptr, ptr %4, align 8, !tbaa !5
  %591 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %589, ptr noundef @.str.14, ptr noundef %590, i32 noundef 8192) #7
  %592 = load ptr, ptr @stdout, align 8, !tbaa !5
  %593 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %592, ptr noundef @.str.15) #7
  %594 = load ptr, ptr @stdout, align 8, !tbaa !5
  %595 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %594, ptr noundef @.str.16, ptr noundef @.str.17) #7
  store i32 1, ptr @wrote_question, align 4, !tbaa !9
  br label %596

596:                                              ; preds = %588, %581
  %597 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %598 = call i32 @fclose(ptr noundef %597)
  %599 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %600 = call i32 @fclose(ptr noundef %599)
  store i32 0, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %632

601:                                              ; preds = %571
  %602 = load i64, ptr %80, align 8, !tbaa !11
  %603 = icmp ne i64 %602, 0
  br i1 %603, label %605, label %604

604:                                              ; preds = %601
  store i32 17, ptr %22, align 4
  br label %632

605:                                              ; preds = %601
  %606 = getelementptr inbounds [256 x i8], ptr %20, i64 0, i64 0
  %607 = getelementptr inbounds [256 x i8], ptr %21, i64 0, i64 0
  %608 = load i64, ptr %80, align 8, !tbaa !11
  %609 = call i32 @memcmp(ptr noundef %606, ptr noundef %607, i64 noundef %608) #9
  %610 = icmp ne i32 %609, 0
  br i1 %610, label %611, label %631

611:                                              ; preds = %605
  %612 = load ptr, ptr @stdout, align 8, !tbaa !5
  %613 = load ptr, ptr %4, align 8, !tbaa !5
  %614 = load ptr, ptr %5, align 8, !tbaa !5
  %615 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %612, ptr noundef @.str.18, ptr noundef %613, ptr noundef %614) #7
  %616 = load i32, ptr @wrote_question, align 4, !tbaa !9
  %617 = icmp eq i32 %616, 0
  br i1 %617, label %618, label %626

618:                                              ; preds = %611
  %619 = load ptr, ptr @stdout, align 8, !tbaa !5
  %620 = load ptr, ptr %4, align 8, !tbaa !5
  %621 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %619, ptr noundef @.str.14, ptr noundef %620, i32 noundef 8192) #7
  %622 = load ptr, ptr @stdout, align 8, !tbaa !5
  %623 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %622, ptr noundef @.str.15) #7
  %624 = load ptr, ptr @stdout, align 8, !tbaa !5
  %625 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %624, ptr noundef @.str.16, ptr noundef @.str.17) #7
  store i32 1, ptr @wrote_question, align 4, !tbaa !9
  br label %626

626:                                              ; preds = %618, %611
  %627 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %628 = call i32 @fclose(ptr noundef %627)
  %629 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %630 = call i32 @fclose(ptr noundef %629)
  store i32 0, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %632

631:                                              ; preds = %605
  store i32 0, ptr %22, align 4
  br label %632

632:                                              ; preds = %631, %626, %604, %596
  call void @llvm.lifetime.end.p0(i64 8, ptr %81) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %80) #7
  %633 = load i32, ptr %22, align 4
  switch i32 %633, label %640 [
    i32 0, label %634
    i32 17, label %635
  ]

634:                                              ; preds = %632
  br label %571

635:                                              ; preds = %632
  %636 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %637 = call i32 @fclose(ptr noundef %636)
  %638 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %639 = call i32 @fclose(ptr noundef %638)
  store i32 0, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %640

640:                                              ; preds = %635, %632, %564, %556, %137, %119, %93, %85
  call void @llvm.lifetime.end.p0(i64 256, ptr %21) #7
  call void @llvm.lifetime.end.p0(i64 256, ptr %20) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  %641 = load i32, ptr %3, align 4
  ret i32 %641
}

declare noalias ptr @fopen(ptr noundef, ptr noundef) #3

declare i32 @fclose(ptr noundef) #3

declare ptr @png_create_read_struct(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_error_fn(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

; Function Attrs: nounwind uwtable
declare hidden void @pngtest_error(ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare hidden void @pngtest_warning(ptr noundef, ptr noundef) #0

declare ptr @png_create_write_struct(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare ptr @png_create_info_struct(ptr noundef) #3

; Function Attrs: nounwind returns_twice
declare i32 @_setjmp(ptr noundef) #4

declare void @png_free(ptr noundef, ptr noundef) #3

declare void @png_destroy_read_struct(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_destroy_info_struct(ptr noundef, ptr noundef) #3

declare void @png_destroy_write_struct(ptr noundef, ptr noundef) #3

declare void @png_init_io(ptr noundef, ptr noundef) #3

declare void @png_set_write_status_fn(ptr noundef, ptr noundef) #3

declare void @png_set_read_status_fn(ptr noundef, ptr noundef) #3

declare void @png_set_read_user_transform_fn(ptr noundef, ptr noundef) #3

declare void @png_set_write_user_transform_fn(ptr noundef, ptr noundef) #3

declare void @png_set_keep_unknown_chunks(ptr noundef, i32 noundef, ptr noundef, i32 noundef) #3

declare void @png_read_info(ptr noundef, ptr noundef) #3

declare i64 @png_get_IHDR(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_IHDR(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #3

declare i64 @png_get_cHRM_fixed(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_cHRM_fixed(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef) #3

declare i64 @png_get_gAMA_fixed(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_gAMA_fixed(ptr noundef, ptr noundef, i64 noundef) #3

declare i64 @png_get_iCCP(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_iCCP(ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef, i64 noundef) #3

declare i64 @png_get_sRGB(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_sRGB(ptr noundef, ptr noundef, i32 noundef) #3

declare i64 @png_get_PLTE(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_PLTE(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #3

declare i64 @png_get_bKGD(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_bKGD(ptr noundef, ptr noundef, ptr noundef) #3

declare i64 @png_get_hIST(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_hIST(ptr noundef, ptr noundef, ptr noundef) #3

declare i64 @png_get_oFFs(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_oFFs(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef) #3

declare i64 @png_get_pCAL(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_pCAL(ptr noundef, ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) #3

declare i64 @png_get_pHYs(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_pHYs(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef) #3

declare i64 @png_get_sBIT(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_sBIT(ptr noundef, ptr noundef, ptr noundef) #3

declare i64 @png_get_sCAL(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_sCAL(ptr noundef, ptr noundef, i32 noundef, double noundef, double noundef) #3

declare i64 @png_get_text(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_text(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #3

declare i64 @png_get_tIME(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_tIME(ptr noundef, ptr noundef, ptr noundef) #3

declare ptr @png_convert_to_rfc1123(ptr noundef, ptr noundef) #3

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #5

declare i64 @png_get_tRNS(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_tRNS(ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef) #3

declare i64 @png_get_unknown_chunks(ptr noundef, ptr noundef, ptr noundef) #3

declare void @png_set_unknown_chunks(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #3

declare void @png_set_unknown_chunk_location(ptr noundef, ptr noundef, i32 noundef, i32 noundef) #3

declare void @png_write_info(ptr noundef, ptr noundef) #3

declare ptr @png_malloc(ptr noundef, i64 noundef) #3

declare i64 @png_get_rowbytes(ptr noundef, ptr noundef) #3

declare i32 @png_set_interlace_handling(ptr noundef) #3

declare void @png_read_rows(ptr noundef, ptr noundef, ptr noundef, i64 noundef) #3

declare void @png_write_rows(ptr noundef, ptr noundef, i64 noundef) #3

declare void @png_free_data(ptr noundef, ptr noundef, i64 noundef, i32 noundef) #3

declare void @png_read_end(ptr noundef, ptr noundef) #3

declare void @png_write_end(ptr noundef, ptr noundef) #3

declare i64 @png_get_image_width(ptr noundef, ptr noundef) #3

declare i64 @png_get_image_height(ptr noundef, ptr noundef) #3

declare i64 @fread(ptr noundef, i64 noundef, i64 noundef, ptr noundef) #3

; Function Attrs: nounwind willreturn memory(read)
declare i32 @memcmp(ptr noundef, ptr noundef, i64 noundef) #6

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { 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 #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { "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 = { nounwind returns_twice "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 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { 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 #7 = { nounwind }
attributes #8 = { nounwind returns_twice }
attributes #9 = { 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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !16, i64 0}
!16 = !{!"double", !7, i64 0}
!17 = !{!7, !7, i64 0}
!18 = !{!19, !7, i64 44}
!19 = !{!"png_info_struct", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !6, i64 32, !20, i64 40, !20, i64 42, !7, i64 44, !7, i64 45, !7, i64 46, !7, i64 47, !7, i64 48, !7, i64 49, !7, i64 50, !7, i64 51, !7, i64 52, !21, i64 60, !7, i64 64, !10, i64 68, !10, i64 72, !6, i64 80, !22, i64 88, !23, i64 96, !6, i64 104, !24, i64 112, !24, i64 122, !12, i64 136, !12, i64 144, !7, i64 152, !12, i64 160, !12, i64 168, !7, i64 176, !6, i64 184, !21, i64 192, !21, i64 196, !21, i64 200, !21, i64 204, !21, i64 208, !21, i64 212, !21, i64 216, !21, i64 220, !6, i64 224, !12, i64 232, !12, i64 240, !6, i64 248, !6, i64 256, !7, i64 264, !7, i64 265, !12, i64 272, !6, i64 280, !12, i64 288, !6, i64 296, !6, i64 304, !12, i64 312, !7, i64 320, !6, i64 328, !12, i64 336, !7, i64 344, !16, i64 352, !16, i64 360, !6, i64 368, !6, i64 376, !6, i64 384, !12, i64 392, !12, i64 400, !12, i64 408, !12, i64 416, !12, i64 424, !12, i64 432, !12, i64 440, !12, i64 448, !12, i64 456}
!20 = !{!"short", !7, i64 0}
!21 = !{!"float", !7, i64 0}
!22 = !{!"png_time_struct", !20, i64 0, !7, i64 2, !7, i64 3, !7, i64 4, !7, i64 5, !7, i64 6}
!23 = !{!"png_color_8_struct", !7, i64 0, !7, i64 1, !7, i64 2, !7, i64 3, !7, i64 4}
!24 = !{!"png_color_16_struct", !7, i64 0, !20, i64 2, !20, i64 4, !20, i64 6, !20, i64 8}
!25 = !{!19, !7, i64 45}
!26 = !{!24, !20, i64 8}
!27 = !{!24, !20, i64 2}
!28 = !{!24, !20, i64 4}
!29 = !{!24, !20, i64 6}
!30 = !{!31, !7, i64 24}
!31 = !{!"png_unknown_chunk_t", !7, i64 0, !6, i64 8, !12, i64 16, !7, i64 24}
!32 = distinct !{!32, !14}
!33 = distinct !{!33, !14}
!34 = distinct !{!34, !14}
!35 = distinct !{!35, !14}


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

%struct.png_unknown_chunk_t = type { [5 x i8], ptr, i64, i8 }

@stdout = external local_unnamed_addr global ptr, align 8
@filters_used = external hidden local_unnamed_addr global [256 x i64], align 16
@zero_samples = external hidden local_unnamed_addr global i64, align 8
@test_one_file.fpin = external hidden local_unnamed_addr global ptr, align 8
@test_one_file.fpout = external hidden local_unnamed_addr global ptr, align 8
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [30 x i8], align 1
@status_dots_requested = external hidden local_unnamed_addr global i32, align 4
@tIME_string = external hidden local_unnamed_addr global [30 x i8], align 16
@tIME_chunk_present = external hidden local_unnamed_addr global i32, align 4
@verbose = external hidden local_unnamed_addr global i32, align 4
@.str.11 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [42 x i8], align 1
@wrote_question = external hidden local_unnamed_addr global i32, align 4
@.str.14 = external hidden unnamed_addr constant [68 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [54 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [32 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local void @read_row_callback(ptr noundef, i64 noundef, i32 noundef) #0

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

; Function Attrs: nounwind uwtable
declare dso_local void @write_row_callback(ptr noundef, i64 noundef, i32 noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @count_filters(ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @count_zero_samples(ptr noundef, ptr noundef, ptr noundef) #0

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

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

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @test_one_file(ptr noundef %0, ptr noundef %1) local_unnamed_addr #0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca [256 x i8], align 16
  %15 = alloca [256 x i8], align 16
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i64, align 8
  %20 = alloca i64, align 8
  %21 = alloca i64, align 8
  %22 = alloca i64, align 8
  %23 = alloca i64, align 8
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca i64, align 8
  %27 = alloca i64, align 8
  %28 = alloca ptr, align 8
  %29 = alloca ptr, align 8
  %30 = alloca i64, align 8
  %31 = alloca i32, align 4
  %32 = alloca i32, align 4
  %33 = alloca ptr, align 8
  %34 = alloca i32, align 4
  %35 = alloca ptr, align 8
  %36 = alloca ptr, align 8
  %37 = alloca i64, align 8
  %38 = alloca i64, align 8
  %39 = alloca i32, align 4
  %40 = alloca ptr, align 8
  %41 = alloca ptr, align 8
  %42 = alloca ptr, align 8
  %43 = alloca i64, align 8
  %44 = alloca i64, align 8
  %45 = alloca i32, align 4
  %46 = alloca i32, align 4
  %47 = alloca i64, align 8
  %48 = alloca i64, align 8
  %49 = alloca i32, align 4
  %50 = alloca ptr, align 8
  %51 = alloca i32, align 4
  %52 = alloca double, align 8
  %53 = alloca double, align 8
  %54 = alloca ptr, align 8
  %55 = alloca i32, align 4
  %56 = alloca ptr, align 8
  %57 = alloca ptr, align 8
  %58 = alloca i32, align 4
  %59 = alloca ptr, align 8
  %60 = alloca ptr, align 8
  %61 = alloca ptr, align 8
  %62 = alloca i32, align 4
  %63 = alloca ptr, align 8
  %64 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %13) #9
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %14) #9
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %15) #9
  store ptr null, ptr %9, align 8, !tbaa !5
  %65 = call noalias ptr @fopen(ptr noundef %0, ptr noundef nonnull @.str.4)
  store ptr %65, ptr @test_one_file.fpin, align 8, !tbaa !5
  %66 = icmp eq ptr %65, null
  br i1 %66, label %67, label %70

67:                                               ; preds = %2
  %68 = load ptr, ptr @stdout, align 8, !tbaa !5
  %69 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %68, ptr noundef nonnull @.str.5, ptr noundef %0) #9
  br label %.thread89

70:                                               ; preds = %2
  %71 = call noalias ptr @fopen(ptr noundef %1, ptr noundef nonnull @.str.6)
  store ptr %71, ptr @test_one_file.fpout, align 8, !tbaa !5
  %72 = icmp eq ptr %71, null
  br i1 %72, label %73, label %78

73:                                               ; preds = %70
  %74 = load ptr, ptr @stdout, align 8, !tbaa !5
  %75 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %74, ptr noundef nonnull @.str.7, ptr noundef %1) #9
  %76 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %77 = call i32 @fclose(ptr noundef %76)
  br label %.thread89

78:                                               ; preds = %70
  %79 = call ptr @png_create_read_struct(ptr noundef nonnull @.str.8, ptr noundef null, ptr noundef null, ptr noundef null) #9
  store ptr %79, ptr %3, align 8, !tbaa !5
  call void @png_set_error_fn(ptr noundef %79, ptr noundef %0, ptr noundef nonnull @pngtest_error, ptr noundef nonnull @pngtest_warning) #9
  %80 = call ptr @png_create_write_struct(ptr noundef nonnull @.str.8, ptr noundef null, ptr noundef null, ptr noundef null) #9
  store ptr %80, ptr %6, align 8, !tbaa !5
  call void @png_set_error_fn(ptr noundef %80, ptr noundef %0, ptr noundef nonnull @pngtest_error, ptr noundef nonnull @pngtest_warning) #9
  %81 = load ptr, ptr %3, align 8, !tbaa !5
  %82 = call ptr @png_create_info_struct(ptr noundef %81) #9
  store ptr %82, ptr %4, align 8, !tbaa !5
  %83 = load ptr, ptr %3, align 8, !tbaa !5
  %84 = call ptr @png_create_info_struct(ptr noundef %83) #9
  store ptr %84, ptr %5, align 8, !tbaa !5
  %85 = load ptr, ptr %6, align 8, !tbaa !5
  %86 = call ptr @png_create_info_struct(ptr noundef %85) #9
  store ptr %86, ptr %7, align 8, !tbaa !5
  %87 = load ptr, ptr %6, align 8, !tbaa !5
  %88 = call ptr @png_create_info_struct(ptr noundef %87) #9
  store ptr %88, ptr %8, align 8, !tbaa !5
  %89 = load ptr, ptr %3, align 8, !tbaa !5
  %90 = call i32 @_setjmp(ptr noundef %89) #10
  %.not = icmp eq i32 %90, 0
  br i1 %.not, label %101, label %91

91:                                               ; preds = %78
  %92 = load ptr, ptr @stdout, align 8, !tbaa !5
  %93 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %92, ptr noundef nonnull @.str.9, ptr noundef %0, ptr noundef %1) #9
  %94 = load ptr, ptr %3, align 8, !tbaa !5
  %95 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_free(ptr noundef %94, ptr noundef %95) #9
  call void @png_destroy_read_struct(ptr noundef nonnull %3, ptr noundef nonnull %4, ptr noundef nonnull %5) #9
  %96 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_destroy_info_struct(ptr noundef %96, ptr noundef nonnull %8) #9
  call void @png_destroy_write_struct(ptr noundef nonnull %6, ptr noundef nonnull %7) #9
  %97 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %98 = call i32 @fclose(ptr noundef %97)
  %99 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %100 = call i32 @fclose(ptr noundef %99)
  br label %.thread89

101:                                              ; preds = %78
  %102 = load ptr, ptr %6, align 8, !tbaa !5
  %103 = call i32 @_setjmp(ptr noundef %102) #10
  %.not63 = icmp eq i32 %103, 0
  br i1 %.not63, label %112, label %104

104:                                              ; preds = %101
  %105 = load ptr, ptr @stdout, align 8, !tbaa !5
  %106 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %105, ptr noundef nonnull @.str.10, ptr noundef %0, ptr noundef %1) #9
  call void @png_destroy_read_struct(ptr noundef nonnull %3, ptr noundef nonnull %4, ptr noundef nonnull %5) #9
  %107 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_destroy_info_struct(ptr noundef %107, ptr noundef nonnull %8) #9
  call void @png_destroy_write_struct(ptr noundef nonnull %6, ptr noundef nonnull %7) #9
  %108 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %109 = call i32 @fclose(ptr noundef %108)
  %110 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %111 = call i32 @fclose(ptr noundef %110)
  br label %.thread89

112:                                              ; preds = %101
  %113 = load ptr, ptr %3, align 8, !tbaa !5
  %114 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  call void @png_init_io(ptr noundef %113, ptr noundef %114) #9
  %115 = load ptr, ptr %6, align 8, !tbaa !5
  %116 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  call void @png_init_io(ptr noundef %115, ptr noundef %116) #9
  %117 = load i32, ptr @status_dots_requested, align 4, !tbaa !9
  %118 = icmp eq i32 %117, 1
  %119 = load ptr, ptr %6, align 8, !tbaa !5
  br i1 %118, label %120, label %122

120:                                              ; preds = %112
  call void @png_set_write_status_fn(ptr noundef %119, ptr noundef nonnull @write_row_callback) #9
  %121 = load ptr, ptr %3, align 8, !tbaa !5
  call void @png_set_read_status_fn(ptr noundef %121, ptr noundef nonnull @read_row_callback) #9
  br label %124

122:                                              ; preds = %112
  call void @png_set_write_status_fn(ptr noundef %119, ptr noundef null) #9
  %123 = load ptr, ptr %3, align 8, !tbaa !5
  call void @png_set_read_status_fn(ptr noundef %123, ptr noundef null) #9
  br label %124

124:                                              ; preds = %122, %120
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(2048) @filters_used, i8 0, i64 2048, i1 false), !tbaa !11
  %125 = load ptr, ptr %3, align 8, !tbaa !5
  call void @png_set_read_user_transform_fn(ptr noundef %125, ptr noundef nonnull @count_filters) #9
  store i64 0, ptr @zero_samples, align 8, !tbaa !11
  %126 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_set_write_user_transform_fn(ptr noundef %126, ptr noundef nonnull @count_zero_samples) #9
  %127 = load ptr, ptr %3, align 8, !tbaa !5
  call void @png_set_keep_unknown_chunks(ptr noundef %127, i32 noundef 3, ptr noundef null, i32 noundef 0) #9
  %128 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_set_keep_unknown_chunks(ptr noundef %128, i32 noundef 2, ptr noundef null, i32 noundef 0) #9
  %129 = load ptr, ptr %3, align 8, !tbaa !5
  %130 = load ptr, ptr %4, align 8, !tbaa !5
  call void @png_read_info(ptr noundef %129, ptr noundef %130) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %16) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %17) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %18) #9
  %131 = load ptr, ptr %3, align 8, !tbaa !5
  %132 = load ptr, ptr %4, align 8, !tbaa !5
  %133 = call i64 @png_get_IHDR(ptr noundef %131, ptr noundef %132, ptr noundef nonnull %10, ptr noundef nonnull %11, ptr noundef nonnull %12, ptr noundef nonnull %13, ptr noundef nonnull %16, ptr noundef nonnull %17, ptr noundef nonnull %18) #9
  %.not64 = icmp eq i64 %133, 0
  br i1 %.not64, label %144, label %134

134:                                              ; preds = %124
  %135 = load ptr, ptr %6, align 8, !tbaa !5
  %136 = load ptr, ptr %7, align 8, !tbaa !5
  %137 = load i64, ptr %10, align 8, !tbaa !11
  %138 = load i64, ptr %11, align 8, !tbaa !11
  %139 = load i32, ptr %12, align 4, !tbaa !9
  %140 = load i32, ptr %13, align 4, !tbaa !9
  %141 = load i32, ptr %16, align 4, !tbaa !9
  %142 = load i32, ptr %17, align 4, !tbaa !9
  %143 = load i32, ptr %18, align 4, !tbaa !9
  call void @png_set_IHDR(ptr noundef %135, ptr noundef %136, i64 noundef %137, i64 noundef %138, i32 noundef %139, i32 noundef %140, i32 noundef %141, i32 noundef %142, i32 noundef %143) #9
  br label %144

144:                                              ; preds = %134, %124
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %18) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %17) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %16) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %19) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %20) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %21) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %22) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %23) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %24) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %25) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %26) #9
  %145 = load ptr, ptr %3, align 8, !tbaa !5
  %146 = load ptr, ptr %4, align 8, !tbaa !5
  %147 = call i64 @png_get_cHRM_fixed(ptr noundef %145, ptr noundef %146, ptr noundef nonnull %19, ptr noundef nonnull %20, ptr noundef nonnull %21, ptr noundef nonnull %22, ptr noundef nonnull %23, ptr noundef nonnull %24, ptr noundef nonnull %25, ptr noundef nonnull %26) #9
  %.not65 = icmp eq i64 %147, 0
  br i1 %.not65, label %159, label %148

148:                                              ; preds = %144
  %149 = load ptr, ptr %6, align 8, !tbaa !5
  %150 = load ptr, ptr %7, align 8, !tbaa !5
  %151 = load i64, ptr %19, align 8, !tbaa !11
  %152 = load i64, ptr %20, align 8, !tbaa !11
  %153 = load i64, ptr %21, align 8, !tbaa !11
  %154 = load i64, ptr %22, align 8, !tbaa !11
  %155 = load i64, ptr %23, align 8, !tbaa !11
  %156 = load i64, ptr %24, align 8, !tbaa !11
  %157 = load i64, ptr %25, align 8, !tbaa !11
  %158 = load i64, ptr %26, align 8, !tbaa !11
  call void @png_set_cHRM_fixed(ptr noundef %149, ptr noundef %150, i64 noundef %151, i64 noundef %152, i64 noundef %153, i64 noundef %154, i64 noundef %155, i64 noundef %156, i64 noundef %157, i64 noundef %158) #9
  br label %159

159:                                              ; preds = %148, %144
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %26) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %25) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %23) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %22) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %21) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %27) #9
  %160 = load ptr, ptr %3, align 8, !tbaa !5
  %161 = load ptr, ptr %4, align 8, !tbaa !5
  %162 = call i64 @png_get_gAMA_fixed(ptr noundef %160, ptr noundef %161, ptr noundef nonnull %27) #9
  %.not66 = icmp eq i64 %162, 0
  br i1 %.not66, label %167, label %163

163:                                              ; preds = %159
  %164 = load ptr, ptr %6, align 8, !tbaa !5
  %165 = load ptr, ptr %7, align 8, !tbaa !5
  %166 = load i64, ptr %27, align 8, !tbaa !11
  call void @png_set_gAMA_fixed(ptr noundef %164, ptr noundef %165, i64 noundef %166) #9
  br label %167

167:                                              ; preds = %163, %159
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %27) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %28) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %29) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %30) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %31) #9
  %168 = load ptr, ptr %3, align 8, !tbaa !5
  %169 = load ptr, ptr %4, align 8, !tbaa !5
  %170 = call i64 @png_get_iCCP(ptr noundef %168, ptr noundef %169, ptr noundef nonnull %28, ptr noundef nonnull %31, ptr noundef nonnull %29, ptr noundef nonnull %30) #9
  %.not67 = icmp eq i64 %170, 0
  br i1 %.not67, label %178, label %171

171:                                              ; preds = %167
  %172 = load ptr, ptr %6, align 8, !tbaa !5
  %173 = load ptr, ptr %7, align 8, !tbaa !5
  %174 = load ptr, ptr %28, align 8, !tbaa !5
  %175 = load i32, ptr %31, align 4, !tbaa !9
  %176 = load ptr, ptr %29, align 8, !tbaa !5
  %177 = load i64, ptr %30, align 8, !tbaa !11
  call void @png_set_iCCP(ptr noundef %172, ptr noundef %173, ptr noundef %174, i32 noundef %175, ptr noundef %176, i64 noundef %177) #9
  br label %178

178:                                              ; preds = %171, %167
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %31) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %30) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %29) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %28) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %32) #9
  %179 = load ptr, ptr %3, align 8, !tbaa !5
  %180 = load ptr, ptr %4, align 8, !tbaa !5
  %181 = call i64 @png_get_sRGB(ptr noundef %179, ptr noundef %180, ptr noundef nonnull %32) #9
  %.not68 = icmp eq i64 %181, 0
  br i1 %.not68, label %186, label %182

182:                                              ; preds = %178
  %183 = load ptr, ptr %6, align 8, !tbaa !5
  %184 = load ptr, ptr %7, align 8, !tbaa !5
  %185 = load i32, ptr %32, align 4, !tbaa !9
  call void @png_set_sRGB(ptr noundef %183, ptr noundef %184, i32 noundef %185) #9
  br label %186

186:                                              ; preds = %182, %178
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %32) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %33) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %34) #9
  %187 = load ptr, ptr %3, align 8, !tbaa !5
  %188 = load ptr, ptr %4, align 8, !tbaa !5
  %189 = call i64 @png_get_PLTE(ptr noundef %187, ptr noundef %188, ptr noundef nonnull %33, ptr noundef nonnull %34) #9
  %.not69 = icmp eq i64 %189, 0
  br i1 %.not69, label %195, label %190

190:                                              ; preds = %186
  %191 = load ptr, ptr %6, align 8, !tbaa !5
  %192 = load ptr, ptr %7, align 8, !tbaa !5
  %193 = load ptr, ptr %33, align 8, !tbaa !5
  %194 = load i32, ptr %34, align 4, !tbaa !9
  call void @png_set_PLTE(ptr noundef %191, ptr noundef %192, ptr noundef %193, i32 noundef %194) #9
  br label %195

195:                                              ; preds = %190, %186
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %34) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %33) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %35) #9
  %196 = load ptr, ptr %3, align 8, !tbaa !5
  %197 = load ptr, ptr %4, align 8, !tbaa !5
  %198 = call i64 @png_get_bKGD(ptr noundef %196, ptr noundef %197, ptr noundef nonnull %35) #9
  %.not70 = icmp eq i64 %198, 0
  br i1 %.not70, label %203, label %199

199:                                              ; preds = %195
  %200 = load ptr, ptr %6, align 8, !tbaa !5
  %201 = load ptr, ptr %7, align 8, !tbaa !5
  %202 = load ptr, ptr %35, align 8, !tbaa !5
  call void @png_set_bKGD(ptr noundef %200, ptr noundef %201, ptr noundef %202) #9
  br label %203

203:                                              ; preds = %199, %195
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %35) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %36) #9
  %204 = load ptr, ptr %3, align 8, !tbaa !5
  %205 = load ptr, ptr %4, align 8, !tbaa !5
  %206 = call i64 @png_get_hIST(ptr noundef %204, ptr noundef %205, ptr noundef nonnull %36) #9
  %.not71 = icmp eq i64 %206, 0
  br i1 %.not71, label %211, label %207

207:                                              ; preds = %203
  %208 = load ptr, ptr %6, align 8, !tbaa !5
  %209 = load ptr, ptr %7, align 8, !tbaa !5
  %210 = load ptr, ptr %36, align 8, !tbaa !5
  call void @png_set_hIST(ptr noundef %208, ptr noundef %209, ptr noundef %210) #9
  br label %211

211:                                              ; preds = %207, %203
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %36) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %37) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %38) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %39) #9
  %212 = load ptr, ptr %3, align 8, !tbaa !5
  %213 = load ptr, ptr %4, align 8, !tbaa !5
  %214 = call i64 @png_get_oFFs(ptr noundef %212, ptr noundef %213, ptr noundef nonnull %37, ptr noundef nonnull %38, ptr noundef nonnull %39) #9
  %.not72 = icmp eq i64 %214, 0
  br i1 %.not72, label %221, label %215

215:                                              ; preds = %211
  %216 = load ptr, ptr %6, align 8, !tbaa !5
  %217 = load ptr, ptr %7, align 8, !tbaa !5
  %218 = load i64, ptr %37, align 8, !tbaa !11
  %219 = load i64, ptr %38, align 8, !tbaa !11
  %220 = load i32, ptr %39, align 4, !tbaa !9
  call void @png_set_oFFs(ptr noundef %216, ptr noundef %217, i64 noundef %218, i64 noundef %219, i32 noundef %220) #9
  br label %221

221:                                              ; preds = %215, %211
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %39) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %38) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %37) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %40) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %41) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %42) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %43) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %44) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %45) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %46) #9
  %222 = load ptr, ptr %3, align 8, !tbaa !5
  %223 = load ptr, ptr %4, align 8, !tbaa !5
  %224 = call i64 @png_get_pCAL(ptr noundef %222, ptr noundef %223, ptr noundef nonnull %40, ptr noundef nonnull %43, ptr noundef nonnull %44, ptr noundef nonnull %45, ptr noundef nonnull %46, ptr noundef nonnull %41, ptr noundef nonnull %42) #9
  %.not73 = icmp eq i64 %224, 0
  br i1 %.not73, label %235, label %225

225:                                              ; preds = %221
  %226 = load ptr, ptr %6, align 8, !tbaa !5
  %227 = load ptr, ptr %7, align 8, !tbaa !5
  %228 = load ptr, ptr %40, align 8, !tbaa !5
  %229 = load i64, ptr %43, align 8, !tbaa !11
  %230 = load i64, ptr %44, align 8, !tbaa !11
  %231 = load i32, ptr %45, align 4, !tbaa !9
  %232 = load i32, ptr %46, align 4, !tbaa !9
  %233 = load ptr, ptr %41, align 8, !tbaa !5
  %234 = load ptr, ptr %42, align 8, !tbaa !5
  call void @png_set_pCAL(ptr noundef %226, ptr noundef %227, ptr noundef %228, i64 noundef %229, i64 noundef %230, i32 noundef %231, i32 noundef %232, ptr noundef %233, ptr noundef %234) #9
  br label %235

235:                                              ; preds = %225, %221
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %46) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %45) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %44) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %43) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %42) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %41) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %40) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %47) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %48) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %49) #9
  %236 = load ptr, ptr %3, align 8, !tbaa !5
  %237 = load ptr, ptr %4, align 8, !tbaa !5
  %238 = call i64 @png_get_pHYs(ptr noundef %236, ptr noundef %237, ptr noundef nonnull %47, ptr noundef nonnull %48, ptr noundef nonnull %49) #9
  %.not74 = icmp eq i64 %238, 0
  br i1 %.not74, label %245, label %239

239:                                              ; preds = %235
  %240 = load ptr, ptr %6, align 8, !tbaa !5
  %241 = load ptr, ptr %7, align 8, !tbaa !5
  %242 = load i64, ptr %47, align 8, !tbaa !11
  %243 = load i64, ptr %48, align 8, !tbaa !11
  %244 = load i32, ptr %49, align 4, !tbaa !9
  call void @png_set_pHYs(ptr noundef %240, ptr noundef %241, i64 noundef %242, i64 noundef %243, i32 noundef %244) #9
  br label %245

245:                                              ; preds = %239, %235
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %49) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %48) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %47) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %50) #9
  %246 = load ptr, ptr %3, align 8, !tbaa !5
  %247 = load ptr, ptr %4, align 8, !tbaa !5
  %248 = call i64 @png_get_sBIT(ptr noundef %246, ptr noundef %247, ptr noundef nonnull %50) #9
  %.not75 = icmp eq i64 %248, 0
  br i1 %.not75, label %253, label %249

249:                                              ; preds = %245
  %250 = load ptr, ptr %6, align 8, !tbaa !5
  %251 = load ptr, ptr %7, align 8, !tbaa !5
  %252 = load ptr, ptr %50, align 8, !tbaa !5
  call void @png_set_sBIT(ptr noundef %250, ptr noundef %251, ptr noundef %252) #9
  br label %253

253:                                              ; preds = %249, %245
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %50) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %51) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %52) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %53) #9
  %254 = load ptr, ptr %3, align 8, !tbaa !5
  %255 = load ptr, ptr %4, align 8, !tbaa !5
  %256 = call i64 @png_get_sCAL(ptr noundef %254, ptr noundef %255, ptr noundef nonnull %51, ptr noundef nonnull %52, ptr noundef nonnull %53) #9
  %.not76 = icmp eq i64 %256, 0
  br i1 %.not76, label %263, label %257

257:                                              ; preds = %253
  %258 = load ptr, ptr %6, align 8, !tbaa !5
  %259 = load ptr, ptr %7, align 8, !tbaa !5
  %260 = load i32, ptr %51, align 4, !tbaa !9
  %261 = load double, ptr %52, align 8, !tbaa !13
  %262 = load double, ptr %53, align 8, !tbaa !13
  call void @png_set_sCAL(ptr noundef %258, ptr noundef %259, i32 noundef %260, double noundef %261, double noundef %262) #9
  br label %263

263:                                              ; preds = %257, %253
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %53) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %52) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %51) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %54) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %55) #9
  %264 = load ptr, ptr %3, align 8, !tbaa !5
  %265 = load ptr, ptr %4, align 8, !tbaa !5
  %266 = call i64 @png_get_text(ptr noundef %264, ptr noundef %265, ptr noundef nonnull %54, ptr noundef nonnull %55) #9
  %.not77 = icmp eq i64 %266, 0
  br i1 %.not77, label %272, label %267

267:                                              ; preds = %263
  %268 = load ptr, ptr %6, align 8, !tbaa !5
  %269 = load ptr, ptr %7, align 8, !tbaa !5
  %270 = load ptr, ptr %54, align 8, !tbaa !5
  %271 = load i32, ptr %55, align 4, !tbaa !9
  call void @png_set_text(ptr noundef %268, ptr noundef %269, ptr noundef %270, i32 noundef %271) #9
  br label %272

272:                                              ; preds = %267, %263
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %55) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %54) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %56) #9
  %273 = load ptr, ptr %3, align 8, !tbaa !5
  %274 = load ptr, ptr %4, align 8, !tbaa !5
  %275 = call i64 @png_get_tIME(ptr noundef %273, ptr noundef %274, ptr noundef nonnull %56) #9
  %.not78 = icmp eq i64 %275, 0
  br i1 %.not78, label %285, label %276

276:                                              ; preds = %272
  %277 = load ptr, ptr %6, align 8, !tbaa !5
  %278 = load ptr, ptr %7, align 8, !tbaa !5
  %279 = load ptr, ptr %56, align 8, !tbaa !5
  call void @png_set_tIME(ptr noundef %277, ptr noundef %278, ptr noundef %279) #9
  %280 = load ptr, ptr %3, align 8, !tbaa !5
  %281 = load ptr, ptr %56, align 8, !tbaa !5
  %282 = call ptr @png_convert_to_rfc1123(ptr noundef %280, ptr noundef %281) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(30) @tIME_string, ptr noundef nonnull align 1 dereferenceable(30) %282, i64 30, i1 false)
  store i8 0, ptr getelementptr inbounds (i8, ptr @tIME_string, i64 29), align 1, !tbaa !15
  %283 = load i32, ptr @tIME_chunk_present, align 4, !tbaa !9
  %284 = add nsw i32 %283, 1
  store i32 %284, ptr @tIME_chunk_present, align 4, !tbaa !9
  br label %285

285:                                              ; preds = %276, %272
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %56) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %57) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %58) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %59) #9
  %286 = load ptr, ptr %3, align 8, !tbaa !5
  %287 = load ptr, ptr %4, align 8, !tbaa !5
  %288 = call i64 @png_get_tRNS(ptr noundef %286, ptr noundef %287, ptr noundef nonnull %57, ptr noundef nonnull %58, ptr noundef nonnull %59) #9
  %.not79 = icmp eq i64 %288, 0
  %.pre114 = load ptr, ptr %4, align 8, !tbaa !5
  br i1 %.not79, label %320, label %289

289:                                              ; preds = %285
  %290 = getelementptr inbounds i8, ptr %.pre114, i64 44
  %291 = load i8, ptr %290, align 4, !tbaa !16
  %292 = zext nneg i8 %291 to i32
  %293 = shl nuw i32 1, %292
  %294 = getelementptr inbounds i8, ptr %.pre114, i64 45
  %295 = load i8, ptr %294, align 1, !tbaa !23
  %.pre = load ptr, ptr %59, align 8, !tbaa !5
  switch i8 %295, label %.thread [
    i8 0, label %296
    i8 2, label %301
  ]

296:                                              ; preds = %289
  %297 = getelementptr inbounds i8, ptr %.pre, i64 8
  %298 = load i16, ptr %297, align 2, !tbaa !24
  %299 = zext i16 %298 to i32
  %300 = icmp slt i32 %293, %299
  br i1 %300, label %320, label %.thread

301:                                              ; preds = %289
  %302 = getelementptr inbounds i8, ptr %.pre, i64 2
  %303 = load i16, ptr %302, align 2, !tbaa !25
  %304 = zext i16 %303 to i32
  %305 = icmp slt i32 %293, %304
  br i1 %305, label %320, label %306

306:                                              ; preds = %301
  %307 = getelementptr inbounds i8, ptr %.pre, i64 4
  %308 = load i16, ptr %307, align 2, !tbaa !26
  %309 = zext i16 %308 to i32
  %310 = icmp ult i32 %293, %309
  br i1 %310, label %320, label %311

311:                                              ; preds = %306
  %312 = getelementptr inbounds i8, ptr %.pre, i64 6
  %313 = load i16, ptr %312, align 2, !tbaa !27
  %314 = zext i16 %313 to i32
  %315 = icmp ult i32 %293, %314
  br i1 %315, label %320, label %.thread

.thread:                                          ; preds = %289, %296, %311
  %316 = load ptr, ptr %6, align 8, !tbaa !5
  %317 = load ptr, ptr %7, align 8, !tbaa !5
  %318 = load ptr, ptr %57, align 8, !tbaa !5
  %319 = load i32, ptr %58, align 4, !tbaa !9
  call void @png_set_tRNS(ptr noundef %316, ptr noundef %317, ptr noundef %318, i32 noundef %319, ptr noundef %.pre) #9
  %.pre113 = load ptr, ptr %4, align 8, !tbaa !5
  br label %320

320:                                              ; preds = %296, %301, %306, %311, %.thread, %285
  %321 = phi ptr [ %.pre114, %296 ], [ %.pre114, %301 ], [ %.pre114, %306 ], [ %.pre114, %311 ], [ %.pre113, %.thread ], [ %.pre114, %285 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %59) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %58) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %57) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %60) #9
  %322 = load ptr, ptr %3, align 8, !tbaa !5
  %323 = call i64 @png_get_unknown_chunks(ptr noundef %322, ptr noundef %321, ptr noundef nonnull %60) #9
  %324 = trunc i64 %323 to i32
  %.not80 = icmp eq i32 %324, 0
  br i1 %.not80, label %.loopexit94, label %325

325:                                              ; preds = %320
  %326 = load ptr, ptr %6, align 8, !tbaa !5
  %327 = load ptr, ptr %7, align 8, !tbaa !5
  %328 = load ptr, ptr %60, align 8, !tbaa !5
  call void @png_set_unknown_chunks(ptr noundef %326, ptr noundef %327, ptr noundef %328, i32 noundef %324) #9
  %sext = shl i64 %323, 32
  %.not104 = icmp eq i64 %sext, 0
  br i1 %.not104, label %.loopexit94, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %325
  %329 = ashr exact i64 %sext, 32
  %umax = call i64 @llvm.umax.i64(i64 %329, i64 1)
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %.05896 = phi i64 [ %337, %.lr.ph ], [ 0, %.lr.ph.preheader ]
  %330 = load ptr, ptr %6, align 8, !tbaa !5
  %331 = load ptr, ptr %7, align 8, !tbaa !5
  %332 = trunc i64 %.05896 to i32
  %333 = load ptr, ptr %60, align 8, !tbaa !5
  %334 = getelementptr inbounds %struct.png_unknown_chunk_t, ptr %333, i64 %.05896, i32 3
  %335 = load i8, ptr %334, align 8, !tbaa !28
  %336 = zext i8 %335 to i32
  call void @png_set_unknown_chunk_location(ptr noundef %330, ptr noundef %331, i32 noundef %332, i32 noundef %336) #9
  %337 = add nuw i64 %.05896, 1
  %exitcond.not = icmp eq i64 %337, %umax
  br i1 %exitcond.not, label %.loopexit94, label %.lr.ph, !llvm.loop !30

.loopexit94:                                      ; preds = %.lr.ph, %325, %320
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %60) #9
  %338 = load ptr, ptr %6, align 8, !tbaa !5
  %339 = load ptr, ptr %7, align 8, !tbaa !5
  call void @png_write_info(ptr noundef %338, ptr noundef %339) #9
  %340 = load ptr, ptr %3, align 8, !tbaa !5
  %341 = load ptr, ptr %4, align 8, !tbaa !5
  %342 = call i64 @png_get_rowbytes(ptr noundef %340, ptr noundef %341) #9
  %343 = call ptr @png_malloc(ptr noundef %340, i64 noundef %342) #9
  store ptr %343, ptr %9, align 8, !tbaa !5
  %344 = load ptr, ptr %3, align 8, !tbaa !5
  %345 = call i32 @png_set_interlace_handling(ptr noundef %344) #9
  %346 = load ptr, ptr %6, align 8, !tbaa !5
  %347 = call i32 @png_set_interlace_handling(ptr noundef %346) #9
  %348 = icmp slt i32 %345, 1
  %349 = load i64, ptr %11, align 8
  %.not105 = icmp eq i64 %349, 0
  %or.cond = select i1 %348, i1 true, i1 %.not105
  br i1 %or.cond, label %._crit_edge100, label %.preheader93

.preheader93:                                     ; preds = %.loopexit94, %._crit_edge
  %350 = phi i64 [ %356, %._crit_edge ], [ 1, %.loopexit94 ]
  %.05499 = phi i32 [ %357, %._crit_edge ], [ 0, %.loopexit94 ]
  %.not106 = icmp eq i64 %350, 0
  br i1 %.not106, label %._crit_edge, label %.lr.ph98

.lr.ph98:                                         ; preds = %.preheader93, %.lr.ph98
  %.05397 = phi i64 [ %353, %.lr.ph98 ], [ 0, %.preheader93 ]
  %351 = load ptr, ptr %3, align 8, !tbaa !5
  call void @png_read_rows(ptr noundef %351, ptr noundef nonnull %9, ptr noundef null, i64 noundef 1) #9
  %352 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_write_rows(ptr noundef %352, ptr noundef nonnull %9, i64 noundef 1) #9
  %353 = add nuw i64 %.05397, 1
  %354 = load i64, ptr %11, align 8, !tbaa !11
  %355 = icmp ult i64 %353, %354
  br i1 %355, label %.lr.ph98, label %._crit_edge, !llvm.loop !32

._crit_edge:                                      ; preds = %.lr.ph98, %.preheader93
  %356 = phi i64 [ 0, %.preheader93 ], [ %354, %.lr.ph98 ]
  %357 = add nuw nsw i32 %.05499, 1
  %exitcond110.not = icmp eq i32 %357, %345
  br i1 %exitcond110.not, label %._crit_edge100, label %.preheader93, !llvm.loop !33

._crit_edge100:                                   ; preds = %._crit_edge, %.loopexit94
  %358 = load ptr, ptr %3, align 8, !tbaa !5
  %359 = load ptr, ptr %4, align 8, !tbaa !5
  call void @png_free_data(ptr noundef %358, ptr noundef %359, i64 noundef 512, i32 noundef -1) #9
  %360 = load ptr, ptr %6, align 8, !tbaa !5
  %361 = load ptr, ptr %7, align 8, !tbaa !5
  call void @png_free_data(ptr noundef %360, ptr noundef %361, i64 noundef 512, i32 noundef -1) #9
  %362 = load ptr, ptr %3, align 8, !tbaa !5
  %363 = load ptr, ptr %5, align 8, !tbaa !5
  call void @png_read_end(ptr noundef %362, ptr noundef %363) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %61) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %62) #9
  %364 = load ptr, ptr %3, align 8, !tbaa !5
  %365 = load ptr, ptr %5, align 8, !tbaa !5
  %366 = call i64 @png_get_text(ptr noundef %364, ptr noundef %365, ptr noundef nonnull %61, ptr noundef nonnull %62) #9
  %.not81 = icmp eq i64 %366, 0
  br i1 %.not81, label %372, label %367

367:                                              ; preds = %._crit_edge100
  %368 = load ptr, ptr %6, align 8, !tbaa !5
  %369 = load ptr, ptr %8, align 8, !tbaa !5
  %370 = load ptr, ptr %61, align 8, !tbaa !5
  %371 = load i32, ptr %62, align 4, !tbaa !9
  call void @png_set_text(ptr noundef %368, ptr noundef %369, ptr noundef %370, i32 noundef %371) #9
  br label %372

372:                                              ; preds = %367, %._crit_edge100
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %62) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %61) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %63) #9
  %373 = load ptr, ptr %3, align 8, !tbaa !5
  %374 = load ptr, ptr %5, align 8, !tbaa !5
  %375 = call i64 @png_get_tIME(ptr noundef %373, ptr noundef %374, ptr noundef nonnull %63) #9
  %.not82 = icmp eq i64 %375, 0
  br i1 %.not82, label %385, label %376

376:                                              ; preds = %372
  %377 = load ptr, ptr %6, align 8, !tbaa !5
  %378 = load ptr, ptr %8, align 8, !tbaa !5
  %379 = load ptr, ptr %63, align 8, !tbaa !5
  call void @png_set_tIME(ptr noundef %377, ptr noundef %378, ptr noundef %379) #9
  %380 = load ptr, ptr %3, align 8, !tbaa !5
  %381 = load ptr, ptr %63, align 8, !tbaa !5
  %382 = call ptr @png_convert_to_rfc1123(ptr noundef %380, ptr noundef %381) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(30) @tIME_string, ptr noundef nonnull align 1 dereferenceable(30) %382, i64 30, i1 false)
  store i8 0, ptr getelementptr inbounds (i8, ptr @tIME_string, i64 29), align 1, !tbaa !15
  %383 = load i32, ptr @tIME_chunk_present, align 4, !tbaa !9
  %384 = add nsw i32 %383, 1
  store i32 %384, ptr @tIME_chunk_present, align 4, !tbaa !9
  br label %385

385:                                              ; preds = %376, %372
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %63) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %64) #9
  %386 = load ptr, ptr %3, align 8, !tbaa !5
  %387 = load ptr, ptr %5, align 8, !tbaa !5
  %388 = call i64 @png_get_unknown_chunks(ptr noundef %386, ptr noundef %387, ptr noundef nonnull %64) #9
  %389 = trunc i64 %388 to i32
  %.not83 = icmp eq i32 %389, 0
  br i1 %.not83, label %.loopexit, label %390

390:                                              ; preds = %385
  %391 = load ptr, ptr %6, align 8, !tbaa !5
  %392 = load ptr, ptr %8, align 8, !tbaa !5
  %393 = load ptr, ptr %64, align 8, !tbaa !5
  call void @png_set_unknown_chunks(ptr noundef %391, ptr noundef %392, ptr noundef %393, i32 noundef %389) #9
  %sext84 = shl i64 %388, 32
  %.not107 = icmp eq i64 %sext84, 0
  br i1 %.not107, label %.loopexit, label %.lr.ph103.preheader

.lr.ph103.preheader:                              ; preds = %390
  %394 = ashr exact i64 %sext84, 32
  %umax111 = call i64 @llvm.umax.i64(i64 %394, i64 1)
  br label %.lr.ph103

.lr.ph103:                                        ; preds = %.lr.ph103.preheader, %.lr.ph103
  %.056101 = phi i64 [ %402, %.lr.ph103 ], [ 0, %.lr.ph103.preheader ]
  %395 = load ptr, ptr %6, align 8, !tbaa !5
  %396 = load ptr, ptr %8, align 8, !tbaa !5
  %397 = trunc i64 %.056101 to i32
  %398 = load ptr, ptr %64, align 8, !tbaa !5
  %399 = getelementptr inbounds %struct.png_unknown_chunk_t, ptr %398, i64 %.056101, i32 3
  %400 = load i8, ptr %399, align 8, !tbaa !28
  %401 = zext i8 %400 to i32
  call void @png_set_unknown_chunk_location(ptr noundef %395, ptr noundef %396, i32 noundef %397, i32 noundef %401) #9
  %402 = add nuw i64 %.056101, 1
  %exitcond112.not = icmp eq i64 %402, %umax111
  br i1 %exitcond112.not, label %.loopexit, label %.lr.ph103, !llvm.loop !35

.loopexit:                                        ; preds = %.lr.ph103, %390, %385
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %64) #9
  %403 = load ptr, ptr %6, align 8, !tbaa !5
  %404 = load ptr, ptr %8, align 8, !tbaa !5
  call void @png_write_end(ptr noundef %403, ptr noundef %404) #9
  %405 = load i32, ptr @verbose, align 4, !tbaa !9
  %.not85 = icmp eq i32 %405, 0
  br i1 %.not85, label %415, label %406

406:                                              ; preds = %.loopexit
  %407 = load ptr, ptr %6, align 8, !tbaa !5
  %408 = load ptr, ptr %7, align 8, !tbaa !5
  %409 = call i64 @png_get_image_width(ptr noundef %407, ptr noundef %408) #9
  %410 = load ptr, ptr %6, align 8, !tbaa !5
  %411 = load ptr, ptr %7, align 8, !tbaa !5
  %412 = call i64 @png_get_image_height(ptr noundef %410, ptr noundef %411) #9
  %413 = load ptr, ptr @stdout, align 8, !tbaa !5
  %414 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %413, ptr noundef nonnull @.str.11, i64 noundef %409, i64 noundef %412) #9
  br label %415

415:                                              ; preds = %406, %.loopexit
  %416 = load ptr, ptr %3, align 8, !tbaa !5
  %417 = load ptr, ptr %9, align 8, !tbaa !5
  call void @png_free(ptr noundef %416, ptr noundef %417) #9
  store ptr null, ptr %9, align 8, !tbaa !5
  call void @png_destroy_read_struct(ptr noundef nonnull %3, ptr noundef nonnull %4, ptr noundef nonnull %5) #9
  %418 = load ptr, ptr %6, align 8, !tbaa !5
  call void @png_destroy_info_struct(ptr noundef %418, ptr noundef nonnull %8) #9
  call void @png_destroy_write_struct(ptr noundef nonnull %6, ptr noundef nonnull %7) #9
  %419 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %420 = call i32 @fclose(ptr noundef %419)
  %421 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %422 = call i32 @fclose(ptr noundef %421)
  %423 = call noalias ptr @fopen(ptr noundef %0, ptr noundef nonnull @.str.4)
  store ptr %423, ptr @test_one_file.fpin, align 8, !tbaa !5
  %424 = icmp eq ptr %423, null
  br i1 %424, label %425, label %428

425:                                              ; preds = %415
  %426 = load ptr, ptr @stdout, align 8, !tbaa !5
  %427 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %426, ptr noundef nonnull @.str.12, ptr noundef %0) #9
  br label %.thread89

428:                                              ; preds = %415
  %429 = call noalias ptr @fopen(ptr noundef %1, ptr noundef nonnull @.str.4)
  store ptr %429, ptr @test_one_file.fpout, align 8, !tbaa !5
  %430 = icmp eq ptr %429, null
  br i1 %430, label %431, label %.preheader

431:                                              ; preds = %428
  %432 = load ptr, ptr @stdout, align 8, !tbaa !5
  %433 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %432, ptr noundef nonnull @.str.12, ptr noundef %1) #9
  %434 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %435 = call i32 @fclose(ptr noundef %434)
  br label %.thread89

.preheader:                                       ; preds = %428, %458
  %436 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %437 = call i64 @fread(ptr noundef nonnull %14, i64 noundef 1, i64 noundef 1, ptr noundef %436)
  %438 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %439 = call i64 @fread(ptr noundef nonnull %15, i64 noundef 1, i64 noundef 1, ptr noundef %438)
  %.not86 = icmp eq i64 %437, %439
  br i1 %.not86, label %457, label %440

440:                                              ; preds = %.preheader
  %441 = load ptr, ptr @stdout, align 8, !tbaa !5
  %442 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %441, ptr noundef nonnull @.str.13, ptr noundef %0, ptr noundef %1) #9
  %443 = load i32, ptr @wrote_question, align 4, !tbaa !9
  %444 = icmp eq i32 %443, 0
  br i1 %444, label %445, label %452

445:                                              ; preds = %440
  %446 = load ptr, ptr @stdout, align 8, !tbaa !5
  %447 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %446, ptr noundef nonnull @.str.14, ptr noundef %0, i32 noundef 8192) #9
  %448 = load ptr, ptr @stdout, align 8, !tbaa !5
  %449 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %448, ptr noundef nonnull @.str.15) #9
  %450 = load ptr, ptr @stdout, align 8, !tbaa !5
  %451 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %450, ptr noundef nonnull @.str.16, ptr noundef nonnull @.str.17) #9
  store i32 1, ptr @wrote_question, align 4, !tbaa !9
  br label %452

452:                                              ; preds = %445, %440
  %453 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %454 = call i32 @fclose(ptr noundef %453)
  %455 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %456 = call i32 @fclose(ptr noundef %455)
  br label %.thread89

457:                                              ; preds = %.preheader
  %.not87 = icmp eq i64 %437, 0
  br i1 %.not87, label %476, label %458

458:                                              ; preds = %457
  %bcmp = call i32 @bcmp(ptr nonnull %14, ptr nonnull %15, i64 %437)
  %.not88 = icmp eq i32 %bcmp, 0
  br i1 %.not88, label %.preheader, label %459

459:                                              ; preds = %458
  %460 = load ptr, ptr @stdout, align 8, !tbaa !5
  %461 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %460, ptr noundef nonnull @.str.18, ptr noundef %0, ptr noundef %1) #9
  %462 = load i32, ptr @wrote_question, align 4, !tbaa !9
  %463 = icmp eq i32 %462, 0
  br i1 %463, label %464, label %471

464:                                              ; preds = %459
  %465 = load ptr, ptr @stdout, align 8, !tbaa !5
  %466 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %465, ptr noundef nonnull @.str.14, ptr noundef %0, i32 noundef 8192) #9
  %467 = load ptr, ptr @stdout, align 8, !tbaa !5
  %468 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %467, ptr noundef nonnull @.str.15) #9
  %469 = load ptr, ptr @stdout, align 8, !tbaa !5
  %470 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %469, ptr noundef nonnull @.str.16, ptr noundef nonnull @.str.17) #9
  store i32 1, ptr @wrote_question, align 4, !tbaa !9
  br label %471

471:                                              ; preds = %464, %459
  %472 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %473 = call i32 @fclose(ptr noundef %472)
  %474 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %475 = call i32 @fclose(ptr noundef %474)
  br label %.thread89

476:                                              ; preds = %457
  %477 = load ptr, ptr @test_one_file.fpin, align 8, !tbaa !5
  %478 = call i32 @fclose(ptr noundef %477)
  %479 = load ptr, ptr @test_one_file.fpout, align 8, !tbaa !5
  %480 = call i32 @fclose(ptr noundef %479)
  br label %.thread89

.thread89:                                        ; preds = %471, %452, %476, %431, %425, %104, %91, %73, %67
  %.2 = phi i32 [ 1, %67 ], [ 1, %73 ], [ 1, %91 ], [ 1, %104 ], [ 1, %425 ], [ 1, %431 ], [ 0, %476 ], [ 0, %452 ], [ 0, %471 ]
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %15) #9
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %13) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #9
  ret i32 %.2
}

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

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

declare ptr @png_create_read_struct(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_error_fn(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
declare hidden void @pngtest_error(ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare hidden void @pngtest_warning(ptr noundef, ptr noundef) #0

declare ptr @png_create_write_struct(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare ptr @png_create_info_struct(ptr noundef) local_unnamed_addr #3

; Function Attrs: nounwind returns_twice
declare i32 @_setjmp(ptr noundef) local_unnamed_addr #4

declare void @png_free(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_destroy_read_struct(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_destroy_info_struct(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_destroy_write_struct(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_init_io(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_write_status_fn(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_read_status_fn(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_read_user_transform_fn(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_write_user_transform_fn(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_keep_unknown_chunks(ptr noundef, i32 noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

declare void @png_read_info(ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_IHDR(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_IHDR(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #3

declare i64 @png_get_cHRM_fixed(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_cHRM_fixed(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef) local_unnamed_addr #3

declare i64 @png_get_gAMA_fixed(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_gAMA_fixed(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

declare i64 @png_get_iCCP(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_iCCP(ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

declare i64 @png_get_sRGB(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_sRGB(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

declare i64 @png_get_PLTE(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_PLTE(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

declare i64 @png_get_bKGD(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_bKGD(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_hIST(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_hIST(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_oFFs(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_oFFs(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef) local_unnamed_addr #3

declare i64 @png_get_pCAL(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_pCAL(ptr noundef, ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_pHYs(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_pHYs(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef) local_unnamed_addr #3

declare i64 @png_get_sBIT(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_sBIT(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_sCAL(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_sCAL(ptr noundef, ptr noundef, i32 noundef, double noundef, double noundef) local_unnamed_addr #3

declare i64 @png_get_text(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_text(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

declare i64 @png_get_tIME(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_tIME(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare ptr @png_convert_to_rfc1123(ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #5

declare i64 @png_get_tRNS(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_tRNS(ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_unknown_chunks(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_set_unknown_chunks(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

declare void @png_set_unknown_chunk_location(ptr noundef, ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #3

declare void @png_write_info(ptr noundef, ptr noundef) local_unnamed_addr #3

declare ptr @png_malloc(ptr noundef, i64 noundef) local_unnamed_addr #3

declare i64 @png_get_rowbytes(ptr noundef, ptr noundef) local_unnamed_addr #3

declare i32 @png_set_interlace_handling(ptr noundef) local_unnamed_addr #3

declare void @png_read_rows(ptr noundef, ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

declare void @png_write_rows(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

declare void @png_free_data(ptr noundef, ptr noundef, i64 noundef, i32 noundef) local_unnamed_addr #3

declare void @png_read_end(ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @png_write_end(ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_image_width(ptr noundef, ptr noundef) local_unnamed_addr #3

declare i64 @png_get_image_height(ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef i64 @fread(ptr nocapture noundef, i64 noundef, i64 noundef, ptr nocapture noundef) local_unnamed_addr #1

; Function Attrs: nofree nounwind willreturn memory(argmem: read)
declare i32 @bcmp(ptr nocapture, ptr nocapture, i64) local_unnamed_addr #6

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #7

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.umax.i64(i64, i64) #8

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { 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 #2 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { "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 = { nounwind returns_twice "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 nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { nofree nounwind willreturn memory(argmem: read) }
attributes #7 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #8 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #9 = { nounwind }
attributes #10 = { nounwind returns_twice }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"double", !7, i64 0}
!15 = !{!7, !7, i64 0}
!16 = !{!17, !7, i64 44}
!17 = !{!"png_info_struct", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !6, i64 32, !18, i64 40, !18, i64 42, !7, i64 44, !7, i64 45, !7, i64 46, !7, i64 47, !7, i64 48, !7, i64 49, !7, i64 50, !7, i64 51, !7, i64 52, !19, i64 60, !7, i64 64, !10, i64 68, !10, i64 72, !6, i64 80, !20, i64 88, !21, i64 96, !6, i64 104, !22, i64 112, !22, i64 122, !12, i64 136, !12, i64 144, !7, i64 152, !12, i64 160, !12, i64 168, !7, i64 176, !6, i64 184, !19, i64 192, !19, i64 196, !19, i64 200, !19, i64 204, !19, i64 208, !19, i64 212, !19, i64 216, !19, i64 220, !6, i64 224, !12, i64 232, !12, i64 240, !6, i64 248, !6, i64 256, !7, i64 264, !7, i64 265, !12, i64 272, !6, i64 280, !12, i64 288, !6, i64 296, !6, i64 304, !12, i64 312, !7, i64 320, !6, i64 328, !12, i64 336, !7, i64 344, !14, i64 352, !14, i64 360, !6, i64 368, !6, i64 376, !6, i64 384, !12, i64 392, !12, i64 400, !12, i64 408, !12, i64 416, !12, i64 424, !12, i64 432, !12, i64 440, !12, i64 448, !12, i64 456}
!18 = !{!"short", !7, i64 0}
!19 = !{!"float", !7, i64 0}
!20 = !{!"png_time_struct", !18, i64 0, !7, i64 2, !7, i64 3, !7, i64 4, !7, i64 5, !7, i64 6}
!21 = !{!"png_color_8_struct", !7, i64 0, !7, i64 1, !7, i64 2, !7, i64 3, !7, i64 4}
!22 = !{!"png_color_16_struct", !7, i64 0, !18, i64 2, !18, i64 4, !18, i64 6, !18, i64 8}
!23 = !{!17, !7, i64 45}
!24 = !{!22, !18, i64 8}
!25 = !{!22, !18, i64 2}
!26 = !{!22, !18, i64 4}
!27 = !{!22, !18, i64 6}
!28 = !{!29, !7, i64 24}
!29 = !{!"png_unknown_chunk_t", !7, i64 0, !6, i64 8, !12, i64 16, !7, i64 24}
!30 = distinct !{!30, !31}
!31 = !{!"llvm.loop.mustprogress"}
!32 = distinct !{!32, !31}
!33 = distinct !{!33, !31, !34}
!34 = !{!"llvm.loop.unswitch.partial.disable"}
!35 = distinct !{!35, !31}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimpleLoopUnswitchPass,SimplifyCFGPass