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

; 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] }

@__const.main.m = external hidden unnamed_addr constant [5 x i32], align 16
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@.str = external hidden unnamed_addr constant [2 x i8], align 1
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.1 = external hidden unnamed_addr constant [3 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 [5 x %"class.std::__cxx11::basic_string"], align 16
  %3 = alloca [5 x i32], align 16
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca double, align 8
  %8 = alloca double, align 8
  %9 = alloca i32, align 4
  %10 = alloca i8, align 1
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca double, align 8
  store i32 0, ptr %1, align 4
  br label %16

16:                                               ; preds = %187, %0
  call void @llvm.lifetime.start.p0(i64 160, ptr %2) #10
  %17 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i32 0, i32 0
  %18 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %17, i64 5
  br label %19

19:                                               ; preds = %19, %16
  %20 = phi ptr [ %17, %16 ], [ %21, %19 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %20) #10
  %21 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %20, i64 1
  %22 = icmp eq ptr %21, %18
  br i1 %22, label %23, label %19

23:                                               ; preds = %19
  call void @llvm.lifetime.start.p0(i64 20, ptr %3) #10
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %3, ptr align 16 @__const.main.m, i64 20, i1 false)
  %24 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 0
  %25 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %24)
          to label %26 unwind label %31

26:                                               ; preds = %23
  %27 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 0
  %28 = invoke noundef zeroext i1 @_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_(ptr noundef nonnull align 8 dereferenceable(32) %27, ptr noundef @.str)
          to label %29 unwind label %31

29:                                               ; preds = %26
  br i1 %28, label %30, label %35

30:                                               ; preds = %29
  store i32 3, ptr %6, align 4
  br label %178

31:                                               ; preds = %26, %23
  %32 = landingpad { ptr, i32 }
          cleanup
  %33 = extractvalue { ptr, i32 } %32, 0
  store ptr %33, ptr %4, align 8
  %34 = extractvalue { ptr, i32 } %32, 1
  store i32 %34, ptr %5, align 4
  br label %193

35:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #10
  store double 0.000000e+00, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #10
  store double 0.000000e+00, ptr %8, align 8, !tbaa !5
  br label %36

36:                                               ; preds = %166, %35
  br label %37

37:                                               ; preds = %36
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #10
  store i32 1, ptr %9, align 4, !tbaa !9
  br label %38

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

41:                                               ; preds = %38
  store i32 6, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  br label %55

42:                                               ; preds = %38
  %43 = load i32, ptr %9, align 4, !tbaa !9
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 %44
  %46 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %45)
          to label %47 unwind label %51

47:                                               ; preds = %42
  br label %48

48:                                               ; preds = %47
  %49 = load i32, ptr %9, align 4, !tbaa !9
  %50 = add nsw i32 %49, 1
  store i32 %50, ptr %9, align 4, !tbaa !9
  br label %38, !llvm.loop !11

51:                                               ; preds = %42
  %52 = landingpad { ptr, i32 }
          cleanup
  %53 = extractvalue { ptr, i32 } %52, 0
  store ptr %53, ptr %4, align 8
  %54 = extractvalue { ptr, i32 } %52, 1
  store i32 %54, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  br label %192

55:                                               ; preds = %41
  call void @llvm.lifetime.start.p0(i64 1, ptr %10) #10
  store i8 0, ptr %10, align 1, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #10
  store i32 0, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #10
  store i32 0, ptr %12, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #10
  store i32 0, ptr %13, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #10
  store i32 0, ptr %14, align 4, !tbaa !9
  br label %56

56:                                               ; preds = %122, %55
  %57 = load i32, ptr %14, align 4, !tbaa !9
  %58 = icmp slt i32 %57, 5
  br i1 %58, label %60, label %59

59:                                               ; preds = %56
  store i32 9, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #10
  br label %125

60:                                               ; preds = %56
  %61 = load i32, ptr %14, align 4, !tbaa !9
  %62 = sext i32 %61 to i64
  %63 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 %62
  %64 = load i32, ptr %14, align 4, !tbaa !9
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 %65
  %67 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %66) #10
  %68 = sub i64 %67, 1
  %69 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %63, i64 noundef %68)
          to label %70 unwind label %73

70:                                               ; preds = %60
  %71 = load i8, ptr %69, align 1, !tbaa !15
  %72 = sext i8 %71 to i32
  switch i32 %72, label %108 [
    i32 103, label %77
    i32 67, label %95
  ]

73:                                               ; preds = %60
  %74 = landingpad { ptr, i32 }
          cleanup
  %75 = extractvalue { ptr, i32 } %74, 0
  store ptr %75, ptr %4, align 8
  %76 = extractvalue { ptr, i32 } %74, 1
  store i32 %76, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #10
  br label %167

77:                                               ; preds = %70
  %78 = load i32, ptr %14, align 4, !tbaa !9
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds [5 x i32], ptr %3, i64 0, i64 %79
  %81 = load i32, ptr %80, align 4, !tbaa !9
  %82 = load i32, ptr %14, align 4, !tbaa !9
  %83 = sext i32 %82 to i64
  %84 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 %83
  %85 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %84) #10
  %86 = call i32 @atoi(ptr noundef %85) #11
  %87 = mul nsw i32 %81, %86
  %88 = load i32, ptr %12, align 4, !tbaa !9
  %89 = add nsw i32 %88, %87
  store i32 %89, ptr %12, align 4, !tbaa !9
  %90 = load i32, ptr %14, align 4, !tbaa !9
  %91 = icmp ne i32 %90, 0
  br i1 %91, label %94, label %92

92:                                               ; preds = %77
  %93 = load i32, ptr %12, align 4, !tbaa !9
  store i32 %93, ptr %11, align 4, !tbaa !9
  br label %94

94:                                               ; preds = %92, %77
  br label %121

95:                                               ; preds = %70
  %96 = load i32, ptr %14, align 4, !tbaa !9
  %97 = sext i32 %96 to i64
  %98 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 %97
  %99 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %98) #10
  %100 = call i32 @atoi(ptr noundef %99) #11
  %101 = load i32, ptr %12, align 4, !tbaa !9
  %102 = add nsw i32 %101, %100
  store i32 %102, ptr %12, align 4, !tbaa !9
  %103 = load i32, ptr %14, align 4, !tbaa !9
  %104 = icmp ne i32 %103, 0
  br i1 %104, label %107, label %105

105:                                              ; preds = %95
  %106 = load i32, ptr %12, align 4, !tbaa !9
  store i32 %106, ptr %11, align 4, !tbaa !9
  br label %107

107:                                              ; preds = %105, %95
  br label %121

108:                                              ; preds = %70
  %109 = load i32, ptr %14, align 4, !tbaa !9
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 %110
  %112 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %111) #10
  %113 = call i32 @atoi(ptr noundef %112) #11
  %114 = load i32, ptr %13, align 4, !tbaa !9
  %115 = add nsw i32 %114, %113
  store i32 %115, ptr %13, align 4, !tbaa !9
  %116 = load i32, ptr %14, align 4, !tbaa !9
  %117 = icmp ne i32 %116, 0
  br i1 %117, label %120, label %118

118:                                              ; preds = %108
  %119 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %119, ptr %11, align 4, !tbaa !9
  store i8 1, ptr %10, align 1, !tbaa !13
  br label %120

120:                                              ; preds = %118, %108
  br label %121

121:                                              ; preds = %120, %107, %94
  br label %122

122:                                              ; preds = %121
  %123 = load i32, ptr %14, align 4, !tbaa !9
  %124 = add nsw i32 %123, 1
  store i32 %124, ptr %14, align 4, !tbaa !9
  br label %56, !llvm.loop !16

125:                                              ; preds = %59
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #10
  %126 = load i32, ptr %12, align 4, !tbaa !9
  %127 = sitofp i32 %126 to double
  %128 = fmul double %127, 1.000000e+02
  %129 = load i32, ptr %13, align 4, !tbaa !9
  %130 = sub nsw i32 100, %129
  %131 = sitofp i32 %130 to double
  %132 = fdiv double %128, %131
  store double %132, ptr %15, align 8, !tbaa !5
  %133 = load i8, ptr %10, align 1, !tbaa !13, !range !17, !noundef !18
  %134 = trunc i8 %133 to i1
  br i1 %134, label %135, label %143

135:                                              ; preds = %125
  %136 = load double, ptr %15, align 8, !tbaa !5
  %137 = load i32, ptr %11, align 4, !tbaa !9
  %138 = sitofp i32 %137 to double
  %139 = fmul double %136, %138
  %140 = fdiv double %139, 1.000000e+02
  %141 = load double, ptr %7, align 8, !tbaa !5
  %142 = fadd double %141, %140
  store double %142, ptr %7, align 8, !tbaa !5
  br label %148

143:                                              ; preds = %125
  %144 = load i32, ptr %11, align 4, !tbaa !9
  %145 = sitofp i32 %144 to double
  %146 = load double, ptr %7, align 8, !tbaa !5
  %147 = fadd double %146, %145
  store double %147, ptr %7, align 8, !tbaa !5
  br label %148

148:                                              ; preds = %143, %135
  %149 = load double, ptr %15, align 8, !tbaa !5
  %150 = load double, ptr %8, align 8, !tbaa !5
  %151 = fadd double %150, %149
  store double %151, ptr %8, align 8, !tbaa !5
  %152 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 0
  %153 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %152)
          to label %154 unwind label %159

154:                                              ; preds = %148
  %155 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i64 0, i64 0
  %156 = invoke noundef zeroext i1 @_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_(ptr noundef nonnull align 8 dereferenceable(32) %155, ptr noundef @.str)
          to label %157 unwind label %159

157:                                              ; preds = %154
  br i1 %156, label %158, label %163

158:                                              ; preds = %157
  store i32 5, ptr %6, align 4
  br label %164

159:                                              ; preds = %154, %148
  %160 = landingpad { ptr, i32 }
          cleanup
  %161 = extractvalue { ptr, i32 } %160, 0
  store ptr %161, ptr %4, align 8
  %162 = extractvalue { ptr, i32 } %160, 1
  store i32 %162, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #10
  br label %167

163:                                              ; preds = %157
  store i32 0, ptr %6, align 4
  br label %164

164:                                              ; preds = %163, %158
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr %10) #10
  %165 = load i32, ptr %6, align 4
  switch i32 %165, label %208 [
    i32 0, label %166
    i32 5, label %168
  ]

166:                                              ; preds = %164
  br label %36, !llvm.loop !19

167:                                              ; preds = %159, %73
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr %10) #10
  br label %192

168:                                              ; preds = %164
  %169 = load double, ptr %7, align 8, !tbaa !5
  %170 = fmul double %169, 1.000000e+02
  %171 = load double, ptr %8, align 8, !tbaa !5
  %172 = fdiv double %170, %171
  %173 = call double @llvm.round.f64(double %172)
  %174 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, double noundef %173)
          to label %175 unwind label %188

175:                                              ; preds = %168
  %176 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %174, ptr noundef @.str.1)
          to label %177 unwind label %188

177:                                              ; preds = %175
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #10
  store i32 0, ptr %6, align 4
  br label %178

178:                                              ; preds = %177, %30
  call void @llvm.lifetime.end.p0(i64 20, ptr %3) #10
  %179 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i32 0, i32 0
  %180 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %179, i64 5
  br label %181

181:                                              ; preds = %181, %178
  %182 = phi ptr [ %180, %178 ], [ %183, %181 ]
  %183 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %182, i64 -1
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %183) #10
  %184 = icmp eq ptr %183, %179
  br i1 %184, label %185, label %181

185:                                              ; preds = %181
  call void @llvm.lifetime.end.p0(i64 160, ptr %2) #10
  %186 = load i32, ptr %6, align 4
  switch i32 %186, label %208 [
    i32 0, label %187
    i32 3, label %201
  ]

187:                                              ; preds = %185
  br label %16, !llvm.loop !20

188:                                              ; preds = %175, %168
  %189 = landingpad { ptr, i32 }
          cleanup
  %190 = extractvalue { ptr, i32 } %189, 0
  store ptr %190, ptr %4, align 8
  %191 = extractvalue { ptr, i32 } %189, 1
  store i32 %191, ptr %5, align 4
  br label %192

192:                                              ; preds = %188, %167, %51
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #10
  br label %193

193:                                              ; preds = %192, %31
  call void @llvm.lifetime.end.p0(i64 20, ptr %3) #10
  %194 = getelementptr inbounds [5 x %"class.std::__cxx11::basic_string"], ptr %2, i32 0, i32 0
  %195 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %194, i64 5
  br label %196

196:                                              ; preds = %196, %193
  %197 = phi ptr [ %195, %193 ], [ %198, %196 ]
  %198 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %197, i64 -1
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %198) #10
  %199 = icmp eq ptr %198, %194
  br i1 %199, label %200, label %196

200:                                              ; preds = %196
  call void @llvm.lifetime.end.p0(i64 160, ptr %2) #10
  br label %203

201:                                              ; preds = %185
  %202 = load i32, ptr %1, align 4
  ret i32 %202

203:                                              ; preds = %200
  %204 = load ptr, ptr %4, align 8
  %205 = load i32, ptr %5, align 4
  %206 = insertvalue { ptr, i32 } poison, ptr %204, 0
  %207 = insertvalue { ptr, i32 } %206, i32 %205, 1
  resume { ptr, i32 } %207

208:                                              ; preds = %185, %164
  unreachable
}

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

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32)) #4

declare i32 @__gxx_personality_v0(...)

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #5

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

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

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

; Function Attrs: inlinehint mustprogress nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr noundef nonnull) #6

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #7

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.round.f64(double) #9

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 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 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 #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = { inlinehint 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 #6 = { inlinehint mustprogress nounwind willreturn memory(read) 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 = { 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 #8 = { 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 #9 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #10 = { nounwind }
attributes #11 = { 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 = !{!"double", !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 = !{!14, !14, i64 0}
!14 = !{!"bool", !7, i64 0}
!15 = !{!7, !7, i64 0}
!16 = distinct !{!16, !12}
!17 = !{i8 0, i8 2}
!18 = !{}
!19 = distinct !{!19, !12}
!20 = distinct !{!20, !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] }

@__const.main.m = external hidden unnamed_addr constant [5 x i32], align 16
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@.str = external hidden unnamed_addr constant [2 x i8], align 1
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.1 = external hidden unnamed_addr constant [3 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 [5 x %"class.std::__cxx11::basic_string"], align 16
  %.ptr.1 = getelementptr inbounds i8, ptr %1, i64 32
  %.ptr.2 = getelementptr inbounds i8, ptr %1, i64 64
  %.ptr.3 = getelementptr inbounds i8, ptr %1, i64 96
  %.ptr.4 = getelementptr inbounds i8, ptr %1, i64 128
  %2 = load i32, ptr @__const.main.m, align 16
  %3 = load i32, ptr getelementptr inbounds (i8, ptr @__const.main.m, i64 4), align 4
  %4 = load i32, ptr getelementptr inbounds (i8, ptr @__const.main.m, i64 8), align 8
  %5 = load i32, ptr getelementptr inbounds (i8, ptr @__const.main.m, i64 12), align 4
  %6 = load i32, ptr getelementptr inbounds (i8, ptr @__const.main.m, i64 16), align 16
  %7 = getelementptr inbounds i8, ptr %1, i64 128
  %8 = getelementptr inbounds i8, ptr %1, i64 96
  %9 = getelementptr inbounds i8, ptr %1, i64 64
  %10 = getelementptr inbounds i8, ptr %1, i64 32
  br label %11

11:                                               ; preds = %109, %0
  call void @llvm.lifetime.start.p0(i64 160, ptr nonnull %1) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.1) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.2) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.3) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.4) #9
  %12 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %1)
          to label %13 unwind label %15

13:                                               ; preds = %11
  %14 = call noundef zeroext i1 @_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_(ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull @.str)
  br i1 %14, label %.critedge, label %.preheader65

15:                                               ; preds = %11
  %16 = landingpad { ptr, i32 }
          cleanup
  br label %112

.preheader65:                                     ; preds = %13, %89
  %.047 = phi double [ %.148, %89 ], [ 0.000000e+00, %13 ]
  %.046 = phi double [ %95, %89 ], [ 0.000000e+00, %13 ]
  %17 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %.ptr.1)
          to label %18 unwind label %30

18:                                               ; preds = %.preheader65
  %19 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %.ptr.2)
          to label %20 unwind label %30

20:                                               ; preds = %18
  %21 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %.ptr.3)
          to label %22 unwind label %30

22:                                               ; preds = %20
  %23 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %.ptr.4)
          to label %.preheader.preheader unwind label %30

.preheader.preheader:                             ; preds = %22
  %24 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #9
  %25 = add i64 %24, -1
  %26 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %25)
  %27 = load i8, ptr %26, align 1, !tbaa !5
  %28 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #9
  %29 = call i32 @atoi(ptr nocapture noundef %28) #10
  switch i8 %27, label %34 [
    i8 103, label %32
    i8 67, label %.preheader.1
  ]

30:                                               ; preds = %22, %20, %18, %.preheader65
  %31 = landingpad { ptr, i32 }
          cleanup
  br label %112

32:                                               ; preds = %.preheader.preheader
  %33 = mul nsw i32 %29, %2
  br label %.preheader.1

34:                                               ; preds = %.preheader.preheader
  br label %.preheader.1

.preheader.1:                                     ; preds = %.preheader.preheader, %34, %32
  %.144 = phi i1 [ false, %32 ], [ true, %34 ], [ false, %.preheader.preheader ]
  %.142 = phi i32 [ %33, %32 ], [ %29, %34 ], [ %29, %.preheader.preheader ]
  %.140 = phi i32 [ %33, %32 ], [ 0, %34 ], [ %29, %.preheader.preheader ]
  %.138 = phi i32 [ 0, %32 ], [ %29, %34 ], [ 0, %.preheader.preheader ]
  %35 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.1) #9
  %36 = add i64 %35, -1
  %37 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.1, i64 noundef %36)
  %38 = load i8, ptr %37, align 1, !tbaa !5
  %39 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.1) #9
  %40 = call i32 @atoi(ptr nocapture noundef %39) #10
  switch i8 %38, label %46 [
    i8 103, label %43
    i8 67, label %41
  ]

41:                                               ; preds = %.preheader.1
  %42 = add nsw i32 %40, %.140
  br label %.preheader.2

43:                                               ; preds = %.preheader.1
  %44 = mul nsw i32 %40, %3
  %45 = add nsw i32 %44, %.140
  br label %.preheader.2

46:                                               ; preds = %.preheader.1
  %47 = add nsw i32 %40, %.138
  br label %.preheader.2

.preheader.2:                                     ; preds = %46, %43, %41
  %.140.1 = phi i32 [ %45, %43 ], [ %42, %41 ], [ %.140, %46 ]
  %.138.1 = phi i32 [ %.138, %43 ], [ %.138, %41 ], [ %47, %46 ]
  %48 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.2) #9
  %49 = add i64 %48, -1
  %50 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.2, i64 noundef %49)
  %51 = load i8, ptr %50, align 1, !tbaa !5
  %52 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.2) #9
  %53 = call i32 @atoi(ptr nocapture noundef %52) #10
  switch i8 %51, label %59 [
    i8 103, label %56
    i8 67, label %54
  ]

54:                                               ; preds = %.preheader.2
  %55 = add nsw i32 %53, %.140.1
  br label %.preheader.3

56:                                               ; preds = %.preheader.2
  %57 = mul nsw i32 %53, %4
  %58 = add nsw i32 %57, %.140.1
  br label %.preheader.3

59:                                               ; preds = %.preheader.2
  %60 = add nsw i32 %53, %.138.1
  br label %.preheader.3

.preheader.3:                                     ; preds = %59, %56, %54
  %.140.2 = phi i32 [ %58, %56 ], [ %55, %54 ], [ %.140.1, %59 ]
  %.138.2 = phi i32 [ %.138.1, %56 ], [ %.138.1, %54 ], [ %60, %59 ]
  %61 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.3) #9
  %62 = add i64 %61, -1
  %63 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.3, i64 noundef %62)
  %64 = load i8, ptr %63, align 1, !tbaa !5
  %65 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.3) #9
  %66 = call i32 @atoi(ptr nocapture noundef %65) #10
  switch i8 %64, label %72 [
    i8 103, label %69
    i8 67, label %67
  ]

67:                                               ; preds = %.preheader.3
  %68 = add nsw i32 %66, %.140.2
  br label %.preheader.4

69:                                               ; preds = %.preheader.3
  %70 = mul nsw i32 %66, %5
  %71 = add nsw i32 %70, %.140.2
  br label %.preheader.4

72:                                               ; preds = %.preheader.3
  %73 = add nsw i32 %66, %.138.2
  br label %.preheader.4

.preheader.4:                                     ; preds = %72, %69, %67
  %.140.3 = phi i32 [ %71, %69 ], [ %68, %67 ], [ %.140.2, %72 ]
  %.138.3 = phi i32 [ %.138.2, %69 ], [ %.138.2, %67 ], [ %73, %72 ]
  %74 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.4) #9
  %75 = add i64 %74, -1
  %76 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.4, i64 noundef %75)
  %77 = load i8, ptr %76, align 1, !tbaa !5
  %78 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %.ptr.4) #9
  %79 = call i32 @atoi(ptr nocapture noundef %78) #10
  switch i8 %77, label %85 [
    i8 103, label %82
    i8 67, label %80
  ]

80:                                               ; preds = %.preheader.4
  %81 = add nsw i32 %79, %.140.3
  br label %87

82:                                               ; preds = %.preheader.4
  %83 = mul nsw i32 %79, %6
  %84 = add nsw i32 %83, %.140.3
  br label %87

85:                                               ; preds = %.preheader.4
  %86 = add nsw i32 %79, %.138.3
  br label %87

87:                                               ; preds = %85, %82, %80
  %.140.4 = phi i32 [ %84, %82 ], [ %81, %80 ], [ %.140.3, %85 ]
  %.138.4 = phi i32 [ %.138.3, %82 ], [ %.138.3, %80 ], [ %86, %85 ]
  %88 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %1)
          to label %89 unwind label %100

89:                                               ; preds = %87
  %90 = sitofp i32 %.140.4 to double
  %91 = fmul double %90, 1.000000e+02
  %92 = sub nsw i32 100, %.138.4
  %93 = sitofp i32 %92 to double
  %94 = fdiv double %91, %93
  %95 = fadd double %.046, %94
  %96 = sitofp i32 %.142 to double
  %97 = fmul double %94, %96
  %98 = fdiv double %97, 1.000000e+02
  %.pn = select i1 %.144, double %98, double %96
  %.148 = fadd double %.047, %.pn
  %99 = call noundef zeroext i1 @_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_(ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull @.str)
  br i1 %99, label %102, label %.preheader65

100:                                              ; preds = %87
  %101 = landingpad { ptr, i32 }
          cleanup
  br label %112

102:                                              ; preds = %89
  %103 = fmul double %.148, 1.000000e+02
  %104 = fdiv double %103, %95
  %105 = call double @llvm.round.f64(double %104)
  %106 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, double noundef %105)
          to label %107 unwind label %110

107:                                              ; preds = %102
  %108 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %106, ptr noundef nonnull @.str.1)
          to label %109 unwind label %110

109:                                              ; preds = %107
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #9
  call void @llvm.lifetime.end.p0(i64 160, ptr nonnull %1) #9
  br i1 %14, label %.loopexit, label %11

110:                                              ; preds = %107, %102
  %111 = landingpad { ptr, i32 }
          cleanup
  br label %112

112:                                              ; preds = %30, %100, %110, %15
  %.pn59.pn = phi { ptr, i32 } [ %16, %15 ], [ %31, %30 ], [ %111, %110 ], [ %101, %100 ]
  %113 = getelementptr inbounds i8, ptr %1, i64 128
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %113) #9
  %114 = getelementptr inbounds i8, ptr %1, i64 96
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %114) #9
  %115 = getelementptr inbounds i8, ptr %1, i64 64
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %115) #9
  %116 = getelementptr inbounds i8, ptr %1, i64 32
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %116) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #9
  call void @llvm.lifetime.end.p0(i64 160, ptr nonnull %1) #9
  resume { ptr, i32 } %.pn59.pn

.critedge:                                        ; preds = %13
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #9
  call void @llvm.lifetime.end.p0(i64 160, ptr nonnull %1) #9
  br label %.loopexit

.loopexit:                                        ; preds = %109, %.critedge
  ret i32 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 nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 align 2

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #3

declare i32 @__gxx_personality_v0(...)

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) local_unnamed_addr #4

; 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 nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), 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 #2 align 2

; Function Attrs: inlinehint mustprogress nofree nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr nocapture noundef nonnull) local_unnamed_addr #5

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

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

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.round.f64(double) #8

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 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 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 #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 = { inlinehint 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 nofree nounwind willreturn memory(read) 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 = { 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 = { 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 #8 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #9 = { nounwind }
attributes #10 = { 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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}


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