; LLVM IR from smv1999/CompetitiveProgrammingQuestionBank :: CodeVita Problems (string_pair)

; 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 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [12 x i8], align 1

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

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @vowelCount(ptr noundef) #0

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

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

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

; Function Attrs: nounwind uwtable
define dso_local i32 @main(i32 noundef %0, ptr noundef %1) #0 {
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i64, align 8
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca [500 x i8], align 16
  %14 = alloca [500 x i8], align 16
  store i32 0, ptr %3, align 4
  store i32 %0, ptr %4, align 4, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #7
  store i32 0, ptr %8, align 4, !tbaa !5
  %15 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %6)
  %16 = load i32, ptr %6, align 4, !tbaa !5
  %17 = zext i32 %16 to i64
  %18 = call ptr @llvm.stacksave.p0()
  store ptr %18, ptr %9, align 8
  %19 = alloca i32, i64 %17, align 16
  store i64 %17, ptr %10, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  call void @llvm.lifetime.start.p0(i64 500, ptr %13) #7
  call void @llvm.lifetime.start.p0(i64 500, ptr %14) #7
  %20 = load i32, ptr %6, align 4, !tbaa !5
  %21 = add nsw i32 %20, 1
  %22 = sext i32 %21 to i64
  %23 = mul i64 %22, 8
  %24 = call noalias ptr @malloc(i64 noundef %23) #8
  store ptr %24, ptr %12, align 8, !tbaa !9
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %25

25:                                               ; preds = %34, %2
  %26 = load i32, ptr %11, align 4, !tbaa !5
  %27 = load i32, ptr %6, align 4, !tbaa !5
  %28 = icmp slt i32 %26, %27
  br i1 %28, label %29, label %37

29:                                               ; preds = %25
  %30 = load i32, ptr %11, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = getelementptr inbounds i32, ptr %19, i64 %31
  %33 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %32)
  br label %34

34:                                               ; preds = %29
  %35 = load i32, ptr %11, align 4, !tbaa !5
  %36 = add nsw i32 %35, 1
  store i32 %36, ptr %11, align 4, !tbaa !5
  br label %25, !llvm.loop !11

37:                                               ; preds = %25
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %38

38:                                               ; preds = %97, %37
  %39 = load i32, ptr %11, align 4, !tbaa !5
  %40 = load i32, ptr %6, align 4, !tbaa !5
  %41 = icmp slt i32 %39, %40
  br i1 %41, label %42, label %100

42:                                               ; preds = %38
  %43 = load i32, ptr %11, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds i32, ptr %19, i64 %44
  %46 = load i32, ptr %45, align 4, !tbaa !5
  %47 = icmp ne i32 %46, 100
  br i1 %47, label %48, label %73

48:                                               ; preds = %42
  %49 = load i32, ptr %11, align 4, !tbaa !5
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds i32, ptr %19, i64 %50
  %52 = load i32, ptr %51, align 4, !tbaa !5
  %53 = getelementptr inbounds [500 x i8], ptr %13, i64 0, i64 0
  call void @numToWords(i32 noundef %52, ptr noundef %53)
  %54 = getelementptr inbounds [500 x i8], ptr %13, i64 0, i64 0
  %55 = call i64 @strlen(ptr noundef %54) #9
  %56 = trunc i64 %55 to i32
  store i32 %56, ptr %7, align 4, !tbaa !5
  %57 = load i32, ptr %7, align 4, !tbaa !5
  %58 = add nsw i32 %57, 10
  %59 = sext i32 %58 to i64
  %60 = mul i64 %59, 1
  %61 = call noalias ptr @malloc(i64 noundef %60) #8
  %62 = load ptr, ptr %12, align 8, !tbaa !9
  %63 = load i32, ptr %11, align 4, !tbaa !5
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds ptr, ptr %62, i64 %64
  store ptr %61, ptr %65, align 8, !tbaa !9
  %66 = load ptr, ptr %12, align 8, !tbaa !9
  %67 = load i32, ptr %11, align 4, !tbaa !5
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds ptr, ptr %66, i64 %68
  %70 = load ptr, ptr %69, align 8, !tbaa !9
  %71 = getelementptr inbounds [500 x i8], ptr %13, i64 0, i64 0
  %72 = call ptr @strcpy(ptr noundef %70, ptr noundef %71) #7
  br label %96

73:                                               ; preds = %42
  %74 = load i32, ptr %11, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds i32, ptr %19, i64 %75
  %77 = load i32, ptr %76, align 4, !tbaa !5
  %78 = icmp eq i32 %77, 100
  br i1 %78, label %79, label %95

79:                                               ; preds = %73
  store i32 7, ptr %7, align 4, !tbaa !5
  %80 = load i32, ptr %7, align 4, !tbaa !5
  %81 = add nsw i32 %80, 10
  %82 = sext i32 %81 to i64
  %83 = mul i64 %82, 1
  %84 = call noalias ptr @malloc(i64 noundef %83) #8
  %85 = load ptr, ptr %12, align 8, !tbaa !9
  %86 = load i32, ptr %11, align 4, !tbaa !5
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds ptr, ptr %85, i64 %87
  store ptr %84, ptr %88, align 8, !tbaa !9
  %89 = load ptr, ptr %12, align 8, !tbaa !9
  %90 = load i32, ptr %11, align 4, !tbaa !5
  %91 = sext i32 %90 to i64
  %92 = getelementptr inbounds ptr, ptr %89, i64 %91
  %93 = load ptr, ptr %92, align 8, !tbaa !9
  %94 = call ptr @strcpy(ptr noundef %93, ptr noundef @.str.1) #7
  br label %95

95:                                               ; preds = %79, %73
  br label %96

96:                                               ; preds = %95, %48
  br label %97

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

100:                                              ; preds = %38
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %101

101:                                              ; preds = %114, %100
  %102 = load i32, ptr %11, align 4, !tbaa !5
  %103 = load i32, ptr %6, align 4, !tbaa !5
  %104 = icmp slt i32 %102, %103
  br i1 %104, label %105, label %117

105:                                              ; preds = %101
  %106 = load ptr, ptr %12, align 8, !tbaa !9
  %107 = load i32, ptr %11, align 4, !tbaa !5
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds ptr, ptr %106, i64 %108
  %110 = load ptr, ptr %109, align 8, !tbaa !9
  %111 = call i32 @vowelCount(ptr noundef %110)
  %112 = load i32, ptr %8, align 4, !tbaa !5
  %113 = add nsw i32 %112, %111
  store i32 %113, ptr %8, align 4, !tbaa !5
  br label %114

114:                                              ; preds = %105
  %115 = load i32, ptr %11, align 4, !tbaa !5
  %116 = add nsw i32 %115, 1
  store i32 %116, ptr %11, align 4, !tbaa !5
  br label %101, !llvm.loop !14

117:                                              ; preds = %101
  %118 = load i32, ptr %6, align 4, !tbaa !5
  %119 = load i32, ptr %8, align 4, !tbaa !5
  %120 = call i32 @countPairs(ptr noundef %19, i32 noundef %118, i32 noundef %119)
  %121 = icmp sle i32 %120, 100
  br i1 %121, label %122, label %130

122:                                              ; preds = %117
  %123 = load i32, ptr %6, align 4, !tbaa !5
  %124 = load i32, ptr %8, align 4, !tbaa !5
  %125 = call i32 @countPairs(ptr noundef %19, i32 noundef %123, i32 noundef %124)
  %126 = getelementptr inbounds [500 x i8], ptr %14, i64 0, i64 0
  call void @numToWords(i32 noundef %125, ptr noundef %126)
  %127 = getelementptr inbounds [500 x i8], ptr %14, i64 0, i64 0
  call void @toLower(ptr noundef %127)
  %128 = getelementptr inbounds [500 x i8], ptr %14, i64 0, i64 0
  %129 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, ptr noundef %128)
  br label %132

130:                                              ; preds = %117
  %131 = call i32 (ptr, ...) @printf(ptr noundef @.str.3)
  br label %132

132:                                              ; preds = %130, %122
  store i32 0, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 500, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 500, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #7
  %133 = load ptr, ptr %9, align 8
  call void @llvm.stackrestore.p0(ptr %133)
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  %134 = load i32, ptr %3, align 4
  ret i32 %134
}

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

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare ptr @llvm.stacksave.p0() #5

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #6

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

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #5

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 = { 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 = { 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 #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 = { nocallback nofree nosync nounwind willreturn }
attributes #6 = { nounwind allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { nounwind allocsize(0) }
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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/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 = distinct !{!14, !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 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [12 x i8], align 1

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

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @vowelCount(ptr noundef) local_unnamed_addr #0

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

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

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

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @main(i32 noundef %0, ptr nocapture noundef readnone %1) local_unnamed_addr #0 {
  %3 = alloca i32, align 4
  %4 = alloca [500 x i8], align 16
  %5 = alloca [500 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #7
  %6 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %3)
  %7 = load i32, ptr %3, align 4, !tbaa !5
  %8 = zext i32 %7 to i64
  %9 = call ptr @llvm.stacksave.p0()
  %10 = alloca i32, i64 %8, align 16
  call void @llvm.lifetime.start.p0(i64 500, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 500, ptr nonnull %5) #7
  %11 = load i32, ptr %3, align 4, !tbaa !5
  %12 = add nsw i32 %11, 1
  %13 = sext i32 %12 to i64
  %14 = shl nsw i64 %13, 3
  %15 = call noalias ptr @malloc(i64 noundef %14) #8
  %16 = icmp sgt i32 %11, 0
  br i1 %16, label %.lr.ph, label %._crit_edge

.preheader29:                                     ; preds = %.lr.ph
  %17 = icmp sgt i32 %20, 0
  br i1 %17, label %.lr.ph32, label %._crit_edge

.lr.ph:                                           ; preds = %2, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %2 ]
  %18 = getelementptr inbounds i32, ptr %10, i64 %indvars.iv
  %19 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %18)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %20 = load i32, ptr %3, align 4, !tbaa !5
  %21 = sext i32 %20 to i64
  %22 = icmp slt i64 %indvars.iv.next, %21
  br i1 %22, label %.lr.ph, label %.preheader29, !llvm.loop !9

.preheader:                                       ; preds = %36
  %23 = icmp sgt i32 %37, 0
  br i1 %23, label %.lr.ph35, label %._crit_edge

.lr.ph32:                                         ; preds = %.preheader29, %36
  %24 = phi i32 [ %37, %36 ], [ %20, %.preheader29 ]
  %indvars.iv40 = phi i64 [ %indvars.iv.next41, %36 ], [ 0, %.preheader29 ]
  %25 = getelementptr inbounds i32, ptr %10, i64 %indvars.iv40
  %26 = load i32, ptr %25, align 4, !tbaa !5
  %.not = icmp eq i32 %26, 100
  br i1 %.not, label %33, label %27

27:                                               ; preds = %.lr.ph32
  call void @numToWords(i32 noundef %26, ptr noundef nonnull %4)
  %28 = call i64 @strlen(ptr noundef nonnull dereferenceable(1) %4) #9
  %29 = shl i64 %28, 32
  %sext = add i64 %29, 42949672960
  %30 = ashr exact i64 %sext, 32
  %31 = call noalias ptr @malloc(i64 noundef %30) #8
  %32 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %31, ptr noundef nonnull dereferenceable(1) %4) #7
  %.pre = load i32, ptr %3, align 4, !tbaa !5
  br label %36

33:                                               ; preds = %.lr.ph32
  %34 = call noalias dereferenceable_or_null(17) ptr @malloc(i64 noundef 17) #8
  %35 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %34, ptr noundef nonnull dereferenceable(1) @.str.1) #7
  br label %36

36:                                               ; preds = %27, %33
  %37 = phi i32 [ %24, %33 ], [ %.pre, %27 ]
  %.sink = phi ptr [ %34, %33 ], [ %31, %27 ]
  %38 = getelementptr inbounds ptr, ptr %15, i64 %indvars.iv40
  store ptr %.sink, ptr %38, align 8
  %indvars.iv.next41 = add nuw nsw i64 %indvars.iv40, 1
  %39 = sext i32 %37 to i64
  %40 = icmp slt i64 %indvars.iv.next41, %39
  br i1 %40, label %.lr.ph32, label %.preheader, !llvm.loop !11

.lr.ph35:                                         ; preds = %.preheader, %.lr.ph35
  %indvars.iv43 = phi i64 [ %indvars.iv.next44, %.lr.ph35 ], [ 0, %.preheader ]
  %.02633 = phi i32 [ %44, %.lr.ph35 ], [ 0, %.preheader ]
  %41 = getelementptr inbounds ptr, ptr %15, i64 %indvars.iv43
  %42 = load ptr, ptr %41, align 8, !tbaa !12
  %43 = call i32 @vowelCount(ptr noundef %42)
  %44 = add nsw i32 %43, %.02633
  %indvars.iv.next44 = add nuw nsw i64 %indvars.iv43, 1
  %45 = load i32, ptr %3, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = icmp slt i64 %indvars.iv.next44, %46
  br i1 %47, label %.lr.ph35, label %._crit_edge, !llvm.loop !14

._crit_edge:                                      ; preds = %.lr.ph35, %2, %.preheader29, %.preheader
  %.026.lcssa = phi i32 [ 0, %.preheader ], [ 0, %.preheader29 ], [ 0, %2 ], [ %44, %.lr.ph35 ]
  %.lcssa = phi i32 [ %37, %.preheader ], [ %20, %.preheader29 ], [ %11, %2 ], [ %45, %.lr.ph35 ]
  %48 = call i32 @countPairs(ptr noundef nonnull %10, i32 noundef %.lcssa, i32 noundef %.026.lcssa)
  %49 = icmp slt i32 %48, 101
  br i1 %49, label %50, label %54

50:                                               ; preds = %._crit_edge
  %51 = load i32, ptr %3, align 4, !tbaa !5
  %52 = call i32 @countPairs(ptr noundef nonnull %10, i32 noundef %51, i32 noundef %.026.lcssa)
  call void @numToWords(i32 noundef %52, ptr noundef nonnull %5)
  call void @toLower(ptr noundef nonnull %5)
  %53 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, ptr noundef nonnull %5)
  br label %56

54:                                               ; preds = %._crit_edge
  %55 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3)
  br label %56

56:                                               ; preds = %54, %50
  call void @llvm.lifetime.end.p0(i64 500, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 500, ptr nonnull %4) #7
  call void @llvm.stackrestore.p0(ptr %9)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  ret i32 0
}

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn
declare ptr @llvm.stacksave.p0() #5

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #5

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 = { mustprogress nofree nounwind willreturn memory(argmem: readwrite) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nofree nounwind willreturn memory(argmem: read) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { mustprogress nocallback nofree nosync nounwind willreturn }
attributes #6 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 allocsize(0) }
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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = !{!13, !13, i64 0}
!13 = !{!"any pointer", !7, i64 0}
!14 = distinct !{!14, !10}


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