; LLVM IR from apache/mxnet :: src (lib_api)

; 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"

%"struct.mxnet::ext::JsonVal" = type { i32, i32, %"class.std::__cxx11::basic_string", %"class.std::vector.14", %"class.std::map" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::vector.14" = type { %"struct.std::_Vector_base.15" }
%"struct.std::_Vector_base.15" = type { %"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl" }
%"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl" = type { %"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl_data" }
%"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<mxnet::ext::JsonVal, std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>, std::_Select1st<std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>>, std::less<mxnet::ext::JsonVal>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<mxnet::ext::JsonVal, std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>, std::_Select1st<std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>>, std::less<mxnet::ext::JsonVal>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

; 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: mustprogress uwtable
define dso_local void @_ZN5mxnet3ext7JsonVal5parseERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8 %0, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef %2) #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i1, align 1
  %8 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %12 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %13 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %14 = alloca i32, align 4
  store ptr %0, ptr %4, align 8
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  store i1 false, ptr %7, align 1
  call void @_ZN5mxnet3ext7JsonValC1Ev(ptr noundef nonnull align 8 dereferenceable(112) %0)
  br label %15

15:                                               ; preds = %140, %3
  %16 = load ptr, ptr %6, align 8, !tbaa !5
  %17 = load i32, ptr %16, align 4, !tbaa !9
  %18 = zext i32 %17 to i64
  %19 = load ptr, ptr %5, align 8, !tbaa !5
  %20 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %19) #4
  %21 = icmp ult i64 %18, %20
  br i1 %21, label %22, label %144

22:                                               ; preds = %15
  %23 = load ptr, ptr %5, align 8, !tbaa !5
  %24 = load ptr, ptr %6, align 8, !tbaa !5
  %25 = load i32, ptr %24, align 4, !tbaa !9
  %26 = zext i32 %25 to i64
  %27 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %23, i64 noundef %26) #4
  %28 = load i8, ptr %27, align 1, !tbaa !11
  %29 = sext i8 %28 to i32
  %30 = icmp eq i32 %29, 34
  br i1 %30, label %31, label %43

31:                                               ; preds = %22
  %32 = load ptr, ptr %6, align 8, !tbaa !5
  %33 = load i32, ptr %32, align 4, !tbaa !9
  %34 = add i32 %33, 1
  store i32 %34, ptr %32, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 112, ptr %8) #4
  %35 = load ptr, ptr %5, align 8, !tbaa !5
  %36 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN5mxnet3ext7JsonVal12parse_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind writable sret(%"struct.mxnet::ext::JsonVal") align 8 %8, ptr noundef nonnull align 8 dereferenceable(32) %35, ptr noundef %36)
          to label %37 unwind label %39

37:                                               ; preds = %31
  %38 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %8) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %8) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr %8) #4
  br label %135

39:                                               ; preds = %31
  %40 = landingpad { ptr, i32 }
          cleanup
  %41 = extractvalue { ptr, i32 } %40, 0
  store ptr %41, ptr %9, align 8
  %42 = extractvalue { ptr, i32 } %40, 1
  store i32 %42, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 112, ptr %8) #4
  br label %149

43:                                               ; preds = %22
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = load ptr, ptr %6, align 8, !tbaa !5
  %46 = load i32, ptr %45, align 4, !tbaa !9
  %47 = zext i32 %46 to i64
  %48 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %44, i64 noundef %47) #4
  %49 = load i8, ptr %48, align 1, !tbaa !11
  %50 = sext i8 %49 to i32
  %51 = icmp sge i32 %50, 48
  br i1 %51, label %52, label %70

52:                                               ; preds = %43
  %53 = load ptr, ptr %5, align 8, !tbaa !5
  %54 = load ptr, ptr %6, align 8, !tbaa !5
  %55 = load i32, ptr %54, align 4, !tbaa !9
  %56 = zext i32 %55 to i64
  %57 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %53, i64 noundef %56) #4
  %58 = load i8, ptr %57, align 1, !tbaa !11
  %59 = sext i8 %58 to i32
  %60 = icmp sle i32 %59, 57
  br i1 %60, label %61, label %70

61:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 112, ptr %11) #4
  %62 = load ptr, ptr %5, align 8, !tbaa !5
  %63 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN5mxnet3ext7JsonVal9parse_numERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind writable sret(%"struct.mxnet::ext::JsonVal") align 8 %11, ptr noundef nonnull align 8 dereferenceable(32) %62, ptr noundef %63)
          to label %64 unwind label %66

64:                                               ; preds = %61
  %65 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %11) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %11) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr %11) #4
  br label %134

66:                                               ; preds = %61
  %67 = landingpad { ptr, i32 }
          cleanup
  %68 = extractvalue { ptr, i32 } %67, 0
  store ptr %68, ptr %9, align 8
  %69 = extractvalue { ptr, i32 } %67, 1
  store i32 %69, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 112, ptr %11) #4
  br label %149

70:                                               ; preds = %52, %43
  %71 = load ptr, ptr %5, align 8, !tbaa !5
  %72 = load ptr, ptr %6, align 8, !tbaa !5
  %73 = load i32, ptr %72, align 4, !tbaa !9
  %74 = zext i32 %73 to i64
  %75 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %71, i64 noundef %74) #4
  %76 = load i8, ptr %75, align 1, !tbaa !11
  %77 = sext i8 %76 to i32
  %78 = icmp eq i32 %77, 91
  br i1 %78, label %79, label %91

79:                                               ; preds = %70
  %80 = load ptr, ptr %6, align 8, !tbaa !5
  %81 = load i32, ptr %80, align 4, !tbaa !9
  %82 = add i32 %81, 1
  store i32 %82, ptr %80, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 112, ptr %12) #4
  %83 = load ptr, ptr %5, align 8, !tbaa !5
  %84 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN5mxnet3ext7JsonVal10parse_listERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind writable sret(%"struct.mxnet::ext::JsonVal") align 8 %12, ptr noundef nonnull align 8 dereferenceable(32) %83, ptr noundef %84)
          to label %85 unwind label %87

85:                                               ; preds = %79
  %86 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %12) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %12) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr %12) #4
  br label %133

87:                                               ; preds = %79
  %88 = landingpad { ptr, i32 }
          cleanup
  %89 = extractvalue { ptr, i32 } %88, 0
  store ptr %89, ptr %9, align 8
  %90 = extractvalue { ptr, i32 } %88, 1
  store i32 %90, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 112, ptr %12) #4
  br label %149

91:                                               ; preds = %70
  %92 = load ptr, ptr %5, align 8, !tbaa !5
  %93 = load ptr, ptr %6, align 8, !tbaa !5
  %94 = load i32, ptr %93, align 4, !tbaa !9
  %95 = zext i32 %94 to i64
  %96 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %92, i64 noundef %95) #4
  %97 = load i8, ptr %96, align 1, !tbaa !11
  %98 = sext i8 %97 to i32
  %99 = icmp eq i32 %98, 123
  br i1 %99, label %100, label %112

100:                                              ; preds = %91
  %101 = load ptr, ptr %6, align 8, !tbaa !5
  %102 = load i32, ptr %101, align 4, !tbaa !9
  %103 = add i32 %102, 1
  store i32 %103, ptr %101, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 112, ptr %13) #4
  %104 = load ptr, ptr %5, align 8, !tbaa !5
  %105 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN5mxnet3ext7JsonVal9parse_mapERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind writable sret(%"struct.mxnet::ext::JsonVal") align 8 %13, ptr noundef nonnull align 8 dereferenceable(32) %104, ptr noundef %105)
          to label %106 unwind label %108

106:                                              ; preds = %100
  %107 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %13) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %13) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr %13) #4
  br label %132

108:                                              ; preds = %100
  %109 = landingpad { ptr, i32 }
          cleanup
  %110 = extractvalue { ptr, i32 } %109, 0
  store ptr %110, ptr %9, align 8
  %111 = extractvalue { ptr, i32 } %109, 1
  store i32 %111, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 112, ptr %13) #4
  br label %149

112:                                              ; preds = %91
  %113 = load ptr, ptr %5, align 8, !tbaa !5
  %114 = load ptr, ptr %6, align 8, !tbaa !5
  %115 = load i32, ptr %114, align 4, !tbaa !9
  %116 = zext i32 %115 to i64
  %117 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %113, i64 noundef %116) #4
  %118 = load i8, ptr %117, align 1, !tbaa !11
  %119 = sext i8 %118 to i32
  %120 = icmp eq i32 %119, 93
  br i1 %120, label %130, label %121

121:                                              ; preds = %112
  %122 = load ptr, ptr %5, align 8, !tbaa !5
  %123 = load ptr, ptr %6, align 8, !tbaa !5
  %124 = load i32, ptr %123, align 4, !tbaa !9
  %125 = zext i32 %124 to i64
  %126 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %122, i64 noundef %125) #4
  %127 = load i8, ptr %126, align 1, !tbaa !11
  %128 = sext i8 %127 to i32
  %129 = icmp eq i32 %128, 125
  br i1 %129, label %130, label %131

130:                                              ; preds = %121, %112
  store i1 true, ptr %7, align 1
  store i32 1, ptr %14, align 4
  br label %145

131:                                              ; preds = %121
  br label %132

132:                                              ; preds = %131, %106
  br label %133

133:                                              ; preds = %132, %85
  br label %134

134:                                              ; preds = %133, %64
  br label %135

135:                                              ; preds = %134, %37
  %136 = getelementptr inbounds %"struct.mxnet::ext::JsonVal", ptr %0, i32 0, i32 0
  %137 = load i32, ptr %136, align 8, !tbaa !12
  %138 = icmp ne i32 %137, 0
  br i1 %138, label %139, label %140

139:                                              ; preds = %135
  store i1 true, ptr %7, align 1
  store i32 1, ptr %14, align 4
  br label %145

140:                                              ; preds = %135
  %141 = load ptr, ptr %6, align 8, !tbaa !5
  %142 = load i32, ptr %141, align 4, !tbaa !9
  %143 = add i32 %142, 1
  store i32 %143, ptr %141, align 4, !tbaa !9
  br label %15, !llvm.loop !30

144:                                              ; preds = %15
  store i1 true, ptr %7, align 1
  store i32 1, ptr %14, align 4
  br label %145

145:                                              ; preds = %144, %139, %130
  %146 = load i1, ptr %7, align 1
  br i1 %146, label %148, label %147

147:                                              ; preds = %145
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %0) #4
  br label %148

148:                                              ; preds = %147, %145
  ret void

149:                                              ; preds = %108, %87, %66, %39
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %0) #4
  br label %150

150:                                              ; preds = %149
  %151 = load ptr, ptr %9, align 8
  %152 = load i32, ptr %10, align 4
  %153 = insertvalue { ptr, i32 } poison, ptr %151, 0
  %154 = insertvalue { ptr, i32 } %153, i32 %152, 1
  resume { ptr, i32 } %154
}

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal12parse_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #1 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal9parse_numERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal10parse_listERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal9parse_mapERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112), ptr noundef nonnull align 8 dereferenceable(112)) #3 align 2

declare void @_ZN5mxnet3ext7JsonValC1Ev(ptr)

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #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, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !14, i64 0}
!13 = !{!"_ZTSN5mxnet3ext7JsonValE", !14, i64 0, !10, i64 4, !15, i64 8, !18, i64 40, !22, i64 64}
!14 = !{!"_ZTSN5mxnet3ext8JsonTypeE", !7, i64 0}
!15 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !16, i64 0, !17, i64 8, !7, i64 16}
!16 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!17 = !{!"long", !7, i64 0}
!18 = !{!"_ZTSSt6vectorIN5mxnet3ext7JsonValESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseIN5mxnet3ext7JsonValESaIS2_EE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIN5mxnet3ext7JsonValESaIS2_EE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIN5mxnet3ext7JsonValESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!22 = !{!"_ZTSSt3mapIN5mxnet3ext7JsonValES2_St4lessIS2_ESaISt4pairIKS2_S2_EEE", !23, i64 0}
!23 = !{!"_ZTSSt8_Rb_treeIN5mxnet3ext7JsonValESt4pairIKS2_S2_ESt10_Select1stIS5_ESt4lessIS2_ESaIS5_EE", !24, i64 0}
!24 = !{!"_ZTSNSt8_Rb_treeIN5mxnet3ext7JsonValESt4pairIKS2_S2_ESt10_Select1stIS5_ESt4lessIS2_ESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !25, i64 0, !27, i64 8}
!25 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessIN5mxnet3ext7JsonValEEE", !26, i64 0}
!26 = !{!"_ZTSSt4lessIN5mxnet3ext7JsonValEE"}
!27 = !{!"_ZTSSt15_Rb_tree_header", !28, i64 0, !17, i64 32}
!28 = !{!"_ZTSSt18_Rb_tree_node_base", !29, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!29 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!30 = distinct !{!30, !31}
!31 = !{!"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"

%"struct.mxnet::ext::JsonVal" = type { i32, i32, %"class.std::__cxx11::basic_string", %"class.std::vector.14", %"class.std::map" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::vector.14" = type { %"struct.std::_Vector_base.15" }
%"struct.std::_Vector_base.15" = type { %"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl" }
%"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl" = type { %"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl_data" }
%"struct.std::_Vector_base<mxnet::ext::JsonVal, std::allocator<mxnet::ext::JsonVal>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<mxnet::ext::JsonVal, std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>, std::_Select1st<std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>>, std::less<mxnet::ext::JsonVal>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<mxnet::ext::JsonVal, std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>, std::_Select1st<std::pair<const mxnet::ext::JsonVal, mxnet::ext::JsonVal>>, std::less<mxnet::ext::JsonVal>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

; 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: mustprogress uwtable
define dso_local void @_ZN5mxnet3ext7JsonVal5parseERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8 %0, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef %2) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %5 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %6 = alloca %"struct.mxnet::ext::JsonVal", align 8
  %7 = alloca %"struct.mxnet::ext::JsonVal", align 8
  tail call void @_ZN5mxnet3ext7JsonValC1Ev(ptr noundef nonnull align 8 dereferenceable(112) %0)
  %8 = load i32, ptr %2, align 4, !tbaa !5
  %9 = zext i32 %8 to i64
  %10 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #4
  %11 = icmp ugt i64 %10, %9
  br i1 %11, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %3, %78
  %12 = load i32, ptr %2, align 4, !tbaa !5
  %13 = zext i32 %12 to i64
  %14 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %13) #4
  %15 = load i8, ptr %14, align 1, !tbaa !9
  %16 = icmp eq i8 %15, 34
  %17 = load i32, ptr %2, align 4, !tbaa !5
  br i1 %16, label %18, label %24

18:                                               ; preds = %.lr.ph
  %19 = add i32 %17, 1
  store i32 %19, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 112, ptr nonnull %4) #4
  invoke void @_ZN5mxnet3ext7JsonVal12parse_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind nonnull writable sret(%"struct.mxnet::ext::JsonVal") align 8 %4, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull %2)
          to label %20 unwind label %22

20:                                               ; preds = %18
  %21 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %4) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %4) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %4) #4
  br label %77

22:                                               ; preds = %18
  %23 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %4) #4
  br label %84

24:                                               ; preds = %.lr.ph
  %25 = zext i32 %17 to i64
  %26 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %25) #4
  %27 = load i8, ptr %26, align 1, !tbaa !9
  %28 = icmp sgt i8 %27, 47
  br i1 %28, label %29, label %40

29:                                               ; preds = %24
  %30 = load i32, ptr %2, align 4, !tbaa !5
  %31 = zext i32 %30 to i64
  %32 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %31) #4
  %33 = load i8, ptr %32, align 1, !tbaa !9
  %34 = icmp slt i8 %33, 58
  br i1 %34, label %35, label %40

35:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 112, ptr nonnull %5) #4
  invoke void @_ZN5mxnet3ext7JsonVal9parse_numERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind nonnull writable sret(%"struct.mxnet::ext::JsonVal") align 8 %5, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull %2)
          to label %36 unwind label %38

36:                                               ; preds = %35
  %37 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %5) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %5) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %5) #4
  br label %77

38:                                               ; preds = %35
  %39 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %5) #4
  br label %84

40:                                               ; preds = %29, %24
  %41 = load i32, ptr %2, align 4, !tbaa !5
  %42 = zext i32 %41 to i64
  %43 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %42) #4
  %44 = load i8, ptr %43, align 1, !tbaa !9
  %45 = icmp eq i8 %44, 91
  %46 = load i32, ptr %2, align 4, !tbaa !5
  br i1 %45, label %47, label %53

47:                                               ; preds = %40
  %48 = add i32 %46, 1
  store i32 %48, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 112, ptr nonnull %6) #4
  invoke void @_ZN5mxnet3ext7JsonVal10parse_listERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind nonnull writable sret(%"struct.mxnet::ext::JsonVal") align 8 %6, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull %2)
          to label %49 unwind label %51

49:                                               ; preds = %47
  %50 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %6) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %6) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %6) #4
  br label %77

51:                                               ; preds = %47
  %52 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %6) #4
  br label %84

53:                                               ; preds = %40
  %54 = zext i32 %46 to i64
  %55 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %54) #4
  %56 = load i8, ptr %55, align 1, !tbaa !9
  %57 = icmp eq i8 %56, 123
  %58 = load i32, ptr %2, align 4, !tbaa !5
  br i1 %57, label %59, label %65

59:                                               ; preds = %53
  %60 = add i32 %58, 1
  store i32 %60, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 112, ptr nonnull %7) #4
  invoke void @_ZN5mxnet3ext7JsonVal9parse_mapERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind nonnull writable sret(%"struct.mxnet::ext::JsonVal") align 8 %7, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull %2)
          to label %61 unwind label %63

61:                                               ; preds = %59
  %62 = call noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(112) %7) #4
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %7) #4
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %7) #4
  br label %77

63:                                               ; preds = %59
  %64 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %7) #4
  br label %84

65:                                               ; preds = %53
  %66 = zext i32 %58 to i64
  %67 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %66) #4
  %68 = load i8, ptr %67, align 1, !tbaa !9
  %69 = icmp eq i8 %68, 93
  br i1 %69, label %._crit_edge, label %70

70:                                               ; preds = %65
  %71 = load i32, ptr %2, align 4, !tbaa !5
  %72 = zext i32 %71 to i64
  %73 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %72) #4
  %74 = load i8, ptr %73, align 1, !tbaa !9
  %75 = icmp ne i8 %74, 125
  %76 = load i32, ptr %0, align 8
  %.not = icmp eq i32 %76, 0
  %or.cond = select i1 %75, i1 %.not, i1 false
  br i1 %or.cond, label %78, label %._crit_edge

77:                                               ; preds = %36, %61, %49, %20
  %.old = load i32, ptr %0, align 8, !tbaa !10
  %.not.old = icmp eq i32 %.old, 0
  br i1 %.not.old, label %78, label %._crit_edge

78:                                               ; preds = %70, %77
  %79 = load i32, ptr %2, align 4, !tbaa !5
  %80 = add i32 %79, 1
  store i32 %80, ptr %2, align 4, !tbaa !5
  %81 = zext i32 %80 to i64
  %82 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #4
  %83 = icmp ugt i64 %82, %81
  br i1 %83, label %.lr.ph, label %._crit_edge, !llvm.loop !29

._crit_edge:                                      ; preds = %78, %77, %65, %70, %3
  ret void

84:                                               ; preds = %63, %51, %38, %22
  %.pn = phi { ptr, i32 } [ %23, %22 ], [ %39, %38 ], [ %52, %51 ], [ %64, %63 ]
  call void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112) %0) #4
  resume { ptr, i32 } %.pn
}

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal12parse_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) local_unnamed_addr #1 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN5mxnet3ext7JsonValD2Ev(ptr noundef nonnull align 8 dereferenceable(112)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal9parse_numERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal10parse_listERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5mxnet3ext7JsonVal9parse_mapERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPj(ptr dead_on_unwind noalias writable sret(%"struct.mxnet::ext::JsonVal") align 8, ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(112) ptr @_ZN5mxnet3ext7JsonValaSEOS1_(ptr noundef nonnull align 8 dereferenceable(112), ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #3 align 2

declare void @_ZN5mxnet3ext7JsonValC1Ev(ptr) local_unnamed_addr

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!7, !7, i64 0}
!10 = !{!11, !12, i64 0}
!11 = !{!"_ZTSN5mxnet3ext7JsonValE", !12, i64 0, !6, i64 4, !13, i64 8, !17, i64 40, !21, i64 64}
!12 = !{!"_ZTSN5mxnet3ext8JsonTypeE", !7, i64 0}
!13 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !14, i64 0, !16, i64 8, !7, i64 16}
!14 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !15, i64 0}
!15 = !{!"any pointer", !7, i64 0}
!16 = !{!"long", !7, i64 0}
!17 = !{!"_ZTSSt6vectorIN5mxnet3ext7JsonValESaIS2_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseIN5mxnet3ext7JsonValESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIN5mxnet3ext7JsonValESaIS2_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIN5mxnet3ext7JsonValESaIS2_EE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!21 = !{!"_ZTSSt3mapIN5mxnet3ext7JsonValES2_St4lessIS2_ESaISt4pairIKS2_S2_EEE", !22, i64 0}
!22 = !{!"_ZTSSt8_Rb_treeIN5mxnet3ext7JsonValESt4pairIKS2_S2_ESt10_Select1stIS5_ESt4lessIS2_ESaIS5_EE", !23, i64 0}
!23 = !{!"_ZTSNSt8_Rb_treeIN5mxnet3ext7JsonValESt4pairIKS2_S2_ESt10_Select1stIS5_ESt4lessIS2_ESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !24, i64 0, !26, i64 8}
!24 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessIN5mxnet3ext7JsonValEEE", !25, i64 0}
!25 = !{!"_ZTSSt4lessIN5mxnet3ext7JsonValEE"}
!26 = !{!"_ZTSSt15_Rb_tree_header", !27, i64 0, !16, i64 32}
!27 = !{!"_ZTSSt18_Rb_tree_node_base", !28, i64 0, !15, i64 8, !15, i64 16, !15, i64 24}
!28 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!29 = distinct !{!29, !30}
!30 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass