; LLVM IR from Izaron/ACM-ICPC :: Timus Online Judge/Volume 1/1081. Binary Lexicographic Sequence (main)

; 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" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str = external hidden unnamed_addr constant [1 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca [100 x i64], align 16
  %3 = alloca i32, align 4
  %4 = alloca i64, align 8
  %5 = alloca i64, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca %"class.std::allocator", align 1
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca %"class.std::__cxx11::basic_string", align 8
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 800, ptr %2) #6
  %13 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 0
  store i64 1, ptr %13, align 16, !tbaa !5
  %14 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 1
  store i64 1, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #6
  store i32 2, ptr %3, align 4, !tbaa !9
  br label %15

15:                                               ; preds = %34, %0
  %16 = load i32, ptr %3, align 4, !tbaa !9
  %17 = icmp slt i32 %16, 50
  br i1 %17, label %19, label %18

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

19:                                               ; preds = %15
  %20 = load i32, ptr %3, align 4, !tbaa !9
  %21 = sub nsw i32 %20, 2
  %22 = sext i32 %21 to i64
  %23 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %22
  %24 = load i64, ptr %23, align 8, !tbaa !5
  %25 = load i32, ptr %3, align 4, !tbaa !9
  %26 = sub nsw i32 %25, 1
  %27 = sext i32 %26 to i64
  %28 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %27
  %29 = load i64, ptr %28, align 8, !tbaa !5
  %30 = add nsw i64 %24, %29
  %31 = load i32, ptr %3, align 4, !tbaa !9
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %32
  store i64 %30, ptr %33, align 8, !tbaa !5
  br label %34

34:                                               ; preds = %19
  %35 = load i32, ptr %3, align 4, !tbaa !9
  %36 = add nsw i32 %35, 1
  store i32 %36, ptr %3, align 4, !tbaa !9
  br label %15, !llvm.loop !11

37:                                               ; preds = %18
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #6
  %38 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %4)
  %39 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %38, ptr noundef nonnull align 8 dereferenceable(8) %5)
  %40 = load i64, ptr %5, align 8, !tbaa !5
  %41 = load i64, ptr %4, align 8, !tbaa !5
  %42 = add nsw i64 %41, 1
  %43 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %42
  %44 = load i64, ptr %43, align 8, !tbaa !5
  %45 = icmp sgt i64 %40, %44
  br i1 %45, label %46, label %48

46:                                               ; preds = %37
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef -1)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %6, align 4
  br label %109

48:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  store i32 45, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 32, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %9) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef @.str, ptr noundef nonnull align 1 dereferenceable(1) %9)
          to label %49 unwind label %79

49:                                               ; preds = %48
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #6
  br label %50

50:                                               ; preds = %90, %49
  %51 = load i64, ptr %5, align 8, !tbaa !5
  %52 = icmp sgt i64 %51, 1
  br i1 %52, label %53, label %93

53:                                               ; preds = %50
  %54 = load i64, ptr %5, align 8, !tbaa !5
  %55 = load i32, ptr %7, align 4, !tbaa !9
  %56 = sub nsw i32 %55, 1
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %57
  %59 = load i64, ptr %58, align 8, !tbaa !5
  %60 = add nsw i64 %59, 1
  %61 = icmp sge i64 %54, %60
  br i1 %61, label %62, label %87

62:                                               ; preds = %53
  %63 = load i64, ptr %5, align 8, !tbaa !5
  %64 = load i32, ptr %7, align 4, !tbaa !9
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %65
  %67 = load i64, ptr %66, align 8, !tbaa !5
  %68 = icmp sle i64 %63, %67
  br i1 %68, label %69, label %87

69:                                               ; preds = %62
  %70 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef @.str.1)
          to label %71 unwind label %83

71:                                               ; preds = %69
  %72 = load i32, ptr %7, align 4, !tbaa !9
  %73 = sub nsw i32 %72, 1
  %74 = sext i32 %73 to i64
  %75 = getelementptr inbounds [100 x i64], ptr %2, i64 0, i64 %74
  %76 = load i64, ptr %75, align 8, !tbaa !5
  %77 = load i64, ptr %5, align 8, !tbaa !5
  %78 = sub nsw i64 %77, %76
  store i64 %78, ptr %5, align 8, !tbaa !5
  br label %90

79:                                               ; preds = %48
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %10, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %11, align 4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #6
  br label %123

83:                                               ; preds = %97, %87, %69
  %84 = landingpad { ptr, i32 }
          cleanup
  %85 = extractvalue { ptr, i32 } %84, 0
  store ptr %85, ptr %10, align 8
  %86 = extractvalue { ptr, i32 } %84, 1
  store i32 %86, ptr %11, align 4
  br label %122

87:                                               ; preds = %62, %53
  %88 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef @.str.2)
          to label %89 unwind label %83

89:                                               ; preds = %87
  br label %90

90:                                               ; preds = %89, %71
  %91 = load i32, ptr %7, align 4, !tbaa !9
  %92 = add nsw i32 %91, -1
  store i32 %92, ptr %7, align 4, !tbaa !9
  br label %50, !llvm.loop !13

93:                                               ; preds = %50
  br label %94

94:                                               ; preds = %99, %93
  %95 = load i32, ptr %7, align 4, !tbaa !9
  %96 = icmp sgt i32 %95, 1
  br i1 %96, label %97, label %102

97:                                               ; preds = %94
  %98 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef @.str.2)
          to label %99 unwind label %83

99:                                               ; preds = %97
  %100 = load i32, ptr %7, align 4, !tbaa !9
  %101 = add nsw i32 %100, -1
  store i32 %101, ptr %7, align 4, !tbaa !9
  br label %94, !llvm.loop !14

102:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 32, ptr %12) #6
  %103 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %8) #6
  %104 = load i64, ptr %4, align 8, !tbaa !5
  %105 = sub i64 %103, %104
  invoke void @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %12, ptr noundef nonnull align 8 dereferenceable(32) %8, i64 noundef %105, i64 noundef -1)
          to label %106 unwind label %113

106:                                              ; preds = %102
  %107 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull align 8 dereferenceable(32) %12)
          to label %108 unwind label %117

108:                                              ; preds = %106
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %12) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  store i32 0, ptr %6, align 4
  br label %109

109:                                              ; preds = %108, %46
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 800, ptr %2) #6
  %110 = load i32, ptr %6, align 4
  switch i32 %110, label %129 [
    i32 0, label %111
    i32 1, label %111
  ]

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

113:                                              ; preds = %102
  %114 = landingpad { ptr, i32 }
          cleanup
  %115 = extractvalue { ptr, i32 } %114, 0
  store ptr %115, ptr %10, align 8
  %116 = extractvalue { ptr, i32 } %114, 1
  store i32 %116, ptr %11, align 4
  br label %121

117:                                              ; preds = %106
  %118 = landingpad { ptr, i32 }
          cleanup
  %119 = extractvalue { ptr, i32 } %118, 0
  store ptr %119, ptr %10, align 8
  %120 = extractvalue { ptr, i32 } %118, 1
  store i32 %120, ptr %11, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %12) #6
  br label %121

121:                                              ; preds = %117, %113
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #6
  br label %122

122:                                              ; preds = %121, %83
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #6
  br label %123

123:                                              ; preds = %122, %79
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 800, ptr %2) #6
  br label %124

124:                                              ; preds = %123
  %125 = load ptr, ptr %10, align 8
  %126 = load i32, ptr %11, align 4
  %127 = insertvalue { ptr, i32 } poison, ptr %125, 0
  %128 = insertvalue { ptr, i32 } %127, i32 %126, 1
  resume { ptr, i32 } %128

129:                                              ; preds = %109
  unreachable
}

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

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

; 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)) #2 align 2

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(32)) #5

; Function Attrs: mustprogress uwtable
declare void @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(32), i64 noundef, i64 noundef) #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #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 = { 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 #5 = { 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 #6 = { 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 = !{!"long long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !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"

%"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" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str = external hidden unnamed_addr constant [1 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca [100 x i64], align 16
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca %"class.std::__cxx11::basic_string", align 8
  %5 = alloca %"class.std::allocator", align 1
  %6 = alloca %"class.std::__cxx11::basic_string", align 8
  call void @llvm.lifetime.start.p0(i64 800, ptr nonnull %1) #6
  store i64 1, ptr %1, align 16, !tbaa !5
  %7 = getelementptr inbounds i8, ptr %1, i64 8
  store i64 1, ptr %7, align 8, !tbaa !5
  %8 = getelementptr inbounds i8, ptr %1, i64 16
  store i64 2, ptr %8, align 16, !tbaa !5
  %9 = getelementptr inbounds i8, ptr %1, i64 24
  store i64 3, ptr %9, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %1, i64 32
  store i64 5, ptr %10, align 16, !tbaa !5
  %11 = getelementptr inbounds i8, ptr %1, i64 40
  store i64 8, ptr %11, align 8, !tbaa !5
  %12 = getelementptr inbounds i8, ptr %1, i64 48
  store i64 13, ptr %12, align 16, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %1, i64 56
  store i64 21, ptr %13, align 8, !tbaa !5
  %14 = getelementptr inbounds i8, ptr %1, i64 64
  store i64 34, ptr %14, align 16, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %1, i64 72
  store i64 55, ptr %15, align 8, !tbaa !5
  %16 = getelementptr inbounds i8, ptr %1, i64 80
  store i64 89, ptr %16, align 16, !tbaa !5
  %17 = getelementptr inbounds i8, ptr %1, i64 88
  store i64 144, ptr %17, align 8, !tbaa !5
  %18 = getelementptr inbounds i8, ptr %1, i64 96
  store i64 233, ptr %18, align 16, !tbaa !5
  %19 = getelementptr inbounds i8, ptr %1, i64 104
  store i64 377, ptr %19, align 8, !tbaa !5
  %20 = getelementptr inbounds i8, ptr %1, i64 112
  store i64 610, ptr %20, align 16, !tbaa !5
  %21 = getelementptr inbounds i8, ptr %1, i64 120
  store i64 987, ptr %21, align 8, !tbaa !5
  %22 = getelementptr inbounds i8, ptr %1, i64 128
  store i64 1597, ptr %22, align 16, !tbaa !5
  %23 = getelementptr inbounds i8, ptr %1, i64 136
  store i64 2584, ptr %23, align 8, !tbaa !5
  %24 = getelementptr inbounds i8, ptr %1, i64 144
  store i64 4181, ptr %24, align 16, !tbaa !5
  %25 = getelementptr inbounds i8, ptr %1, i64 152
  store i64 6765, ptr %25, align 8, !tbaa !5
  %26 = getelementptr inbounds i8, ptr %1, i64 160
  store i64 10946, ptr %26, align 16, !tbaa !5
  %27 = getelementptr inbounds i8, ptr %1, i64 168
  store i64 17711, ptr %27, align 8, !tbaa !5
  %28 = getelementptr inbounds i8, ptr %1, i64 176
  store i64 28657, ptr %28, align 16, !tbaa !5
  %29 = getelementptr inbounds i8, ptr %1, i64 184
  store i64 46368, ptr %29, align 8, !tbaa !5
  %30 = getelementptr inbounds i8, ptr %1, i64 192
  store i64 75025, ptr %30, align 16, !tbaa !5
  %31 = getelementptr inbounds i8, ptr %1, i64 200
  store i64 121393, ptr %31, align 8, !tbaa !5
  %32 = getelementptr inbounds i8, ptr %1, i64 208
  store i64 196418, ptr %32, align 16, !tbaa !5
  %33 = getelementptr inbounds i8, ptr %1, i64 216
  store i64 317811, ptr %33, align 8, !tbaa !5
  %34 = getelementptr inbounds i8, ptr %1, i64 224
  store i64 514229, ptr %34, align 16, !tbaa !5
  %35 = getelementptr inbounds i8, ptr %1, i64 232
  store i64 832040, ptr %35, align 8, !tbaa !5
  %36 = getelementptr inbounds i8, ptr %1, i64 240
  store i64 1346269, ptr %36, align 16, !tbaa !5
  %37 = getelementptr inbounds i8, ptr %1, i64 248
  store i64 2178309, ptr %37, align 8, !tbaa !5
  %38 = getelementptr inbounds i8, ptr %1, i64 256
  store i64 3524578, ptr %38, align 16, !tbaa !5
  %39 = getelementptr inbounds i8, ptr %1, i64 264
  store i64 5702887, ptr %39, align 8, !tbaa !5
  %40 = getelementptr inbounds i8, ptr %1, i64 272
  store i64 9227465, ptr %40, align 16, !tbaa !5
  %41 = getelementptr inbounds i8, ptr %1, i64 280
  store i64 14930352, ptr %41, align 8, !tbaa !5
  %42 = getelementptr inbounds i8, ptr %1, i64 288
  store i64 24157817, ptr %42, align 16, !tbaa !5
  %43 = getelementptr inbounds i8, ptr %1, i64 296
  store i64 39088169, ptr %43, align 8, !tbaa !5
  %44 = getelementptr inbounds i8, ptr %1, i64 304
  store i64 63245986, ptr %44, align 16, !tbaa !5
  %45 = getelementptr inbounds i8, ptr %1, i64 312
  store i64 102334155, ptr %45, align 8, !tbaa !5
  %46 = getelementptr inbounds i8, ptr %1, i64 320
  store i64 165580141, ptr %46, align 16, !tbaa !5
  %47 = getelementptr inbounds i8, ptr %1, i64 328
  store i64 267914296, ptr %47, align 8, !tbaa !5
  %48 = getelementptr inbounds i8, ptr %1, i64 336
  store i64 433494437, ptr %48, align 16, !tbaa !5
  %49 = getelementptr inbounds i8, ptr %1, i64 344
  store i64 701408733, ptr %49, align 8, !tbaa !5
  %50 = getelementptr inbounds i8, ptr %1, i64 352
  store i64 1134903170, ptr %50, align 16, !tbaa !5
  %51 = getelementptr inbounds i8, ptr %1, i64 360
  store i64 1836311903, ptr %51, align 8, !tbaa !5
  %52 = getelementptr inbounds i8, ptr %1, i64 368
  store i64 2971215073, ptr %52, align 16, !tbaa !5
  %53 = getelementptr inbounds i8, ptr %1, i64 376
  store i64 4807526976, ptr %53, align 8, !tbaa !5
  %54 = getelementptr inbounds i8, ptr %1, i64 384
  store i64 7778742049, ptr %54, align 16, !tbaa !5
  %55 = getelementptr inbounds i8, ptr %1, i64 392
  store i64 12586269025, ptr %55, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #6
  %56 = 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)
  %57 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %56, ptr noundef nonnull align 8 dereferenceable(8) %3)
  %58 = load i64, ptr %3, align 8, !tbaa !5
  %59 = load i64, ptr %2, align 8, !tbaa !5
  %60 = add nsw i64 %59, 1
  %61 = getelementptr inbounds [100 x i64], ptr %1, i64 0, i64 %60
  %62 = load i64, ptr %61, align 8, !tbaa !5
  %63 = icmp sgt i64 %58, %62
  br i1 %63, label %64, label %66

64:                                               ; preds = %0
  %65 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef -1)
  br label %100

66:                                               ; preds = %0
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %5) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull @.str, ptr noundef nonnull align 1 dereferenceable(1) %5)
          to label %67 unwind label %83

67:                                               ; preds = %66
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #6
  %68 = load i64, ptr %3, align 8, !tbaa !5
  %69 = icmp sgt i64 %68, 1
  br i1 %69, label %.lr.ph, label %.lr.ph29.preheader

.preheader:                                       ; preds = %87
  %70 = trunc nsw i64 %indvars.iv.next33 to i32
  %71 = icmp sgt i64 %indvars.iv32, 2
  br i1 %71, label %.lr.ph29.preheader, label %._crit_edge

.lr.ph29.preheader:                               ; preds = %67, %.preheader
  %.11728.ph = phi i32 [ 45, %67 ], [ %70, %.preheader ]
  br label %.lr.ph29

.lr.ph:                                           ; preds = %67, %87
  %indvars.iv32 = phi i64 [ %indvars.iv.next33, %87 ], [ 45, %67 ]
  %72 = phi i64 [ %88, %87 ], [ %68, %67 ]
  %indvars.iv.next33 = add nsw i64 %indvars.iv32, -1
  %73 = getelementptr inbounds [100 x i64], ptr %1, i64 0, i64 %indvars.iv.next33
  %74 = load i64, ptr %73, align 8, !tbaa !5
  %.not.not = icmp sgt i64 %72, %74
  br i1 %.not.not, label %75, label %85

75:                                               ; preds = %.lr.ph
  %76 = getelementptr inbounds [100 x i64], ptr %1, i64 0, i64 %indvars.iv32
  %77 = load i64, ptr %76, align 8, !tbaa !5
  %.not = icmp sgt i64 %72, %77
  br i1 %.not, label %85, label %78

78:                                               ; preds = %75
  %79 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull @.str.1)
          to label %80 unwind label %.loopexit.split-lp

80:                                               ; preds = %78
  %81 = load i64, ptr %3, align 8, !tbaa !5
  %82 = sub nsw i64 %81, %74
  store i64 %82, ptr %3, align 8, !tbaa !5
  br label %87

83:                                               ; preds = %66
  %84 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #6
  br label %107

.loopexit:                                        ; preds = %.lr.ph29
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %106

.loopexit.split-lp:                               ; preds = %78, %85
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %106

85:                                               ; preds = %75, %.lr.ph
  %86 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull @.str.2)
          to label %._crit_edge35 unwind label %.loopexit.split-lp

._crit_edge35:                                    ; preds = %85
  %.pre36 = load i64, ptr %3, align 8, !tbaa !5
  br label %87

87:                                               ; preds = %._crit_edge35, %80
  %88 = phi i64 [ %.pre36, %._crit_edge35 ], [ %82, %80 ]
  %89 = icmp sgt i64 %88, 1
  br i1 %89, label %.lr.ph, label %.preheader, !llvm.loop !9

.lr.ph29:                                         ; preds = %.lr.ph29.preheader, %91
  %.11728 = phi i32 [ %92, %91 ], [ %.11728.ph, %.lr.ph29.preheader ]
  %90 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull @.str.2)
          to label %91 unwind label %.loopexit

91:                                               ; preds = %.lr.ph29
  %92 = add nsw i32 %.11728, -1
  %93 = icmp sgt i32 %.11728, 2
  br i1 %93, label %.lr.ph29, label %._crit_edge, !llvm.loop !11

._crit_edge:                                      ; preds = %91, %.preheader
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #6
  %94 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %4) #6
  %95 = load i64, ptr %2, align 8, !tbaa !5
  %96 = sub i64 %94, %95
  invoke void @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %6, ptr noundef nonnull align 8 dereferenceable(32) %4, i64 noundef %96, i64 noundef -1)
          to label %97 unwind label %101

97:                                               ; preds = %._crit_edge
  %98 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull align 8 dereferenceable(32) %6)
          to label %99 unwind label %103

99:                                               ; preds = %97
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #6
  br label %100

100:                                              ; preds = %99, %64
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 800, ptr nonnull %1) #6
  ret i32 0

101:                                              ; preds = %._crit_edge
  %102 = landingpad { ptr, i32 }
          cleanup
  br label %105

103:                                              ; preds = %97
  %104 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #6
  br label %105

105:                                              ; preds = %103, %101
  %.pn = phi { ptr, i32 } [ %104, %103 ], [ %102, %101 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  br label %106

106:                                              ; preds = %.loopexit, %.loopexit.split-lp, %105
  %.pn22 = phi { ptr, i32 } [ %.pn, %105 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #6
  br label %107

107:                                              ; preds = %106, %83
  %.pn22.pn = phi { ptr, i32 } [ %.pn22, %106 ], [ %84, %83 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 800, ptr nonnull %1) #6
  resume { ptr, i32 } %.pn22.pn
}

; 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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; 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 #2 align 2

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare void @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(32), i64 noundef, i64 noundef) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #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 = { 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 #5 = { 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 #6 = { 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 = !{!"long long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}


; Effective O3 passes: BDCEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass