; LLVM IR from vczh/herodb :: Kernel/Source/Vlpp.ll (ZN2vl7parsing3xml16XmlUnescapeValueERKNS_12ObjectStringIwEE)

; 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.vl::ObjectString" = type { %"class.vl::Object", ptr, ptr, i64, i64, i64 }
%"class.vl::Object" = type { ptr }

@.str.371 = external hidden unnamed_addr constant [5 x i32], align 4
@.str.372 = external hidden unnamed_addr constant [5 x i32], align 4
@.str.373 = external hidden unnamed_addr constant [6 x i32], align 4
@.str.374 = external hidden unnamed_addr constant [7 x i32], align 4
@.str.375 = external hidden unnamed_addr constant [7 x i32], align 4

; 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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZNK2vl12ObjectStringIwE6BufferEv(ptr noundef nonnull align 8 dereferenceable(48)) #1 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #1 align 2

; Function Attrs: nounwind willreturn memory(read)
declare i32 @wcsncmp(ptr noundef, ptr noundef, i64 noundef) #3

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN2vl7parsing3xml16XmlUnescapeValueERKNS_12ObjectStringIwEE(ptr dead_on_unwind noalias writable sret(%"class.vl::ObjectString") align 8 %0, ptr noundef nonnull align 8 dereferenceable(48) %1) #1 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i1, align 1
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %"class.vl::ObjectString", align 8
  %10 = alloca i32, align 4
  %11 = alloca %"class.vl::ObjectString", align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.vl::ObjectString", align 8
  %14 = alloca i32, align 4
  %15 = alloca %"class.vl::ObjectString", align 8
  %16 = alloca i32, align 4
  %17 = alloca %"class.vl::ObjectString", align 8
  %18 = alloca i32, align 4
  %19 = alloca %"class.vl::ObjectString", align 8
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  store i1 false, ptr %5, align 1
  call void @_ZN2vl12ObjectStringIwEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %0)
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #4
  %20 = load ptr, ptr %4, align 8, !tbaa !5
  %21 = invoke noundef ptr @_ZNK2vl12ObjectStringIwE6BufferEv(ptr noundef nonnull align 8 dereferenceable(48) %20)
          to label %22 unwind label %37

22:                                               ; preds = %2
  store ptr %21, ptr %6, align 8, !tbaa !5
  br label %23

23:                                               ; preds = %145, %22
  %24 = load ptr, ptr %6, align 8, !tbaa !5
  %25 = load i32, ptr %24, align 4, !tbaa !9
  %26 = icmp ne i32 %25, 0
  br i1 %26, label %27, label %146

27:                                               ; preds = %23
  %28 = load ptr, ptr %6, align 8, !tbaa !5
  %29 = call i32 @wcsncmp(ptr noundef %28, ptr noundef @.str.371, i64 noundef 4) #5
  %30 = icmp eq i32 %29, 0
  br i1 %30, label %31, label %50

31:                                               ; preds = %27
  call void @llvm.lifetime.start.p0(i64 48, ptr %9) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #4
  store i32 60, ptr %10, align 4, !tbaa !9
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %9, ptr noundef nonnull align 4 dereferenceable(4) %10)
          to label %32 unwind label %41

32:                                               ; preds = %31
  %33 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %9)
          to label %34 unwind label %45

34:                                               ; preds = %32
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %9) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %9) #4
  %35 = load ptr, ptr %6, align 8, !tbaa !5
  %36 = getelementptr inbounds i32, ptr %35, i64 4
  store ptr %36, ptr %6, align 8, !tbaa !5
  br label %145

37:                                               ; preds = %2
  %38 = landingpad { ptr, i32 }
          cleanup
  %39 = extractvalue { ptr, i32 } %38, 0
  store ptr %39, ptr %7, align 8
  %40 = extractvalue { ptr, i32 } %38, 1
  store i32 %40, ptr %8, align 4
  br label %148

41:                                               ; preds = %31
  %42 = landingpad { ptr, i32 }
          cleanup
  %43 = extractvalue { ptr, i32 } %42, 0
  store ptr %43, ptr %7, align 8
  %44 = extractvalue { ptr, i32 } %42, 1
  store i32 %44, ptr %8, align 4
  br label %49

45:                                               ; preds = %32
  %46 = landingpad { ptr, i32 }
          cleanup
  %47 = extractvalue { ptr, i32 } %46, 0
  store ptr %47, ptr %7, align 8
  %48 = extractvalue { ptr, i32 } %46, 1
  store i32 %48, ptr %8, align 4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %9) #4
  br label %49

49:                                               ; preds = %45, %41
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %9) #4
  br label %148

50:                                               ; preds = %27
  %51 = load ptr, ptr %6, align 8, !tbaa !5
  %52 = call i32 @wcsncmp(ptr noundef %51, ptr noundef @.str.372, i64 noundef 4) #5
  %53 = icmp eq i32 %52, 0
  br i1 %53, label %54, label %69

54:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 48, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  store i32 62, ptr %12, align 4, !tbaa !9
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %11, ptr noundef nonnull align 4 dereferenceable(4) %12)
          to label %55 unwind label %60

55:                                               ; preds = %54
  %56 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %11)
          to label %57 unwind label %64

57:                                               ; preds = %55
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %11) #4
  %58 = load ptr, ptr %6, align 8, !tbaa !5
  %59 = getelementptr inbounds i32, ptr %58, i64 4
  store ptr %59, ptr %6, align 8, !tbaa !5
  br label %144

60:                                               ; preds = %54
  %61 = landingpad { ptr, i32 }
          cleanup
  %62 = extractvalue { ptr, i32 } %61, 0
  store ptr %62, ptr %7, align 8
  %63 = extractvalue { ptr, i32 } %61, 1
  store i32 %63, ptr %8, align 4
  br label %68

64:                                               ; preds = %55
  %65 = landingpad { ptr, i32 }
          cleanup
  %66 = extractvalue { ptr, i32 } %65, 0
  store ptr %66, ptr %7, align 8
  %67 = extractvalue { ptr, i32 } %65, 1
  store i32 %67, ptr %8, align 4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #4
  br label %68

68:                                               ; preds = %64, %60
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %11) #4
  br label %148

69:                                               ; preds = %50
  %70 = load ptr, ptr %6, align 8, !tbaa !5
  %71 = call i32 @wcsncmp(ptr noundef %70, ptr noundef @.str.373, i64 noundef 5) #5
  %72 = icmp eq i32 %71, 0
  br i1 %72, label %73, label %88

73:                                               ; preds = %69
  call void @llvm.lifetime.start.p0(i64 48, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  store i32 38, ptr %14, align 4, !tbaa !9
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %13, ptr noundef nonnull align 4 dereferenceable(4) %14)
          to label %74 unwind label %79

74:                                               ; preds = %73
  %75 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %13)
          to label %76 unwind label %83

76:                                               ; preds = %74
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %13) #4
  %77 = load ptr, ptr %6, align 8, !tbaa !5
  %78 = getelementptr inbounds i32, ptr %77, i64 5
  store ptr %78, ptr %6, align 8, !tbaa !5
  br label %143

79:                                               ; preds = %73
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %7, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %8, align 4
  br label %87

83:                                               ; preds = %74
  %84 = landingpad { ptr, i32 }
          cleanup
  %85 = extractvalue { ptr, i32 } %84, 0
  store ptr %85, ptr %7, align 8
  %86 = extractvalue { ptr, i32 } %84, 1
  store i32 %86, ptr %8, align 4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #4
  br label %87

87:                                               ; preds = %83, %79
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %13) #4
  br label %148

88:                                               ; preds = %69
  %89 = load ptr, ptr %6, align 8, !tbaa !5
  %90 = call i32 @wcsncmp(ptr noundef %89, ptr noundef @.str.374, i64 noundef 6) #5
  %91 = icmp eq i32 %90, 0
  br i1 %91, label %92, label %107

92:                                               ; preds = %88
  call void @llvm.lifetime.start.p0(i64 48, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  store i32 39, ptr %16, align 4, !tbaa !9
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %15, ptr noundef nonnull align 4 dereferenceable(4) %16)
          to label %93 unwind label %98

93:                                               ; preds = %92
  %94 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %15)
          to label %95 unwind label %102

95:                                               ; preds = %93
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %15) #4
  %96 = load ptr, ptr %6, align 8, !tbaa !5
  %97 = getelementptr inbounds i32, ptr %96, i64 6
  store ptr %97, ptr %6, align 8, !tbaa !5
  br label %142

98:                                               ; preds = %92
  %99 = landingpad { ptr, i32 }
          cleanup
  %100 = extractvalue { ptr, i32 } %99, 0
  store ptr %100, ptr %7, align 8
  %101 = extractvalue { ptr, i32 } %99, 1
  store i32 %101, ptr %8, align 4
  br label %106

102:                                              ; preds = %93
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %7, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %8, align 4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #4
  br label %106

106:                                              ; preds = %102, %98
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %15) #4
  br label %148

107:                                              ; preds = %88
  %108 = load ptr, ptr %6, align 8, !tbaa !5
  %109 = call i32 @wcsncmp(ptr noundef %108, ptr noundef @.str.375, i64 noundef 6) #5
  %110 = icmp eq i32 %109, 0
  br i1 %110, label %111, label %126

111:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 48, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #4
  store i32 34, ptr %18, align 4, !tbaa !9
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %17, ptr noundef nonnull align 4 dereferenceable(4) %18)
          to label %112 unwind label %117

112:                                              ; preds = %111
  %113 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %17)
          to label %114 unwind label %121

114:                                              ; preds = %112
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %17) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %17) #4
  %115 = load ptr, ptr %6, align 8, !tbaa !5
  %116 = getelementptr inbounds i32, ptr %115, i64 6
  store ptr %116, ptr %6, align 8, !tbaa !5
  br label %141

117:                                              ; preds = %111
  %118 = landingpad { ptr, i32 }
          cleanup
  %119 = extractvalue { ptr, i32 } %118, 0
  store ptr %119, ptr %7, align 8
  %120 = extractvalue { ptr, i32 } %118, 1
  store i32 %120, ptr %8, align 4
  br label %125

121:                                              ; preds = %112
  %122 = landingpad { ptr, i32 }
          cleanup
  %123 = extractvalue { ptr, i32 } %122, 0
  store ptr %123, ptr %7, align 8
  %124 = extractvalue { ptr, i32 } %122, 1
  store i32 %124, ptr %8, align 4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %17) #4
  br label %125

125:                                              ; preds = %121, %117
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %17) #4
  br label %148

126:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 48, ptr %19) #4
  %127 = load ptr, ptr %6, align 8, !tbaa !5
  %128 = getelementptr inbounds i32, ptr %127, i32 1
  store ptr %128, ptr %6, align 8, !tbaa !5
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef nonnull align 4 dereferenceable(4) %127)
          to label %129 unwind label %132

129:                                              ; preds = %126
  %130 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %19)
          to label %131 unwind label %136

131:                                              ; preds = %129
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #4
  br label %141

132:                                              ; preds = %126
  %133 = landingpad { ptr, i32 }
          cleanup
  %134 = extractvalue { ptr, i32 } %133, 0
  store ptr %134, ptr %7, align 8
  %135 = extractvalue { ptr, i32 } %133, 1
  store i32 %135, ptr %8, align 4
  br label %140

136:                                              ; preds = %129
  %137 = landingpad { ptr, i32 }
          cleanup
  %138 = extractvalue { ptr, i32 } %137, 0
  store ptr %138, ptr %7, align 8
  %139 = extractvalue { ptr, i32 } %137, 1
  store i32 %139, ptr %8, align 4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #4
  br label %140

140:                                              ; preds = %136, %132
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #4
  br label %148

141:                                              ; preds = %131, %114
  br label %142

142:                                              ; preds = %141, %95
  br label %143

143:                                              ; preds = %142, %76
  br label %144

144:                                              ; preds = %143, %57
  br label %145

145:                                              ; preds = %144, %34
  br label %23, !llvm.loop !11

146:                                              ; preds = %23
  store i1 true, ptr %5, align 1
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  %147 = load i1, ptr %5, align 1
  br i1 %147, label %150, label %149

148:                                              ; preds = %140, %125, %106, %87, %68, %49, %37
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %0) #4
  br label %151

149:                                              ; preds = %146
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %0) #4
  br label %150

150:                                              ; preds = %149, %146
  ret void

151:                                              ; preds = %148
  %152 = load ptr, ptr %7, align 8
  %153 = load i32, ptr %8, align 4
  %154 = insertvalue { ptr, i32 } poison, ptr %152, 0
  %155 = insertvalue { ptr, i32 } %154, i32 %153, 1
  resume { ptr, i32 } %155
}

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 = { nounwind willreturn memory(read) "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 }
attributes #5 = { nounwind willreturn memory(read) }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"wchar_t", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"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.vl::ObjectString" = type { %"class.vl::Object", ptr, ptr, i64, i64, i64 }
%"class.vl::Object" = type { ptr }

@.str.371 = external hidden unnamed_addr constant [5 x i32], align 4
@.str.372 = external hidden unnamed_addr constant [5 x i32], align 4
@.str.373 = external hidden unnamed_addr constant [6 x i32], align 4
@.str.374 = external hidden unnamed_addr constant [7 x i32], align 4
@.str.375 = external hidden unnamed_addr constant [7 x i32], align 4

; 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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZNK2vl12ObjectStringIwE6BufferEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #1 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nofree nounwind willreturn memory(read)
declare i32 @wcsncmp(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN2vl7parsing3xml16XmlUnescapeValueERKNS_12ObjectStringIwEE(ptr dead_on_unwind noalias nonnull writable sret(%"class.vl::ObjectString") align 8 %0, ptr noundef nonnull align 8 dereferenceable(48) %1) local_unnamed_addr #1 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.vl::ObjectString", align 8
  %4 = alloca i32, align 4
  %5 = alloca %"class.vl::ObjectString", align 8
  %6 = alloca i32, align 4
  %7 = alloca %"class.vl::ObjectString", align 8
  %8 = alloca i32, align 4
  %9 = alloca %"class.vl::ObjectString", align 8
  %10 = alloca i32, align 4
  %11 = alloca %"class.vl::ObjectString", align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.vl::ObjectString", align 8
  tail call void @_ZN2vl12ObjectStringIwEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %0)
  %14 = invoke noundef ptr @_ZNK2vl12ObjectStringIwE6BufferEv(ptr noundef nonnull align 8 dereferenceable(48) %1)
          to label %.preheader unwind label %23

.preheader:                                       ; preds = %2
  %15 = load i32, ptr %14, align 4, !tbaa !5
  %.not36 = icmp eq i32 %15, 0
  br i1 %.not36, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader, %92
  %.02237 = phi ptr [ %.123, %92 ], [ %14, %.preheader ]
  %16 = call i32 @wcsncmp(ptr noundef nonnull %.02237, ptr noundef nonnull @.str.371, i64 noundef 4) #4
  %17 = icmp eq i32 %16, 0
  br i1 %17, label %18, label %30

18:                                               ; preds = %.lr.ph
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %3) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #5
  store i32 60, ptr %4, align 4, !tbaa !5
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 4 dereferenceable(4) %4)
          to label %19 unwind label %25

19:                                               ; preds = %18
  %20 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %3)
          to label %21 unwind label %27

21:                                               ; preds = %19
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %3) #5
  %22 = getelementptr inbounds i8, ptr %.02237, i64 16
  br label %92

23:                                               ; preds = %2
  %24 = landingpad { ptr, i32 }
          cleanup
  br label %94

25:                                               ; preds = %18
  %26 = landingpad { ptr, i32 }
          cleanup
  br label %29

27:                                               ; preds = %19
  %28 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  br label %29

29:                                               ; preds = %27, %25
  %.pn33 = phi { ptr, i32 } [ %28, %27 ], [ %26, %25 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %3) #5
  br label %94

30:                                               ; preds = %.lr.ph
  %31 = call i32 @wcsncmp(ptr noundef nonnull %.02237, ptr noundef nonnull @.str.372, i64 noundef 4) #4
  %32 = icmp eq i32 %31, 0
  br i1 %32, label %33, label %43

33:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %5) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #5
  store i32 62, ptr %6, align 4, !tbaa !5
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %5, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %34 unwind label %38

34:                                               ; preds = %33
  %35 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %5)
          to label %36 unwind label %40

36:                                               ; preds = %34
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %5) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %5) #5
  %37 = getelementptr inbounds i8, ptr %.02237, i64 16
  br label %92

38:                                               ; preds = %33
  %39 = landingpad { ptr, i32 }
          cleanup
  br label %42

40:                                               ; preds = %34
  %41 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %5) #5
  br label %42

42:                                               ; preds = %40, %38
  %.pn31 = phi { ptr, i32 } [ %41, %40 ], [ %39, %38 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %5) #5
  br label %94

43:                                               ; preds = %30
  %44 = call i32 @wcsncmp(ptr noundef nonnull %.02237, ptr noundef nonnull @.str.373, i64 noundef 5) #4
  %45 = icmp eq i32 %44, 0
  br i1 %45, label %46, label %56

46:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %7) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #5
  store i32 38, ptr %8, align 4, !tbaa !5
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %7, ptr noundef nonnull align 4 dereferenceable(4) %8)
          to label %47 unwind label %51

47:                                               ; preds = %46
  %48 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %7)
          to label %49 unwind label %53

49:                                               ; preds = %47
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %7) #5
  %50 = getelementptr inbounds i8, ptr %.02237, i64 20
  br label %92

51:                                               ; preds = %46
  %52 = landingpad { ptr, i32 }
          cleanup
  br label %55

53:                                               ; preds = %47
  %54 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #5
  br label %55

55:                                               ; preds = %53, %51
  %.pn29 = phi { ptr, i32 } [ %54, %53 ], [ %52, %51 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %7) #5
  br label %94

56:                                               ; preds = %43
  %57 = call i32 @wcsncmp(ptr noundef nonnull %.02237, ptr noundef nonnull @.str.374, i64 noundef 6) #4
  %58 = icmp eq i32 %57, 0
  br i1 %58, label %59, label %69

59:                                               ; preds = %56
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #5
  store i32 39, ptr %10, align 4, !tbaa !5
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %9, ptr noundef nonnull align 4 dereferenceable(4) %10)
          to label %60 unwind label %64

60:                                               ; preds = %59
  %61 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %9)
          to label %62 unwind label %66

62:                                               ; preds = %60
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #5
  %63 = getelementptr inbounds i8, ptr %.02237, i64 24
  br label %92

64:                                               ; preds = %59
  %65 = landingpad { ptr, i32 }
          cleanup
  br label %68

66:                                               ; preds = %60
  %67 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %9) #5
  br label %68

68:                                               ; preds = %66, %64
  %.pn27 = phi { ptr, i32 } [ %67, %66 ], [ %65, %64 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #5
  br label %94

69:                                               ; preds = %56
  %70 = call i32 @wcsncmp(ptr noundef nonnull %.02237, ptr noundef nonnull @.str.375, i64 noundef 6) #4
  %71 = icmp eq i32 %70, 0
  br i1 %71, label %72, label %82

72:                                               ; preds = %69
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %11) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #5
  store i32 34, ptr %12, align 4, !tbaa !5
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %11, ptr noundef nonnull align 4 dereferenceable(4) %12)
          to label %73 unwind label %77

73:                                               ; preds = %72
  %74 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %11)
          to label %75 unwind label %79

75:                                               ; preds = %73
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %11) #5
  %76 = getelementptr inbounds i8, ptr %.02237, i64 24
  br label %92

77:                                               ; preds = %72
  %78 = landingpad { ptr, i32 }
          cleanup
  br label %81

79:                                               ; preds = %73
  %80 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #5
  br label %81

81:                                               ; preds = %79, %77
  %.pn25 = phi { ptr, i32 } [ %80, %79 ], [ %78, %77 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %11) #5
  br label %94

82:                                               ; preds = %69
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %13) #5
  %83 = getelementptr inbounds i8, ptr %.02237, i64 4
  invoke void @_ZN2vl12ObjectStringIwEC2ERKw(ptr noundef nonnull align 8 dereferenceable(48) %13, ptr noundef nonnull align 4 dereferenceable(4) %.02237)
          to label %84 unwind label %87

84:                                               ; preds = %82
  %85 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vl12ObjectStringIwEpLERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 8 dereferenceable(48) %13)
          to label %86 unwind label %89

86:                                               ; preds = %84
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %13) #5
  br label %92

87:                                               ; preds = %82
  %88 = landingpad { ptr, i32 }
          cleanup
  br label %91

89:                                               ; preds = %84
  %90 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #5
  br label %91

91:                                               ; preds = %89, %87
  %.pn = phi { ptr, i32 } [ %90, %89 ], [ %88, %87 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %13) #5
  br label %94

92:                                               ; preds = %36, %62, %86, %75, %49, %21
  %.123 = phi ptr [ %22, %21 ], [ %37, %36 ], [ %50, %49 ], [ %63, %62 ], [ %76, %75 ], [ %83, %86 ]
  %93 = load i32, ptr %.123, align 4, !tbaa !5
  %.not = icmp eq i32 %93, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph, !llvm.loop !9

94:                                               ; preds = %91, %81, %68, %55, %42, %29, %23
  %.pn33.pn = phi { ptr, i32 } [ %.pn33, %29 ], [ %.pn31, %42 ], [ %.pn29, %55 ], [ %.pn27, %68 ], [ %.pn25, %81 ], [ %.pn, %91 ], [ %24, %23 ]
  call void @_ZN2vl12ObjectStringIwED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %0) #5
  resume { ptr, i32 } %.pn33.pn

._crit_edge:                                      ; preds = %92, %.preheader
  ret void
}

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 = { mustprogress nofree nounwind willreturn memory(read) "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 willreturn memory(read) }
attributes #5 = { 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 = !{!"wchar_t", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}


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