; LLVM IR from erwincoumans/tiny-differentiable-simulator :: third_party/dear_imgui/imgui.ll (ZN5ImGui20DockBuilderSplitNodeEjifPjS0_)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.ImGuiDockRequest = type { i32, ptr, ptr, ptr, i32, float, i8, ptr, ptr }
%struct.ImGuiDockNode = type <{ i32, i32, i32, [4 x i8], ptr, [2 x ptr], %struct.ImVector.5, ptr, %struct.ImVec2, %struct.ImVec2, %struct.ImVec2, i32, %struct.ImGuiWindowClass, i32, [4 x i8], ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i16, i8, [5 x i8] }>
%struct.ImVector.5 = type { i32, i32, ptr }
%struct.ImVec2 = type { float, float }
%struct.ImGuiWindowClass = type <{ i32, i32, i32, i32, i32, i32, i8, i8, [2 x i8] }>

@GImGui = external dso_local global ptr, align 8
@.str.3 = external hidden unnamed_addr constant [109 x i8], align 1
@.str.204 = external hidden unnamed_addr constant [27 x i8], align 1
@__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_ = external hidden unnamed_addr constant [84 x i8], align 1
@.str.205 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.206 = external hidden unnamed_addr constant [21 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: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #1

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef float @_ZL10ImSaturatef(float noundef) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK13ImGuiDockNode11IsSplitNodeEv(ptr noundef nonnull align 8 dereferenceable(187)) #3 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN5ImGuiL22DockContextProcessDockEP12ImGuiContextP16ImGuiDockRequest(ptr noundef, ptr noundef) #4

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZN5ImGuiL23DockContextFindNodeByIDEP12ImGuiContextj(ptr noundef, i32 noundef) #4

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN5ImGui20DockBuilderSplitNodeEjifPjS0_(i32 noundef %0, i32 noundef %1, float noundef %2, ptr noundef %3, ptr noundef %4) #4 {
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca float, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca %struct.ImGuiDockRequest, align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  store i32 %0, ptr %7, align 4, !tbaa !5
  store i32 %1, ptr %8, align 4, !tbaa !5
  store float %2, ptr %9, align 4, !tbaa !9
  store ptr %3, ptr %10, align 8, !tbaa !11
  store ptr %4, ptr %11, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %18 = load ptr, ptr @GImGui, align 8, !tbaa !11
  store ptr %18, ptr %12, align 8, !tbaa !11
  %19 = load i32, ptr %8, align 4, !tbaa !5
  %20 = icmp ne i32 %19, -1
  br i1 %20, label %21, label %22

21:                                               ; preds = %5
  br label %24

22:                                               ; preds = %5
  call void @__assert_fail(ptr noundef @.str.204, ptr noundef @.str.3, i32 noundef 14484, ptr noundef @__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_) #6
  unreachable

23:                                               ; No predecessors!
  br label %24

24:                                               ; preds = %23, %21
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  %25 = load ptr, ptr %12, align 8, !tbaa !11
  %26 = load i32, ptr %7, align 4, !tbaa !5
  %27 = call noundef ptr @_ZN5ImGuiL23DockContextFindNodeByIDEP12ImGuiContextj(ptr noundef %25, i32 noundef %26)
  store ptr %27, ptr %13, align 8, !tbaa !11
  %28 = load ptr, ptr %13, align 8, !tbaa !11
  %29 = icmp eq ptr %28, null
  br i1 %29, label %30, label %37

30:                                               ; preds = %24
  %31 = load ptr, ptr %13, align 8, !tbaa !11
  %32 = icmp ne ptr %31, null
  br i1 %32, label %33, label %34

33:                                               ; preds = %30
  br label %36

34:                                               ; preds = %30
  call void @__assert_fail(ptr noundef @.str.205, ptr noundef @.str.3, i32 noundef 14490, ptr noundef @__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_) #6
  unreachable

35:                                               ; No predecessors!
  br label %36

36:                                               ; preds = %35, %33
  store i32 0, ptr %6, align 4
  store i32 1, ptr %14, align 4
  br label %113

37:                                               ; preds = %24
  %38 = load ptr, ptr %13, align 8, !tbaa !11
  %39 = call noundef zeroext i1 @_ZNK13ImGuiDockNode11IsSplitNodeEv(ptr noundef nonnull align 8 dereferenceable(187) %38)
  %40 = xor i1 %39, true
  br i1 %40, label %41, label %42

41:                                               ; preds = %37
  br label %44

42:                                               ; preds = %37
  call void @__assert_fail(ptr noundef @.str.206, ptr noundef @.str.3, i32 noundef 14494, ptr noundef @__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_) #6
  unreachable

43:                                               ; No predecessors!
  br label %44

44:                                               ; preds = %43, %41
  call void @llvm.lifetime.start.p0(i64 64, ptr %15) #5
  call void @_ZN16ImGuiDockRequestC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %15)
  %45 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 0
  store i32 3, ptr %45, align 8, !tbaa !13
  %46 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 1
  store ptr null, ptr %46, align 8, !tbaa !17
  %47 = load ptr, ptr %13, align 8, !tbaa !11
  %48 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 2
  store ptr %47, ptr %48, align 8, !tbaa !18
  %49 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 3
  store ptr null, ptr %49, align 8, !tbaa !19
  %50 = load i32, ptr %8, align 4, !tbaa !5
  %51 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 4
  store i32 %50, ptr %51, align 8, !tbaa !20
  %52 = load i32, ptr %8, align 4, !tbaa !5
  %53 = icmp eq i32 %52, 0
  br i1 %53, label %57, label %54

54:                                               ; preds = %44
  %55 = load i32, ptr %8, align 4, !tbaa !5
  %56 = icmp eq i32 %55, 2
  br i1 %56, label %57, label %59

57:                                               ; preds = %54, %44
  %58 = load float, ptr %9, align 4, !tbaa !9
  br label %62

59:                                               ; preds = %54
  %60 = load float, ptr %9, align 4, !tbaa !9
  %61 = fsub float 1.000000e+00, %60
  br label %62

62:                                               ; preds = %59, %57
  %63 = phi float [ %58, %57 ], [ %61, %59 ]
  %64 = call noundef float @_ZL10ImSaturatef(float noundef %63)
  %65 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 5
  store float %64, ptr %65, align 4, !tbaa !21
  %66 = getelementptr inbounds %struct.ImGuiDockRequest, ptr %15, i32 0, i32 6
  store i8 0, ptr %66, align 8, !tbaa !22
  %67 = load ptr, ptr %12, align 8, !tbaa !11
  call void @_ZN5ImGuiL22DockContextProcessDockEP12ImGuiContextP16ImGuiDockRequest(ptr noundef %67, ptr noundef %15)
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %68 = load ptr, ptr %13, align 8, !tbaa !11
  %69 = getelementptr inbounds %struct.ImGuiDockNode, ptr %68, i32 0, i32 5
  %70 = load i32, ptr %8, align 4, !tbaa !5
  %71 = icmp eq i32 %70, 0
  br i1 %71, label %75, label %72

72:                                               ; preds = %62
  %73 = load i32, ptr %8, align 4, !tbaa !5
  %74 = icmp eq i32 %73, 2
  br label %75

75:                                               ; preds = %72, %62
  %76 = phi i1 [ true, %62 ], [ %74, %72 ]
  %77 = zext i1 %76 to i64
  %78 = select i1 %76, i32 0, i32 1
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds [2 x ptr], ptr %69, i64 0, i64 %79
  %81 = load ptr, ptr %80, align 8, !tbaa !11
  %82 = getelementptr inbounds %struct.ImGuiDockNode, ptr %81, i32 0, i32 0
  %83 = load i32, ptr %82, align 8, !tbaa !23
  store i32 %83, ptr %16, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  %84 = load ptr, ptr %13, align 8, !tbaa !11
  %85 = getelementptr inbounds %struct.ImGuiDockNode, ptr %84, i32 0, i32 5
  %86 = load i32, ptr %8, align 4, !tbaa !5
  %87 = icmp eq i32 %86, 0
  br i1 %87, label %91, label %88

88:                                               ; preds = %75
  %89 = load i32, ptr %8, align 4, !tbaa !5
  %90 = icmp eq i32 %89, 2
  br label %91

91:                                               ; preds = %88, %75
  %92 = phi i1 [ true, %75 ], [ %90, %88 ]
  %93 = zext i1 %92 to i64
  %94 = select i1 %92, i32 1, i32 0
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds [2 x ptr], ptr %85, i64 0, i64 %95
  %97 = load ptr, ptr %96, align 8, !tbaa !11
  %98 = getelementptr inbounds %struct.ImGuiDockNode, ptr %97, i32 0, i32 0
  %99 = load i32, ptr %98, align 8, !tbaa !23
  store i32 %99, ptr %17, align 4, !tbaa !5
  %100 = load ptr, ptr %10, align 8, !tbaa !11
  %101 = icmp ne ptr %100, null
  br i1 %101, label %102, label %105

102:                                              ; preds = %91
  %103 = load i32, ptr %16, align 4, !tbaa !5
  %104 = load ptr, ptr %10, align 8, !tbaa !11
  store i32 %103, ptr %104, align 4, !tbaa !5
  br label %105

105:                                              ; preds = %102, %91
  %106 = load ptr, ptr %11, align 8, !tbaa !11
  %107 = icmp ne ptr %106, null
  br i1 %107, label %108, label %111

108:                                              ; preds = %105
  %109 = load i32, ptr %17, align 4, !tbaa !5
  %110 = load ptr, ptr %11, align 8, !tbaa !11
  store i32 %109, ptr %110, align 4, !tbaa !5
  br label %111

111:                                              ; preds = %108, %105
  %112 = load i32, ptr %16, align 4, !tbaa !5
  store i32 %112, ptr %6, align 4
  store i32 1, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 64, ptr %15) #5
  br label %113

113:                                              ; preds = %111, %36
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  %114 = load i32, ptr %6, align 4
  ret i32 %114
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { noreturn 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 #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 = { 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 = { 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 = { nounwind }
attributes #6 = { noreturn nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"any pointer", !7, i64 0}
!13 = !{!14, !15, i64 0}
!14 = !{!"_ZTS16ImGuiDockRequest", !15, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !6, i64 32, !10, i64 36, !16, i64 40, !12, i64 48, !12, i64 56}
!15 = !{!"_ZTS20ImGuiDockRequestType", !7, i64 0}
!16 = !{!"bool", !7, i64 0}
!17 = !{!14, !12, i64 8}
!18 = !{!14, !12, i64 16}
!19 = !{!14, !12, i64 24}
!20 = !{!14, !6, i64 32}
!21 = !{!14, !10, i64 36}
!22 = !{!14, !16, i64 40}
!23 = !{!24, !6, i64 0}
!24 = !{!"_ZTS13ImGuiDockNode", !6, i64 0, !6, i64 4, !6, i64 8, !12, i64 16, !7, i64 24, !25, i64 40, !12, i64 56, !26, i64 64, !26, i64 72, !26, i64 80, !27, i64 88, !28, i64 92, !29, i64 120, !12, i64 128, !12, i64 136, !12, i64 144, !12, i64 152, !6, i64 160, !6, i64 164, !6, i64 168, !6, i64 172, !6, i64 176, !6, i64 180, !6, i64 184, !6, i64 184, !6, i64 184, !16, i64 185, !16, i64 185, !16, i64 185, !16, i64 185, !16, i64 185, !16, i64 185, !16, i64 185, !16, i64 186, !16, i64 186, !16, i64 186, !16, i64 186}
!25 = !{!"_ZTS8ImVectorIP11ImGuiWindowE", !6, i64 0, !6, i64 4, !12, i64 8}
!26 = !{!"_ZTS6ImVec2", !10, i64 0, !10, i64 4}
!27 = !{!"_ZTS9ImGuiAxis", !7, i64 0}
!28 = !{!"_ZTS16ImGuiWindowClass", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12, !6, i64 16, !6, i64 20, !16, i64 24, !16, i64 25}
!29 = !{!"_ZTS18ImGuiDockNodeState", !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"

%struct.ImGuiDockRequest = type { i32, ptr, ptr, ptr, i32, float, i8, ptr, ptr }

@GImGui = external dso_local local_unnamed_addr global ptr, align 8
@.str.3 = external hidden unnamed_addr constant [109 x i8], align 1
@.str.204 = external hidden unnamed_addr constant [27 x i8], align 1
@__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_ = external hidden unnamed_addr constant [84 x i8], align 1
@.str.205 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.206 = external hidden unnamed_addr constant [21 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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef float @_ZL10ImSaturatef(float noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN5ImGuiL22DockContextProcessDockEP12ImGuiContextP16ImGuiDockRequest(ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZN5ImGuiL23DockContextFindNodeByIDEP12ImGuiContextj(ptr noundef, i32 noundef) local_unnamed_addr #4

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN5ImGui20DockBuilderSplitNodeEjifPjS0_(i32 noundef %0, i32 noundef %1, float noundef %2, ptr noundef writeonly %3, ptr noundef writeonly %4) local_unnamed_addr #4 {
  %6 = alloca %struct.ImGuiDockRequest, align 8
  %7 = load ptr, ptr @GImGui, align 8, !tbaa !5
  %.not = icmp eq i32 %1, -1
  br i1 %.not, label %8, label %9

8:                                                ; preds = %5
  tail call void @__assert_fail(ptr noundef nonnull @.str.204, ptr noundef nonnull @.str.3, i32 noundef 14484, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_) #5
  unreachable

9:                                                ; preds = %5
  %10 = tail call noundef ptr @_ZN5ImGuiL23DockContextFindNodeByIDEP12ImGuiContextj(ptr noundef %7, i32 noundef %0)
  %11 = icmp eq ptr %10, null
  br i1 %11, label %12, label %13

12:                                               ; preds = %9
  tail call void @__assert_fail(ptr noundef nonnull @.str.205, ptr noundef nonnull @.str.3, i32 noundef 14490, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_) #5
  unreachable

13:                                               ; preds = %9
  %14 = tail call noundef zeroext i1 @_ZNK13ImGuiDockNode11IsSplitNodeEv(ptr noundef nonnull align 8 dereferenceable(187) %10)
  br i1 %14, label %15, label %16

15:                                               ; preds = %13
  tail call void @__assert_fail(ptr noundef nonnull @.str.206, ptr noundef nonnull @.str.3, i32 noundef 14494, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN5ImGui20DockBuilderSplitNodeEjifPjS0_) #5
  unreachable

16:                                               ; preds = %13
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %6) #6
  call void @_ZN16ImGuiDockRequestC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %6)
  store i32 3, ptr %6, align 8, !tbaa !9
  %17 = getelementptr inbounds i8, ptr %6, i64 8
  store ptr null, ptr %17, align 8, !tbaa !15
  %18 = getelementptr inbounds i8, ptr %6, i64 16
  store ptr %10, ptr %18, align 8, !tbaa !16
  %19 = getelementptr inbounds i8, ptr %6, i64 24
  store ptr null, ptr %19, align 8, !tbaa !17
  %20 = getelementptr inbounds i8, ptr %6, i64 32
  store i32 %1, ptr %20, align 8, !tbaa !18
  %21 = and i32 %1, -3
  %or.cond = icmp ne i32 %21, 0
  %22 = fsub float 1.000000e+00, %2
  %23 = select i1 %or.cond, float %22, float %2
  %24 = call noundef float @_ZL10ImSaturatef(float noundef %23)
  %25 = getelementptr inbounds i8, ptr %6, i64 36
  store float %24, ptr %25, align 4, !tbaa !19
  %26 = getelementptr inbounds i8, ptr %6, i64 40
  store i8 0, ptr %26, align 8, !tbaa !20
  call void @_ZN5ImGuiL22DockContextProcessDockEP12ImGuiContextP16ImGuiDockRequest(ptr noundef %7, ptr noundef nonnull %6)
  %27 = getelementptr inbounds i8, ptr %10, i64 24
  %28 = zext i1 %or.cond to i64
  %29 = getelementptr inbounds [2 x ptr], ptr %27, i64 0, i64 %28
  %30 = load ptr, ptr %29, align 8, !tbaa !5
  %31 = load i32, ptr %30, align 8, !tbaa !21
  %not.or.cond = xor i1 %or.cond, true
  %32 = zext i1 %not.or.cond to i64
  %33 = getelementptr inbounds [2 x ptr], ptr %27, i64 0, i64 %32
  %34 = load ptr, ptr %33, align 8, !tbaa !5
  %35 = load i32, ptr %34, align 8, !tbaa !21
  %.not31 = icmp eq ptr %3, null
  br i1 %.not31, label %37, label %36

36:                                               ; preds = %16
  store i32 %31, ptr %3, align 4, !tbaa !28
  br label %37

37:                                               ; preds = %36, %16
  %.not32 = icmp eq ptr %4, null
  br i1 %.not32, label %39, label %38

38:                                               ; preds = %37
  store i32 %35, ptr %4, align 4, !tbaa !28
  br label %39

39:                                               ; preds = %38, %37
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %6) #6
  ret i32 %31
}

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { noreturn 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 #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 = { 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 = { 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 = { noreturn nounwind }
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, !11, i64 0}
!10 = !{!"_ZTS16ImGuiDockRequest", !11, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !12, i64 32, !13, i64 36, !14, i64 40, !6, i64 48, !6, i64 56}
!11 = !{!"_ZTS20ImGuiDockRequestType", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!"float", !7, i64 0}
!14 = !{!"bool", !7, i64 0}
!15 = !{!10, !6, i64 8}
!16 = !{!10, !6, i64 16}
!17 = !{!10, !6, i64 24}
!18 = !{!10, !12, i64 32}
!19 = !{!10, !13, i64 36}
!20 = !{!10, !14, i64 40}
!21 = !{!22, !12, i64 0}
!22 = !{!"_ZTS13ImGuiDockNode", !12, i64 0, !12, i64 4, !12, i64 8, !6, i64 16, !7, i64 24, !23, i64 40, !6, i64 56, !24, i64 64, !24, i64 72, !24, i64 80, !25, i64 88, !26, i64 92, !27, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !12, i64 160, !12, i64 164, !12, i64 168, !12, i64 172, !12, i64 176, !12, i64 180, !12, i64 184, !12, i64 184, !12, i64 184, !14, i64 185, !14, i64 185, !14, i64 185, !14, i64 185, !14, i64 185, !14, i64 185, !14, i64 185, !14, i64 186, !14, i64 186, !14, i64 186, !14, i64 186}
!23 = !{!"_ZTS8ImVectorIP11ImGuiWindowE", !12, i64 0, !12, i64 4, !6, i64 8}
!24 = !{!"_ZTS6ImVec2", !13, i64 0, !13, i64 4}
!25 = !{!"_ZTS9ImGuiAxis", !7, i64 0}
!26 = !{!"_ZTS16ImGuiWindowClass", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20, !14, i64 24, !14, i64 25}
!27 = !{!"_ZTS18ImGuiDockNodeState", !7, i64 0}
!28 = !{!12, !12, i64 0}


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