; LLVM IR from intuitive-robots/mdt_policy :: pyhash-0.9.3/src/smhasher/KeysetTest.ll (Z14TwoBytesKeygeniR11KeyCallback)

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

@.str.8 = external hidden unnamed_addr constant [55 x i8], align 1

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z14TwoBytesKeygeniR11KeyCallback(i32 noundef %0, ptr noundef nonnull align 8 dereferenceable(12) %1) #3 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca [256 x i8], align 16
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  store i32 %0, ptr %3, align 4, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #4
  store i32 0, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #4
  store i32 2, ptr %6, align 4, !tbaa !5
  br label %18

18:                                               ; preds = %29, %2
  %19 = load i32, ptr %6, align 4, !tbaa !5
  %20 = load i32, ptr %3, align 4, !tbaa !5
  %21 = icmp sle i32 %19, %20
  br i1 %21, label %23, label %22

22:                                               ; preds = %18
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #4
  br label %32

23:                                               ; preds = %18
  %24 = load i32, ptr %6, align 4, !tbaa !5
  %25 = call noundef double @_Z7chooseKii(i32 noundef %24, i32 noundef 2)
  %26 = fptosi double %25 to i32
  %27 = load i32, ptr %5, align 4, !tbaa !5
  %28 = add nsw i32 %27, %26
  store i32 %28, ptr %5, align 4, !tbaa !5
  br label %29

29:                                               ; preds = %23
  %30 = load i32, ptr %6, align 4, !tbaa !5
  %31 = add nsw i32 %30, 1
  store i32 %31, ptr %6, align 4, !tbaa !5
  br label %18, !llvm.loop !11

32:                                               ; preds = %22
  %33 = load i32, ptr %5, align 4, !tbaa !5
  %34 = mul nsw i32 %33, 65025
  store i32 %34, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #4
  store i32 2, ptr %7, align 4, !tbaa !5
  br label %35

35:                                               ; preds = %45, %32
  %36 = load i32, ptr %7, align 4, !tbaa !5
  %37 = load i32, ptr %3, align 4, !tbaa !5
  %38 = icmp sle i32 %36, %37
  br i1 %38, label %40, label %39

39:                                               ; preds = %35
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #4
  br label %48

40:                                               ; preds = %35
  %41 = load i32, ptr %7, align 4, !tbaa !5
  %42 = mul nsw i32 %41, 255
  %43 = load i32, ptr %5, align 4, !tbaa !5
  %44 = add nsw i32 %43, %42
  store i32 %44, ptr %5, align 4, !tbaa !5
  br label %45

45:                                               ; preds = %40
  %46 = load i32, ptr %7, align 4, !tbaa !5
  %47 = add nsw i32 %46, 1
  store i32 %47, ptr %7, align 4, !tbaa !5
  br label %35, !llvm.loop !13

48:                                               ; preds = %39
  %49 = load i32, ptr %3, align 4, !tbaa !5
  %50 = load i32, ptr %5, align 4, !tbaa !5
  %51 = call i32 (ptr, ...) @printf(ptr noundef @.str.8, i32 noundef %49, i32 noundef %50)
  %52 = load ptr, ptr %4, align 8, !tbaa !9
  %53 = load i32, ptr %5, align 4, !tbaa !5
  %54 = load ptr, ptr %52, align 8, !tbaa !14
  %55 = getelementptr inbounds ptr, ptr %54, i64 3
  %56 = load ptr, ptr %55, align 8
  call void %56(ptr noundef nonnull align 8 dereferenceable(12) %52, i32 noundef %53)
  call void @llvm.lifetime.start.p0(i64 256, ptr %8) #4
  %57 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 0
  call void @llvm.memset.p0.i64(ptr align 16 %57, i8 0, i64 256, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  store i32 2, ptr %9, align 4, !tbaa !5
  br label %58

58:                                               ; preds = %97, %48
  %59 = load i32, ptr %9, align 4, !tbaa !5
  %60 = load i32, ptr %3, align 4, !tbaa !5
  %61 = icmp sle i32 %59, %60
  br i1 %61, label %63, label %62

62:                                               ; preds = %58
  store i32 8, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  br label %100

63:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %64

64:                                               ; preds = %93, %63
  %65 = load i32, ptr %11, align 4, !tbaa !5
  %66 = load i32, ptr %9, align 4, !tbaa !5
  %67 = icmp slt i32 %65, %66
  br i1 %67, label %69, label %68

68:                                               ; preds = %64
  store i32 11, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  br label %96

69:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  store i32 1, ptr %12, align 4, !tbaa !5
  br label %70

70:                                               ; preds = %86, %69
  %71 = load i32, ptr %12, align 4, !tbaa !5
  %72 = icmp sle i32 %71, 255
  br i1 %72, label %74, label %73

73:                                               ; preds = %70
  store i32 14, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  br label %89

74:                                               ; preds = %70
  %75 = load i32, ptr %12, align 4, !tbaa !5
  %76 = trunc i32 %75 to i8
  %77 = load i32, ptr %11, align 4, !tbaa !5
  %78 = sext i32 %77 to i64
  %79 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 %78
  store i8 %76, ptr %79, align 1, !tbaa !16
  %80 = load ptr, ptr %4, align 8, !tbaa !9
  %81 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 0
  %82 = load i32, ptr %9, align 4, !tbaa !5
  %83 = load ptr, ptr %80, align 8, !tbaa !14
  %84 = getelementptr inbounds ptr, ptr %83, i64 2
  %85 = load ptr, ptr %84, align 8
  call void %85(ptr noundef nonnull align 8 dereferenceable(12) %80, ptr noundef %81, i32 noundef %82)
  br label %86

86:                                               ; preds = %74
  %87 = load i32, ptr %12, align 4, !tbaa !5
  %88 = add nsw i32 %87, 1
  store i32 %88, ptr %12, align 4, !tbaa !5
  br label %70, !llvm.loop !17

89:                                               ; preds = %73
  %90 = load i32, ptr %11, align 4, !tbaa !5
  %91 = sext i32 %90 to i64
  %92 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 %91
  store i8 0, ptr %92, align 1, !tbaa !16
  br label %93

93:                                               ; preds = %89
  %94 = load i32, ptr %11, align 4, !tbaa !5
  %95 = add nsw i32 %94, 1
  store i32 %95, ptr %11, align 4, !tbaa !5
  br label %64, !llvm.loop !18

96:                                               ; preds = %68
  br label %97

97:                                               ; preds = %96
  %98 = load i32, ptr %9, align 4, !tbaa !5
  %99 = add nsw i32 %98, 1
  store i32 %99, ptr %9, align 4, !tbaa !5
  br label %58, !llvm.loop !19

100:                                              ; preds = %62
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  store i32 2, ptr %13, align 4, !tbaa !5
  br label %101

101:                                              ; preds = %170, %100
  %102 = load i32, ptr %13, align 4, !tbaa !5
  %103 = load i32, ptr %3, align 4, !tbaa !5
  %104 = icmp sle i32 %102, %103
  br i1 %104, label %106, label %105

105:                                              ; preds = %101
  store i32 17, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  br label %173

106:                                              ; preds = %101
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %107

107:                                              ; preds = %166, %106
  %108 = load i32, ptr %14, align 4, !tbaa !5
  %109 = load i32, ptr %13, align 4, !tbaa !5
  %110 = sub nsw i32 %109, 1
  %111 = icmp slt i32 %108, %110
  br i1 %111, label %113, label %112

112:                                              ; preds = %107
  store i32 20, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  br label %169

113:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  %114 = load i32, ptr %14, align 4, !tbaa !5
  %115 = add nsw i32 %114, 1
  store i32 %115, ptr %15, align 4, !tbaa !5
  br label %116

116:                                              ; preds = %162, %113
  %117 = load i32, ptr %15, align 4, !tbaa !5
  %118 = load i32, ptr %13, align 4, !tbaa !5
  %119 = icmp slt i32 %117, %118
  br i1 %119, label %121, label %120

120:                                              ; preds = %116
  store i32 23, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  br label %165

121:                                              ; preds = %116
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  store i32 1, ptr %16, align 4, !tbaa !5
  br label %122

122:                                              ; preds = %155, %121
  %123 = load i32, ptr %16, align 4, !tbaa !5
  %124 = icmp sle i32 %123, 255
  br i1 %124, label %126, label %125

125:                                              ; preds = %122
  store i32 26, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  br label %158

126:                                              ; preds = %122
  %127 = load i32, ptr %16, align 4, !tbaa !5
  %128 = trunc i32 %127 to i8
  %129 = load i32, ptr %14, align 4, !tbaa !5
  %130 = sext i32 %129 to i64
  %131 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 %130
  store i8 %128, ptr %131, align 1, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  store i32 1, ptr %17, align 4, !tbaa !5
  br label %132

132:                                              ; preds = %148, %126
  %133 = load i32, ptr %17, align 4, !tbaa !5
  %134 = icmp sle i32 %133, 255
  br i1 %134, label %136, label %135

135:                                              ; preds = %132
  store i32 29, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  br label %151

136:                                              ; preds = %132
  %137 = load i32, ptr %17, align 4, !tbaa !5
  %138 = trunc i32 %137 to i8
  %139 = load i32, ptr %15, align 4, !tbaa !5
  %140 = sext i32 %139 to i64
  %141 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 %140
  store i8 %138, ptr %141, align 1, !tbaa !16
  %142 = load ptr, ptr %4, align 8, !tbaa !9
  %143 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 0
  %144 = load i32, ptr %13, align 4, !tbaa !5
  %145 = load ptr, ptr %142, align 8, !tbaa !14
  %146 = getelementptr inbounds ptr, ptr %145, i64 2
  %147 = load ptr, ptr %146, align 8
  call void %147(ptr noundef nonnull align 8 dereferenceable(12) %142, ptr noundef %143, i32 noundef %144)
  br label %148

148:                                              ; preds = %136
  %149 = load i32, ptr %17, align 4, !tbaa !5
  %150 = add nsw i32 %149, 1
  store i32 %150, ptr %17, align 4, !tbaa !5
  br label %132, !llvm.loop !20

151:                                              ; preds = %135
  %152 = load i32, ptr %15, align 4, !tbaa !5
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 %153
  store i8 0, ptr %154, align 1, !tbaa !16
  br label %155

155:                                              ; preds = %151
  %156 = load i32, ptr %16, align 4, !tbaa !5
  %157 = add nsw i32 %156, 1
  store i32 %157, ptr %16, align 4, !tbaa !5
  br label %122, !llvm.loop !21

158:                                              ; preds = %125
  %159 = load i32, ptr %14, align 4, !tbaa !5
  %160 = sext i32 %159 to i64
  %161 = getelementptr inbounds [256 x i8], ptr %8, i64 0, i64 %160
  store i8 0, ptr %161, align 1, !tbaa !16
  br label %162

162:                                              ; preds = %158
  %163 = load i32, ptr %15, align 4, !tbaa !5
  %164 = add nsw i32 %163, 1
  store i32 %164, ptr %15, align 4, !tbaa !5
  br label %116, !llvm.loop !22

165:                                              ; preds = %120
  br label %166

166:                                              ; preds = %165
  %167 = load i32, ptr %14, align 4, !tbaa !5
  %168 = add nsw i32 %167, 1
  store i32 %168, ptr %14, align 4, !tbaa !5
  br label %107, !llvm.loop !23

169:                                              ; preds = %112
  br label %170

170:                                              ; preds = %169
  %171 = load i32, ptr %13, align 4, !tbaa !5
  %172 = add nsw i32 %171, 1
  store i32 %172, ptr %13, align 4, !tbaa !5
  br label %101, !llvm.loop !24

173:                                              ; preds = %105
  call void @llvm.lifetime.end.p0(i64 256, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #4
  ret void
}

declare noundef double @_Z7chooseKii(i32 noundef, i32 noundef) #2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: write) }
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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = !{!15, !15, i64 0}
!15 = !{!"vtable pointer", !8, i64 0}
!16 = !{!7, !7, i64 0}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}
!19 = distinct !{!19, !12}
!20 = distinct !{!20, !12}
!21 = distinct !{!21, !12}
!22 = distinct !{!22, !12}
!23 = distinct !{!23, !12}
!24 = distinct !{!24, !12}


; 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.8 = external hidden unnamed_addr constant [55 x i8], align 1

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z14TwoBytesKeygeniR11KeyCallback(i32 noundef %0, ptr noundef nonnull align 8 dereferenceable(12) %1) local_unnamed_addr #3 {
  %3 = alloca [256 x i8], align 16
  %.not67 = icmp slt i32 %0, 2
  br i1 %.not67, label %._crit_edge89.critedge, label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph
  %4 = mul i32 %24, 65025
  br i1 %.not67, label %._crit_edge89.critedge, label %.lr.ph74.preheader

.lr.ph74.preheader:                               ; preds = %._crit_edge
  %5 = mul i32 %0, 765
  %6 = add i32 %4, %5
  %7 = add nsw i32 %0, -2
  %8 = zext nneg i32 %7 to i33
  %9 = add nsw i32 %0, -3
  %10 = zext i32 %9 to i33
  %11 = mul i33 %8, %10
  %12 = lshr i33 %11, 1
  %13 = trunc nuw i33 %12 to i32
  %14 = mul i32 %13, 255
  %15 = add i32 %6, %14
  %16 = add i32 %15, -1020
  %17 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.8, i32 noundef %0, i32 noundef %16)
  %18 = load ptr, ptr %1, align 8, !tbaa !5
  %19 = getelementptr inbounds i8, ptr %18, i64 24
  %20 = load ptr, ptr %19, align 8
  tail call void %20(ptr noundef nonnull align 8 dereferenceable(12) %1, i32 noundef %16)
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %3) #5
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %3, i8 0, i64 256, i1 false)
  %21 = add nuw i32 %0, 1
  %wide.trip.count97 = zext i32 %21 to i64
  br label %.preheader66

.lr.ph:                                           ; preds = %2, %.lr.ph
  %.05769 = phi i32 [ %25, %.lr.ph ], [ 2, %2 ]
  %.05868 = phi i32 [ %24, %.lr.ph ], [ 0, %2 ]
  %22 = tail call noundef double @_Z7chooseKii(i32 noundef %.05769, i32 noundef 2)
  %23 = fptosi double %22 to i32
  %24 = add nsw i32 %.05868, %23
  %25 = add nuw i32 %.05769, 1
  %exitcond.not = icmp eq i32 %.05769, %0
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !8

.preheader66:                                     ; preds = %.lr.ph74.preheader, %29
  %indvars.iv94 = phi i64 [ 2, %.lr.ph74.preheader ], [ %indvars.iv.next95, %29 ]
  %26 = trunc nuw nsw i64 %indvars.iv94 to i32
  br label %.preheader65

.preheader64:                                     ; preds = %29
  br i1 %.not67, label %._crit_edge89, label %.preheader63.preheader

.preheader63.preheader:                           ; preds = %.preheader64
  %27 = add nuw i32 %0, 1
  %wide.trip.count121 = zext i32 %27 to i64
  br label %.lr.ph85.preheader

.preheader65:                                     ; preds = %.preheader66, %30
  %indvars.iv = phi i64 [ 0, %.preheader66 ], [ %indvars.iv.next, %30 ]
  %28 = getelementptr inbounds [256 x i8], ptr %3, i64 0, i64 %indvars.iv
  br label %31

29:                                               ; preds = %30
  %indvars.iv.next95 = add nuw nsw i64 %indvars.iv94, 1
  %exitcond98.not = icmp eq i64 %indvars.iv.next95, %wide.trip.count97
  br i1 %exitcond98.not, label %.preheader64, label %.preheader66, !llvm.loop !10

30:                                               ; preds = %31
  store i8 0, ptr %28, align 1, !tbaa !11
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond93.not = icmp eq i64 %indvars.iv.next, %indvars.iv94
  br i1 %exitcond93.not, label %29, label %.preheader65, !llvm.loop !13

31:                                               ; preds = %.preheader65, %31
  %.05377 = phi i32 [ 1, %.preheader65 ], [ %36, %31 ]
  %32 = trunc nuw i32 %.05377 to i8
  store i8 %32, ptr %28, align 1, !tbaa !11
  %33 = load ptr, ptr %1, align 8, !tbaa !5
  %34 = getelementptr inbounds i8, ptr %33, i64 16
  %35 = load ptr, ptr %34, align 8
  call void %35(ptr noundef nonnull align 8 dereferenceable(12) %1, ptr noundef nonnull %3, i32 noundef %26)
  %36 = add nuw nsw i32 %.05377, 1
  %exitcond91.not = icmp eq i32 %36, 256
  br i1 %exitcond91.not, label %30, label %31, !llvm.loop !14

.lr.ph85.preheader:                               ; preds = %._crit_edge86, %.preheader63.preheader
  %indvars.iv116 = phi i64 [ 2, %.preheader63.preheader ], [ %indvars.iv.next117, %._crit_edge86 ]
  %indvars.iv114 = phi i64 [ 1, %.preheader63.preheader ], [ %indvars.iv.next115, %._crit_edge86 ]
  %37 = trunc nuw nsw i64 %indvars.iv116 to i32
  br label %.preheader.lr.ph

._crit_edge89.critedge:                           ; preds = %._crit_edge, %2
  %.1.lcssa.ph = phi i32 [ 0, %2 ], [ %4, %._crit_edge ]
  %38 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.8, i32 noundef %0, i32 noundef %.1.lcssa.ph)
  %39 = load ptr, ptr %1, align 8, !tbaa !5
  %40 = getelementptr inbounds i8, ptr %39, i64 24
  %41 = load ptr, ptr %40, align 8
  tail call void %41(ptr noundef nonnull align 8 dereferenceable(12) %1, i32 noundef %.1.lcssa.ph)
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %3) #5
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %3, i8 0, i64 256, i1 false)
  br label %._crit_edge89

._crit_edge89:                                    ; preds = %._crit_edge86, %._crit_edge89.critedge, %.preheader64
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %3) #5
  ret void

.loopexit:                                        ; preds = %44
  %indvars.iv.next102 = add nuw nsw i64 %indvars.iv101, 1
  %exitcond113.not = icmp eq i64 %indvars.iv.next108, %indvars.iv114
  br i1 %exitcond113.not, label %._crit_edge86, label %.preheader.lr.ph, !llvm.loop !15

._crit_edge86:                                    ; preds = %.loopexit
  %indvars.iv.next117 = add nuw nsw i64 %indvars.iv116, 1
  %indvars.iv.next115 = add nuw nsw i64 %indvars.iv114, 1
  %exitcond122.not = icmp eq i64 %indvars.iv.next117, %wide.trip.count121
  br i1 %exitcond122.not, label %._crit_edge89, label %.lr.ph85.preheader, !llvm.loop !16

.preheader.lr.ph:                                 ; preds = %.loopexit, %.lr.ph85.preheader
  %indvars.iv107 = phi i64 [ 0, %.lr.ph85.preheader ], [ %indvars.iv.next108, %.loopexit ]
  %indvars.iv101 = phi i64 [ 1, %.lr.ph85.preheader ], [ %indvars.iv.next102, %.loopexit ]
  %indvars.iv.next108 = add nuw nsw i64 %indvars.iv107, 1
  %42 = getelementptr inbounds [256 x i8], ptr %3, i64 0, i64 %indvars.iv107
  br label %.preheader

.preheader:                                       ; preds = %.preheader.lr.ph, %44
  %indvars.iv103 = phi i64 [ %indvars.iv101, %.preheader.lr.ph ], [ %indvars.iv.next104, %44 ]
  %43 = getelementptr inbounds [256 x i8], ptr %3, i64 0, i64 %indvars.iv103
  br label %45

44:                                               ; preds = %47
  store i8 0, ptr %42, align 1, !tbaa !11
  %indvars.iv.next104 = add nuw nsw i64 %indvars.iv103, 1
  %exitcond106.not = icmp eq i64 %indvars.iv.next104, %indvars.iv116
  br i1 %exitcond106.not, label %.loopexit, label %.preheader, !llvm.loop !17

45:                                               ; preds = %.preheader, %47
  %.04982 = phi i32 [ 1, %.preheader ], [ %48, %47 ]
  %46 = trunc nuw i32 %.04982 to i8
  store i8 %46, ptr %42, align 1, !tbaa !11
  br label %49

47:                                               ; preds = %49
  store i8 0, ptr %43, align 1, !tbaa !11
  %48 = add nuw nsw i32 %.04982, 1
  %exitcond100.not = icmp eq i32 %48, 256
  br i1 %exitcond100.not, label %44, label %45, !llvm.loop !18

49:                                               ; preds = %45, %49
  %.081 = phi i32 [ 1, %45 ], [ %54, %49 ]
  %50 = trunc nuw i32 %.081 to i8
  store i8 %50, ptr %43, align 1, !tbaa !11
  %51 = load ptr, ptr %1, align 8, !tbaa !5
  %52 = getelementptr inbounds i8, ptr %51, i64 16
  %53 = load ptr, ptr %52, align 8
  call void %53(ptr noundef nonnull align 8 dereferenceable(12) %1, ptr noundef nonnull %3, i32 noundef %37)
  %54 = add nuw nsw i32 %.081, 1
  %exitcond99.not = icmp eq i32 %54, 256
  br i1 %exitcond99.not, label %47, label %49, !llvm.loop !19
}

declare noundef double @_Z7chooseKii(i32 noundef, i32 noundef) local_unnamed_addr #4

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { 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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = distinct !{!8, !9}
!9 = !{!"llvm.loop.mustprogress"}
!10 = distinct !{!10, !9}
!11 = !{!12, !12, i64 0}
!12 = !{!"omnipotent char", !7, i64 0}
!13 = distinct !{!13, !9}
!14 = distinct !{!14, !9}
!15 = distinct !{!15, !9}
!16 = distinct !{!16, !9}
!17 = distinct !{!17, !9}
!18 = distinct !{!18, !9}
!19 = distinct !{!19, !9}


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