; LLVM IR from Discngine/fpocket :: src (dpocket)

; 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.s_dparams = type { ptr, ptr, ptr, ptr, ptr, float, i32, i32, ptr }

@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [454 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@stdout = external global ptr, align 8
@.str.4 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [40 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @dpocket(ptr noundef %0) #0 {
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca [3 x ptr], align 16
  store ptr %0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr %5) #4
  %6 = load ptr, ptr %2, align 8, !tbaa !5
  %7 = icmp ne ptr %6, null
  br i1 %7, label %8, label %167

8:                                                ; preds = %1
  %9 = load ptr, ptr %2, align 8, !tbaa !5
  %10 = getelementptr inbounds %struct.s_dparams, ptr %9, i32 0, i32 2
  %11 = load ptr, ptr %10, align 8, !tbaa !9
  %12 = call noalias ptr @fopen(ptr noundef %11, ptr noundef @.str)
  %13 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 0
  store ptr %12, ptr %13, align 16, !tbaa !5
  %14 = load ptr, ptr %2, align 8, !tbaa !5
  %15 = getelementptr inbounds %struct.s_dparams, ptr %14, i32 0, i32 3
  %16 = load ptr, ptr %15, align 8, !tbaa !13
  %17 = call noalias ptr @fopen(ptr noundef %16, ptr noundef @.str)
  %18 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 1
  store ptr %17, ptr %18, align 8, !tbaa !5
  %19 = load ptr, ptr %2, align 8, !tbaa !5
  %20 = getelementptr inbounds %struct.s_dparams, ptr %19, i32 0, i32 4
  %21 = load ptr, ptr %20, align 8, !tbaa !14
  %22 = call noalias ptr @fopen(ptr noundef %21, ptr noundef @.str)
  %23 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 2
  store ptr %22, ptr %23, align 16, !tbaa !5
  %24 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 0
  %25 = load ptr, ptr %24, align 16, !tbaa !5
  %26 = icmp ne ptr %25, null
  br i1 %26, label %27, label %138

27:                                               ; preds = %8
  %28 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 1
  %29 = load ptr, ptr %28, align 8, !tbaa !5
  %30 = icmp ne ptr %29, null
  br i1 %30, label %31, label %138

31:                                               ; preds = %27
  %32 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 2
  %33 = load ptr, ptr %32, align 16, !tbaa !5
  %34 = icmp ne ptr %33, null
  br i1 %34, label %35, label %138

35:                                               ; preds = %31
  store i32 0, ptr %3, align 4, !tbaa !15
  br label %36

36:                                               ; preds = %65, %35
  %37 = load i32, ptr %3, align 4, !tbaa !15
  %38 = icmp slt i32 %37, 3
  br i1 %38, label %39, label %68

39:                                               ; preds = %36
  %40 = load i32, ptr %3, align 4, !tbaa !15
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 %41
  %43 = load ptr, ptr %42, align 8, !tbaa !5
  %44 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %43, ptr noundef @.str.1) #4
  store i32 0, ptr %4, align 4, !tbaa !15
  br label %45

45:                                               ; preds = %56, %39
  %46 = load i32, ptr %4, align 4, !tbaa !15
  %47 = icmp slt i32 %46, 20
  br i1 %47, label %48, label %59

48:                                               ; preds = %45
  %49 = load i32, ptr %3, align 4, !tbaa !15
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 %50
  %52 = load ptr, ptr %51, align 8, !tbaa !5
  %53 = load i32, ptr %4, align 4, !tbaa !15
  %54 = call ptr @get_aa_name3(i32 noundef %53)
  %55 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %52, ptr noundef @.str.2, ptr noundef %54) #4
  br label %56

56:                                               ; preds = %48
  %57 = load i32, ptr %4, align 4, !tbaa !15
  %58 = add nsw i32 %57, 1
  store i32 %58, ptr %4, align 4, !tbaa !15
  br label %45, !llvm.loop !16

59:                                               ; preds = %45
  %60 = load i32, ptr %3, align 4, !tbaa !15
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 %61
  %63 = load ptr, ptr %62, align 8, !tbaa !5
  %64 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %63, ptr noundef @.str.3) #4
  br label %65

65:                                               ; preds = %59
  %66 = load i32, ptr %3, align 4, !tbaa !15
  %67 = add nsw i32 %66, 1
  store i32 %67, ptr %3, align 4, !tbaa !15
  br label %36, !llvm.loop !18

68:                                               ; preds = %36
  store i32 0, ptr %3, align 4, !tbaa !15
  br label %69

69:                                               ; preds = %121, %68
  %70 = load i32, ptr %3, align 4, !tbaa !15
  %71 = load ptr, ptr %2, align 8, !tbaa !5
  %72 = getelementptr inbounds %struct.s_dparams, ptr %71, i32 0, i32 6
  %73 = load i32, ptr %72, align 4, !tbaa !19
  %74 = icmp slt i32 %70, %73
  br i1 %74, label %75, label %124

75:                                               ; preds = %69
  %76 = load ptr, ptr @stdout, align 8, !tbaa !5
  %77 = load i32, ptr %3, align 4, !tbaa !15
  %78 = add nsw i32 %77, 1
  %79 = load ptr, ptr %2, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.s_dparams, ptr %79, i32 0, i32 6
  %81 = load i32, ptr %80, align 4, !tbaa !19
  %82 = load ptr, ptr %2, align 8, !tbaa !5
  %83 = getelementptr inbounds %struct.s_dparams, ptr %82, i32 0, i32 0
  %84 = load ptr, ptr %83, align 8, !tbaa !20
  %85 = load i32, ptr %3, align 4, !tbaa !15
  %86 = sext i32 %85 to i64
  %87 = getelementptr inbounds ptr, ptr %84, i64 %86
  %88 = load ptr, ptr %87, align 8, !tbaa !5
  %89 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %76, ptr noundef @.str.4, i32 noundef %78, i32 noundef %81, ptr noundef %88) #4
  call void @print_number_of_objects_in_memory()
  %90 = load ptr, ptr %2, align 8, !tbaa !5
  %91 = getelementptr inbounds %struct.s_dparams, ptr %90, i32 0, i32 0
  %92 = load ptr, ptr %91, align 8, !tbaa !20
  %93 = load i32, ptr %3, align 4, !tbaa !15
  %94 = sext i32 %93 to i64
  %95 = getelementptr inbounds ptr, ptr %92, i64 %94
  %96 = load ptr, ptr %95, align 8, !tbaa !5
  %97 = load ptr, ptr %2, align 8, !tbaa !5
  %98 = getelementptr inbounds %struct.s_dparams, ptr %97, i32 0, i32 1
  %99 = load ptr, ptr %98, align 8, !tbaa !21
  %100 = load i32, ptr %3, align 4, !tbaa !15
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds ptr, ptr %99, i64 %101
  %103 = load ptr, ptr %102, align 8, !tbaa !5
  %104 = load ptr, ptr %2, align 8, !tbaa !5
  %105 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 0
  call void @desc_pocket(ptr noundef %96, ptr noundef %103, ptr noundef %104, ptr noundef %105)
  call void @print_number_of_objects_in_memory()
  %106 = load i32, ptr %3, align 4, !tbaa !15
  %107 = load ptr, ptr %2, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.s_dparams, ptr %107, i32 0, i32 6
  %109 = load i32, ptr %108, align 4, !tbaa !19
  %110 = sub nsw i32 %109, 1
  %111 = icmp eq i32 %106, %110
  br i1 %111, label %112, label %115

112:                                              ; preds = %75
  %113 = load ptr, ptr @stdout, align 8, !tbaa !5
  %114 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %113, ptr noundef @.str.3) #4
  br label %118

115:                                              ; preds = %75
  %116 = load ptr, ptr @stdout, align 8, !tbaa !5
  %117 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %116, ptr noundef @.str.5) #4
  br label %118

118:                                              ; preds = %115, %112
  %119 = load ptr, ptr @stdout, align 8, !tbaa !5
  %120 = call i32 @fflush(ptr noundef %119)
  br label %121

121:                                              ; preds = %118
  %122 = load i32, ptr %3, align 4, !tbaa !15
  %123 = add nsw i32 %122, 1
  store i32 %123, ptr %3, align 4, !tbaa !15
  br label %69, !llvm.loop !22

124:                                              ; preds = %69
  store i32 0, ptr %3, align 4, !tbaa !15
  br label %125

125:                                              ; preds = %134, %124
  %126 = load i32, ptr %3, align 4, !tbaa !15
  %127 = icmp slt i32 %126, 3
  br i1 %127, label %128, label %137

128:                                              ; preds = %125
  %129 = load i32, ptr %3, align 4, !tbaa !15
  %130 = sext i32 %129 to i64
  %131 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 %130
  %132 = load ptr, ptr %131, align 8, !tbaa !5
  %133 = call i32 @fclose(ptr noundef %132)
  br label %134

134:                                              ; preds = %128
  %135 = load i32, ptr %3, align 4, !tbaa !15
  %136 = add nsw i32 %135, 1
  store i32 %136, ptr %3, align 4, !tbaa !15
  br label %125, !llvm.loop !23

137:                                              ; preds = %125
  br label %166

138:                                              ; preds = %31, %27, %8
  %139 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 0
  %140 = load ptr, ptr %139, align 16, !tbaa !5
  %141 = icmp ne ptr %140, null
  br i1 %141, label %148, label %142

142:                                              ; preds = %138
  %143 = load ptr, ptr @stdout, align 8, !tbaa !5
  %144 = load ptr, ptr %2, align 8, !tbaa !5
  %145 = getelementptr inbounds %struct.s_dparams, ptr %144, i32 0, i32 2
  %146 = load ptr, ptr %145, align 8, !tbaa !9
  %147 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %143, ptr noundef @.str.6, ptr noundef %146) #4
  br label %165

148:                                              ; preds = %138
  %149 = getelementptr inbounds [3 x ptr], ptr %5, i64 0, i64 1
  %150 = load ptr, ptr %149, align 8, !tbaa !5
  %151 = icmp ne ptr %150, null
  br i1 %151, label %158, label %152

152:                                              ; preds = %148
  %153 = load ptr, ptr @stdout, align 8, !tbaa !5
  %154 = load ptr, ptr %2, align 8, !tbaa !5
  %155 = getelementptr inbounds %struct.s_dparams, ptr %154, i32 0, i32 3
  %156 = load ptr, ptr %155, align 8, !tbaa !13
  %157 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %153, ptr noundef @.str.6, ptr noundef %156) #4
  br label %164

158:                                              ; preds = %148
  %159 = load ptr, ptr @stdout, align 8, !tbaa !5
  %160 = load ptr, ptr %2, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.s_dparams, ptr %160, i32 0, i32 4
  %162 = load ptr, ptr %161, align 8, !tbaa !14
  %163 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %159, ptr noundef @.str.6, ptr noundef %162) #4
  br label %164

164:                                              ; preds = %158, %152
  br label %165

165:                                              ; preds = %164, %142
  br label %166

166:                                              ; preds = %165, %137
  br label %167

167:                                              ; preds = %166, %1
  call void @llvm.lifetime.end.p0(i64 24, ptr %5) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #4
  ret void
}

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

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

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

declare ptr @get_aa_name3(i32 noundef) #2

declare void @print_number_of_objects_in_memory() #2

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

declare i32 @fflush(ptr noundef) #2

declare i32 @fclose(ptr noundef) #2

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

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

!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, !6, i64 16}
!10 = !{!"s_dparams", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !11, i64 40, !12, i64 44, !12, i64 48, !6, i64 56}
!11 = !{!"float", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!10, !6, i64 24}
!14 = !{!10, !6, i64 32}
!15 = !{!12, !12, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17}
!19 = !{!10, !12, i64 44}
!20 = !{!10, !6, i64 0}
!21 = !{!10, !6, i64 8}
!22 = distinct !{!22, !17}
!23 = distinct !{!23, !17}


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

@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [454 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@stdout = external local_unnamed_addr global ptr, align 8
@.str.4 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [40 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @dpocket(ptr noundef %0) local_unnamed_addr #0 {
  %2 = alloca [3 x ptr], align 16
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %2) #4
  %.not = icmp eq ptr %0, null
  br i1 %.not, label %.loopexit, label %3

3:                                                ; preds = %1
  %4 = getelementptr inbounds i8, ptr %0, i64 16
  %5 = load ptr, ptr %4, align 8, !tbaa !5
  %6 = tail call noalias ptr @fopen(ptr noundef %5, ptr noundef nonnull @.str)
  store ptr %6, ptr %2, align 16, !tbaa !12
  %7 = getelementptr inbounds i8, ptr %0, i64 24
  %8 = load ptr, ptr %7, align 8, !tbaa !13
  %9 = tail call noalias ptr @fopen(ptr noundef %8, ptr noundef nonnull @.str)
  %10 = getelementptr inbounds i8, ptr %2, i64 8
  store ptr %9, ptr %10, align 8, !tbaa !12
  %11 = getelementptr inbounds i8, ptr %0, i64 32
  %12 = load ptr, ptr %11, align 8, !tbaa !14
  %13 = tail call noalias ptr @fopen(ptr noundef %12, ptr noundef nonnull @.str)
  %14 = getelementptr inbounds i8, ptr %2, i64 16
  store ptr %13, ptr %14, align 16, !tbaa !12
  %15 = icmp ne ptr %6, null
  %16 = icmp ne ptr %9, null
  %17 = icmp ne ptr %13, null
  %18 = and i1 %16, %17
  %or.cond5 = and i1 %18, %15
  br i1 %or.cond5, label %.preheader40, label %98

.preheader39:                                     ; preds = %.preheader40
  %19 = getelementptr inbounds i8, ptr %0, i64 44
  %20 = load i32, ptr %19, align 4, !tbaa !15
  %21 = icmp sgt i32 %20, 0
  br i1 %21, label %.lr.ph, label %.preheader

.lr.ph:                                           ; preds = %.preheader39
  %22 = getelementptr inbounds i8, ptr %0, i64 8
  br label %73

.preheader40:                                     ; preds = %3, %.preheader40
  %indvars.iv = phi i64 [ %indvars.iv.next, %.preheader40 ], [ 0, %3 ]
  %23 = getelementptr inbounds [3 x ptr], ptr %2, i64 0, i64 %indvars.iv
  %24 = load ptr, ptr %23, align 8, !tbaa !12
  %25 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.1) #4
  %26 = tail call ptr @get_aa_name3(i32 noundef 0) #4
  %27 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %26) #4
  %28 = tail call ptr @get_aa_name3(i32 noundef 1) #4
  %29 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %28) #4
  %30 = tail call ptr @get_aa_name3(i32 noundef 2) #4
  %31 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %30) #4
  %32 = tail call ptr @get_aa_name3(i32 noundef 3) #4
  %33 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %32) #4
  %34 = tail call ptr @get_aa_name3(i32 noundef 4) #4
  %35 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %34) #4
  %36 = tail call ptr @get_aa_name3(i32 noundef 5) #4
  %37 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %36) #4
  %38 = tail call ptr @get_aa_name3(i32 noundef 6) #4
  %39 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %38) #4
  %40 = tail call ptr @get_aa_name3(i32 noundef 7) #4
  %41 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %40) #4
  %42 = tail call ptr @get_aa_name3(i32 noundef 8) #4
  %43 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %42) #4
  %44 = tail call ptr @get_aa_name3(i32 noundef 9) #4
  %45 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %44) #4
  %46 = tail call ptr @get_aa_name3(i32 noundef 10) #4
  %47 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %46) #4
  %48 = tail call ptr @get_aa_name3(i32 noundef 11) #4
  %49 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %48) #4
  %50 = tail call ptr @get_aa_name3(i32 noundef 12) #4
  %51 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %50) #4
  %52 = tail call ptr @get_aa_name3(i32 noundef 13) #4
  %53 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %52) #4
  %54 = tail call ptr @get_aa_name3(i32 noundef 14) #4
  %55 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %54) #4
  %56 = tail call ptr @get_aa_name3(i32 noundef 15) #4
  %57 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %56) #4
  %58 = tail call ptr @get_aa_name3(i32 noundef 16) #4
  %59 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %58) #4
  %60 = tail call ptr @get_aa_name3(i32 noundef 17) #4
  %61 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %60) #4
  %62 = tail call ptr @get_aa_name3(i32 noundef 18) #4
  %63 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %62) #4
  %64 = tail call ptr @get_aa_name3(i32 noundef 19) #4
  %65 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.2, ptr noundef %64) #4
  %66 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.3) #4
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 3
  br i1 %exitcond.not, label %.preheader39, label %.preheader40, !llvm.loop !16

.preheader.loopexit:                              ; preds = %73
  %.pre = load ptr, ptr %2, align 16, !tbaa !12
  br label %.preheader

.preheader:                                       ; preds = %.preheader.loopexit, %.preheader39
  %67 = phi ptr [ %.pre, %.preheader.loopexit ], [ %6, %.preheader39 ]
  %68 = call i32 @fclose(ptr noundef %67)
  %69 = load ptr, ptr %10, align 8, !tbaa !12
  %70 = call i32 @fclose(ptr noundef %69)
  %71 = load ptr, ptr %14, align 16, !tbaa !12
  %72 = call i32 @fclose(ptr noundef %71)
  br label %.loopexit

73:                                               ; preds = %.lr.ph, %73
  %indvars.iv46 = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next47, %73 ]
  %74 = phi i32 [ %20, %.lr.ph ], [ %95, %73 ]
  %75 = load ptr, ptr @stdout, align 8, !tbaa !12
  %indvars.iv.next47 = add nuw nsw i64 %indvars.iv46, 1
  %76 = load ptr, ptr %0, align 8, !tbaa !18
  %77 = getelementptr inbounds ptr, ptr %76, i64 %indvars.iv46
  %78 = load ptr, ptr %77, align 8, !tbaa !12
  %79 = trunc nuw nsw i64 %indvars.iv.next47 to i32
  %80 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %75, ptr noundef nonnull @.str.4, i32 noundef %79, i32 noundef %74, ptr noundef %78) #4
  call void @print_number_of_objects_in_memory() #4
  %81 = load ptr, ptr %0, align 8, !tbaa !18
  %82 = getelementptr inbounds ptr, ptr %81, i64 %indvars.iv46
  %83 = load ptr, ptr %82, align 8, !tbaa !12
  %84 = load ptr, ptr %22, align 8, !tbaa !19
  %85 = getelementptr inbounds ptr, ptr %84, i64 %indvars.iv46
  %86 = load ptr, ptr %85, align 8, !tbaa !12
  call void @desc_pocket(ptr noundef %83, ptr noundef %86, ptr noundef nonnull %0, ptr noundef nonnull %2)
  call void @print_number_of_objects_in_memory() #4
  %87 = load i32, ptr %19, align 4, !tbaa !15
  %88 = add nsw i32 %87, -1
  %89 = zext i32 %88 to i64
  %90 = icmp eq i64 %indvars.iv46, %89
  %91 = load ptr, ptr @stdout, align 8, !tbaa !12
  %.str.3..str.5 = select i1 %90, ptr @.str.3, ptr @.str.5
  %92 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %91, ptr noundef nonnull %.str.3..str.5) #4
  %93 = load ptr, ptr @stdout, align 8, !tbaa !12
  %94 = call i32 @fflush(ptr noundef %93)
  %95 = load i32, ptr %19, align 4, !tbaa !15
  %96 = sext i32 %95 to i64
  %97 = icmp slt i64 %indvars.iv.next47, %96
  br i1 %97, label %73, label %.preheader.loopexit, !llvm.loop !20

98:                                               ; preds = %3
  %99 = load ptr, ptr @stdout, align 8, !tbaa !12
  br i1 %15, label %103, label %100

100:                                              ; preds = %98
  %101 = load ptr, ptr %4, align 8, !tbaa !5
  %102 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %99, ptr noundef nonnull @.str.6, ptr noundef %101) #4
  br label %.loopexit

103:                                              ; preds = %98
  br i1 %16, label %107, label %104

104:                                              ; preds = %103
  %105 = load ptr, ptr %7, align 8, !tbaa !13
  %106 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %99, ptr noundef nonnull @.str.6, ptr noundef %105) #4
  br label %.loopexit

107:                                              ; preds = %103
  %108 = load ptr, ptr %11, align 8, !tbaa !14
  %109 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %99, ptr noundef nonnull @.str.6, ptr noundef %108) #4
  br label %.loopexit

.loopexit:                                        ; preds = %.preheader, %104, %107, %100, %1
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #4
  ret void
}

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

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

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

declare ptr @get_aa_name3(i32 noundef) local_unnamed_addr #3

declare void @print_number_of_objects_in_memory() local_unnamed_addr #3

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

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

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

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

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 16}
!6 = !{!"s_dparams", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !10, i64 40, !11, i64 44, !11, i64 48, !7, i64 56}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"float", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!7, !7, i64 0}
!13 = !{!6, !7, i64 24}
!14 = !{!6, !7, i64 32}
!15 = !{!6, !11, i64 44}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = !{!6, !7, i64 0}
!19 = !{!6, !7, i64 8}
!20 = distinct !{!20, !17}


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