; LLVM IR from dynexcoin/Dynex :: src/Common/JsonValue.ll (ZN6Common9JsonValue10readNumberERSic)

; 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::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon.6 }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon.6 = type { i64, [8 x i8] }
%"class.std::__cxx11::basic_istringstream" = type { %"class.std::basic_istream.base", %"class.std::__cxx11::basic_stringbuf", %"class.std::basic_ios" }
%"class.std::basic_istream.base" = type { ptr, i64 }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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.Common::JsonValue" = type { i32, %union.anon }
%union.anon = type { i64, [40 x i8] }

@_ZTISt13runtime_error = external constant ptr
@.str.14 = external hidden unnamed_addr constant [16 x i8], align 1

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

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

declare ptr @__cxa_allocate_exception(i64)

declare void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #1

declare i32 @__gxx_personality_v0(...)

declare void @__cxa_free_exception(ptr)

; Function Attrs: nounwind
declare void @_ZNSt13runtime_errorD1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2

declare void @__cxa_throw(ptr, ptr, ptr)

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Common9JsonValue13destructValueEv(ptr noundef nonnull align 8 dereferenceable(56)) #0 align 2

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

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

; Function Attrs: mustprogress uwtable
declare void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(120), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #4 align 2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN6Common9JsonValue10readNumberERSic(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(16) %1, i8 noundef signext %2) #4 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i8, align 1
  %7 = alloca %"class.std::__cxx11::basic_string", align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i64, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca double, align 8
  %15 = alloca %"class.std::__cxx11::basic_istringstream", align 8
  %16 = alloca i64, align 8
  %17 = alloca %"class.std::__cxx11::basic_istringstream", align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i8 %2, ptr %6, align 1, !tbaa !9
  %18 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr %7) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #6
  %19 = load i8, ptr %6, align 1, !tbaa !9
  %20 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext %19)
          to label %21 unwind label %38

21:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  store i64 0, ptr %10, align 8, !tbaa !10
  br label %22

22:                                               ; preds = %62, %21
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  %23 = load ptr, ptr %5, align 8, !tbaa !5
  %24 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %23)
          to label %25 unwind label %42

25:                                               ; preds = %22
  store i32 %24, ptr %11, align 4, !tbaa !12
  %26 = load i32, ptr %11, align 4, !tbaa !12
  %27 = icmp sge i32 %26, 48
  br i1 %27, label %28, label %46

28:                                               ; preds = %25
  %29 = load i32, ptr %11, align 4, !tbaa !12
  %30 = icmp sle i32 %29, 57
  br i1 %30, label %31, label %46

31:                                               ; preds = %28
  %32 = load ptr, ptr %5, align 8, !tbaa !5
  %33 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %32, ptr noundef %6, i64 noundef 1)
          to label %34 unwind label %42

34:                                               ; preds = %31
  %35 = load i8, ptr %6, align 1, !tbaa !9
  %36 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext %35)
          to label %37 unwind label %42

37:                                               ; preds = %34
  br label %59

38:                                               ; preds = %3
  %39 = landingpad { ptr, i32 }
          cleanup
  %40 = extractvalue { ptr, i32 } %39, 0
  store ptr %40, ptr %8, align 8
  %41 = extractvalue { ptr, i32 } %39, 1
  store i32 %41, ptr %9, align 4
  br label %234

42:                                               ; preds = %52, %49, %34, %31, %22
  %43 = landingpad { ptr, i32 }
          cleanup
  %44 = extractvalue { ptr, i32 } %43, 0
  store ptr %44, ptr %8, align 8
  %45 = extractvalue { ptr, i32 } %43, 1
  store i32 %45, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  br label %233

46:                                               ; preds = %28, %25
  %47 = load i32, ptr %11, align 4, !tbaa !12
  %48 = icmp eq i32 %47, 46
  br i1 %48, label %49, label %57

49:                                               ; preds = %46
  %50 = load ptr, ptr %5, align 8, !tbaa !5
  %51 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %50, ptr noundef %6, i64 noundef 1)
          to label %52 unwind label %42

52:                                               ; preds = %49
  %53 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext 46)
          to label %54 unwind label %42

54:                                               ; preds = %52
  %55 = load i64, ptr %10, align 8, !tbaa !10
  %56 = add i64 %55, 1
  store i64 %56, ptr %10, align 8, !tbaa !10
  br label %58

57:                                               ; preds = %46
  store i32 2, ptr %12, align 4
  br label %60

58:                                               ; preds = %54
  br label %59

59:                                               ; preds = %58, %37
  store i32 0, ptr %12, align 4
  br label %60

60:                                               ; preds = %59, %57
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  %61 = load i32, ptr %12, align 4
  switch i32 %61, label %240 [
    i32 0, label %62
    i32 2, label %63
  ]

62:                                               ; preds = %60
  br label %22, !llvm.loop !14

63:                                               ; preds = %60
  %64 = load i64, ptr %10, align 8, !tbaa !10
  %65 = icmp ugt i64 %64, 0
  br i1 %65, label %66, label %183

66:                                               ; preds = %63
  %67 = load i64, ptr %10, align 8, !tbaa !10
  %68 = icmp ugt i64 %67, 1
  br i1 %68, label %69, label %80

69:                                               ; preds = %66
  %70 = call ptr @__cxa_allocate_exception(i64 16) #6
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %70, ptr noundef @.str.14)
          to label %71 unwind label %72

71:                                               ; preds = %69
  invoke void @__cxa_throw(ptr %70, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #7
          to label %240 unwind label %76

72:                                               ; preds = %69
  %73 = landingpad { ptr, i32 }
          cleanup
  %74 = extractvalue { ptr, i32 } %73, 0
  store ptr %74, ptr %8, align 8
  %75 = extractvalue { ptr, i32 } %73, 1
  store i32 %75, ptr %9, align 4
  call void @__cxa_free_exception(ptr %70) #6
  br label %233

76:                                               ; preds = %206, %198, %192, %186, %71
  %77 = landingpad { ptr, i32 }
          cleanup
  %78 = extractvalue { ptr, i32 } %77, 0
  store ptr %78, ptr %8, align 8
  %79 = extractvalue { ptr, i32 } %77, 1
  store i32 %79, ptr %9, align 4
  br label %233

80:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  %81 = load ptr, ptr %5, align 8, !tbaa !5
  %82 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %81)
          to label %83 unwind label %110

83:                                               ; preds = %80
  store i32 %82, ptr %13, align 4, !tbaa !12
  %84 = load ptr, ptr %5, align 8, !tbaa !5
  %85 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %84)
          to label %86 unwind label %110

86:                                               ; preds = %83
  %87 = icmp eq i32 %85, 101
  br i1 %87, label %88, label %161

88:                                               ; preds = %86
  %89 = load ptr, ptr %5, align 8, !tbaa !5
  %90 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %89, ptr noundef %6, i64 noundef 1)
          to label %91 unwind label %110

91:                                               ; preds = %88
  %92 = load i8, ptr %6, align 1, !tbaa !9
  %93 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext %92)
          to label %94 unwind label %110

94:                                               ; preds = %91
  %95 = load ptr, ptr %5, align 8, !tbaa !5
  %96 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %95)
          to label %97 unwind label %110

97:                                               ; preds = %94
  store i32 %96, ptr %13, align 4, !tbaa !12
  %98 = load i32, ptr %13, align 4, !tbaa !12
  %99 = icmp eq i32 %98, 43
  br i1 %99, label %100, label %114

100:                                              ; preds = %97
  %101 = load ptr, ptr %5, align 8, !tbaa !5
  %102 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %101, ptr noundef %6, i64 noundef 1)
          to label %103 unwind label %110

103:                                              ; preds = %100
  %104 = load i8, ptr %6, align 1, !tbaa !9
  %105 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext %104)
          to label %106 unwind label %110

106:                                              ; preds = %103
  %107 = load ptr, ptr %5, align 8, !tbaa !5
  %108 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %107)
          to label %109 unwind label %110

109:                                              ; preds = %106
  store i32 %108, ptr %13, align 4, !tbaa !12
  br label %128

110:                                              ; preds = %148, %145, %142, %136, %123, %120, %117, %106, %103, %100, %94, %91, %88, %83, %80
  %111 = landingpad { ptr, i32 }
          cleanup
  %112 = extractvalue { ptr, i32 } %111, 0
  store ptr %112, ptr %8, align 8
  %113 = extractvalue { ptr, i32 } %111, 1
  store i32 %113, ptr %9, align 4
  br label %182

114:                                              ; preds = %97
  %115 = load i32, ptr %13, align 4, !tbaa !12
  %116 = icmp eq i32 %115, 45
  br i1 %116, label %117, label %127

117:                                              ; preds = %114
  %118 = load ptr, ptr %5, align 8, !tbaa !5
  %119 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %118, ptr noundef %6, i64 noundef 1)
          to label %120 unwind label %110

120:                                              ; preds = %117
  %121 = load i8, ptr %6, align 1, !tbaa !9
  %122 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext %121)
          to label %123 unwind label %110

123:                                              ; preds = %120
  %124 = load ptr, ptr %5, align 8, !tbaa !5
  %125 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %124)
          to label %126 unwind label %110

126:                                              ; preds = %123
  store i32 %125, ptr %13, align 4, !tbaa !12
  br label %127

127:                                              ; preds = %126, %114
  br label %128

128:                                              ; preds = %127, %109
  %129 = load i32, ptr %13, align 4, !tbaa !12
  %130 = icmp slt i32 %129, 48
  br i1 %130, label %134, label %131

131:                                              ; preds = %128
  %132 = load i32, ptr %13, align 4, !tbaa !12
  %133 = icmp sgt i32 %132, 57
  br i1 %133, label %134, label %141

134:                                              ; preds = %131, %128
  %135 = call ptr @__cxa_allocate_exception(i64 16) #6
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %135, ptr noundef @.str.14)
          to label %136 unwind label %137

136:                                              ; preds = %134
  invoke void @__cxa_throw(ptr %135, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #7
          to label %240 unwind label %110

137:                                              ; preds = %134
  %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 @__cxa_free_exception(ptr %135) #6
  br label %182

141:                                              ; preds = %131
  br label %142

142:                                              ; preds = %158, %141
  %143 = load ptr, ptr %5, align 8, !tbaa !5
  %144 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %143, ptr noundef %6, i64 noundef 1)
          to label %145 unwind label %110

145:                                              ; preds = %142
  %146 = load i8, ptr %6, align 1, !tbaa !9
  %147 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %7, i8 noundef signext %146)
          to label %148 unwind label %110

148:                                              ; preds = %145
  %149 = load ptr, ptr %5, align 8, !tbaa !5
  %150 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %149)
          to label %151 unwind label %110

151:                                              ; preds = %148
  store i32 %150, ptr %13, align 4, !tbaa !12
  br label %152

152:                                              ; preds = %151
  %153 = load i32, ptr %13, align 4, !tbaa !12
  %154 = icmp sge i32 %153, 48
  br i1 %154, label %155, label %158

155:                                              ; preds = %152
  %156 = load i32, ptr %13, align 4, !tbaa !12
  %157 = icmp sle i32 %156, 57
  br label %158

158:                                              ; preds = %155, %152
  %159 = phi i1 [ false, %152 ], [ %157, %155 ]
  br i1 %159, label %142, label %160, !llvm.loop !16

160:                                              ; preds = %158
  br label %161

161:                                              ; preds = %160, %86
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.start.p0(i64 384, ptr %15) #6
  invoke void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(120) %15, ptr noundef nonnull align 8 dereferenceable(32) %7, i32 noundef 8)
          to label %162 unwind label %170

162:                                              ; preds = %161
  %163 = invoke noundef nonnull align 8 dereferenceable(120) ptr @_ZStrsINSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEERdEOT_S8_OT0_(ptr noundef nonnull align 8 dereferenceable(120) %15, ptr noundef nonnull align 8 dereferenceable(8) %14)
          to label %164 unwind label %174

164:                                              ; preds = %162
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %15) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr %15) #6
  %165 = getelementptr inbounds %"class.Common::JsonValue", ptr %18, i32 0, i32 0
  %166 = load i32, ptr %165, align 8, !tbaa !17
  %167 = icmp ne i32 %166, 5
  br i1 %167, label %168, label %179

168:                                              ; preds = %164
  call void @_ZN6Common9JsonValue13destructValueEv(ptr noundef nonnull align 8 dereferenceable(56) %18)
  %169 = getelementptr inbounds %"class.Common::JsonValue", ptr %18, i32 0, i32 0
  store i32 5, ptr %169, align 8, !tbaa !17
  br label %179

170:                                              ; preds = %161
  %171 = landingpad { ptr, i32 }
          cleanup
  %172 = extractvalue { ptr, i32 } %171, 0
  store ptr %172, ptr %8, align 8
  %173 = extractvalue { ptr, i32 } %171, 1
  store i32 %173, ptr %9, align 4
  br label %178

174:                                              ; preds = %162
  %175 = landingpad { ptr, i32 }
          cleanup
  %176 = extractvalue { ptr, i32 } %175, 0
  store ptr %176, ptr %8, align 8
  %177 = extractvalue { ptr, i32 } %175, 1
  store i32 %177, ptr %9, align 4
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %15) #6
  br label %178

178:                                              ; preds = %174, %170
  call void @llvm.lifetime.end.p0(i64 384, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  br label %182

179:                                              ; preds = %168, %164
  %180 = load double, ptr %14, align 8, !tbaa !20
  %181 = getelementptr inbounds %"class.Common::JsonValue", ptr %18, i32 0, i32 1
  store double %180, ptr %181, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  br label %232

182:                                              ; preds = %178, %137, %110
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  br label %233

183:                                              ; preds = %63
  %184 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %7) #6
  %185 = icmp ugt i64 %184, 1
  br i1 %185, label %186, label %211

186:                                              ; preds = %183
  %187 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %7, i64 noundef 0)
          to label %188 unwind label %76

188:                                              ; preds = %186
  %189 = load i8, ptr %187, align 1, !tbaa !9
  %190 = sext i8 %189 to i32
  %191 = icmp eq i32 %190, 48
  br i1 %191, label %204, label %192

192:                                              ; preds = %188
  %193 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %7, i64 noundef 0)
          to label %194 unwind label %76

194:                                              ; preds = %192
  %195 = load i8, ptr %193, align 1, !tbaa !9
  %196 = sext i8 %195 to i32
  %197 = icmp eq i32 %196, 45
  br i1 %197, label %198, label %211

198:                                              ; preds = %194
  %199 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %7, i64 noundef 1)
          to label %200 unwind label %76

200:                                              ; preds = %198
  %201 = load i8, ptr %199, align 1, !tbaa !9
  %202 = sext i8 %201 to i32
  %203 = icmp eq i32 %202, 48
  br i1 %203, label %204, label %211

204:                                              ; preds = %200, %188
  %205 = call ptr @__cxa_allocate_exception(i64 16) #6
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %205, ptr noundef @.str.14)
          to label %206 unwind label %207

206:                                              ; preds = %204
  invoke void @__cxa_throw(ptr %205, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #7
          to label %240 unwind label %76

207:                                              ; preds = %204
  %208 = landingpad { ptr, i32 }
          cleanup
  %209 = extractvalue { ptr, i32 } %208, 0
  store ptr %209, ptr %8, align 8
  %210 = extractvalue { ptr, i32 } %208, 1
  store i32 %210, ptr %9, align 4
  call void @__cxa_free_exception(ptr %205) #6
  br label %233

211:                                              ; preds = %200, %194, %183
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.start.p0(i64 384, ptr %17) #6
  invoke void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(120) %17, ptr noundef nonnull align 8 dereferenceable(32) %7, i32 noundef 8)
          to label %212 unwind label %220

212:                                              ; preds = %211
  %213 = invoke noundef nonnull align 8 dereferenceable(120) ptr @_ZStrsINSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEERlEOT_S8_OT0_(ptr noundef nonnull align 8 dereferenceable(120) %17, ptr noundef nonnull align 8 dereferenceable(8) %16)
          to label %214 unwind label %224

214:                                              ; preds = %212
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %17) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr %17) #6
  %215 = getelementptr inbounds %"class.Common::JsonValue", ptr %18, i32 0, i32 0
  %216 = load i32, ptr %215, align 8, !tbaa !17
  %217 = icmp ne i32 %216, 2
  br i1 %217, label %218, label %229

218:                                              ; preds = %214
  call void @_ZN6Common9JsonValue13destructValueEv(ptr noundef nonnull align 8 dereferenceable(56) %18)
  %219 = getelementptr inbounds %"class.Common::JsonValue", ptr %18, i32 0, i32 0
  store i32 2, ptr %219, align 8, !tbaa !17
  br label %229

220:                                              ; preds = %211
  %221 = landingpad { ptr, i32 }
          cleanup
  %222 = extractvalue { ptr, i32 } %221, 0
  store ptr %222, ptr %8, align 8
  %223 = extractvalue { ptr, i32 } %221, 1
  store i32 %223, ptr %9, align 4
  br label %228

224:                                              ; preds = %212
  %225 = landingpad { ptr, i32 }
          cleanup
  %226 = extractvalue { ptr, i32 } %225, 0
  store ptr %226, ptr %8, align 8
  %227 = extractvalue { ptr, i32 } %225, 1
  store i32 %227, ptr %9, align 4
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %17) #6
  br label %228

228:                                              ; preds = %224, %220
  call void @llvm.lifetime.end.p0(i64 384, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %233

229:                                              ; preds = %218, %214
  %230 = load i64, ptr %16, align 8, !tbaa !10
  %231 = getelementptr inbounds %"class.Common::JsonValue", ptr %18, i32 0, i32 1
  store i64 %230, ptr %231, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %232

232:                                              ; preds = %229, %179
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %7) #6
  ret void

233:                                              ; preds = %228, %207, %182, %76, %72, %42
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  br label %234

234:                                              ; preds = %233, %38
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %7) #6
  br label %235

235:                                              ; preds = %234
  %236 = load ptr, ptr %8, align 8
  %237 = load i32, ptr %9, align 4
  %238 = insertvalue { ptr, i32 } poison, ptr %236, 0
  %239 = insertvalue { ptr, i32 } %238, i32 %237, 1
  resume { ptr, i32 } %239

240:                                              ; preds = %206, %136, %71, %60
  unreachable
}

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef, i64 noundef) #1

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

declare noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16)) #1

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

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

attributes #0 = { 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 #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }
attributes #7 = { noreturn }

!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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!7, !7, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"long", !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = distinct !{!16, !15}
!17 = !{!18, !19, i64 0}
!18 = !{!"_ZTSN6Common9JsonValueE", !19, i64 0, !7, i64 8}
!19 = !{!"_ZTSN6Common9JsonValue4TypeE", !7, i64 0}
!20 = !{!21, !21, i64 0}
!21 = !{!"double", !7, i64 0}


; 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::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon.6 }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon.6 = type { i64, [8 x i8] }
%"class.std::__cxx11::basic_istringstream" = type { %"class.std::basic_istream.base", %"class.std::__cxx11::basic_stringbuf", %"class.std::basic_ios" }
%"class.std::basic_istream.base" = type { ptr, i64 }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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 }

@_ZTISt13runtime_error = external constant ptr
@.str.14 = external hidden unnamed_addr constant [16 x i8], align 1

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

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

declare ptr @__cxa_allocate_exception(i64) local_unnamed_addr

declare void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #1

declare i32 @__gxx_personality_v0(...)

declare void @__cxa_free_exception(ptr) local_unnamed_addr

; Function Attrs: nounwind
declare void @_ZNSt13runtime_errorD1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2

declare void @__cxa_throw(ptr, ptr, ptr) local_unnamed_addr

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Common9JsonValue13destructValueEv(ptr noundef nonnull align 8 dereferenceable(56)) local_unnamed_addr #0 align 2

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

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

; Function Attrs: mustprogress uwtable
declare void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(120), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #4 align 2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN6Common9JsonValue10readNumberERSic(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(16) %1, i8 noundef signext %2) local_unnamed_addr #4 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca i8, align 1
  %5 = alloca %"class.std::__cxx11::basic_string", align 8
  %6 = alloca double, align 8
  %7 = alloca %"class.std::__cxx11::basic_istringstream", align 8
  %8 = alloca i64, align 8
  %9 = alloca %"class.std::__cxx11::basic_istringstream", align 8
  store i8 %2, ptr %4, align 1, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #6
  %10 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %5, i8 noundef signext %2)
          to label %.preheader58.outer unwind label %19

.preheader58.outer:                               ; preds = %3, %27
  %.033.ph = phi i64 [ %28, %27 ], [ 0, %3 ]
  br label %.preheader58

.preheader58:                                     ; preds = %.preheader58.outer, %16
  %11 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
          to label %12 unwind label %.loopexit66

12:                                               ; preds = %.preheader58
  %13 = add i32 %11, -48
  %or.cond = icmp ult i32 %13, 10
  br i1 %or.cond, label %14, label %21

14:                                               ; preds = %12
  %15 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull %4, i64 noundef 1)
          to label %16 unwind label %.loopexit66

16:                                               ; preds = %14
  %17 = load i8, ptr %4, align 1, !tbaa !5
  %18 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %5, i8 noundef signext %17)
          to label %.preheader58 unwind label %.loopexit66

19:                                               ; preds = %3
  %20 = landingpad { ptr, i32 }
          cleanup
  br label %118

.loopexit66:                                      ; preds = %.preheader58, %14, %16
  %lpad.loopexit68 = landingpad { ptr, i32 }
          cleanup
  br label %118

.loopexit.split-lp67:                             ; preds = %23, %25
  %lpad.loopexit.split-lp69 = landingpad { ptr, i32 }
          cleanup
  br label %118

21:                                               ; preds = %12
  %22 = icmp eq i32 %11, 46
  br i1 %22, label %23, label %29

23:                                               ; preds = %21
  %24 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull %4, i64 noundef 1)
          to label %25 unwind label %.loopexit.split-lp67

25:                                               ; preds = %23
  %26 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %5, i8 noundef signext 46)
          to label %27 unwind label %.loopexit.split-lp67

27:                                               ; preds = %25
  %28 = add i64 %.033.ph, 1
  br label %.preheader58.outer

29:                                               ; preds = %21
  switch i64 %.033.ph, label %30 [
    i64 0, label %83
    i64 1, label %36
  ]

30:                                               ; preds = %29
  %31 = call ptr @__cxa_allocate_exception(i64 16) #6
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %31, ptr noundef nonnull @.str.14)
          to label %.invoke unwind label %32

32:                                               ; preds = %30
  %33 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %31) #6
  br label %118

34:                                               ; preds = %.invoke
  %35 = landingpad { ptr, i32 }
          cleanup
  br label %118

36:                                               ; preds = %29
  %37 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
          to label %38 unwind label %.loopexit.split-lp

38:                                               ; preds = %36
  %39 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
          to label %40 unwind label %.loopexit.split-lp

40:                                               ; preds = %38
  %41 = icmp eq i32 %39, 101
  br i1 %41, label %42, label %.loopexit57

42:                                               ; preds = %40
  %43 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull %4, i64 noundef 1)
          to label %44 unwind label %.loopexit.split-lp

44:                                               ; preds = %42
  %45 = load i8, ptr %4, align 1, !tbaa !5
  %46 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %5, i8 noundef signext %45)
          to label %47 unwind label %.loopexit.split-lp

47:                                               ; preds = %44
  %48 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
          to label %49 unwind label %.loopexit.split-lp

49:                                               ; preds = %47
  switch i32 %48, label %54 [
    i32 43, label %.invoke65
    i32 45, label %.invoke65
  ]

.invoke65:                                        ; preds = %49, %49
  %50 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull %4, i64 noundef 1)
          to label %.invoke63 unwind label %.loopexit.split-lp

.invoke63:                                        ; preds = %.invoke65
  %51 = load i8, ptr %4, align 1, !tbaa !5
  %52 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %5, i8 noundef signext %51)
          to label %.invoke62 unwind label %.loopexit.split-lp

.invoke62:                                        ; preds = %.invoke63
  %53 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
          to label %54 unwind label %.loopexit.split-lp

.loopexit:                                        ; preds = %.preheader, %62, %65
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %118

.loopexit.split-lp:                               ; preds = %.invoke65, %.invoke63, %.invoke62, %36, %38, %42, %44, %47, %58
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %118

54:                                               ; preds = %.invoke62, %49
  %.0 = phi i32 [ %48, %49 ], [ %53, %.invoke62 ]
  %55 = add i32 %.0, -58
  %or.cond3 = icmp ult i32 %55, -10
  br i1 %or.cond3, label %56, label %.preheader

56:                                               ; preds = %54
  %57 = call ptr @__cxa_allocate_exception(i64 16) #6
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %57, ptr noundef nonnull @.str.14)
          to label %58 unwind label %59

58:                                               ; preds = %56
  invoke void @__cxa_throw(ptr nonnull %57, ptr nonnull @_ZTISt13runtime_error, ptr nonnull @_ZNSt13runtime_errorD1Ev) #7
          to label %119 unwind label %.loopexit.split-lp

59:                                               ; preds = %56
  %60 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %57) #6
  br label %118

.preheader:                                       ; preds = %54, %67
  %61 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull %4, i64 noundef 1)
          to label %62 unwind label %.loopexit

62:                                               ; preds = %.preheader
  %63 = load i8, ptr %4, align 1, !tbaa !5
  %64 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %5, i8 noundef signext %63)
          to label %65 unwind label %.loopexit

65:                                               ; preds = %62
  %66 = invoke noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
          to label %67 unwind label %.loopexit

67:                                               ; preds = %65
  %68 = add i32 %66, -48
  %69 = icmp ult i32 %68, 10
  br i1 %69, label %.preheader, label %.loopexit57, !llvm.loop !8

.loopexit57:                                      ; preds = %67, %40
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #6
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %7) #6
  invoke void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(120) %7, ptr noundef nonnull align 8 dereferenceable(32) %5, i32 noundef 8)
          to label %70 unwind label %75

70:                                               ; preds = %.loopexit57
  %71 = invoke noundef nonnull align 8 dereferenceable(120) ptr @_ZStrsINSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEERdEOT_S8_OT0_(ptr noundef nonnull align 8 dereferenceable(120) %7, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %72 unwind label %77

72:                                               ; preds = %70
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %7) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %7) #6
  %73 = load i32, ptr %0, align 8, !tbaa !10
  %.not47 = icmp eq i32 %73, 5
  br i1 %.not47, label %80, label %74

74:                                               ; preds = %72
  call void @_ZN6Common9JsonValue13destructValueEv(ptr noundef nonnull align 8 dereferenceable(56) %0)
  store i32 5, ptr %0, align 8, !tbaa !10
  br label %80

75:                                               ; preds = %.loopexit57
  %76 = landingpad { ptr, i32 }
          cleanup
  br label %79

77:                                               ; preds = %70
  %78 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %7) #6
  br label %79

79:                                               ; preds = %77, %75
  %.pn45 = phi { ptr, i32 } [ %78, %77 ], [ %76, %75 ]
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  br label %118

80:                                               ; preds = %74, %72
  %81 = load double, ptr %6, align 8, !tbaa !13
  %82 = getelementptr inbounds i8, ptr %0, i64 8
  store double %81, ptr %82, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  br label %117

83:                                               ; preds = %29
  %84 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %5) #6
  %85 = icmp ugt i64 %84, 1
  br i1 %85, label %86, label %103

86:                                               ; preds = %83
  %87 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %5, i64 noundef 0)
  %88 = load i8, ptr %87, align 1, !tbaa !5
  %89 = icmp eq i8 %88, 48
  br i1 %89, label %98, label %90

90:                                               ; preds = %86
  %91 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %5, i64 noundef 0)
  %92 = load i8, ptr %91, align 1, !tbaa !5
  %93 = icmp eq i8 %92, 45
  br i1 %93, label %94, label %103

94:                                               ; preds = %90
  %95 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %5, i64 noundef 1)
  %96 = load i8, ptr %95, align 1, !tbaa !5
  %97 = icmp eq i8 %96, 48
  br i1 %97, label %98, label %103

98:                                               ; preds = %94, %86
  %99 = call ptr @__cxa_allocate_exception(i64 16) #6
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %99, ptr noundef nonnull @.str.14)
          to label %.invoke unwind label %101

.invoke:                                          ; preds = %30, %98
  %100 = phi ptr [ %99, %98 ], [ %31, %30 ]
  invoke void @__cxa_throw(ptr nonnull %100, ptr nonnull @_ZTISt13runtime_error, ptr nonnull @_ZNSt13runtime_errorD1Ev) #7
          to label %.cont unwind label %34

.cont:                                            ; preds = %.invoke
  unreachable

101:                                              ; preds = %98
  %102 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %99) #6
  br label %118

103:                                              ; preds = %94, %90, %83
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #6
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %9) #6
  invoke void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(120) %9, ptr noundef nonnull align 8 dereferenceable(32) %5, i32 noundef 8)
          to label %104 unwind label %109

104:                                              ; preds = %103
  %105 = invoke noundef nonnull align 8 dereferenceable(120) ptr @_ZStrsINSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEERlEOT_S8_OT0_(ptr noundef nonnull align 8 dereferenceable(120) %9, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %106 unwind label %111

106:                                              ; preds = %104
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %9) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %9) #6
  %107 = load i32, ptr %0, align 8, !tbaa !10
  %.not43 = icmp eq i32 %107, 2
  br i1 %.not43, label %114, label %108

108:                                              ; preds = %106
  call void @_ZN6Common9JsonValue13destructValueEv(ptr noundef nonnull align 8 dereferenceable(56) %0)
  store i32 2, ptr %0, align 8, !tbaa !10
  br label %114

109:                                              ; preds = %103
  %110 = landingpad { ptr, i32 }
          cleanup
  br label %113

111:                                              ; preds = %104
  %112 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(120) %9) #6
  br label %113

113:                                              ; preds = %111, %109
  %.pn = phi { ptr, i32 } [ %112, %111 ], [ %110, %109 ]
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  br label %118

114:                                              ; preds = %108, %106
  %115 = load i64, ptr %8, align 8, !tbaa !15
  %116 = getelementptr inbounds i8, ptr %0, i64 8
  store i64 %115, ptr %116, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  br label %117

117:                                              ; preds = %114, %80
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #6
  ret void

118:                                              ; preds = %.loopexit66, %.loopexit.split-lp67, %.loopexit, %.loopexit.split-lp, %32, %34, %101, %113, %79, %59, %19
  %.pn50.pn = phi { ptr, i32 } [ %20, %19 ], [ %35, %34 ], [ %33, %32 ], [ %102, %101 ], [ %.pn, %113 ], [ %60, %59 ], [ %.pn45, %79 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ], [ %lpad.loopexit68, %.loopexit66 ], [ %lpad.loopexit.split-lp69, %.loopexit.split-lp67 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #6
  resume { ptr, i32 } %.pn50.pn

119:                                              ; preds = %58
  unreachable
}

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi4readEPcl(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef, i64 noundef) local_unnamed_addr #1

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

declare noundef i32 @_ZNSi4peekEv(ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #1

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

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

attributes #0 = { 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 #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }
attributes #7 = { noreturn }

!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"}
!8 = distinct !{!8, !9}
!9 = !{!"llvm.loop.mustprogress"}
!10 = !{!11, !12, i64 0}
!11 = !{!"_ZTSN6Common9JsonValueE", !12, i64 0, !6, i64 8}
!12 = !{!"_ZTSN6Common9JsonValue4TypeE", !6, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"double", !6, i64 0}
!15 = !{!16, !16, i64 0}
!16 = !{!"long", !6, i64 0}


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