; LLVM IR from HiroIshida/tinyfk :: urdf_parser/tinyxml/tinyxmlparser.ll (ZN9TiXmlNode8IdentifyEPKc13TiXmlEncoding)

; 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.TiXmlNode = type { %class.TiXmlBase, ptr, i32, ptr, ptr, %"class.std::__cxx11::basic_string", ptr, ptr }
%class.TiXmlBase = type { ptr, %struct.TiXmlCursor, ptr }
%struct.TiXmlCursor = type { i32, i32 }
%"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] }

@.str.11 = external hidden unnamed_addr constant [1 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [10 x i8], align 1

; 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 nounwind uwtable
declare dso_local noundef i32 @_ZN9TiXmlBase7IsAlphaEh13TiXmlEncoding(i8 noundef zeroext, i32 noundef) #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZN9TiXmlBase14SkipWhiteSpaceEPKc13TiXmlEncoding(ptr noundef, i32 noundef) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef, ptr noundef, i1 noundef zeroext, i32 noundef) #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN9TiXmlNode8IdentifyEPKc13TiXmlEncoding(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef %1, i32 noundef %2) #2 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store i32 %2, ptr %7, align 4, !tbaa !9
  %17 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  store ptr null, ptr %8, align 8, !tbaa !5
  %18 = load ptr, ptr %6, align 8, !tbaa !5
  %19 = load i32, ptr %7, align 4, !tbaa !9
  %20 = call noundef ptr @_ZN9TiXmlBase14SkipWhiteSpaceEPKc13TiXmlEncoding(ptr noundef %18, i32 noundef %19)
  store ptr %20, ptr %6, align 8, !tbaa !5
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  %22 = icmp ne ptr %21, null
  br i1 %22, label %23, label %32

23:                                               ; preds = %3
  %24 = load ptr, ptr %6, align 8, !tbaa !5
  %25 = load i8, ptr %24, align 1, !tbaa !11
  %26 = icmp ne i8 %25, 0
  br i1 %26, label %27, label %32

27:                                               ; preds = %23
  %28 = load ptr, ptr %6, align 8, !tbaa !5
  %29 = load i8, ptr %28, align 1, !tbaa !11
  %30 = sext i8 %29 to i32
  %31 = icmp ne i32 %30, 60
  br i1 %31, label %32, label %33

32:                                               ; preds = %27, %23, %3
  store ptr null, ptr %4, align 8
  store i32 1, ptr %9, align 4
  br label %134

33:                                               ; preds = %27
  %34 = load ptr, ptr %6, align 8, !tbaa !5
  %35 = load i32, ptr %7, align 4, !tbaa !9
  %36 = call noundef ptr @_ZN9TiXmlBase14SkipWhiteSpaceEPKc13TiXmlEncoding(ptr noundef %34, i32 noundef %35)
  store ptr %36, ptr %6, align 8, !tbaa !5
  %37 = load ptr, ptr %6, align 8, !tbaa !5
  %38 = icmp ne ptr %37, null
  br i1 %38, label %39, label %43

39:                                               ; preds = %33
  %40 = load ptr, ptr %6, align 8, !tbaa !5
  %41 = load i8, ptr %40, align 1, !tbaa !11
  %42 = icmp ne i8 %41, 0
  br i1 %42, label %44, label %43

43:                                               ; preds = %39, %33
  store ptr null, ptr %4, align 8
  store i32 1, ptr %9, align 4
  br label %134

44:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  store ptr @.str.19, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  store ptr @.str.20, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  store ptr @.str.21, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  store ptr @.str.22, ptr %13, align 8, !tbaa !5
  %45 = load ptr, ptr %6, align 8, !tbaa !5
  %46 = load ptr, ptr %10, align 8, !tbaa !5
  %47 = load i32, ptr %7, align 4, !tbaa !9
  %48 = call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef %45, ptr noundef %46, i1 noundef zeroext true, i32 noundef %47)
  br i1 %48, label %49, label %56

49:                                               ; preds = %44
  %50 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 200) #7
  invoke void @_ZN16TiXmlDeclarationC2Ev(ptr noundef nonnull align 8 dereferenceable(200) %50)
          to label %51 unwind label %52

51:                                               ; preds = %49
  store ptr %50, ptr %8, align 8, !tbaa !5
  br label %125

52:                                               ; preds = %49
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %14, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %15, align 4
  call void @_ZdlPvm(ptr noundef %50, i64 noundef 200) #8
  br label %133

56:                                               ; preds = %44
  %57 = load ptr, ptr %6, align 8, !tbaa !5
  %58 = load ptr, ptr %11, align 8, !tbaa !5
  %59 = load i32, ptr %7, align 4, !tbaa !9
  %60 = call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef %57, ptr noundef %58, i1 noundef zeroext false, i32 noundef %59)
  br i1 %60, label %61, label %68

61:                                               ; preds = %56
  %62 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 104) #7
  invoke void @_ZN12TiXmlCommentC2Ev(ptr noundef nonnull align 8 dereferenceable(104) %62)
          to label %63 unwind label %64

63:                                               ; preds = %61
  store ptr %62, ptr %8, align 8, !tbaa !5
  br label %124

64:                                               ; preds = %61
  %65 = landingpad { ptr, i32 }
          cleanup
  %66 = extractvalue { ptr, i32 } %65, 0
  store ptr %66, ptr %14, align 8
  %67 = extractvalue { ptr, i32 } %65, 1
  store i32 %67, ptr %15, align 4
  call void @_ZdlPvm(ptr noundef %62, i64 noundef 104) #8
  br label %133

68:                                               ; preds = %56
  %69 = load ptr, ptr %6, align 8, !tbaa !5
  %70 = load ptr, ptr %13, align 8, !tbaa !5
  %71 = load i32, ptr %7, align 4, !tbaa !9
  %72 = call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef %69, ptr noundef %70, i1 noundef zeroext false, i32 noundef %71)
  br i1 %72, label %73, label %82

73:                                               ; preds = %68
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %74 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 112) #7
  invoke void @_ZN9TiXmlTextC2EPKc(ptr noundef nonnull align 8 dereferenceable(105) %74, ptr noundef @.str.11)
          to label %75 unwind label %78

75:                                               ; preds = %73
  store ptr %74, ptr %16, align 8, !tbaa !5
  %76 = load ptr, ptr %16, align 8, !tbaa !5
  call void @_ZN9TiXmlText8SetCDATAEb(ptr noundef nonnull align 8 dereferenceable(105) %76, i1 noundef zeroext true)
  %77 = load ptr, ptr %16, align 8, !tbaa !5
  store ptr %77, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %123

78:                                               ; preds = %73
  %79 = landingpad { ptr, i32 }
          cleanup
  %80 = extractvalue { ptr, i32 } %79, 0
  store ptr %80, ptr %14, align 8
  %81 = extractvalue { ptr, i32 } %79, 1
  store i32 %81, ptr %15, align 4
  call void @_ZdlPvm(ptr noundef %74, i64 noundef 112) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %133

82:                                               ; preds = %68
  %83 = load ptr, ptr %6, align 8, !tbaa !5
  %84 = load ptr, ptr %12, align 8, !tbaa !5
  %85 = load i32, ptr %7, align 4, !tbaa !9
  %86 = call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef %83, ptr noundef %84, i1 noundef zeroext false, i32 noundef %85)
  br i1 %86, label %87, label %94

87:                                               ; preds = %82
  %88 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 104) #7
  invoke void @_ZN12TiXmlUnknownC2Ev(ptr noundef nonnull align 8 dereferenceable(104) %88)
          to label %89 unwind label %90

89:                                               ; preds = %87
  store ptr %88, ptr %8, align 8, !tbaa !5
  br label %122

90:                                               ; preds = %87
  %91 = landingpad { ptr, i32 }
          cleanup
  %92 = extractvalue { ptr, i32 } %91, 0
  store ptr %92, ptr %14, align 8
  %93 = extractvalue { ptr, i32 } %91, 1
  store i32 %93, ptr %15, align 4
  call void @_ZdlPvm(ptr noundef %88, i64 noundef 104) #8
  br label %133

94:                                               ; preds = %82
  %95 = load ptr, ptr %6, align 8, !tbaa !5
  %96 = getelementptr inbounds i8, ptr %95, i64 1
  %97 = load i8, ptr %96, align 1, !tbaa !11
  %98 = load i32, ptr %7, align 4, !tbaa !9
  %99 = call noundef i32 @_ZN9TiXmlBase7IsAlphaEh13TiXmlEncoding(i8 noundef zeroext %97, i32 noundef %98)
  %100 = icmp ne i32 %99, 0
  br i1 %100, label %107, label %101

101:                                              ; preds = %94
  %102 = load ptr, ptr %6, align 8, !tbaa !5
  %103 = getelementptr inbounds i8, ptr %102, i64 1
  %104 = load i8, ptr %103, align 1, !tbaa !11
  %105 = sext i8 %104 to i32
  %106 = icmp eq i32 %105, 95
  br i1 %106, label %107, label %114

107:                                              ; preds = %101, %94
  %108 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 216) #7
  invoke void @_ZN12TiXmlElementC1EPKc(ptr noundef nonnull align 8 dereferenceable(216) %108, ptr noundef @.str.11)
          to label %109 unwind label %110

109:                                              ; preds = %107
  store ptr %108, ptr %8, align 8, !tbaa !5
  br label %121

110:                                              ; preds = %107
  %111 = landingpad { ptr, i32 }
          cleanup
  %112 = extractvalue { ptr, i32 } %111, 0
  store ptr %112, ptr %14, align 8
  %113 = extractvalue { ptr, i32 } %111, 1
  store i32 %113, ptr %15, align 4
  call void @_ZdlPvm(ptr noundef %108, i64 noundef 216) #8
  br label %133

114:                                              ; preds = %101
  %115 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 104) #7
  invoke void @_ZN12TiXmlUnknownC2Ev(ptr noundef nonnull align 8 dereferenceable(104) %115)
          to label %116 unwind label %117

116:                                              ; preds = %114
  store ptr %115, ptr %8, align 8, !tbaa !5
  br label %121

117:                                              ; preds = %114
  %118 = landingpad { ptr, i32 }
          cleanup
  %119 = extractvalue { ptr, i32 } %118, 0
  store ptr %119, ptr %14, align 8
  %120 = extractvalue { ptr, i32 } %118, 1
  store i32 %120, ptr %15, align 4
  call void @_ZdlPvm(ptr noundef %115, i64 noundef 104) #8
  br label %133

121:                                              ; preds = %116, %109
  br label %122

122:                                              ; preds = %121, %89
  br label %123

123:                                              ; preds = %122, %75
  br label %124

124:                                              ; preds = %123, %63
  br label %125

125:                                              ; preds = %124, %51
  %126 = load ptr, ptr %8, align 8, !tbaa !5
  %127 = icmp ne ptr %126, null
  br i1 %127, label %128, label %131

128:                                              ; preds = %125
  %129 = load ptr, ptr %8, align 8, !tbaa !5
  %130 = getelementptr inbounds %class.TiXmlNode, ptr %129, i32 0, i32 1
  store ptr %17, ptr %130, align 8, !tbaa !12
  br label %131

131:                                              ; preds = %128, %125
  %132 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %132, ptr %4, align 8
  store i32 1, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  br label %134

133:                                              ; preds = %117, %110, %90, %78, %64, %52
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  br label %136

134:                                              ; preds = %131, %43, %32
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  %135 = load ptr, ptr %4, align 8
  ret ptr %135

136:                                              ; preds = %133
  %137 = load ptr, ptr %14, align 8
  %138 = load i32, ptr %15, align 4
  %139 = insertvalue { ptr, i32 } poison, ptr %137, 0
  %140 = insertvalue { ptr, i32 } %139, i32 %138, 1
  resume { ptr, i32 } %140
}

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) #3

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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #4

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN9TiXmlTextC2EPKc(ptr noundef nonnull align 8 dereferenceable(105), ptr noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN9TiXmlText8SetCDATAEb(ptr noundef nonnull align 8 dereferenceable(105), i1 noundef zeroext) #1 align 2

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

declare void @_ZN12TiXmlElementC1EPKc(ptr noundef nonnull align 8 dereferenceable(216), ptr noundef) unnamed_addr #5

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #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 = { nobuiltin allocsize(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 = { nobuiltin 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 #5 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }
attributes #7 = { builtin allocsize(0) }
attributes #8 = { builtin 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 = !{!"_ZTS13TiXmlEncoding", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !6, i64 24}
!13 = !{!"_ZTS9TiXmlNode", !14, i64 0, !6, i64 24, !17, i64 32, !6, i64 40, !6, i64 48, !18, i64 56, !6, i64 88, !6, i64 96}
!14 = !{!"_ZTS9TiXmlBase", !15, i64 8, !6, i64 16}
!15 = !{!"_ZTS11TiXmlCursor", !16, i64 0, !16, i64 4}
!16 = !{!"int", !7, i64 0}
!17 = !{!"_ZTSN9TiXmlNode8NodeTypeE", !7, i64 0}
!18 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !19, i64 0, !20, i64 8, !7, i64 16}
!19 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!20 = !{!"long", !7, i64 0}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@.str.11 = external hidden unnamed_addr constant [1 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [10 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN9TiXmlBase7IsAlphaEh13TiXmlEncoding(i8 noundef zeroext, i32 noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZN9TiXmlBase14SkipWhiteSpaceEPKc13TiXmlEncoding(ptr noundef, i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef, ptr noundef, i1 noundef zeroext, i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN9TiXmlNode8IdentifyEPKc13TiXmlEncoding(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef %1, i32 noundef %2) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = tail call noundef ptr @_ZN9TiXmlBase14SkipWhiteSpaceEPKc13TiXmlEncoding(ptr noundef %1, i32 noundef %2)
  %.not = icmp eq ptr %4, null
  br i1 %.not, label %54, label %5

5:                                                ; preds = %3
  %6 = load i8, ptr %4, align 1, !tbaa !5
  %cond = icmp eq i8 %6, 60
  br i1 %cond, label %7, label %54

7:                                                ; preds = %5
  %8 = tail call noundef ptr @_ZN9TiXmlBase14SkipWhiteSpaceEPKc13TiXmlEncoding(ptr noundef nonnull %4, i32 noundef %2)
  %.not40 = icmp eq ptr %8, null
  br i1 %.not40, label %54, label %9

9:                                                ; preds = %7
  %10 = load i8, ptr %8, align 1, !tbaa !5
  %.not41 = icmp eq i8 %10, 0
  br i1 %.not41, label %54, label %11

11:                                               ; preds = %9
  %12 = tail call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef nonnull %8, ptr noundef nonnull @.str.19, i1 noundef zeroext true, i32 noundef %2)
  br i1 %12, label %13, label %17

13:                                               ; preds = %11
  %14 = tail call noalias noundef nonnull dereferenceable(200) ptr @_Znwm(i64 noundef 200) #5
  invoke void @_ZN16TiXmlDeclarationC2Ev(ptr noundef nonnull align 8 dereferenceable(200) %14)
          to label %51 unwind label %15

15:                                               ; preds = %13
  %16 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %14, i64 noundef 200) #6
  br label %53

17:                                               ; preds = %11
  %18 = tail call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef nonnull %8, ptr noundef nonnull @.str.20, i1 noundef zeroext false, i32 noundef %2)
  br i1 %18, label %19, label %23

19:                                               ; preds = %17
  %20 = tail call noalias noundef nonnull dereferenceable(104) ptr @_Znwm(i64 noundef 104) #5
  invoke void @_ZN12TiXmlCommentC2Ev(ptr noundef nonnull align 8 dereferenceable(104) %20)
          to label %51 unwind label %21

21:                                               ; preds = %19
  %22 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %20, i64 noundef 104) #6
  br label %53

23:                                               ; preds = %17
  %24 = tail call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef nonnull %8, ptr noundef nonnull @.str.22, i1 noundef zeroext false, i32 noundef %2)
  br i1 %24, label %25, label %30

25:                                               ; preds = %23
  %26 = tail call noalias noundef nonnull dereferenceable(112) ptr @_Znwm(i64 noundef 112) #5
  invoke void @_ZN9TiXmlTextC2EPKc(ptr noundef nonnull align 8 dereferenceable(105) %26, ptr noundef nonnull @.str.11)
          to label %27 unwind label %28

27:                                               ; preds = %25
  tail call void @_ZN9TiXmlText8SetCDATAEb(ptr noundef nonnull align 8 dereferenceable(105) %26, i1 noundef zeroext true)
  br label %51

28:                                               ; preds = %25
  %29 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %26, i64 noundef 112) #6
  br label %53

30:                                               ; preds = %23
  %31 = tail call noundef zeroext i1 @_ZN9TiXmlBase11StringEqualEPKcS1_b13TiXmlEncoding(ptr noundef nonnull %8, ptr noundef nonnull @.str.21, i1 noundef zeroext false, i32 noundef %2)
  br i1 %31, label %32, label %36

32:                                               ; preds = %30
  %33 = tail call noalias noundef nonnull dereferenceable(104) ptr @_Znwm(i64 noundef 104) #5
  invoke void @_ZN12TiXmlUnknownC2Ev(ptr noundef nonnull align 8 dereferenceable(104) %33)
          to label %51 unwind label %34

34:                                               ; preds = %32
  %35 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %33, i64 noundef 104) #6
  br label %53

36:                                               ; preds = %30
  %37 = getelementptr inbounds i8, ptr %8, i64 1
  %38 = load i8, ptr %37, align 1, !tbaa !5
  %39 = tail call noundef i32 @_ZN9TiXmlBase7IsAlphaEh13TiXmlEncoding(i8 noundef zeroext %38, i32 noundef %2)
  %.not42 = icmp eq i32 %39, 0
  br i1 %.not42, label %40, label %43

40:                                               ; preds = %36
  %41 = load i8, ptr %37, align 1, !tbaa !5
  %42 = icmp eq i8 %41, 95
  br i1 %42, label %43, label %47

43:                                               ; preds = %40, %36
  %44 = tail call noalias noundef nonnull dereferenceable(216) ptr @_Znwm(i64 noundef 216) #5
  invoke void @_ZN12TiXmlElementC1EPKc(ptr noundef nonnull align 8 dereferenceable(216) %44, ptr noundef nonnull @.str.11)
          to label %51 unwind label %45

45:                                               ; preds = %43
  %46 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %44, i64 noundef 216) #6
  br label %53

47:                                               ; preds = %40
  %48 = tail call noalias noundef nonnull dereferenceable(104) ptr @_Znwm(i64 noundef 104) #5
  invoke void @_ZN12TiXmlUnknownC2Ev(ptr noundef nonnull align 8 dereferenceable(104) %48)
          to label %51 unwind label %49

49:                                               ; preds = %47
  %50 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %48, i64 noundef 104) #6
  br label %53

51:                                               ; preds = %27, %13, %19, %32, %43, %47
  %.034 = phi ptr [ %26, %27 ], [ %14, %13 ], [ %20, %19 ], [ %33, %32 ], [ %44, %43 ], [ %48, %47 ]
  %52 = getelementptr inbounds i8, ptr %.034, i64 24
  store ptr %0, ptr %52, align 8, !tbaa !8
  br label %54

53:                                               ; preds = %49, %45, %34, %28, %21, %15
  %.pn = phi { ptr, i32 } [ %16, %15 ], [ %22, %21 ], [ %29, %28 ], [ %35, %34 ], [ %46, %45 ], [ %50, %49 ]
  resume { ptr, i32 } %.pn

54:                                               ; preds = %5, %7, %9, %3, %51
  %.0 = phi ptr [ %.034, %51 ], [ null, %5 ], [ null, %3 ], [ null, %9 ], [ null, %7 ]
  ret ptr %.0
}

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16TiXmlDeclarationC2Ev(ptr noundef nonnull align 8 dereferenceable(200)) unnamed_addr #1 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN12TiXmlCommentC2Ev(ptr noundef nonnull align 8 dereferenceable(104)) unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN9TiXmlText8SetCDATAEb(ptr noundef nonnull align 8 dereferenceable(105), i1 noundef zeroext) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN12TiXmlUnknownC2Ev(ptr noundef nonnull align 8 dereferenceable(104)) unnamed_addr #1 align 2

declare void @_ZN12TiXmlElementC1EPKc(ptr noundef nonnull align 8 dereferenceable(216), ptr noundef) unnamed_addr #4

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { 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 = { nobuiltin allocsize(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 = { nobuiltin 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 #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { builtin allocsize(0) }
attributes #6 = { builtin 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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !13, i64 24}
!9 = !{!"_ZTS9TiXmlNode", !10, i64 0, !13, i64 24, !14, i64 32, !13, i64 40, !13, i64 48, !15, i64 56, !13, i64 88, !13, i64 96}
!10 = !{!"_ZTS9TiXmlBase", !11, i64 8, !13, i64 16}
!11 = !{!"_ZTS11TiXmlCursor", !12, i64 0, !12, i64 4}
!12 = !{!"int", !6, i64 0}
!13 = !{!"any pointer", !6, i64 0}
!14 = !{!"_ZTSN9TiXmlNode8NodeTypeE", !6, i64 0}
!15 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !16, i64 0, !17, i64 8, !6, i64 16}
!16 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !13, i64 0}
!17 = !{!"long", !6, i64 0}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,SimplifyCFGPass,TailCallElimPass