; LLVM IR from Razakhel/RaZ :: extern/openxr/src/external/jsoncpp/src/lib_json (json_reader)

; 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.Json::Value" = type { %"union.Json::Value::ValueHolder", %struct.anon, %"class.Json::Value::Comments", i64, i64 }
%"union.Json::Value::ValueHolder" = type { i64 }
%struct.anon = type { i16, [2 x i8] }
%"class.Json::Value::Comments" = type { %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.10" }
%"struct.std::_Head_base.10" = type { ptr }
%"class.Json::Reader::Token" = type { i32, ptr, ptr }

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

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

; Function Attrs: nounwind
declare void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN4Json6Reader12decodeNumberERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(40) %2) #2 align 2 {
  %4 = alloca i1, align 1
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i8, align 1
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i8, align 1
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca %"class.Json::Value", align 8
  %17 = alloca %"class.Json::Value", align 8
  %18 = alloca %"class.Json::Value", align 8
  %19 = alloca %"class.Json::Value", align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %20 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #4
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  %22 = getelementptr inbounds %"class.Json::Reader::Token", ptr %21, i32 0, i32 1
  %23 = load ptr, ptr %22, align 8, !tbaa !9
  store ptr %23, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %9) #4
  %24 = load ptr, ptr %8, align 8, !tbaa !5
  %25 = load i8, ptr %24, align 1, !tbaa !12
  %26 = sext i8 %25 to i32
  %27 = icmp eq i32 %26, 45
  %28 = zext i1 %27 to i8
  store i8 %28, ptr %9, align 1, !tbaa !13
  %29 = load i8, ptr %9, align 1, !tbaa !13, !range !15, !noundef !16
  %30 = trunc i8 %29 to i1
  br i1 %30, label %31, label %34

31:                                               ; preds = %3
  %32 = load ptr, ptr %8, align 8, !tbaa !5
  %33 = getelementptr inbounds i8, ptr %32, i32 1
  store ptr %33, ptr %8, align 8, !tbaa !5
  br label %34

34:                                               ; preds = %31, %3
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  %35 = load i8, ptr %9, align 1, !tbaa !13, !range !15, !noundef !16
  %36 = trunc i8 %35 to i1
  %37 = zext i1 %36 to i64
  %38 = select i1 %36, i64 -9223372036854775808, i64 -1
  store i64 %38, ptr %10, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  %39 = load i64, ptr %10, align 8, !tbaa !17
  %40 = udiv i64 %39, 10
  store i64 %40, ptr %11, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  store i64 0, ptr %12, align 8, !tbaa !17
  br label %41

41:                                               ; preds = %99, %34
  %42 = load ptr, ptr %8, align 8, !tbaa !5
  %43 = load ptr, ptr %6, align 8, !tbaa !5
  %44 = getelementptr inbounds %"class.Json::Reader::Token", ptr %43, i32 0, i32 2
  %45 = load ptr, ptr %44, align 8, !tbaa !19
  %46 = icmp ult ptr %42, %45
  br i1 %46, label %47, label %100

47:                                               ; preds = %41
  call void @llvm.lifetime.start.p0(i64 1, ptr %13) #4
  %48 = load ptr, ptr %8, align 8, !tbaa !5
  %49 = getelementptr inbounds i8, ptr %48, i32 1
  store ptr %49, ptr %8, align 8, !tbaa !5
  %50 = load i8, ptr %48, align 1, !tbaa !12
  store i8 %50, ptr %13, align 1, !tbaa !12
  %51 = load i8, ptr %13, align 1, !tbaa !12
  %52 = sext i8 %51 to i32
  %53 = icmp slt i32 %52, 48
  br i1 %53, label %58, label %54

54:                                               ; preds = %47
  %55 = load i8, ptr %13, align 1, !tbaa !12
  %56 = sext i8 %55 to i32
  %57 = icmp sgt i32 %56, 57
  br i1 %57, label %58, label %62

58:                                               ; preds = %54, %47
  %59 = load ptr, ptr %6, align 8, !tbaa !5
  %60 = load ptr, ptr %7, align 8, !tbaa !5
  %61 = call noundef zeroext i1 @_ZN4Json6Reader12decodeDoubleERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269) %20, ptr noundef nonnull align 8 dereferenceable(24) %59, ptr noundef nonnull align 8 dereferenceable(40) %60)
  store i1 %61, ptr %4, align 1
  store i32 1, ptr %14, align 4
  br label %97

62:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  %63 = load i8, ptr %13, align 1, !tbaa !12
  %64 = sext i8 %63 to i32
  %65 = sub nsw i32 %64, 48
  store i32 %65, ptr %15, align 4, !tbaa !20
  %66 = load i64, ptr %12, align 8, !tbaa !17
  %67 = load i64, ptr %11, align 8, !tbaa !17
  %68 = icmp uge i64 %66, %67
  br i1 %68, label %69, label %90

69:                                               ; preds = %62
  %70 = load i64, ptr %12, align 8, !tbaa !17
  %71 = load i64, ptr %11, align 8, !tbaa !17
  %72 = icmp ugt i64 %70, %71
  br i1 %72, label %85, label %73

73:                                               ; preds = %69
  %74 = load ptr, ptr %8, align 8, !tbaa !5
  %75 = load ptr, ptr %6, align 8, !tbaa !5
  %76 = getelementptr inbounds %"class.Json::Reader::Token", ptr %75, i32 0, i32 2
  %77 = load ptr, ptr %76, align 8, !tbaa !19
  %78 = icmp ne ptr %74, %77
  br i1 %78, label %85, label %79

79:                                               ; preds = %73
  %80 = load i32, ptr %15, align 4, !tbaa !20
  %81 = zext i32 %80 to i64
  %82 = load i64, ptr %10, align 8, !tbaa !17
  %83 = urem i64 %82, 10
  %84 = icmp ugt i64 %81, %83
  br i1 %84, label %85, label %89

85:                                               ; preds = %79, %73, %69
  %86 = load ptr, ptr %6, align 8, !tbaa !5
  %87 = load ptr, ptr %7, align 8, !tbaa !5
  %88 = call noundef zeroext i1 @_ZN4Json6Reader12decodeDoubleERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269) %20, ptr noundef nonnull align 8 dereferenceable(24) %86, ptr noundef nonnull align 8 dereferenceable(40) %87)
  store i1 %88, ptr %4, align 1
  store i32 1, ptr %14, align 4
  br label %96

89:                                               ; preds = %79
  br label %90

90:                                               ; preds = %89, %62
  %91 = load i64, ptr %12, align 8, !tbaa !17
  %92 = mul i64 %91, 10
  %93 = load i32, ptr %15, align 4, !tbaa !20
  %94 = zext i32 %93 to i64
  %95 = add i64 %92, %94
  store i64 %95, ptr %12, align 8, !tbaa !17
  store i32 0, ptr %14, align 4
  br label %96

96:                                               ; preds = %90, %85
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  br label %97

97:                                               ; preds = %96, %58
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #4
  %98 = load i32, ptr %14, align 4
  switch i32 %98, label %132 [
    i32 0, label %99
  ]

99:                                               ; preds = %97
  br label %41, !llvm.loop !22

100:                                              ; preds = %41
  %101 = load i8, ptr %9, align 1, !tbaa !13, !range !15, !noundef !16
  %102 = trunc i8 %101 to i1
  br i1 %102, label %103, label %110

103:                                              ; preds = %100
  %104 = load i64, ptr %12, align 8, !tbaa !17
  %105 = load i64, ptr %10, align 8, !tbaa !17
  %106 = icmp eq i64 %104, %105
  br i1 %106, label %107, label %110

107:                                              ; preds = %103
  call void @llvm.lifetime.start.p0(i64 40, ptr %16) #4
  call void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40) %16, i64 noundef -9223372036854775808)
  %108 = load ptr, ptr %7, align 8, !tbaa !5
  %109 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %108, ptr noundef nonnull align 8 dereferenceable(40) %16) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %16) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr %16) #4
  br label %131

110:                                              ; preds = %103, %100
  %111 = load i8, ptr %9, align 1, !tbaa !13, !range !15, !noundef !16
  %112 = trunc i8 %111 to i1
  br i1 %112, label %113, label %118

113:                                              ; preds = %110
  call void @llvm.lifetime.start.p0(i64 40, ptr %17) #4
  %114 = load i64, ptr %12, align 8, !tbaa !17
  %115 = sub nsw i64 0, %114
  call void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40) %17, i64 noundef %115)
  %116 = load ptr, ptr %7, align 8, !tbaa !5
  %117 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %116, ptr noundef nonnull align 8 dereferenceable(40) %17) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %17) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr %17) #4
  br label %130

118:                                              ; preds = %110
  %119 = load i64, ptr %12, align 8, !tbaa !17
  %120 = icmp ule i64 %119, 2147483647
  br i1 %120, label %121, label %125

121:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 40, ptr %18) #4
  %122 = load i64, ptr %12, align 8, !tbaa !17
  call void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40) %18, i64 noundef %122)
  %123 = load ptr, ptr %7, align 8, !tbaa !5
  %124 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %123, ptr noundef nonnull align 8 dereferenceable(40) %18) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %18) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr %18) #4
  br label %129

125:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 40, ptr %19) #4
  %126 = load i64, ptr %12, align 8, !tbaa !17
  call void @_ZN4Json5ValueC1Em(ptr noundef nonnull align 8 dereferenceable(40) %19, i64 noundef %126)
  %127 = load ptr, ptr %7, align 8, !tbaa !5
  %128 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %127, ptr noundef nonnull align 8 dereferenceable(40) %19) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %19) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr %19) #4
  br label %129

129:                                              ; preds = %125, %121
  br label %130

130:                                              ; preds = %129, %113
  br label %131

131:                                              ; preds = %130, %107
  store i1 true, ptr %4, align 1
  store i32 1, ptr %14, align 4
  br label %132

132:                                              ; preds = %131, %97
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #4
  %133 = load i1, ptr %4, align 1
  ret i1 %133
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN4Json6Reader12decodeDoubleERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(40)) #2 align 2

declare void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) unnamed_addr #3

; Function Attrs: nounwind
declare noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 8 dereferenceable(40)) #1

declare void @_ZN4Json5ValueC1Em(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) unnamed_addr #3

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 8}
!10 = !{!"_ZTSN4Json6Reader5TokenE", !11, i64 0, !6, i64 8, !6, i64 16}
!11 = !{!"_ZTSN4Json6Reader9TokenTypeE", !7, i64 0}
!12 = !{!7, !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"bool", !7, i64 0}
!15 = !{i8 0, i8 2}
!16 = !{}
!17 = !{!18, !18, i64 0}
!18 = !{!"long", !7, i64 0}
!19 = !{!10, !6, i64 16}
!20 = !{!21, !21, i64 0}
!21 = !{!"int", !7, i64 0}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}


; 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.Json::Value" = type { %"union.Json::Value::ValueHolder", %struct.anon, %"class.Json::Value::Comments", i64, i64 }
%"union.Json::Value::ValueHolder" = type { i64 }
%struct.anon = type { i16, [2 x i8] }
%"class.Json::Value::Comments" = type { %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.10" }
%"struct.std::_Head_base.10" = type { ptr }

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

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

; Function Attrs: nounwind
declare void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN4Json6Reader12decodeNumberERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(40) %2) local_unnamed_addr #2 align 2 {
  %4 = alloca %"class.Json::Value", align 8
  %5 = alloca %"class.Json::Value", align 8
  %6 = alloca %"class.Json::Value", align 8
  %7 = alloca %"class.Json::Value", align 8
  %8 = getelementptr inbounds i8, ptr %1, i64 8
  %9 = load ptr, ptr %8, align 8, !tbaa !5
  %10 = load i8, ptr %9, align 1, !tbaa !11
  %11 = icmp eq i8 %10, 45
  %spec.select = select i1 %11, i64 -9223372036854775808, i64 -1
  %spec.select53.idx = zext i1 %11 to i64
  %spec.select53 = getelementptr inbounds i8, ptr %9, i64 %spec.select53.idx
  %12 = udiv i64 %spec.select, 10
  %13 = urem i64 %spec.select, 10
  %14 = getelementptr inbounds i8, ptr %1, i64 16
  %15 = load ptr, ptr %14, align 8, !tbaa !12
  %16 = icmp ult ptr %spec.select53, %15
  br i1 %16, label %.lr.ph, label %.thread73

.lr.ph:                                           ; preds = %3, %31
  %.14568 = phi ptr [ %17, %31 ], [ %spec.select53, %3 ]
  %.04667 = phi i64 [ %33, %31 ], [ 0, %3 ]
  %17 = getelementptr inbounds i8, ptr %.14568, i64 1
  %18 = load i8, ptr %.14568, align 1, !tbaa !11
  %19 = add i8 %18, -58
  %or.cond = icmp ult i8 %19, -10
  br i1 %or.cond, label %20, label %22

20:                                               ; preds = %.lr.ph
  %21 = tail call noundef zeroext i1 @_ZN4Json6Reader12decodeDoubleERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(40) %2)
  br label %.thread

22:                                               ; preds = %.lr.ph
  %23 = zext nneg i8 %18 to i32
  %24 = add nsw i32 %23, -48
  %.not = icmp ult i64 %.04667, %12
  br i1 %.not, label %._crit_edge69, label %25

._crit_edge69:                                    ; preds = %22
  %.pre = zext nneg i32 %24 to i64
  br label %31

25:                                               ; preds = %22
  %26 = icmp ugt i64 %.04667, %12
  %.not52 = icmp ne ptr %17, %15
  %or.cond54.not64 = select i1 %26, i1 true, i1 %.not52
  %27 = zext nneg i32 %24 to i64
  %28 = icmp ult i64 %13, %27
  %or.cond57 = select i1 %or.cond54.not64, i1 true, i1 %28
  br i1 %or.cond57, label %29, label %31

29:                                               ; preds = %25
  %30 = tail call noundef zeroext i1 @_ZN4Json6Reader12decodeDoubleERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(40) %2)
  br label %.thread

31:                                               ; preds = %._crit_edge69, %25
  %.pre-phi = phi i64 [ %.pre, %._crit_edge69 ], [ %27, %25 ]
  %32 = mul i64 %.04667, 10
  %33 = add i64 %32, %.pre-phi
  %34 = icmp ult ptr %17, %15
  br i1 %34, label %.lr.ph, label %._crit_edge, !llvm.loop !13

._crit_edge:                                      ; preds = %31
  %35 = icmp eq i64 %33, %spec.select
  %or.cond58 = select i1 %11, i1 %35, i1 false
  br i1 %or.cond58, label %36, label %38

36:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %4) #4
  call void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40) %4, i64 noundef -9223372036854775808)
  %37 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull align 8 dereferenceable(40) %4) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %4) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %4) #4
  br label %.thread

38:                                               ; preds = %._crit_edge
  br i1 %11, label %39, label %42

.thread73:                                        ; preds = %3
  br i1 %11, label %39, label %.thread77

39:                                               ; preds = %.thread73, %38
  %.046.lcssa7276 = phi i64 [ 0, %.thread73 ], [ %33, %38 ]
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #4
  %40 = sub nsw i64 0, %.046.lcssa7276
  call void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef %40)
  %41 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull align 8 dereferenceable(40) %5) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %5) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #4
  br label %.thread

42:                                               ; preds = %38
  %43 = icmp ult i64 %33, 2147483648
  br i1 %43, label %.thread77, label %45

.thread77:                                        ; preds = %.thread73, %42
  %.046.lcssa727579 = phi i64 [ %33, %42 ], [ 0, %.thread73 ]
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %6) #4
  call void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40) %6, i64 noundef %.046.lcssa727579)
  %44 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull align 8 dereferenceable(40) %6) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %6) #4
  br label %.thread

45:                                               ; preds = %42
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %7) #4
  call void @_ZN4Json5ValueC1Em(ptr noundef nonnull align 8 dereferenceable(40) %7, i64 noundef %33)
  %46 = call noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull align 8 dereferenceable(40) %7) #4
  call void @_ZN4Json5ValueD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %7) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %7) #4
  br label %.thread

.thread:                                          ; preds = %29, %20, %36, %.thread77, %45, %39
  %.3 = phi i1 [ true, %39 ], [ true, %45 ], [ true, %.thread77 ], [ true, %36 ], [ %30, %29 ], [ %21, %20 ]
  ret i1 %.3
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN4Json6Reader12decodeDoubleERNS0_5TokenERNS_5ValueE(ptr noundef nonnull align 8 dereferenceable(269), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #2 align 2

declare void @_ZN4Json5ValueC1El(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) unnamed_addr #3

; Function Attrs: nounwind
declare noundef nonnull align 8 dereferenceable(40) ptr @_ZN4Json5ValueaSEOS0_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #1

declare void @_ZN4Json5ValueC1Em(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) unnamed_addr #3

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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, !10, i64 8}
!6 = !{!"_ZTSN4Json6Reader5TokenE", !7, i64 0, !10, i64 8, !10, i64 16}
!7 = !{!"_ZTSN4Json6Reader9TokenTypeE", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!8, !8, i64 0}
!12 = !{!6, !10, i64 16}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}


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