; LLVM IR from facebookresearch/habitat-sim :: src/deps/tinyxml2/tinyxml2.ll (ZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeE)

; 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.tinyxml2::XMLDocument" = type { %"class.tinyxml2::XMLNode", i8, i8, i32, i32, %"class.tinyxml2::StrPair", i32, ptr, i32, i32, %"class.tinyxml2::DynArray", %"class.tinyxml2::MemPoolT", %"class.tinyxml2::MemPoolT.1", %"class.tinyxml2::MemPoolT.3", %"class.tinyxml2::MemPoolT.5" }
%"class.tinyxml2::XMLNode" = type { ptr, ptr, ptr, %"class.tinyxml2::StrPair", i32, ptr, ptr, ptr, ptr, ptr, ptr }
%"class.tinyxml2::StrPair" = type { i32, ptr, ptr }
%"class.tinyxml2::DynArray" = type { ptr, [10 x ptr], i32, i32 }
%"class.tinyxml2::MemPoolT" = type { %"class.tinyxml2::MemPool", %"class.tinyxml2::DynArray.0", ptr, i32, i32, i32, i32 }
%"class.tinyxml2::MemPool" = type { ptr }
%"class.tinyxml2::DynArray.0" = type { ptr, [10 x ptr], i32, i32 }
%"class.tinyxml2::MemPoolT.1" = type { %"class.tinyxml2::MemPool", %"class.tinyxml2::DynArray.2", ptr, i32, i32, i32, i32 }
%"class.tinyxml2::DynArray.2" = type { ptr, [10 x ptr], i32, i32 }
%"class.tinyxml2::MemPoolT.3" = type { %"class.tinyxml2::MemPool", %"class.tinyxml2::DynArray.4", ptr, i32, i32, i32, i32 }
%"class.tinyxml2::DynArray.4" = type { ptr, [10 x ptr], i32, i32 }
%"class.tinyxml2::MemPoolT.5" = type { %"class.tinyxml2::MemPool", %"class.tinyxml2::DynArray.6", ptr, i32, i32, i32, i32 }
%"class.tinyxml2::DynArray.6" = type { ptr, [10 x ptr], i32, i32 }

@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9xmlHeader = external hidden global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13commentHeader = external hidden global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE11cdataHeader = external hidden global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9dtdHeader = external hidden global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13elementHeader = external hidden global ptr, align 8

; 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
declare dso_local noundef ptr @_ZN8tinyxml27XMLUtil14SkipWhiteSpaceEPcPi(ptr noundef, ptr noundef) #1 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef %1, ptr noundef %2) #1 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %13 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %14 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %14, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  %15 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %16 = load i32, ptr %15, align 8, !tbaa !9
  store i32 %16, ptr %9, align 4, !tbaa !27
  %17 = load ptr, ptr %6, align 8, !tbaa !5
  %18 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %19 = call noundef ptr @_ZN8tinyxml27XMLUtil14SkipWhiteSpaceEPcPi(ptr noundef %17, ptr noundef %18)
  store ptr %19, ptr %6, align 8, !tbaa !5
  %20 = load ptr, ptr %6, align 8, !tbaa !5
  %21 = load i8, ptr %20, align 1, !tbaa !28
  %22 = icmp ne i8 %21, 0
  br i1 %22, label %26, label %23

23:                                               ; preds = %3
  %24 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr null, ptr %24, align 8, !tbaa !5
  %25 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %25, ptr %4, align 8
  store i32 1, ptr %10, align 4
  br label %111

26:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  store ptr null, ptr %11, align 8, !tbaa !5
  %27 = load ptr, ptr %6, align 8, !tbaa !5
  %28 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9xmlHeader, align 8, !tbaa !5
  %29 = call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef %27, ptr noundef %28, i32 noundef 2)
  br i1 %29, label %30, label %39

30:                                               ; preds = %26
  %31 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 14
  %32 = call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_14XMLDeclarationELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %13, ptr noundef nonnull align 8 dereferenceable(128) %31)
  store ptr %32, ptr %11, align 8, !tbaa !5
  %33 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %34 = load i32, ptr %33, align 8, !tbaa !9
  %35 = load ptr, ptr %11, align 8, !tbaa !5
  %36 = getelementptr inbounds %"class.tinyxml2::XMLNode", ptr %35, i32 0, i32 4
  store i32 %34, ptr %36, align 8, !tbaa !29
  %37 = load ptr, ptr %6, align 8, !tbaa !5
  %38 = getelementptr inbounds i8, ptr %37, i64 2
  store ptr %38, ptr %6, align 8, !tbaa !5
  br label %107

39:                                               ; preds = %26
  %40 = load ptr, ptr %6, align 8, !tbaa !5
  %41 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13commentHeader, align 8, !tbaa !5
  %42 = call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef %40, ptr noundef %41, i32 noundef 4)
  br i1 %42, label %43, label %52

43:                                               ; preds = %39
  %44 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 14
  %45 = call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLCommentELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %13, ptr noundef nonnull align 8 dereferenceable(128) %44)
  store ptr %45, ptr %11, align 8, !tbaa !5
  %46 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %47 = load i32, ptr %46, align 8, !tbaa !9
  %48 = load ptr, ptr %11, align 8, !tbaa !5
  %49 = getelementptr inbounds %"class.tinyxml2::XMLNode", ptr %48, i32 0, i32 4
  store i32 %47, ptr %49, align 8, !tbaa !29
  %50 = load ptr, ptr %6, align 8, !tbaa !5
  %51 = getelementptr inbounds i8, ptr %50, i64 4
  store ptr %51, ptr %6, align 8, !tbaa !5
  br label %106

52:                                               ; preds = %39
  %53 = load ptr, ptr %6, align 8, !tbaa !5
  %54 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE11cdataHeader, align 8, !tbaa !5
  %55 = call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef %53, ptr noundef %54, i32 noundef 9)
  br i1 %55, label %56, label %67

56:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %57 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 13
  %58 = call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_7XMLTextELi112EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %13, ptr noundef nonnull align 8 dereferenceable(128) %57)
  store ptr %58, ptr %12, align 8, !tbaa !5
  %59 = load ptr, ptr %12, align 8, !tbaa !5
  store ptr %59, ptr %11, align 8, !tbaa !5
  %60 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %61 = load i32, ptr %60, align 8, !tbaa !9
  %62 = load ptr, ptr %11, align 8, !tbaa !5
  %63 = getelementptr inbounds %"class.tinyxml2::XMLNode", ptr %62, i32 0, i32 4
  store i32 %61, ptr %63, align 8, !tbaa !29
  %64 = load ptr, ptr %6, align 8, !tbaa !5
  %65 = getelementptr inbounds i8, ptr %64, i64 9
  store ptr %65, ptr %6, align 8, !tbaa !5
  %66 = load ptr, ptr %12, align 8, !tbaa !5
  call void @_ZN8tinyxml27XMLText8SetCDataEb(ptr noundef nonnull align 8 dereferenceable(105) %66, i1 noundef zeroext true)
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  br label %105

67:                                               ; preds = %52
  %68 = load ptr, ptr %6, align 8, !tbaa !5
  %69 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9dtdHeader, align 8, !tbaa !5
  %70 = call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef %68, ptr noundef %69, i32 noundef 2)
  br i1 %70, label %71, label %80

71:                                               ; preds = %67
  %72 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 14
  %73 = call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLUnknownELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %13, ptr noundef nonnull align 8 dereferenceable(128) %72)
  store ptr %73, ptr %11, align 8, !tbaa !5
  %74 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %75 = load i32, ptr %74, align 8, !tbaa !9
  %76 = load ptr, ptr %11, align 8, !tbaa !5
  %77 = getelementptr inbounds %"class.tinyxml2::XMLNode", ptr %76, i32 0, i32 4
  store i32 %75, ptr %77, align 8, !tbaa !29
  %78 = load ptr, ptr %6, align 8, !tbaa !5
  %79 = getelementptr inbounds i8, ptr %78, i64 2
  store ptr %79, ptr %6, align 8, !tbaa !5
  br label %104

80:                                               ; preds = %67
  %81 = load ptr, ptr %6, align 8, !tbaa !5
  %82 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13elementHeader, align 8, !tbaa !5
  %83 = call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef %81, ptr noundef %82, i32 noundef 1)
  br i1 %83, label %84, label %93

84:                                               ; preds = %80
  %85 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 11
  %86 = call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLElementELi120EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %13, ptr noundef nonnull align 8 dereferenceable(128) %85)
  store ptr %86, ptr %11, align 8, !tbaa !5
  %87 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %88 = load i32, ptr %87, align 8, !tbaa !9
  %89 = load ptr, ptr %11, align 8, !tbaa !5
  %90 = getelementptr inbounds %"class.tinyxml2::XMLNode", ptr %89, i32 0, i32 4
  store i32 %88, ptr %90, align 8, !tbaa !29
  %91 = load ptr, ptr %6, align 8, !tbaa !5
  %92 = getelementptr inbounds i8, ptr %91, i64 1
  store ptr %92, ptr %6, align 8, !tbaa !5
  br label %103

93:                                               ; preds = %80
  %94 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 13
  %95 = call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_7XMLTextELi112EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %13, ptr noundef nonnull align 8 dereferenceable(128) %94)
  store ptr %95, ptr %11, align 8, !tbaa !5
  %96 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  %97 = load i32, ptr %96, align 8, !tbaa !9
  %98 = load ptr, ptr %11, align 8, !tbaa !5
  %99 = getelementptr inbounds %"class.tinyxml2::XMLNode", ptr %98, i32 0, i32 4
  store i32 %97, ptr %99, align 8, !tbaa !29
  %100 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %100, ptr %6, align 8, !tbaa !5
  %101 = load i32, ptr %9, align 4, !tbaa !27
  %102 = getelementptr inbounds %"class.tinyxml2::XMLDocument", ptr %13, i32 0, i32 8
  store i32 %101, ptr %102, align 8, !tbaa !9
  br label %103

103:                                              ; preds = %93, %84
  br label %104

104:                                              ; preds = %103, %71
  br label %105

105:                                              ; preds = %104, %56
  br label %106

106:                                              ; preds = %105, %43
  br label %107

107:                                              ; preds = %106, %30
  %108 = load ptr, ptr %11, align 8, !tbaa !5
  %109 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %108, ptr %109, align 8, !tbaa !5
  %110 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %110, ptr %4, align 8
  store i32 1, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  br label %111

111:                                              ; preds = %107, %23
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  %112 = load ptr, ptr %4, align 8
  ret ptr %112
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_14XMLDeclarationELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLCommentELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_7XMLTextELi112EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) #3 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLUnknownELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLElementELi120EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) #3 align 2

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 = { 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 #3 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !13, i64 160}
!10 = !{!"_ZTSN8tinyxml211XMLDocumentE", !11, i64 0, !14, i64 104, !14, i64 105, !15, i64 108, !16, i64 112, !12, i64 120, !13, i64 144, !6, i64 152, !13, i64 160, !13, i64 164, !17, i64 168, !18, i64 264, !21, i64 392, !23, i64 520, !25, i64 648}
!11 = !{!"_ZTSN8tinyxml27XMLNodeE", !6, i64 8, !6, i64 16, !12, i64 24, !13, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96}
!12 = !{!"_ZTSN8tinyxml27StrPairE", !13, i64 0, !6, i64 8, !6, i64 16}
!13 = !{!"int", !7, i64 0}
!14 = !{!"bool", !7, i64 0}
!15 = !{!"_ZTSN8tinyxml28XMLErrorE", !7, i64 0}
!16 = !{!"_ZTSN8tinyxml210WhitespaceE", !7, i64 0}
!17 = !{!"_ZTSN8tinyxml28DynArrayIPNS_7XMLNodeELi10EEE", !6, i64 0, !7, i64 8, !13, i64 88, !13, i64 92}
!18 = !{!"_ZTSN8tinyxml28MemPoolTILi120EEE", !19, i64 0, !20, i64 8, !6, i64 104, !13, i64 112, !13, i64 116, !13, i64 120, !13, i64 124}
!19 = !{!"_ZTSN8tinyxml27MemPoolE"}
!20 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi120EE5BlockELi10EEE", !6, i64 0, !7, i64 8, !13, i64 88, !13, i64 92}
!21 = !{!"_ZTSN8tinyxml28MemPoolTILi80EEE", !19, i64 0, !22, i64 8, !6, i64 104, !13, i64 112, !13, i64 116, !13, i64 120, !13, i64 124}
!22 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi80EE5BlockELi10EEE", !6, i64 0, !7, i64 8, !13, i64 88, !13, i64 92}
!23 = !{!"_ZTSN8tinyxml28MemPoolTILi112EEE", !19, i64 0, !24, i64 8, !6, i64 104, !13, i64 112, !13, i64 116, !13, i64 120, !13, i64 124}
!24 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi112EE5BlockELi10EEE", !6, i64 0, !7, i64 8, !13, i64 88, !13, i64 92}
!25 = !{!"_ZTSN8tinyxml28MemPoolTILi104EEE", !19, i64 0, !26, i64 8, !6, i64 104, !13, i64 112, !13, i64 116, !13, i64 120, !13, i64 124}
!26 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi104EE5BlockELi10EEE", !6, i64 0, !7, i64 8, !13, i64 88, !13, i64 92}
!27 = !{!13, !13, i64 0}
!28 = !{!7, !7, i64 0}
!29 = !{!11, !13, i64 48}


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

@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9xmlHeader = external hidden local_unnamed_addr global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13commentHeader = external hidden local_unnamed_addr global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE11cdataHeader = external hidden local_unnamed_addr global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9dtdHeader = external hidden local_unnamed_addr global ptr, align 8
@_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13elementHeader = external hidden local_unnamed_addr global ptr, align 8

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml27XMLUtil14SkipWhiteSpaceEPcPi(ptr noundef, ptr noundef) local_unnamed_addr #0 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef %1, ptr nocapture noundef writeonly %2) local_unnamed_addr #0 align 2 {
  %4 = getelementptr inbounds i8, ptr %0, i64 160
  %5 = load i32, ptr %4, align 8, !tbaa !5
  %6 = tail call noundef ptr @_ZN8tinyxml27XMLUtil14SkipWhiteSpaceEPcPi(ptr noundef %1, ptr noundef nonnull %4)
  %7 = load i8, ptr %6, align 1, !tbaa !26
  %.not = icmp eq i8 %7, 0
  br i1 %.not, label %58, label %8

8:                                                ; preds = %3
  %9 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9xmlHeader, align 8, !tbaa !27
  %10 = tail call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef nonnull %6, ptr noundef %9, i32 noundef 2)
  br i1 %10, label %11, label %17

11:                                               ; preds = %8
  %12 = getelementptr inbounds i8, ptr %0, i64 648
  %13 = tail call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_14XMLDeclarationELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef nonnull align 8 dereferenceable(128) %12)
  %14 = load i32, ptr %4, align 8, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %13, i64 48
  store i32 %14, ptr %15, align 8, !tbaa !28
  %16 = getelementptr inbounds i8, ptr %6, i64 2
  br label %58

17:                                               ; preds = %8
  %18 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13commentHeader, align 8, !tbaa !27
  %19 = tail call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef nonnull %6, ptr noundef %18, i32 noundef 4)
  br i1 %19, label %20, label %26

20:                                               ; preds = %17
  %21 = getelementptr inbounds i8, ptr %0, i64 648
  %22 = tail call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLCommentELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef nonnull align 8 dereferenceable(128) %21)
  %23 = load i32, ptr %4, align 8, !tbaa !5
  %24 = getelementptr inbounds i8, ptr %22, i64 48
  store i32 %23, ptr %24, align 8, !tbaa !28
  %25 = getelementptr inbounds i8, ptr %6, i64 4
  br label %58

26:                                               ; preds = %17
  %27 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE11cdataHeader, align 8, !tbaa !27
  %28 = tail call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef nonnull %6, ptr noundef %27, i32 noundef 9)
  br i1 %28, label %29, label %35

29:                                               ; preds = %26
  %30 = getelementptr inbounds i8, ptr %0, i64 520
  %31 = tail call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_7XMLTextELi112EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef nonnull align 8 dereferenceable(128) %30)
  %32 = load i32, ptr %4, align 8, !tbaa !5
  %33 = getelementptr inbounds i8, ptr %31, i64 48
  store i32 %32, ptr %33, align 8, !tbaa !28
  %34 = getelementptr inbounds i8, ptr %6, i64 9
  tail call void @_ZN8tinyxml27XMLText8SetCDataEb(ptr noundef nonnull align 8 dereferenceable(105) %31, i1 noundef zeroext true)
  br label %58

35:                                               ; preds = %26
  %36 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE9dtdHeader, align 8, !tbaa !27
  %37 = tail call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef nonnull %6, ptr noundef %36, i32 noundef 2)
  br i1 %37, label %38, label %44

38:                                               ; preds = %35
  %39 = getelementptr inbounds i8, ptr %0, i64 648
  %40 = tail call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLUnknownELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef nonnull align 8 dereferenceable(128) %39)
  %41 = load i32, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds i8, ptr %40, i64 48
  store i32 %41, ptr %42, align 8, !tbaa !28
  %43 = getelementptr inbounds i8, ptr %6, i64 2
  br label %58

44:                                               ; preds = %35
  %45 = load ptr, ptr @_ZZN8tinyxml211XMLDocument8IdentifyEPcPPNS_7XMLNodeEE13elementHeader, align 8, !tbaa !27
  %46 = tail call noundef zeroext i1 @_ZN8tinyxml27XMLUtil11StringEqualEPKcS2_i(ptr noundef nonnull %6, ptr noundef %45, i32 noundef 1)
  br i1 %46, label %47, label %53

47:                                               ; preds = %44
  %48 = getelementptr inbounds i8, ptr %0, i64 264
  %49 = tail call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLElementELi120EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef nonnull align 8 dereferenceable(128) %48)
  %50 = load i32, ptr %4, align 8, !tbaa !5
  %51 = getelementptr inbounds i8, ptr %49, i64 48
  store i32 %50, ptr %51, align 8, !tbaa !28
  %52 = getelementptr inbounds i8, ptr %6, i64 1
  br label %58

53:                                               ; preds = %44
  %54 = getelementptr inbounds i8, ptr %0, i64 520
  %55 = tail call noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_7XMLTextELi112EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776) %0, ptr noundef nonnull align 8 dereferenceable(128) %54)
  %56 = load i32, ptr %4, align 8, !tbaa !5
  %57 = getelementptr inbounds i8, ptr %55, i64 48
  store i32 %56, ptr %57, align 8, !tbaa !28
  store i32 %5, ptr %4, align 8, !tbaa !5
  br label %58

58:                                               ; preds = %11, %29, %47, %53, %38, %20, %3
  %storemerge = phi ptr [ null, %3 ], [ %13, %11 ], [ %22, %20 ], [ %31, %29 ], [ %40, %38 ], [ %49, %47 ], [ %55, %53 ]
  %.0 = phi ptr [ %6, %3 ], [ %16, %11 ], [ %25, %20 ], [ %34, %29 ], [ %43, %38 ], [ %52, %47 ], [ %1, %53 ]
  store ptr %storemerge, ptr %2, align 8, !tbaa !27
  ret ptr %.0
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_14XMLDeclarationELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLCommentELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_7XMLTextELi112EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) local_unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLUnknownELi104EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN8tinyxml211XMLDocument18CreateUnlinkedNodeINS_10XMLElementELi120EEEPT_RNS_8MemPoolTIXT0_EEE(ptr noundef nonnull align 8 dereferenceable(776), ptr noundef nonnull align 8 dereferenceable(128)) local_unnamed_addr #2 align 2

attributes #0 = { 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 #1 = { 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 #2 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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" }

!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, !12, i64 160}
!6 = !{!"_ZTSN8tinyxml211XMLDocumentE", !7, i64 0, !13, i64 104, !13, i64 105, !14, i64 108, !15, i64 112, !11, i64 120, !12, i64 144, !8, i64 152, !12, i64 160, !12, i64 164, !16, i64 168, !17, i64 264, !20, i64 392, !22, i64 520, !24, i64 648}
!7 = !{!"_ZTSN8tinyxml27XMLNodeE", !8, i64 8, !8, i64 16, !11, i64 24, !12, i64 48, !8, i64 56, !8, i64 64, !8, i64 72, !8, i64 80, !8, i64 88, !8, i64 96}
!8 = !{!"any pointer", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"_ZTSN8tinyxml27StrPairE", !12, i64 0, !8, i64 8, !8, i64 16}
!12 = !{!"int", !9, i64 0}
!13 = !{!"bool", !9, i64 0}
!14 = !{!"_ZTSN8tinyxml28XMLErrorE", !9, i64 0}
!15 = !{!"_ZTSN8tinyxml210WhitespaceE", !9, i64 0}
!16 = !{!"_ZTSN8tinyxml28DynArrayIPNS_7XMLNodeELi10EEE", !8, i64 0, !9, i64 8, !12, i64 88, !12, i64 92}
!17 = !{!"_ZTSN8tinyxml28MemPoolTILi120EEE", !18, i64 0, !19, i64 8, !8, i64 104, !12, i64 112, !12, i64 116, !12, i64 120, !12, i64 124}
!18 = !{!"_ZTSN8tinyxml27MemPoolE"}
!19 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi120EE5BlockELi10EEE", !8, i64 0, !9, i64 8, !12, i64 88, !12, i64 92}
!20 = !{!"_ZTSN8tinyxml28MemPoolTILi80EEE", !18, i64 0, !21, i64 8, !8, i64 104, !12, i64 112, !12, i64 116, !12, i64 120, !12, i64 124}
!21 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi80EE5BlockELi10EEE", !8, i64 0, !9, i64 8, !12, i64 88, !12, i64 92}
!22 = !{!"_ZTSN8tinyxml28MemPoolTILi112EEE", !18, i64 0, !23, i64 8, !8, i64 104, !12, i64 112, !12, i64 116, !12, i64 120, !12, i64 124}
!23 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi112EE5BlockELi10EEE", !8, i64 0, !9, i64 8, !12, i64 88, !12, i64 92}
!24 = !{!"_ZTSN8tinyxml28MemPoolTILi104EEE", !18, i64 0, !25, i64 8, !8, i64 104, !12, i64 112, !12, i64 116, !12, i64 120, !12, i64 124}
!25 = !{!"_ZTSN8tinyxml28DynArrayIPNS_8MemPoolTILi104EE5BlockELi10EEE", !8, i64 0, !9, i64 8, !12, i64 88, !12, i64 92}
!26 = !{!9, !9, i64 0}
!27 = !{!8, !8, i64 0}
!28 = !{!7, !12, i64 48}


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