; LLVM IR from Overload-Technologies/Overload :: Dependencies/assimp/code/PostProcessing (ArmaturePopulate)

; 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.__gnu_cxx::__normal_iterator" = type { ptr }
%struct.aiNode = type { %struct.aiString, %class.aiMatrix4x4t, ptr, i32, ptr, i32, ptr, ptr }
%struct.aiString = type { i32, [1024 x i8] }
%class.aiMatrix4x4t = type { float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float }
%struct.aiScene = type { i32, ptr, i32, ptr, i32, ptr, i32, ptr, i32, ptr, i32, ptr, i32, ptr, ptr, %struct.aiString, i32, ptr, ptr }
%struct.aiMesh = type { i32, i32, i32, ptr, ptr, ptr, ptr, [8 x ptr], [8 x ptr], [8 x i32], ptr, i32, ptr, i32, %struct.aiString, i32, ptr, i32, %struct.aiAABB, ptr }
%struct.aiAABB = type { %class.aiVector3t, %class.aiVector3t }
%class.aiVector3t = type { float, float, float }

@.str.3 = external hidden unnamed_addr constant [125 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [16 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: mustprogress uwtable
define dso_local void @_ZN6Assimp16ArmaturePopulate13BuildBoneListEP6aiNodePKS1_PK7aiSceneRSt6vectorIP6aiBoneSaISA_EE(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef nonnull align 8 dereferenceable(24) %3) #1 align 2 {
  %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 i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca ptr, align 8
  %17 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %18 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %19 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %20 = alloca %"class.__gnu_cxx::__normal_iterator", 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
  store ptr %3, ptr %8, align 8, !tbaa !5
  %21 = load ptr, ptr %7, align 8, !tbaa !5
  %22 = icmp ne ptr %21, null
  br i1 %22, label %24, label %23

23:                                               ; preds = %4
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef @.str.5, ptr noundef @.str.3, i32 noundef 112)
  br label %24

24:                                               ; preds = %23, %4
  %25 = phi i1 [ true, %4 ], [ false, %23 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  store i32 0, ptr %9, align 4, !tbaa !9
  br label %26

26:                                               ; preds = %132, %24
  %27 = load i32, ptr %9, align 4, !tbaa !9
  %28 = load ptr, ptr %5, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.aiNode, ptr %28, i32 0, i32 3
  %30 = load i32, ptr %29, align 8, !tbaa !11
  %31 = icmp ult i32 %27, %30
  br i1 %31, label %33, label %32

32:                                               ; preds = %26
  store i32 2, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  br label %135

33:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %34 = load ptr, ptr %5, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.aiNode, ptr %34, i32 0, i32 4
  %36 = load ptr, ptr %35, align 8, !tbaa !16
  %37 = load i32, ptr %9, align 4, !tbaa !9
  %38 = zext i32 %37 to i64
  %39 = getelementptr inbounds ptr, ptr %36, i64 %38
  %40 = load ptr, ptr %39, align 8, !tbaa !5
  store ptr %40, ptr %11, align 8, !tbaa !5
  %41 = load ptr, ptr %11, align 8, !tbaa !5
  %42 = icmp ne ptr %41, null
  br i1 %42, label %44, label %43

43:                                               ; preds = %33
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef @.str.6, ptr noundef @.str.3, i32 noundef 115)
  br label %44

44:                                               ; preds = %43, %33
  %45 = phi i1 [ true, %33 ], [ false, %43 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  store i32 0, ptr %12, align 4, !tbaa !9
  br label %46

46:                                               ; preds = %124, %44
  %47 = load i32, ptr %12, align 4, !tbaa !9
  %48 = load ptr, ptr %11, align 8, !tbaa !5
  %49 = getelementptr inbounds %struct.aiNode, ptr %48, i32 0, i32 5
  %50 = load i32, ptr %49, align 8, !tbaa !17
  %51 = icmp ult i32 %47, %50
  br i1 %51, label %53, label %52

52:                                               ; preds = %46
  store i32 5, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  br label %127

53:                                               ; preds = %46
  %54 = load ptr, ptr %11, align 8, !tbaa !5
  %55 = getelementptr inbounds %struct.aiNode, ptr %54, i32 0, i32 6
  %56 = load ptr, ptr %55, align 8, !tbaa !18
  %57 = icmp ne ptr %56, null
  br i1 %57, label %59, label %58

58:                                               ; preds = %53
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef @.str.7, ptr noundef @.str.3, i32 noundef 119)
  br label %59

59:                                               ; preds = %58, %53
  %60 = phi i1 [ true, %53 ], [ false, %58 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  %61 = load ptr, ptr %11, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.aiNode, ptr %61, i32 0, i32 6
  %63 = load ptr, ptr %62, align 8, !tbaa !18
  %64 = load i32, ptr %12, align 4, !tbaa !9
  %65 = zext i32 %64 to i64
  %66 = getelementptr inbounds i32, ptr %63, i64 %65
  %67 = load i32, ptr %66, align 4, !tbaa !9
  store i32 %67, ptr %13, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %68 = load ptr, ptr %7, align 8, !tbaa !5
  %69 = getelementptr inbounds %struct.aiScene, ptr %68, i32 0, i32 3
  %70 = load ptr, ptr %69, align 8, !tbaa !19
  %71 = load i32, ptr %13, align 4, !tbaa !9
  %72 = zext i32 %71 to i64
  %73 = getelementptr inbounds ptr, ptr %70, i64 %72
  %74 = load ptr, ptr %73, align 8, !tbaa !5
  store ptr %74, ptr %14, align 8, !tbaa !5
  %75 = load ptr, ptr %14, align 8, !tbaa !5
  %76 = icmp ne ptr %75, null
  br i1 %76, label %78, label %77

77:                                               ; preds = %59
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef @.str.8, ptr noundef @.str.3, i32 noundef 122)
  br label %78

78:                                               ; preds = %77, %59
  %79 = phi i1 [ true, %59 ], [ false, %77 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #6
  store i32 0, ptr %15, align 4, !tbaa !9
  br label %80

80:                                               ; preds = %120, %78
  %81 = load i32, ptr %15, align 4, !tbaa !9
  %82 = load ptr, ptr %14, align 8, !tbaa !5
  %83 = getelementptr inbounds %struct.aiMesh, ptr %82, i32 0, i32 11
  %84 = load i32, ptr %83, align 8, !tbaa !21
  %85 = icmp ult i32 %81, %84
  br i1 %85, label %87, label %86

86:                                               ; preds = %80
  store i32 8, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #6
  br label %123

87:                                               ; preds = %80
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %88 = load ptr, ptr %14, align 8, !tbaa !5
  %89 = getelementptr inbounds %struct.aiMesh, ptr %88, i32 0, i32 12
  %90 = load ptr, ptr %89, align 8, !tbaa !26
  %91 = load i32, ptr %15, align 4, !tbaa !9
  %92 = zext i32 %91 to i64
  %93 = getelementptr inbounds ptr, ptr %90, i64 %92
  %94 = load ptr, ptr %93, align 8, !tbaa !5
  store ptr %94, ptr %16, align 8, !tbaa !5
  %95 = load ptr, ptr %16, align 8, !tbaa !5
  %96 = icmp ne ptr null, %95
  br i1 %96, label %98, label %97

97:                                               ; preds = %87
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef @.str.9, ptr noundef @.str.3, i32 noundef 126)
  br label %98

98:                                               ; preds = %97, %87
  %99 = phi i1 [ true, %87 ], [ false, %97 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  %100 = load ptr, ptr %8, align 8, !tbaa !5
  %101 = call ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %100) #6
  %102 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %18, i32 0, i32 0
  store ptr %101, ptr %102, align 8
  %103 = load ptr, ptr %8, align 8, !tbaa !5
  %104 = call ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %103) #6
  %105 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %19, i32 0, i32 0
  store ptr %104, ptr %105, align 8
  %106 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %18, i32 0, i32 0
  %107 = load ptr, ptr %106, align 8
  %108 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %19, i32 0, i32 0
  %109 = load ptr, ptr %108, align 8
  %110 = call ptr @_ZSt4findIN9__gnu_cxx17__normal_iteratorIPP6aiBoneSt6vectorIS3_SaIS3_EEEES3_ET_S9_S9_RKT0_(ptr %107, ptr %109, ptr noundef nonnull align 8 dereferenceable(8) %16)
  %111 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %17, i32 0, i32 0
  store ptr %110, ptr %111, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  %112 = load ptr, ptr %8, align 8, !tbaa !5
  %113 = call ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %112) #6
  %114 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %20, i32 0, i32 0
  store ptr %113, ptr %114, align 8
  %115 = call noundef zeroext i1 @_ZN9__gnu_cxxeqIPP6aiBoneSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull align 8 dereferenceable(8) %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  br i1 %115, label %116, label %119

116:                                              ; preds = %98
  %117 = load ptr, ptr %8, align 8, !tbaa !5
  %118 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE12emplace_backIJRS1_EEES5_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %117, ptr noundef nonnull align 8 dereferenceable(8) %16)
  br label %119

119:                                              ; preds = %116, %98
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %120

120:                                              ; preds = %119
  %121 = load i32, ptr %15, align 4, !tbaa !9
  %122 = add i32 %121, 1
  store i32 %122, ptr %15, align 4, !tbaa !9
  br label %80, !llvm.loop !27

123:                                              ; preds = %86
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  br label %124

124:                                              ; preds = %123
  %125 = load i32, ptr %12, align 4, !tbaa !9
  %126 = add i32 %125, 1
  store i32 %126, ptr %12, align 4, !tbaa !9
  br label %46, !llvm.loop !29

127:                                              ; preds = %52
  %128 = load ptr, ptr %11, align 8, !tbaa !5
  %129 = load ptr, ptr %6, align 8, !tbaa !5
  %130 = load ptr, ptr %7, align 8, !tbaa !5
  %131 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN6Assimp16ArmaturePopulate13BuildBoneListEP6aiNodePKS1_PK7aiSceneRSt6vectorIP6aiBoneSaISA_EE(ptr noundef %128, ptr noundef %129, ptr noundef %130, ptr noundef nonnull align 8 dereferenceable(24) %131)
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %132

132:                                              ; preds = %127
  %133 = load i32, ptr %9, align 4, !tbaa !9
  %134 = add i32 %133, 1
  store i32 %134, ptr %9, align 4, !tbaa !9
  br label %26, !llvm.loop !30

135:                                              ; preds = %32
  ret void
}

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

declare void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef, ptr noundef, i32 noundef) #2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxeqIPP6aiBoneSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #3

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local ptr @_ZSt4findIN9__gnu_cxx17__normal_iteratorIPP6aiBoneSt6vectorIS3_SaIS3_EEEES3_ET_S9_S9_RKT0_(ptr, ptr, ptr noundef nonnull align 8 dereferenceable(8)) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) #5 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) #5 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE12emplace_backIJRS1_EEES5_DpOT_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(8)) #1 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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { 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 #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 1104}
!12 = !{!"_ZTS6aiNode", !13, i64 0, !14, i64 1028, !6, i64 1096, !10, i64 1104, !6, i64 1112, !10, i64 1120, !6, i64 1128, !6, i64 1136}
!13 = !{!"_ZTS8aiString", !10, i64 0, !7, i64 4}
!14 = !{!"_ZTS12aiMatrix4x4tIfE", !15, i64 0, !15, i64 4, !15, i64 8, !15, i64 12, !15, i64 16, !15, i64 20, !15, i64 24, !15, i64 28, !15, i64 32, !15, i64 36, !15, i64 40, !15, i64 44, !15, i64 48, !15, i64 52, !15, i64 56, !15, i64 60}
!15 = !{!"float", !7, i64 0}
!16 = !{!12, !6, i64 1112}
!17 = !{!12, !10, i64 1120}
!18 = !{!12, !6, i64 1128}
!19 = !{!20, !6, i64 24}
!20 = !{!"_ZTS7aiScene", !10, i64 0, !6, i64 8, !10, i64 16, !6, i64 24, !10, i64 32, !6, i64 40, !10, i64 48, !6, i64 56, !10, i64 64, !6, i64 72, !10, i64 80, !6, i64 88, !10, i64 96, !6, i64 104, !6, i64 112, !13, i64 120, !10, i64 1148, !6, i64 1152, !6, i64 1160}
!21 = !{!22, !10, i64 216}
!22 = !{!"_ZTS6aiMesh", !10, i64 0, !10, i64 4, !10, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !7, i64 48, !7, i64 112, !7, i64 176, !6, i64 208, !10, i64 216, !6, i64 224, !10, i64 232, !13, i64 236, !10, i64 1264, !6, i64 1272, !23, i64 1280, !24, i64 1284, !6, i64 1312}
!23 = !{!"_ZTS16aiMorphingMethod", !7, i64 0}
!24 = !{!"_ZTS6aiAABB", !25, i64 0, !25, i64 12}
!25 = !{!"_ZTS10aiVector3tIfE", !15, i64 0, !15, i64 4, !15, i64 8}
!26 = !{!22, !6, i64 224}
!27 = distinct !{!27, !28}
!28 = !{!"llvm.loop.mustprogress"}
!29 = distinct !{!29, !28}
!30 = distinct !{!30, !28}


; 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.__gnu_cxx::__normal_iterator" = type { ptr }

@.str.3 = external hidden unnamed_addr constant [125 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [16 x i8], align 1

; 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 uwtable
define dso_local void @_ZN6Assimp16ArmaturePopulate13BuildBoneListEP6aiNodePKS1_PK7aiSceneRSt6vectorIP6aiBoneSaISA_EE(ptr nocapture noundef readonly %0, ptr nocapture noundef readnone %1, ptr noundef %2, ptr noundef nonnull align 8 dereferenceable(24) %3) local_unnamed_addr #1 align 2 {
  %5 = alloca ptr, align 8
  %6 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %7 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %.not = icmp eq ptr %2, null
  br i1 %.not, label %8, label %9

8:                                                ; preds = %4
  tail call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.3, i32 noundef 112)
  br label %9

9:                                                ; preds = %8, %4
  %10 = getelementptr inbounds i8, ptr %0, i64 1104
  %11 = load i32, ptr %10, align 8, !tbaa !5
  %.not44 = icmp eq i32 %11, 0
  br i1 %.not44, label %._crit_edge43, label %.lr.ph42

.lr.ph42:                                         ; preds = %9
  %12 = getelementptr inbounds i8, ptr %0, i64 1112
  %13 = getelementptr inbounds i8, ptr %2, i64 24
  br label %14

._crit_edge43:                                    ; preds = %._crit_edge39, %9
  ret void

14:                                               ; preds = %.lr.ph42, %._crit_edge39
  %indvars.iv51 = phi i64 [ 0, %.lr.ph42 ], [ %indvars.iv.next52, %._crit_edge39 ]
  %15 = load ptr, ptr %12, align 8, !tbaa !14
  %16 = getelementptr inbounds ptr, ptr %15, i64 %indvars.iv51
  %17 = load ptr, ptr %16, align 8, !tbaa !15
  %.not31 = icmp eq ptr %17, null
  br i1 %.not31, label %18, label %19

18:                                               ; preds = %14
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef nonnull @.str.6, ptr noundef nonnull @.str.3, i32 noundef 115)
  br label %19

19:                                               ; preds = %18, %14
  %20 = getelementptr inbounds i8, ptr %17, i64 1120
  %21 = load i32, ptr %20, align 8, !tbaa !16
  %.not45 = icmp eq i32 %21, 0
  br i1 %.not45, label %._crit_edge39, label %.lr.ph38

.lr.ph38:                                         ; preds = %19
  %22 = getelementptr inbounds i8, ptr %17, i64 1128
  br label %26

._crit_edge39:                                    ; preds = %._crit_edge, %19
  call void @_ZN6Assimp16ArmaturePopulate13BuildBoneListEP6aiNodePKS1_PK7aiSceneRSt6vectorIP6aiBoneSaISA_EE(ptr noundef nonnull %17, ptr noundef %1, ptr noundef %2, ptr noundef nonnull align 8 dereferenceable(24) %3)
  %indvars.iv.next52 = add nuw nsw i64 %indvars.iv51, 1
  %23 = load i32, ptr %10, align 8, !tbaa !5
  %24 = zext i32 %23 to i64
  %25 = icmp ult i64 %indvars.iv.next52, %24
  br i1 %25, label %14, label %._crit_edge43, !llvm.loop !17

26:                                               ; preds = %.lr.ph38, %._crit_edge
  %indvars.iv48 = phi i64 [ 0, %.lr.ph38 ], [ %indvars.iv.next49, %._crit_edge ]
  %27 = load ptr, ptr %22, align 8, !tbaa !19
  %.not32 = icmp eq ptr %27, null
  br i1 %.not32, label %28, label %29

28:                                               ; preds = %26
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef nonnull @.str.7, ptr noundef nonnull @.str.3, i32 noundef 119)
  %.pre = load ptr, ptr %22, align 8, !tbaa !19
  br label %29

29:                                               ; preds = %28, %26
  %30 = phi ptr [ %.pre, %28 ], [ %27, %26 ]
  %31 = getelementptr inbounds i32, ptr %30, i64 %indvars.iv48
  %32 = load i32, ptr %31, align 4, !tbaa !20
  %33 = load ptr, ptr %13, align 8, !tbaa !21
  %34 = zext i32 %32 to i64
  %35 = getelementptr inbounds ptr, ptr %33, i64 %34
  %36 = load ptr, ptr %35, align 8, !tbaa !15
  %.not33 = icmp eq ptr %36, null
  br i1 %.not33, label %37, label %38

37:                                               ; preds = %29
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef nonnull @.str.8, ptr noundef nonnull @.str.3, i32 noundef 122)
  br label %38

38:                                               ; preds = %37, %29
  %39 = getelementptr inbounds i8, ptr %36, i64 216
  %40 = load i32, ptr %39, align 8, !tbaa !23
  %.not46 = icmp eq i32 %40, 0
  br i1 %.not46, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %38
  %41 = getelementptr inbounds i8, ptr %36, i64 224
  br label %45

._crit_edge:                                      ; preds = %58, %38
  %indvars.iv.next49 = add nuw nsw i64 %indvars.iv48, 1
  %42 = load i32, ptr %20, align 8, !tbaa !16
  %43 = zext i32 %42 to i64
  %44 = icmp ult i64 %indvars.iv.next49, %43
  br i1 %44, label %26, label %._crit_edge39, !llvm.loop !28

45:                                               ; preds = %.lr.ph, %58
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %58 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #6
  %46 = load ptr, ptr %41, align 8, !tbaa !29
  %47 = getelementptr inbounds ptr, ptr %46, i64 %indvars.iv
  %48 = load ptr, ptr %47, align 8, !tbaa !15
  store ptr %48, ptr %5, align 8, !tbaa !15
  %.not34 = icmp eq ptr %48, null
  br i1 %.not34, label %49, label %50

49:                                               ; preds = %45
  call void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef nonnull @.str.9, ptr noundef nonnull @.str.3, i32 noundef 126)
  br label %50

50:                                               ; preds = %49, %45
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #6
  %51 = call ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #6
  %52 = call ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #6
  %53 = call ptr @_ZSt4findIN9__gnu_cxx17__normal_iteratorIPP6aiBoneSt6vectorIS3_SaIS3_EEEES3_ET_S9_S9_RKT0_(ptr %51, ptr %52, ptr noundef nonnull align 8 dereferenceable(8) %5)
  store ptr %53, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #6
  %54 = call ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #6
  store ptr %54, ptr %7, align 8
  %55 = call noundef zeroext i1 @_ZN9__gnu_cxxeqIPP6aiBoneSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  br i1 %55, label %56, label %58

56:                                               ; preds = %50
  %57 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE12emplace_backIJRS1_EEES5_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 8 dereferenceable(8) %5)
  br label %58

58:                                               ; preds = %56, %50
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %59 = load i32, ptr %39, align 8, !tbaa !23
  %60 = zext i32 %59 to i64
  %61 = icmp ult i64 %indvars.iv.next, %60
  br i1 %61, label %45, label %._crit_edge, !llvm.loop !30
}

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

declare void @_ZN6Assimp17aiAssertViolationEPKcS1_i(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local ptr @_ZSt4findIN9__gnu_cxx17__normal_iteratorIPP6aiBoneSt6vectorIS3_SaIS3_EEEES3_ET_S9_S9_RKT0_(ptr, ptr, ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #5 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorIP6aiBoneSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #5 align 2

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

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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { 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 #6 = { 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, !8, i64 1104}
!6 = !{!"_ZTS6aiNode", !7, i64 0, !11, i64 1028, !13, i64 1096, !8, i64 1104, !13, i64 1112, !8, i64 1120, !13, i64 1128, !13, i64 1136}
!7 = !{!"_ZTS8aiString", !8, i64 0, !9, i64 4}
!8 = !{!"int", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"_ZTS12aiMatrix4x4tIfE", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !12, i64 40, !12, i64 44, !12, i64 48, !12, i64 52, !12, i64 56, !12, i64 60}
!12 = !{!"float", !9, i64 0}
!13 = !{!"any pointer", !9, i64 0}
!14 = !{!6, !13, i64 1112}
!15 = !{!13, !13, i64 0}
!16 = !{!6, !8, i64 1120}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = !{!6, !13, i64 1128}
!20 = !{!8, !8, i64 0}
!21 = !{!22, !13, i64 24}
!22 = !{!"_ZTS7aiScene", !8, i64 0, !13, i64 8, !8, i64 16, !13, i64 24, !8, i64 32, !13, i64 40, !8, i64 48, !13, i64 56, !8, i64 64, !13, i64 72, !8, i64 80, !13, i64 88, !8, i64 96, !13, i64 104, !13, i64 112, !7, i64 120, !8, i64 1148, !13, i64 1152, !13, i64 1160}
!23 = !{!24, !8, i64 216}
!24 = !{!"_ZTS6aiMesh", !8, i64 0, !8, i64 4, !8, i64 8, !13, i64 16, !13, i64 24, !13, i64 32, !13, i64 40, !9, i64 48, !9, i64 112, !9, i64 176, !13, i64 208, !8, i64 216, !13, i64 224, !8, i64 232, !7, i64 236, !8, i64 1264, !13, i64 1272, !25, i64 1280, !26, i64 1284, !13, i64 1312}
!25 = !{!"_ZTS16aiMorphingMethod", !9, i64 0}
!26 = !{!"_ZTS6aiAABB", !27, i64 0, !27, i64 12}
!27 = !{!"_ZTS10aiVector3tIfE", !12, i64 0, !12, i64 4, !12, i64 8}
!28 = distinct !{!28, !18}
!29 = !{!24, !13, i64 224}
!30 = distinct !{!30, !18}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass