; LLVM IR from eyangch/competitive-programming :: Codeforces/22 (b)

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

@_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 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca i64, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i8, align 1
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #8
  %19 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %2)
  %20 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %19, ptr noundef nonnull align 4 dereferenceable(4) %3)
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = zext i32 %21 to i64
  %23 = call ptr @llvm.stacksave.p0()
  store ptr %23, ptr %4, align 8
  %24 = alloca %"class.std::__cxx11::basic_string", i64 %22, align 16
  store i64 %22, ptr %5, align 8
  %25 = icmp eq i64 %22, 0
  br i1 %25, label %32, label %26

26:                                               ; preds = %0
  %27 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %22
  br label %28

28:                                               ; preds = %28, %26
  %29 = phi ptr [ %24, %26 ], [ %30, %28 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %29) #8
  %30 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %29, i64 1
  %31 = icmp eq ptr %30, %27
  br i1 %31, label %32, label %28

32:                                               ; preds = %28, %0
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #8
  store i32 0, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  store i32 0, ptr %7, align 4, !tbaa !5
  br label %33

33:                                               ; preds = %44, %32
  %34 = load i32, ptr %7, align 4, !tbaa !5
  %35 = load i32, ptr %2, align 4, !tbaa !5
  %36 = icmp slt i32 %34, %35
  br i1 %36, label %38, label %37

37:                                               ; preds = %33
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  br label %51

38:                                               ; preds = %33
  %39 = load i32, ptr %7, align 4, !tbaa !5
  %40 = sext i32 %39 to i64
  %41 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %40
  %42 = 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) %41)
          to label %43 unwind label %47

43:                                               ; preds = %38
  br label %44

44:                                               ; preds = %43
  %45 = load i32, ptr %7, align 4, !tbaa !5
  %46 = add nsw i32 %45, 1
  store i32 %46, ptr %7, align 4, !tbaa !5
  br label %33, !llvm.loop !9

47:                                               ; preds = %38
  %48 = landingpad { ptr, i32 }
          cleanup
  %49 = extractvalue { ptr, i32 } %48, 0
  store ptr %49, ptr %8, align 8
  %50 = extractvalue { ptr, i32 } %48, 1
  store i32 %50, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  br label %212

51:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #8
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %52

52:                                               ; preds = %197, %51
  %53 = load i32, ptr %10, align 4, !tbaa !5
  %54 = load i32, ptr %2, align 4, !tbaa !5
  %55 = icmp slt i32 %53, %54
  br i1 %55, label %57, label %56

56:                                               ; preds = %52
  store i32 5, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #8
  br label %200

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

58:                                               ; preds = %192, %57
  %59 = load i32, ptr %12, align 4, !tbaa !5
  %60 = load i32, ptr %3, align 4, !tbaa !5
  %61 = icmp slt i32 %59, %60
  br i1 %61, label %63, label %62

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

63:                                               ; preds = %58
  %64 = load i32, ptr %10, align 4, !tbaa !5
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %65
  %67 = load i32, ptr %12, align 4, !tbaa !5
  %68 = sext i32 %67 to i64
  %69 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %66, i64 noundef %68)
          to label %70 unwind label %75

70:                                               ; preds = %63
  %71 = load i8, ptr %69, align 1, !tbaa !11
  %72 = sext i8 %71 to i32
  %73 = icmp eq i32 %72, 49
  br i1 %73, label %74, label %79

74:                                               ; preds = %70
  br label %192

75:                                               ; preds = %63
  %76 = landingpad { ptr, i32 }
          cleanup
  %77 = extractvalue { ptr, i32 } %76, 0
  store ptr %77, ptr %8, align 8
  %78 = extractvalue { ptr, i32 } %76, 1
  store i32 %78, ptr %9, align 4
  br label %195

79:                                               ; preds = %70
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #8
  %80 = load i32, ptr %10, align 4, !tbaa !5
  store i32 %80, ptr %13, align 4, !tbaa !5
  br label %81

81:                                               ; preds = %188, %79
  %82 = load i32, ptr %13, align 4, !tbaa !5
  %83 = load i32, ptr %2, align 4, !tbaa !5
  %84 = icmp slt i32 %82, %83
  br i1 %84, label %86, label %85

85:                                               ; preds = %81
  store i32 11, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  br label %191

86:                                               ; preds = %81
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #8
  %87 = load i32, ptr %12, align 4, !tbaa !5
  store i32 %87, ptr %14, align 4, !tbaa !5
  br label %88

88:                                               ; preds = %181, %86
  %89 = load i32, ptr %14, align 4, !tbaa !5
  %90 = load i32, ptr %3, align 4, !tbaa !5
  %91 = icmp slt i32 %89, %90
  br i1 %91, label %93, label %92

92:                                               ; preds = %88
  store i32 14, ptr %11, align 4
  br label %185

93:                                               ; preds = %88
  %94 = load i32, ptr %13, align 4, !tbaa !5
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %95
  %97 = load i32, ptr %14, align 4, !tbaa !5
  %98 = sext i32 %97 to i64
  %99 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %96, i64 noundef %98)
          to label %100 unwind label %105

100:                                              ; preds = %93
  %101 = load i8, ptr %99, align 1, !tbaa !11
  %102 = sext i8 %101 to i32
  %103 = icmp eq i32 %102, 49
  br i1 %103, label %104, label %109

104:                                              ; preds = %100
  br label %181

105:                                              ; preds = %93
  %106 = landingpad { ptr, i32 }
          cleanup
  %107 = extractvalue { ptr, i32 } %106, 0
  store ptr %107, ptr %8, align 8
  %108 = extractvalue { ptr, i32 } %106, 1
  store i32 %108, ptr %9, align 4
  br label %186

109:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 1, ptr %15) #8
  store i8 1, ptr %15, align 1, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #8
  %110 = load i32, ptr %10, align 4, !tbaa !5
  store i32 %110, ptr %16, align 4, !tbaa !5
  br label %111

111:                                              ; preds = %151, %109
  %112 = load i32, ptr %16, align 4, !tbaa !5
  %113 = load i32, ptr %13, align 4, !tbaa !5
  %114 = add nsw i32 %113, 1
  %115 = icmp slt i32 %112, %114
  br i1 %115, label %117, label %116

116:                                              ; preds = %111
  store i32 17, ptr %11, align 4
  br label %154

117:                                              ; preds = %111
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #8
  %118 = load i32, ptr %12, align 4, !tbaa !5
  store i32 %118, ptr %17, align 4, !tbaa !5
  br label %119

119:                                              ; preds = %142, %117
  %120 = load i32, ptr %17, align 4, !tbaa !5
  %121 = load i32, ptr %14, align 4, !tbaa !5
  %122 = add nsw i32 %121, 1
  %123 = icmp slt i32 %120, %122
  br i1 %123, label %125, label %124

124:                                              ; preds = %119
  store i32 20, ptr %11, align 4
  br label %145

125:                                              ; preds = %119
  %126 = load i32, ptr %16, align 4, !tbaa !5
  %127 = sext i32 %126 to i64
  %128 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %127
  %129 = load i32, ptr %17, align 4, !tbaa !5
  %130 = sext i32 %129 to i64
  %131 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %128, i64 noundef %130)
          to label %132 unwind label %137

132:                                              ; preds = %125
  %133 = load i8, ptr %131, align 1, !tbaa !11
  %134 = sext i8 %133 to i32
  %135 = icmp eq i32 %134, 49
  br i1 %135, label %136, label %141

136:                                              ; preds = %132
  store i8 0, ptr %15, align 1, !tbaa !12
  store i32 20, ptr %11, align 4
  br label %145

137:                                              ; preds = %125
  %138 = landingpad { ptr, i32 }
          cleanup
  %139 = extractvalue { ptr, i32 } %138, 0
  store ptr %139, ptr %8, align 8
  %140 = extractvalue { ptr, i32 } %138, 1
  store i32 %140, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #8
  br label %184

141:                                              ; preds = %132
  br label %142

142:                                              ; preds = %141
  %143 = load i32, ptr %17, align 4, !tbaa !5
  %144 = add nsw i32 %143, 1
  store i32 %144, ptr %17, align 4, !tbaa !5
  br label %119, !llvm.loop !14

145:                                              ; preds = %136, %124
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #8
  br label %146

146:                                              ; preds = %145
  %147 = load i8, ptr %15, align 1, !tbaa !12, !range !15, !noundef !16
  %148 = trunc i8 %147 to i1
  br i1 %148, label %150, label %149

149:                                              ; preds = %146
  store i32 17, ptr %11, align 4
  br label %154

150:                                              ; preds = %146
  br label %151

151:                                              ; preds = %150
  %152 = load i32, ptr %16, align 4, !tbaa !5
  %153 = add nsw i32 %152, 1
  store i32 %153, ptr %16, align 4, !tbaa !5
  br label %111, !llvm.loop !17

154:                                              ; preds = %149, %116
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #8
  br label %155

155:                                              ; preds = %154
  %156 = load i8, ptr %15, align 1, !tbaa !12, !range !15, !noundef !16
  %157 = trunc i8 %156 to i1
  br i1 %157, label %159, label %158

158:                                              ; preds = %155
  store i32 14, ptr %11, align 4
  br label %178

159:                                              ; preds = %155
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #8
  %160 = load i32, ptr %13, align 4, !tbaa !5
  %161 = load i32, ptr %10, align 4, !tbaa !5
  %162 = sub nsw i32 %160, %161
  %163 = add nsw i32 %162, 1
  %164 = load i32, ptr %14, align 4, !tbaa !5
  %165 = load i32, ptr %12, align 4, !tbaa !5
  %166 = sub nsw i32 %164, %165
  %167 = add nsw i32 %166, 1
  %168 = add nsw i32 %163, %167
  %169 = mul nsw i32 2, %168
  store i32 %169, ptr %18, align 4, !tbaa !5
  %170 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %6, ptr noundef nonnull align 4 dereferenceable(4) %18)
          to label %171 unwind label %173

171:                                              ; preds = %159
  %172 = load i32, ptr %170, align 4, !tbaa !5
  store i32 %172, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  br label %177

173:                                              ; preds = %159
  %174 = landingpad { ptr, i32 }
          cleanup
  %175 = extractvalue { ptr, i32 } %174, 0
  store ptr %175, ptr %8, align 8
  %176 = extractvalue { ptr, i32 } %174, 1
  store i32 %176, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  br label %184

177:                                              ; preds = %171
  store i32 0, ptr %11, align 4
  br label %178

178:                                              ; preds = %177, %158
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #8
  %179 = load i32, ptr %11, align 4
  switch i32 %179, label %185 [
    i32 0, label %180
  ]

180:                                              ; preds = %178
  br label %181

181:                                              ; preds = %180, %104
  %182 = load i32, ptr %14, align 4, !tbaa !5
  %183 = add nsw i32 %182, 1
  store i32 %183, ptr %14, align 4, !tbaa !5
  br label %88, !llvm.loop !18

184:                                              ; preds = %173, %137
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #8
  br label %186

185:                                              ; preds = %178, %92
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #8
  br label %187

186:                                              ; preds = %184, %105
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  br label %195

187:                                              ; preds = %185
  br label %188

188:                                              ; preds = %187
  %189 = load i32, ptr %13, align 4, !tbaa !5
  %190 = add nsw i32 %189, 1
  store i32 %190, ptr %13, align 4, !tbaa !5
  br label %81, !llvm.loop !19

191:                                              ; preds = %85
  br label %192

192:                                              ; preds = %191, %74
  %193 = load i32, ptr %12, align 4, !tbaa !5
  %194 = add nsw i32 %193, 1
  store i32 %194, ptr %12, align 4, !tbaa !5
  br label %58, !llvm.loop !20

195:                                              ; preds = %186, %75
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #8
  br label %212

196:                                              ; preds = %62
  br label %197

197:                                              ; preds = %196
  %198 = load i32, ptr %10, align 4, !tbaa !5
  %199 = add nsw i32 %198, 1
  store i32 %199, ptr %10, align 4, !tbaa !5
  br label %52, !llvm.loop !21

200:                                              ; preds = %56
  %201 = load i32, ptr %6, align 4, !tbaa !5
  %202 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %201)
          to label %203 unwind label %208

203:                                              ; preds = %200
  %204 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %202, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %205 unwind label %208

205:                                              ; preds = %203
  store i32 0, ptr %1, align 4
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #8
  %206 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %22
  %207 = icmp eq ptr %24, %206
  br i1 %207, label %219, label %215

208:                                              ; preds = %203, %200
  %209 = landingpad { ptr, i32 }
          cleanup
  %210 = extractvalue { ptr, i32 } %209, 0
  store ptr %210, ptr %8, align 8
  %211 = extractvalue { ptr, i32 } %209, 1
  store i32 %211, ptr %9, align 4
  br label %212

212:                                              ; preds = %208, %195, %47
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #8
  %213 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %24, i64 %22
  %214 = icmp eq ptr %24, %213
  br i1 %214, label %226, label %222

215:                                              ; preds = %215, %205
  %216 = phi ptr [ %206, %205 ], [ %217, %215 ]
  %217 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %216, i64 -1
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %217) #8
  %218 = icmp eq ptr %217, %24
  br i1 %218, label %219, label %215

219:                                              ; preds = %215, %205
  %220 = load ptr, ptr %4, align 8
  call void @llvm.stackrestore.p0(ptr %220)
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #8
  %221 = load i32, ptr %1, align 4
  ret i32 %221

222:                                              ; preds = %222, %212
  %223 = phi ptr [ %213, %212 ], [ %224, %222 ]
  %224 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %223, i64 -1
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %224) #8
  %225 = icmp eq ptr %224, %24
  br i1 %225, label %226, label %222

226:                                              ; preds = %222, %212
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #8
  br label %227

227:                                              ; preds = %226
  %228 = load ptr, ptr %8, align 8
  %229 = load i32, ptr %9, align 4
  %230 = insertvalue { ptr, i32 } poison, ptr %228, 0
  %231 = insertvalue { ptr, i32 } %230, i32 %229, 1
  resume { ptr, i32 } %231
}

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) #2

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 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)) #2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #5

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

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

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

; 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: nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #3

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 = { "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 }
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 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 = { 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 = { 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 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"bool", !7, i64 0}
!14 = distinct !{!14, !10}
!15 = !{i8 0, i8 2}
!16 = !{}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}


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

@_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 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #8
  %5 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %1)
  %6 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull align 4 dereferenceable(4) %2)
  %7 = load i32, ptr %1, align 4, !tbaa !5
  %8 = zext i32 %7 to i64
  %9 = call ptr @llvm.stacksave.p0()
  %10 = alloca %"class.std::__cxx11::basic_string", i64 %8, align 16
  %11 = icmp eq i32 %7, 0
  br i1 %11, label %.loopexit65, label %12

12:                                               ; preds = %0
  %13 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %8
  br label %14

14:                                               ; preds = %14, %12
  %15 = phi ptr [ %10, %12 ], [ %16, %14 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %15) #8
  %16 = getelementptr inbounds i8, ptr %15, i64 32
  %17 = icmp eq ptr %16, %13
  br i1 %17, label %.loopexit65, label %14

.loopexit65:                                      ; preds = %14, %0
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #8
  store i32 0, ptr %3, align 4, !tbaa !5
  %18 = load i32, ptr %1, align 4, !tbaa !5
  %19 = icmp sgt i32 %18, 0
  br i1 %19, label %.lr.ph, label %._crit_edge84

.preheader64:                                     ; preds = %25
  %20 = icmp sgt i32 %26, 0
  %21 = load i32, ptr %2, align 4
  %22 = icmp sgt i32 %21, 0
  %or.cond132 = select i1 %20, i1 %22, i1 false
  br i1 %or.cond132, label %.preheader63, label %._crit_edge84

.lr.ph:                                           ; preds = %.loopexit65, %25
  %indvars.iv = phi i64 [ %indvars.iv.next, %25 ], [ 0, %.loopexit65 ]
  %23 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %indvars.iv
  %24 = 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) %23)
          to label %25 unwind label %29

25:                                               ; preds = %.lr.ph
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %26 = load i32, ptr %1, align 4, !tbaa !5
  %27 = sext i32 %26 to i64
  %28 = icmp slt i64 %indvars.iv.next, %27
  br i1 %28, label %.lr.ph, label %.preheader64, !llvm.loop !9

29:                                               ; preds = %.lr.ph
  %30 = landingpad { ptr, i32 }
          cleanup
  br label %101

.preheader63:                                     ; preds = %.preheader64, %._crit_edge82
  %31 = phi i32 [ %37, %._crit_edge82 ], [ %26, %.preheader64 ]
  %32 = phi i32 [ %38, %._crit_edge82 ], [ %21, %.preheader64 ]
  %indvars.iv101 = phi i64 [ %indvars.iv.next102, %._crit_edge82 ], [ 0, %.preheader64 ]
  %33 = icmp sgt i32 %32, 0
  br i1 %33, label %.lr.ph81, label %._crit_edge82

.lr.ph81:                                         ; preds = %.preheader63
  %34 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %indvars.iv101
  br label %41

._crit_edge84:                                    ; preds = %._crit_edge82, %.loopexit65, %.preheader64
  %35 = load i32, ptr %3, align 4, !tbaa !5
  %36 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %35)
          to label %95 unwind label %99

._crit_edge82:                                    ; preds = %.loopexit62, %.preheader63
  %37 = phi i32 [ %31, %.preheader63 ], [ %91, %.loopexit62 ]
  %38 = phi i32 [ %32, %.preheader63 ], [ %92, %.loopexit62 ]
  %indvars.iv.next102 = add nuw nsw i64 %indvars.iv101, 1
  %39 = sext i32 %37 to i64
  %40 = icmp slt i64 %indvars.iv.next102, %39
  br i1 %40, label %.preheader63, label %._crit_edge84, !llvm.loop !11

41:                                               ; preds = %.lr.ph81, %.loopexit62
  %indvars.iv106 = phi i64 [ 1, %.lr.ph81 ], [ %indvars.iv.next107, %.loopexit62 ]
  %indvars.iv92 = phi i64 [ 0, %.lr.ph81 ], [ %indvars.iv.next93, %.loopexit62 ]
  %42 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %34, i64 noundef %indvars.iv92)
  %43 = load i8, ptr %42, align 1, !tbaa !13
  %44 = icmp ne i8 %43, 49
  %45 = load i32, ptr %1, align 4
  %46 = sext i32 %45 to i64
  %47 = icmp slt i64 %indvars.iv101, %46
  %or.cond = select i1 %44, i1 %47, i1 false
  %.pre125 = load i32, ptr %2, align 4, !tbaa !5
  br i1 %or.cond, label %.preheader59.lr.ph, label %.loopexit62

.preheader59.lr.ph:                               ; preds = %41
  %48 = add nuw nsw i64 %indvars.iv92, %indvars.iv101
  %49 = sext i32 %.pre125 to i64
  %50 = icmp slt i64 %indvars.iv92, %49
  br i1 %50, label %.preheader59, label %.loopexit62

.preheader59:                                     ; preds = %.preheader59.lr.ph, %.critedge
  %indvars.iv118 = phi i64 [ %indvars.iv.next119, %.critedge ], [ %indvars.iv101, %.preheader59.lr.ph ]
  %51 = load i32, ptr %2, align 4, !tbaa !5
  %52 = sext i32 %51 to i64
  %53 = icmp slt i64 %indvars.iv92, %52
  br i1 %53, label %.lr.ph74, label %.critedge

.lr.ph74:                                         ; preds = %.preheader59
  %54 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %indvars.iv118
  %.not70 = icmp ugt i64 %indvars.iv101, %indvars.iv118
  %55 = sub nsw i64 %indvars.iv118, %48
  %.not70.fr = freeze i1 %.not70
  br i1 %.not70.fr, label %.lr.ph74.split.us, label %.lr.ph74.split

.lr.ph74.split.us:                                ; preds = %.lr.ph74, %59
  %indvars.iv115 = phi i64 [ %indvars.iv.next116, %59 ], [ %indvars.iv92, %.lr.ph74 ]
  %56 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %54, i64 noundef %indvars.iv115)
  %57 = load i8, ptr %56, align 1, !tbaa !13
  %58 = icmp eq i8 %57, 49
  br i1 %58, label %59, label %.preheader58.us

59:                                               ; preds = %.preheader58.us, %.lr.ph74.split.us
  %indvars.iv.next116 = add nuw nsw i64 %indvars.iv115, 1
  %60 = load i32, ptr %2, align 4, !tbaa !5
  %61 = trunc nuw i64 %indvars.iv.next116 to i32
  %62 = icmp sgt i32 %60, %61
  br i1 %62, label %.lr.ph74.split.us, label %.critedge, !llvm.loop !14

.preheader58.us:                                  ; preds = %.lr.ph74.split.us
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #8
  %63 = add nsw i64 %55, %indvars.iv115
  %64 = trunc nuw i64 %63 to i32
  %65 = shl i32 %64, 1
  %66 = add i32 %65, 4
  store i32 %66, ptr %4, align 4, !tbaa !5
  %67 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %3, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %68 = load i32, ptr %67, align 4, !tbaa !5
  store i32 %68, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  br label %59

.lr.ph74.split:                                   ; preds = %.lr.ph74, %84
  %indvars.iv110 = phi i64 [ %indvars.iv.next111, %84 ], [ %indvars.iv92, %.lr.ph74 ]
  %indvars.iv108 = phi i64 [ %indvars.iv.next109, %84 ], [ %indvars.iv106, %.lr.ph74 ]
  %69 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %54, i64 noundef %indvars.iv110)
  %70 = load i8, ptr %69, align 1, !tbaa !13
  %71 = icmp eq i8 %70, 49
  br i1 %71, label %84, label %.preheader58

.preheader58:                                     ; preds = %.lr.ph74.split
  %.not5067 = icmp ugt i64 %indvars.iv92, %indvars.iv110
  br i1 %.not5067, label %._crit_edge72, label %.preheader57

.preheader57:                                     ; preds = %.preheader58, %._crit_edge
  %indvars.iv103 = phi i64 [ %indvars.iv.next104, %._crit_edge ], [ %indvars.iv101, %.preheader58 ]
  %72 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %indvars.iv103
  br label %74

73:                                               ; preds = %74
  %indvars.iv.next95 = add nuw nsw i64 %indvars.iv94, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next95, %indvars.iv108
  br i1 %exitcond.not, label %._crit_edge, label %74, !llvm.loop !15

74:                                               ; preds = %.preheader57, %73
  %indvars.iv94 = phi i64 [ %indvars.iv92, %.preheader57 ], [ %indvars.iv.next95, %73 ]
  %75 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %72, i64 noundef %indvars.iv94)
  %76 = load i8, ptr %75, align 1, !tbaa !13
  %77 = icmp eq i8 %76, 49
  br i1 %77, label %.critedge, label %73

._crit_edge:                                      ; preds = %73
  %indvars.iv.next104 = add nuw nsw i64 %indvars.iv103, 1
  %.not.not = icmp ult i64 %indvars.iv103, %indvars.iv118
  br i1 %.not.not, label %.preheader57, label %._crit_edge72, !llvm.loop !16

._crit_edge72:                                    ; preds = %._crit_edge, %.preheader58
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #8
  %78 = add nsw i64 %55, %indvars.iv110
  %79 = trunc nuw i64 %78 to i32
  %80 = shl i32 %79, 1
  %81 = add i32 %80, 4
  store i32 %81, ptr %4, align 4, !tbaa !5
  %82 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %3, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %83 = load i32, ptr %82, align 4, !tbaa !5
  store i32 %83, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  br label %84

84:                                               ; preds = %._crit_edge72, %.lr.ph74.split
  %indvars.iv.next111 = add nuw nsw i64 %indvars.iv110, 1
  %85 = load i32, ptr %2, align 4, !tbaa !5
  %86 = sext i32 %85 to i64
  %87 = icmp slt i64 %indvars.iv.next111, %86
  %indvars.iv.next109 = add nuw nsw i64 %indvars.iv108, 1
  br i1 %87, label %.lr.ph74.split, label %.critedge, !llvm.loop !14

.critedge:                                        ; preds = %84, %59, %74, %.preheader59
  %indvars.iv.next119 = add nuw nsw i64 %indvars.iv118, 1
  %88 = load i32, ptr %1, align 4, !tbaa !5
  %89 = sext i32 %88 to i64
  %90 = icmp slt i64 %indvars.iv.next119, %89
  br i1 %90, label %.preheader59, label %.loopexit62.loopexit, !llvm.loop !17

.loopexit62.loopexit:                             ; preds = %.critedge
  %.pre = load i32, ptr %2, align 4, !tbaa !5
  br label %.loopexit62

.loopexit62:                                      ; preds = %.preheader59.lr.ph, %.loopexit62.loopexit, %41
  %91 = phi i32 [ %88, %.loopexit62.loopexit ], [ %45, %41 ], [ %45, %.preheader59.lr.ph ]
  %92 = phi i32 [ %.pre, %.loopexit62.loopexit ], [ %.pre125, %41 ], [ %.pre125, %.preheader59.lr.ph ]
  %indvars.iv.next93 = add nuw nsw i64 %indvars.iv92, 1
  %93 = sext i32 %92 to i64
  %94 = icmp slt i64 %indvars.iv.next93, %93
  %indvars.iv.next107 = add nuw nsw i64 %indvars.iv106, 1
  br i1 %94, label %41, label %._crit_edge82, !llvm.loop !18

95:                                               ; preds = %._crit_edge84
  %96 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %36, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %97 unwind label %99

97:                                               ; preds = %95
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br i1 %11, label %.loopexit56, label %.preheader55.preheader

.preheader55.preheader:                           ; preds = %97
  %98 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %8
  br label %.preheader55

99:                                               ; preds = %95, %._crit_edge84
  %100 = landingpad { ptr, i32 }
          cleanup
  br label %101

101:                                              ; preds = %99, %29
  %.pn = phi { ptr, i32 } [ %30, %29 ], [ %100, %99 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br i1 %11, label %.loopexit, label %.preheader.preheader

.preheader.preheader:                             ; preds = %101
  %102 = getelementptr inbounds %"class.std::__cxx11::basic_string", ptr %10, i64 %8
  br label %.preheader

.preheader55:                                     ; preds = %.preheader55.preheader, %.preheader55
  %103 = phi ptr [ %104, %.preheader55 ], [ %98, %.preheader55.preheader ]
  %104 = getelementptr inbounds i8, ptr %103, i64 -32
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %104) #8
  %105 = icmp eq ptr %104, %10
  br i1 %105, label %.loopexit56, label %.preheader55

.loopexit56:                                      ; preds = %.preheader55, %97
  call void @llvm.stackrestore.p0(ptr %9)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #8
  ret i32 0

.preheader:                                       ; preds = %.preheader.preheader, %.preheader
  %106 = phi ptr [ %107, %.preheader ], [ %102, %.preheader.preheader ]
  %107 = getelementptr inbounds i8, ptr %106, i64 -32
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %107) #8
  %108 = icmp eq ptr %107, %10
  br i1 %108, label %.loopexit, label %.preheader

.loopexit:                                        ; preds = %.preheader, %101
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #8
  resume { ptr, i32 } %.pn
}

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 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 #2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #5

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

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

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

; 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 nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #3

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 = { "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 }
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 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 = { 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 = { 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 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10, !12}
!12 = !{!"llvm.loop.unswitch.partial.disable"}
!13 = !{!7, !7, i64 0}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10, !12}
!18 = distinct !{!18, !10}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimpleLoopUnswitchPass,SimplifyCFGPass