; LLVM IR from abeaumont/competitive-programming :: kattis (perfectpowers)

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

%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca i32, align 4
  %5 = alloca i64, align 8
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  store i32 0, ptr %1, align 4
  %11 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %12 = getelementptr i8, ptr %11, i64 -24
  %13 = load i64, ptr %12, align 8
  %14 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %13
  %15 = call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %14, ptr noundef null)
  %16 = call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  br label %17

17:                                               ; preds = %111, %0
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #7
  store i64 1, ptr %3, align 8, !tbaa !8
  %18 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %2)
  %19 = load i64, ptr %2, align 8, !tbaa !8
  %20 = icmp ne i64 %19, 0
  br i1 %20, label %22, label %21

21:                                               ; preds = %17
  store i32 3, ptr %4, align 4
  br label %109

22:                                               ; preds = %17
  %23 = load i64, ptr %2, align 8, !tbaa !8
  %24 = icmp slt i64 %23, 0
  br i1 %24, label %25, label %67

25:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #7
  store i64 2, ptr %5, align 8, !tbaa !8
  br label %26

26:                                               ; preds = %63, %25
  %27 = load i64, ptr %5, align 8, !tbaa !8
  %28 = load i64, ptr %5, align 8, !tbaa !8
  %29 = mul nsw i64 %27, %28
  %30 = load i64, ptr %2, align 8, !tbaa !8
  %31 = sub nsw i64 0, %30
  %32 = icmp sle i64 %29, %31
  br i1 %32, label %34, label %33

33:                                               ; preds = %26
  store i32 4, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  br label %66

34:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #7
  %35 = load i64, ptr %5, align 8, !tbaa !8
  %36 = sub nsw i64 0, %35
  store i64 %36, ptr %6, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #7
  store i64 1, ptr %7, align 8, !tbaa !8
  br label %37

37:                                               ; preds = %55, %34
  %38 = load i64, ptr %6, align 8, !tbaa !8
  %39 = call i64 @llvm.abs.i64(i64 %38, i1 true)
  %40 = load i64, ptr %2, align 8, !tbaa !8
  %41 = sub nsw i64 0, %40
  %42 = icmp sle i64 %39, %41
  br i1 %42, label %44, label %43

43:                                               ; preds = %37
  store i32 7, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  br label %62

44:                                               ; preds = %37
  %45 = load i64, ptr %6, align 8, !tbaa !8
  %46 = load i64, ptr %2, align 8, !tbaa !8
  %47 = icmp eq i64 %45, %46
  br i1 %47, label %48, label %54

48:                                               ; preds = %44
  %49 = load i64, ptr %7, align 8, !tbaa !8
  %50 = load i64, ptr %3, align 8, !tbaa !8
  %51 = icmp sgt i64 %49, %50
  br i1 %51, label %52, label %54

52:                                               ; preds = %48
  %53 = load i64, ptr %7, align 8, !tbaa !8
  store i64 %53, ptr %3, align 8, !tbaa !8
  br label %54

54:                                               ; preds = %52, %48, %44
  br label %55

55:                                               ; preds = %54
  %56 = load i64, ptr %5, align 8, !tbaa !8
  %57 = sub nsw i64 0, %56
  %58 = load i64, ptr %6, align 8, !tbaa !8
  %59 = mul nsw i64 %58, %57
  store i64 %59, ptr %6, align 8, !tbaa !8
  %60 = load i64, ptr %7, align 8, !tbaa !8
  %61 = add nsw i64 %60, 1
  store i64 %61, ptr %7, align 8, !tbaa !8
  br label %37, !llvm.loop !11

62:                                               ; preds = %43
  br label %63

63:                                               ; preds = %62
  %64 = load i64, ptr %5, align 8, !tbaa !8
  %65 = add nsw i64 %64, 1
  store i64 %65, ptr %5, align 8, !tbaa !8
  br label %26, !llvm.loop !13

66:                                               ; preds = %33
  br label %105

67:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #7
  store i64 2, ptr %8, align 8, !tbaa !8
  br label %68

68:                                               ; preds = %101, %67
  %69 = load i64, ptr %8, align 8, !tbaa !8
  %70 = load i64, ptr %8, align 8, !tbaa !8
  %71 = mul nsw i64 %69, %70
  %72 = load i64, ptr %2, align 8, !tbaa !8
  %73 = call i64 @llvm.abs.i64(i64 %72, i1 true)
  %74 = icmp sle i64 %71, %73
  br i1 %74, label %76, label %75

75:                                               ; preds = %68
  store i32 10, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #7
  br label %104

76:                                               ; preds = %68
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  %77 = load i64, ptr %8, align 8, !tbaa !8
  store i64 %77, ptr %9, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #7
  store i64 1, ptr %10, align 8, !tbaa !8
  br label %78

78:                                               ; preds = %94, %76
  %79 = load i64, ptr %9, align 8, !tbaa !8
  %80 = load i64, ptr %2, align 8, !tbaa !8
  %81 = icmp sle i64 %79, %80
  br i1 %81, label %83, label %82

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

83:                                               ; preds = %78
  %84 = load i64, ptr %9, align 8, !tbaa !8
  %85 = load i64, ptr %2, align 8, !tbaa !8
  %86 = icmp eq i64 %84, %85
  br i1 %86, label %87, label %93

87:                                               ; preds = %83
  %88 = load i64, ptr %10, align 8, !tbaa !8
  %89 = load i64, ptr %3, align 8, !tbaa !8
  %90 = icmp sgt i64 %88, %89
  br i1 %90, label %91, label %93

91:                                               ; preds = %87
  %92 = load i64, ptr %10, align 8, !tbaa !8
  store i64 %92, ptr %3, align 8, !tbaa !8
  br label %93

93:                                               ; preds = %91, %87, %83
  br label %94

94:                                               ; preds = %93
  %95 = load i64, ptr %8, align 8, !tbaa !8
  %96 = load i64, ptr %9, align 8, !tbaa !8
  %97 = mul nsw i64 %96, %95
  store i64 %97, ptr %9, align 8, !tbaa !8
  %98 = load i64, ptr %10, align 8, !tbaa !8
  %99 = add nsw i64 %98, 1
  store i64 %99, ptr %10, align 8, !tbaa !8
  br label %78, !llvm.loop !14

100:                                              ; preds = %82
  br label %101

101:                                              ; preds = %100
  %102 = load i64, ptr %8, align 8, !tbaa !8
  %103 = add nsw i64 %102, 1
  store i64 %103, ptr %8, align 8, !tbaa !8
  br label %68, !llvm.loop !15

104:                                              ; preds = %75
  br label %105

105:                                              ; preds = %104, %66
  %106 = load i64, ptr %3, align 8, !tbaa !8
  %107 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %106)
  %108 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8) %107, i8 noundef signext 10)
  store i32 0, ptr %4, align 4
  br label %109

109:                                              ; preds = %105, %21
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #7
  %110 = load i32, ptr %4, align 4
  switch i32 %110, label %114 [
    i32 0, label %111
    i32 3, label %112
  ]

111:                                              ; preds = %109
  br label %17, !llvm.loop !16

112:                                              ; preds = %109
  %113 = load i32, ptr %1, align 4
  ret i32 %113

114:                                              ; preds = %109
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264), ptr noundef) #1 align 2

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) #2

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #4 align 2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.abs.i64(i64, i1 immarg) #5

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8), i8 noundef signext) #6

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef) #4 align 2

attributes #0 = { mustprogress norecurse 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 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 #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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { inlinehint 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 #7 = { 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 = !{!9, !9, i64 0}
!9 = !{!"long long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !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"

%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca i64, align 8
  %2 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %3 = getelementptr i8, ptr %2, i64 -24
  %4 = load i64, ptr %3, align 8
  %5 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %4
  %6 = tail call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %5, ptr noundef null)
  %7 = tail call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #8
  %8 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %1)
  %9 = load i64, ptr %1, align 8, !tbaa !8
  %.not67 = icmp eq i64 %9, 0
  br i1 %.not67, label %._crit_edge70, label %.lr.ph69

.lr.ph69:                                         ; preds = %0, %.loopexit
  %10 = phi i64 [ %30, %.loopexit ], [ %9, %0 ]
  %11 = icmp slt i64 %10, 0
  br i1 %11, label %.preheader43, label %.preheader44

.preheader44:                                     ; preds = %.lr.ph69
  %.not3650 = icmp ult i64 %10, 4
  br i1 %.not3650, label %.loopexit, label %.preheader

.preheader43:                                     ; preds = %.lr.ph69
  %12 = sub nsw i64 0, %10
  %.not3862 = icmp ugt i64 %10, -4
  br i1 %.not3862, label %.loopexit, label %.lr.ph65

.lr.ph65:                                         ; preds = %.preheader43, %._crit_edge60
  %.03164 = phi i64 [ %14, %._crit_edge60 ], [ 2, %.preheader43 ]
  %.03363 = phi i64 [ %.1.lcssa, %._crit_edge60 ], [ 1, %.preheader43 ]
  %13 = sub nsw i64 0, %.03164
  %.not3954 = icmp sgt i64 %.03164, %12
  br i1 %.not3954, label %._crit_edge60, label %.lr.ph59

._crit_edge60:                                    ; preds = %.lr.ph59, %.lr.ph65
  %.1.lcssa = phi i64 [ %.03363, %.lr.ph65 ], [ %.2, %.lr.ph59 ]
  %14 = add nuw nsw i64 %.03164, 1
  %15 = mul nuw nsw i64 %14, %14
  %.not38 = icmp sgt i64 %15, %12
  br i1 %.not38, label %.loopexit, label %.lr.ph65, !llvm.loop !11

.lr.ph59:                                         ; preds = %.lr.ph65, %.lr.ph59
  %.02957 = phi i64 [ %19, %.lr.ph59 ], [ 1, %.lr.ph65 ]
  %.03056 = phi i64 [ %18, %.lr.ph59 ], [ %13, %.lr.ph65 ]
  %.155 = phi i64 [ %.2, %.lr.ph59 ], [ %.03363, %.lr.ph65 ]
  %16 = icmp eq i64 %.03056, %10
  %17 = call i64 @llvm.smax.i64(i64 %.02957, i64 %.155)
  %.2 = select i1 %16, i64 %17, i64 %.155
  %18 = mul nsw i64 %.03056, %13
  %19 = add nuw nsw i64 %.02957, 1
  %20 = call i64 @llvm.abs.i64(i64 %18, i1 true)
  %.not39 = icmp sgt i64 %20, %12
  br i1 %.not39, label %._crit_edge60, label %.lr.ph59, !llvm.loop !13

.preheader:                                       ; preds = %.preheader44, %._crit_edge
  %.02852 = phi i64 [ %21, %._crit_edge ], [ 2, %.preheader44 ]
  %.351 = phi i64 [ %.4.lcssa, %._crit_edge ], [ 1, %.preheader44 ]
  %.not3746 = icmp sgt i64 %.02852, %10
  br i1 %.not3746, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %.preheader
  %.4.lcssa = phi i64 [ %.351, %.preheader ], [ %.5, %.lr.ph ]
  %21 = add nuw nsw i64 %.02852, 1
  %22 = mul nuw nsw i64 %21, %21
  %.not36 = icmp ugt i64 %22, %10
  br i1 %.not36, label %.loopexit, label %.preheader, !llvm.loop !14

.lr.ph:                                           ; preds = %.preheader, %.lr.ph
  %.049 = phi i64 [ %26, %.lr.ph ], [ 1, %.preheader ]
  %.02748 = phi i64 [ %25, %.lr.ph ], [ %.02852, %.preheader ]
  %.447 = phi i64 [ %.5, %.lr.ph ], [ %.351, %.preheader ]
  %23 = icmp eq i64 %.02748, %10
  %24 = call i64 @llvm.smax.i64(i64 %.049, i64 %.447)
  %.5 = select i1 %23, i64 %24, i64 %.447
  %25 = mul nuw nsw i64 %.02748, %.02852
  %26 = add nuw nsw i64 %.049, 1
  %.not37 = icmp sgt i64 %25, %10
  br i1 %.not37, label %._crit_edge, label %.lr.ph, !llvm.loop !15

.loopexit:                                        ; preds = %._crit_edge, %._crit_edge60, %.preheader44, %.preheader43
  %.6 = phi i64 [ 1, %.preheader43 ], [ 1, %.preheader44 ], [ %.1.lcssa, %._crit_edge60 ], [ %.4.lcssa, %._crit_edge ]
  %27 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %.6)
  %28 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8) %27, i8 noundef signext 10)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #8
  %29 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %1)
  %30 = load i64, ptr %1, align 8, !tbaa !8
  %.not = icmp eq i64 %30, 0
  br i1 %.not, label %._crit_edge70, label %.lr.ph69

._crit_edge70:                                    ; preds = %.loopexit, %0
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #8
  ret i32 0
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264), ptr noundef) local_unnamed_addr #1 align 2

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.abs.i64(i64, i1 immarg) #5

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8), i8 noundef signext) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef) local_unnamed_addr #4 align 2

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

attributes #0 = { mustprogress norecurse 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 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 #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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { inlinehint 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 #7 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #8 = { 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 = !{!9, !9, i64 0}
!9 = !{!"long long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}


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