; LLVM IR from Devaniti/BoolkaEngine :: ThirdParty/imgui/backends (imgui_impl_vulkan)

; 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.ImGui_ImplVulkan_InitInfo = type { ptr, ptr, ptr, i32, ptr, ptr, ptr, i32, i32, i32, i32, ptr, ptr }
%struct.ImGui_ImplVulkanH_WindowRenderBuffers = type { i32, i32, ptr }
%struct.VkMappedMemoryRange = type { i32, ptr, ptr, i64, i64 }
%struct.ImVec2 = type { float, float }
%struct.ImVec4 = type { float, float, float, float }
%struct.VkRect2D = type { %struct.VkOffset2D, %struct.VkExtent2D }
%struct.VkOffset2D = type { i32, i32 }
%struct.VkExtent2D = type { i32, i32 }
%struct.ImDrawData = type <{ i8, [7 x i8], ptr, i32, i32, i32, %struct.ImVec2, %struct.ImVec2, %struct.ImVec2, [4 x i8] }>
%struct.ImGui_ImplVulkanH_FrameRenderBuffers = type { ptr, ptr, i64, i64, ptr, ptr }
%struct.ImDrawList = type <{ %struct.ImVector, %struct.ImVector.0, %struct.ImVector.1, i32, i32, ptr, ptr, ptr, ptr, %struct.ImVector.2, %struct.ImVector.3, %struct.ImVector.4, %struct.ImDrawCmdHeader, %struct.ImDrawListSplitter, float, [4 x i8] }>
%struct.ImVector = type { i32, i32, ptr }
%struct.ImVector.0 = type { i32, i32, ptr }
%struct.ImVector.1 = type { i32, i32, ptr }
%struct.ImVector.2 = type { i32, i32, ptr }
%struct.ImVector.3 = type { i32, i32, ptr }
%struct.ImVector.4 = type { i32, i32, ptr }
%struct.ImDrawCmdHeader = type <{ %struct.ImVec4, ptr, i32, [4 x i8] }>
%struct.ImDrawListSplitter = type { i32, i32, %struct.ImVector.5 }
%struct.ImVector.5 = type { i32, i32, ptr }
%struct.ImDrawVert = type { %struct.ImVec2, %struct.ImVec2, i32 }
%struct.ImDrawCmd = type { %struct.ImVec4, ptr, i32, i32, i32, ptr, ptr }

@_ZL16g_VulkanInitInfo = external hidden global %struct.ImGui_ImplVulkan_InitInfo, align 8
@_ZL10g_Pipeline = external hidden global ptr, align 8
@_ZL25g_MainWindowRenderBuffers = external hidden global %struct.ImGui_ImplVulkanH_WindowRenderBuffers, align 8
@.str = external hidden unnamed_addr constant [28 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [103 x i8], align 1
@__PRETTY_FUNCTION__._Z31ImGui_ImplVulkan_RenderDrawDataP10ImDrawDataP17VkCommandBuffer_TP12VkPipeline_T = external hidden unnamed_addr constant [80 x i8], align 1

; Function Attrs: mustprogress uwtable
define dso_local void @_Z31ImGui_ImplVulkan_RenderDrawDataP10ImDrawDataP17VkCommandBuffer_TP12VkPipeline_T(ptr noundef %0, ptr noundef %1, ptr noundef %2) #0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca ptr, align 8
  %20 = alloca [2 x %struct.VkMappedMemoryRange], align 16
  %21 = alloca %struct.ImVec2, align 4
  %22 = alloca %struct.ImVec2, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca ptr, align 8
  %27 = alloca i32, align 4
  %28 = alloca ptr, align 8
  %29 = alloca %struct.ImVec4, align 4
  %30 = alloca %struct.VkRect2D, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  %31 = load ptr, ptr %4, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct.ImDrawData, ptr %31, i32 0, i32 7
  %33 = getelementptr inbounds %struct.ImVec2, ptr %32, i32 0, i32 0
  %34 = load float, ptr %33, align 4, !tbaa !9
  %35 = load ptr, ptr %4, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct.ImDrawData, ptr %35, i32 0, i32 8
  %37 = getelementptr inbounds %struct.ImVec2, ptr %36, i32 0, i32 0
  %38 = load float, ptr %37, align 4, !tbaa !15
  %39 = fmul float %34, %38
  %40 = fptosi float %39 to i32
  store i32 %40, ptr %7, align 4, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #8
  %41 = load ptr, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.ImDrawData, ptr %41, i32 0, i32 7
  %43 = getelementptr inbounds %struct.ImVec2, ptr %42, i32 0, i32 1
  %44 = load float, ptr %43, align 4, !tbaa !17
  %45 = load ptr, ptr %4, align 8, !tbaa !5
  %46 = getelementptr inbounds %struct.ImDrawData, ptr %45, i32 0, i32 8
  %47 = getelementptr inbounds %struct.ImVec2, ptr %46, i32 0, i32 1
  %48 = load float, ptr %47, align 4, !tbaa !18
  %49 = fmul float %44, %48
  %50 = fptosi float %49 to i32
  store i32 %50, ptr %8, align 4, !tbaa !16
  %51 = load i32, ptr %7, align 4, !tbaa !16
  %52 = icmp sle i32 %51, 0
  br i1 %52, label %56, label %53

53:                                               ; preds = %3
  %54 = load i32, ptr %8, align 4, !tbaa !16
  %55 = icmp sle i32 %54, 0
  br i1 %55, label %56, label %57

56:                                               ; preds = %53, %3
  store i32 1, ptr %9, align 4
  br label %485

57:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #8
  store ptr @_ZL16g_VulkanInitInfo, ptr %10, align 8, !tbaa !5
  %58 = load ptr, ptr %6, align 8, !tbaa !5
  %59 = icmp eq ptr %58, null
  br i1 %59, label %60, label %62

60:                                               ; preds = %57
  %61 = load ptr, ptr @_ZL10g_Pipeline, align 8, !tbaa !5
  store ptr %61, ptr %6, align 8, !tbaa !5
  br label %62

62:                                               ; preds = %60, %57
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #8
  store ptr @_ZL25g_MainWindowRenderBuffers, ptr %11, align 8, !tbaa !5
  %63 = load ptr, ptr %11, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %63, i32 0, i32 2
  %65 = load ptr, ptr %64, align 8, !tbaa !19
  %66 = icmp eq ptr %65, null
  br i1 %66, label %67, label %91

67:                                               ; preds = %62
  %68 = load ptr, ptr %11, align 8, !tbaa !5
  %69 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %68, i32 0, i32 0
  store i32 0, ptr %69, align 8, !tbaa !21
  %70 = load ptr, ptr %10, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %70, i32 0, i32 9
  %72 = load i32, ptr %71, align 8, !tbaa !22
  %73 = load ptr, ptr %11, align 8, !tbaa !5
  %74 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %73, i32 0, i32 1
  store i32 %72, ptr %74, align 4, !tbaa !25
  %75 = load ptr, ptr %11, align 8, !tbaa !5
  %76 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %75, i32 0, i32 1
  %77 = load i32, ptr %76, align 4, !tbaa !25
  %78 = zext i32 %77 to i64
  %79 = mul i64 48, %78
  %80 = call noundef ptr @_ZN5ImGui8MemAllocEm(i64 noundef %79)
  %81 = load ptr, ptr %11, align 8, !tbaa !5
  %82 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %81, i32 0, i32 2
  store ptr %80, ptr %82, align 8, !tbaa !19
  %83 = load ptr, ptr %11, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %83, i32 0, i32 2
  %85 = load ptr, ptr %84, align 8, !tbaa !19
  %86 = load ptr, ptr %11, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %86, i32 0, i32 1
  %88 = load i32, ptr %87, align 4, !tbaa !25
  %89 = zext i32 %88 to i64
  %90 = mul i64 48, %89
  call void @llvm.memset.p0.i64(ptr align 8 %85, i8 0, i64 %90, i1 false)
  br label %91

91:                                               ; preds = %67, %62
  %92 = load ptr, ptr %11, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %92, i32 0, i32 1
  %94 = load i32, ptr %93, align 4, !tbaa !25
  %95 = load ptr, ptr %10, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %95, i32 0, i32 9
  %97 = load i32, ptr %96, align 8, !tbaa !22
  %98 = icmp eq i32 %94, %97
  br i1 %98, label %99, label %100

99:                                               ; preds = %91
  br label %102

100:                                              ; preds = %91
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 340, ptr noundef @__PRETTY_FUNCTION__._Z31ImGui_ImplVulkan_RenderDrawDataP10ImDrawDataP17VkCommandBuffer_TP12VkPipeline_T) #9
  unreachable

101:                                              ; No predecessors!
  br label %102

102:                                              ; preds = %101, %99
  %103 = load ptr, ptr %11, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %103, i32 0, i32 0
  %105 = load i32, ptr %104, align 8, !tbaa !21
  %106 = add i32 %105, 1
  %107 = load ptr, ptr %11, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %107, i32 0, i32 1
  %109 = load i32, ptr %108, align 4, !tbaa !25
  %110 = urem i32 %106, %109
  %111 = load ptr, ptr %11, align 8, !tbaa !5
  %112 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %111, i32 0, i32 0
  store i32 %110, ptr %112, align 8, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #8
  %113 = load ptr, ptr %11, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %113, i32 0, i32 2
  %115 = load ptr, ptr %114, align 8, !tbaa !19
  %116 = load ptr, ptr %11, align 8, !tbaa !5
  %117 = getelementptr inbounds %struct.ImGui_ImplVulkanH_WindowRenderBuffers, ptr %116, i32 0, i32 0
  %118 = load i32, ptr %117, align 8, !tbaa !21
  %119 = zext i32 %118 to i64
  %120 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %115, i64 %119
  store ptr %120, ptr %12, align 8, !tbaa !5
  %121 = load ptr, ptr %4, align 8, !tbaa !5
  %122 = getelementptr inbounds %struct.ImDrawData, ptr %121, i32 0, i32 5
  %123 = load i32, ptr %122, align 8, !tbaa !26
  %124 = icmp sgt i32 %123, 0
  br i1 %124, label %125, label %283

125:                                              ; preds = %102
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #8
  %126 = load ptr, ptr %4, align 8, !tbaa !5
  %127 = getelementptr inbounds %struct.ImDrawData, ptr %126, i32 0, i32 5
  %128 = load i32, ptr %127, align 8, !tbaa !26
  %129 = sext i32 %128 to i64
  %130 = mul i64 %129, 20
  store i64 %130, ptr %13, align 8, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  %131 = load ptr, ptr %4, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct.ImDrawData, ptr %131, i32 0, i32 4
  %133 = load i32, ptr %132, align 4, !tbaa !29
  %134 = sext i32 %133 to i64
  %135 = mul i64 %134, 2
  store i64 %135, ptr %14, align 8, !tbaa !27
  %136 = load ptr, ptr %12, align 8, !tbaa !5
  %137 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %136, i32 0, i32 4
  %138 = load ptr, ptr %137, align 8, !tbaa !30
  %139 = icmp eq ptr %138, null
  br i1 %139, label %146, label %140

140:                                              ; preds = %125
  %141 = load ptr, ptr %12, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %141, i32 0, i32 2
  %143 = load i64, ptr %142, align 8, !tbaa !32
  %144 = load i64, ptr %13, align 8, !tbaa !27
  %145 = icmp ult i64 %143, %144
  br i1 %145, label %146, label %154

146:                                              ; preds = %140, %125
  %147 = load ptr, ptr %12, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %147, i32 0, i32 4
  %149 = load ptr, ptr %12, align 8, !tbaa !5
  %150 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %149, i32 0, i32 0
  %151 = load ptr, ptr %12, align 8, !tbaa !5
  %152 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %151, i32 0, i32 2
  %153 = load i64, ptr %13, align 8, !tbaa !27
  call void @_ZL20CreateOrResizeBufferRP10VkBuffer_TRP16VkDeviceMemory_TRmm21VkBufferUsageFlagBits(ptr noundef nonnull align 8 dereferenceable(8) %148, ptr noundef nonnull align 8 dereferenceable(8) %150, ptr noundef nonnull align 8 dereferenceable(8) %152, i64 noundef %153, i32 noundef 128)
  br label %154

154:                                              ; preds = %146, %140
  %155 = load ptr, ptr %12, align 8, !tbaa !5
  %156 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %155, i32 0, i32 5
  %157 = load ptr, ptr %156, align 8, !tbaa !33
  %158 = icmp eq ptr %157, null
  br i1 %158, label %165, label %159

159:                                              ; preds = %154
  %160 = load ptr, ptr %12, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %160, i32 0, i32 3
  %162 = load i64, ptr %161, align 8, !tbaa !34
  %163 = load i64, ptr %14, align 8, !tbaa !27
  %164 = icmp ult i64 %162, %163
  br i1 %164, label %165, label %173

165:                                              ; preds = %159, %154
  %166 = load ptr, ptr %12, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %166, i32 0, i32 5
  %168 = load ptr, ptr %12, align 8, !tbaa !5
  %169 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %168, i32 0, i32 1
  %170 = load ptr, ptr %12, align 8, !tbaa !5
  %171 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %170, i32 0, i32 3
  %172 = load i64, ptr %14, align 8, !tbaa !27
  call void @_ZL20CreateOrResizeBufferRP10VkBuffer_TRP16VkDeviceMemory_TRmm21VkBufferUsageFlagBits(ptr noundef nonnull align 8 dereferenceable(8) %167, ptr noundef nonnull align 8 dereferenceable(8) %169, ptr noundef nonnull align 8 dereferenceable(8) %171, i64 noundef %172, i32 noundef 64)
  br label %173

173:                                              ; preds = %165, %159
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #8
  store ptr null, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #8
  store ptr null, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #8
  %174 = load ptr, ptr %10, align 8, !tbaa !5
  %175 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %174, i32 0, i32 2
  %176 = load ptr, ptr %175, align 8, !tbaa !35
  %177 = load ptr, ptr %12, align 8, !tbaa !5
  %178 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %177, i32 0, i32 0
  %179 = load ptr, ptr %178, align 8, !tbaa !36
  %180 = load i64, ptr %13, align 8, !tbaa !27
  %181 = call i32 @vkMapMemory(ptr noundef %176, ptr noundef %179, i64 noundef 0, i64 noundef %180, i32 noundef 0, ptr noundef %15)
  store i32 %181, ptr %17, align 4, !tbaa !37
  %182 = load i32, ptr %17, align 4, !tbaa !37
  call void @_ZL15check_vk_result8VkResult(i32 noundef %182)
  %183 = load ptr, ptr %10, align 8, !tbaa !5
  %184 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %183, i32 0, i32 2
  %185 = load ptr, ptr %184, align 8, !tbaa !35
  %186 = load ptr, ptr %12, align 8, !tbaa !5
  %187 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %186, i32 0, i32 1
  %188 = load ptr, ptr %187, align 8, !tbaa !39
  %189 = load i64, ptr %14, align 8, !tbaa !27
  %190 = call i32 @vkMapMemory(ptr noundef %185, ptr noundef %188, i64 noundef 0, i64 noundef %189, i32 noundef 0, ptr noundef %16)
  store i32 %190, ptr %17, align 4, !tbaa !37
  %191 = load i32, ptr %17, align 4, !tbaa !37
  call void @_ZL15check_vk_result8VkResult(i32 noundef %191)
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #8
  store i32 0, ptr %18, align 4, !tbaa !16
  br label %192

192:                                              ; preds = %243, %173
  %193 = load i32, ptr %18, align 4, !tbaa !16
  %194 = load ptr, ptr %4, align 8, !tbaa !5
  %195 = getelementptr inbounds %struct.ImDrawData, ptr %194, i32 0, i32 3
  %196 = load i32, ptr %195, align 8, !tbaa !40
  %197 = icmp slt i32 %193, %196
  br i1 %197, label %199, label %198

198:                                              ; preds = %192
  store i32 2, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  br label %246

199:                                              ; preds = %192
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #8
  %200 = load ptr, ptr %4, align 8, !tbaa !5
  %201 = getelementptr inbounds %struct.ImDrawData, ptr %200, i32 0, i32 2
  %202 = load ptr, ptr %201, align 8, !tbaa !41
  %203 = load i32, ptr %18, align 4, !tbaa !16
  %204 = sext i32 %203 to i64
  %205 = getelementptr inbounds ptr, ptr %202, i64 %204
  %206 = load ptr, ptr %205, align 8, !tbaa !5
  store ptr %206, ptr %19, align 8, !tbaa !5
  %207 = load ptr, ptr %15, align 8, !tbaa !5
  %208 = load ptr, ptr %19, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.ImDrawList, ptr %208, i32 0, i32 2
  %210 = getelementptr inbounds %struct.ImVector.1, ptr %209, i32 0, i32 2
  %211 = load ptr, ptr %210, align 8, !tbaa !42
  %212 = load ptr, ptr %19, align 8, !tbaa !5
  %213 = getelementptr inbounds %struct.ImDrawList, ptr %212, i32 0, i32 2
  %214 = getelementptr inbounds %struct.ImVector.1, ptr %213, i32 0, i32 0
  %215 = load i32, ptr %214, align 8, !tbaa !54
  %216 = sext i32 %215 to i64
  %217 = mul i64 %216, 20
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %207, ptr align 4 %211, i64 %217, i1 false)
  %218 = load ptr, ptr %16, align 8, !tbaa !5
  %219 = load ptr, ptr %19, align 8, !tbaa !5
  %220 = getelementptr inbounds %struct.ImDrawList, ptr %219, i32 0, i32 1
  %221 = getelementptr inbounds %struct.ImVector.0, ptr %220, i32 0, i32 2
  %222 = load ptr, ptr %221, align 8, !tbaa !55
  %223 = load ptr, ptr %19, align 8, !tbaa !5
  %224 = getelementptr inbounds %struct.ImDrawList, ptr %223, i32 0, i32 1
  %225 = getelementptr inbounds %struct.ImVector.0, ptr %224, i32 0, i32 0
  %226 = load i32, ptr %225, align 8, !tbaa !56
  %227 = sext i32 %226 to i64
  %228 = mul i64 %227, 2
  call void @llvm.memcpy.p0.p0.i64(ptr align 2 %218, ptr align 2 %222, i64 %228, i1 false)
  %229 = load ptr, ptr %19, align 8, !tbaa !5
  %230 = getelementptr inbounds %struct.ImDrawList, ptr %229, i32 0, i32 2
  %231 = getelementptr inbounds %struct.ImVector.1, ptr %230, i32 0, i32 0
  %232 = load i32, ptr %231, align 8, !tbaa !54
  %233 = load ptr, ptr %15, align 8, !tbaa !5
  %234 = sext i32 %232 to i64
  %235 = getelementptr inbounds %struct.ImDrawVert, ptr %233, i64 %234
  store ptr %235, ptr %15, align 8, !tbaa !5
  %236 = load ptr, ptr %19, align 8, !tbaa !5
  %237 = getelementptr inbounds %struct.ImDrawList, ptr %236, i32 0, i32 1
  %238 = getelementptr inbounds %struct.ImVector.0, ptr %237, i32 0, i32 0
  %239 = load i32, ptr %238, align 8, !tbaa !56
  %240 = load ptr, ptr %16, align 8, !tbaa !5
  %241 = sext i32 %239 to i64
  %242 = getelementptr inbounds i16, ptr %240, i64 %241
  store ptr %242, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  br label %243

243:                                              ; preds = %199
  %244 = load i32, ptr %18, align 4, !tbaa !16
  %245 = add nsw i32 %244, 1
  store i32 %245, ptr %18, align 4, !tbaa !16
  br label %192, !llvm.loop !57

246:                                              ; preds = %198
  call void @llvm.lifetime.start.p0(i64 80, ptr %20) #8
  call void @llvm.memset.p0.i64(ptr align 16 %20, i8 0, i64 80, i1 false)
  %247 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 0
  %248 = getelementptr inbounds %struct.VkMappedMemoryRange, ptr %247, i32 0, i32 0
  store i32 6, ptr %248, align 16, !tbaa !59
  %249 = load ptr, ptr %12, align 8, !tbaa !5
  %250 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %249, i32 0, i32 0
  %251 = load ptr, ptr %250, align 8, !tbaa !36
  %252 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 0
  %253 = getelementptr inbounds %struct.VkMappedMemoryRange, ptr %252, i32 0, i32 2
  store ptr %251, ptr %253, align 16, !tbaa !62
  %254 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 0
  %255 = getelementptr inbounds %struct.VkMappedMemoryRange, ptr %254, i32 0, i32 4
  store i64 -1, ptr %255, align 16, !tbaa !63
  %256 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 1
  %257 = getelementptr inbounds %struct.VkMappedMemoryRange, ptr %256, i32 0, i32 0
  store i32 6, ptr %257, align 8, !tbaa !59
  %258 = load ptr, ptr %12, align 8, !tbaa !5
  %259 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %258, i32 0, i32 1
  %260 = load ptr, ptr %259, align 8, !tbaa !39
  %261 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 1
  %262 = getelementptr inbounds %struct.VkMappedMemoryRange, ptr %261, i32 0, i32 2
  store ptr %260, ptr %262, align 8, !tbaa !62
  %263 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 1
  %264 = getelementptr inbounds %struct.VkMappedMemoryRange, ptr %263, i32 0, i32 4
  store i64 -1, ptr %264, align 8, !tbaa !63
  %265 = load ptr, ptr %10, align 8, !tbaa !5
  %266 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %265, i32 0, i32 2
  %267 = load ptr, ptr %266, align 8, !tbaa !35
  %268 = getelementptr inbounds [2 x %struct.VkMappedMemoryRange], ptr %20, i64 0, i64 0
  %269 = call i32 @vkFlushMappedMemoryRanges(ptr noundef %267, i32 noundef 2, ptr noundef %268)
  store i32 %269, ptr %17, align 4, !tbaa !37
  %270 = load i32, ptr %17, align 4, !tbaa !37
  call void @_ZL15check_vk_result8VkResult(i32 noundef %270)
  %271 = load ptr, ptr %10, align 8, !tbaa !5
  %272 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %271, i32 0, i32 2
  %273 = load ptr, ptr %272, align 8, !tbaa !35
  %274 = load ptr, ptr %12, align 8, !tbaa !5
  %275 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %274, i32 0, i32 0
  %276 = load ptr, ptr %275, align 8, !tbaa !36
  call void @vkUnmapMemory(ptr noundef %273, ptr noundef %276)
  %277 = load ptr, ptr %10, align 8, !tbaa !5
  %278 = getelementptr inbounds %struct.ImGui_ImplVulkan_InitInfo, ptr %277, i32 0, i32 2
  %279 = load ptr, ptr %278, align 8, !tbaa !35
  %280 = load ptr, ptr %12, align 8, !tbaa !5
  %281 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %280, i32 0, i32 1
  %282 = load ptr, ptr %281, align 8, !tbaa !39
  call void @vkUnmapMemory(ptr noundef %279, ptr noundef %282)
  call void @llvm.lifetime.end.p0(i64 80, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  br label %283

283:                                              ; preds = %246, %102
  %284 = load ptr, ptr %4, align 8, !tbaa !5
  %285 = load ptr, ptr %6, align 8, !tbaa !5
  %286 = load ptr, ptr %5, align 8, !tbaa !5
  %287 = load ptr, ptr %12, align 8, !tbaa !5
  %288 = load i32, ptr %7, align 4, !tbaa !16
  %289 = load i32, ptr %8, align 4, !tbaa !16
  call void @_ZL33ImGui_ImplVulkan_SetupRenderStateP10ImDrawDataP12VkPipeline_TP17VkCommandBuffer_TP36ImGui_ImplVulkanH_FrameRenderBuffersii(ptr noundef %284, ptr noundef %285, ptr noundef %286, ptr noundef %287, i32 noundef %288, i32 noundef %289)
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #8
  %290 = load ptr, ptr %4, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct.ImDrawData, ptr %290, i32 0, i32 6
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %21, ptr align 4 %291, i64 8, i1 false), !tbaa.struct !64
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #8
  %292 = load ptr, ptr %4, align 8, !tbaa !5
  %293 = getelementptr inbounds %struct.ImDrawData, ptr %292, i32 0, i32 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %22, ptr align 4 %293, i64 8, i1 false), !tbaa.struct !64
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #8
  store i32 0, ptr %23, align 4, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #8
  store i32 0, ptr %24, align 4, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #8
  store i32 0, ptr %25, align 4, !tbaa !16
  br label %294

294:                                              ; preds = %481, %283
  %295 = load i32, ptr %25, align 4, !tbaa !16
  %296 = load ptr, ptr %4, align 8, !tbaa !5
  %297 = getelementptr inbounds %struct.ImDrawData, ptr %296, i32 0, i32 3
  %298 = load i32, ptr %297, align 8, !tbaa !40
  %299 = icmp slt i32 %295, %298
  br i1 %299, label %301, label %300

300:                                              ; preds = %294
  store i32 5, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #8
  br label %484

301:                                              ; preds = %294
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #8
  %302 = load ptr, ptr %4, align 8, !tbaa !5
  %303 = getelementptr inbounds %struct.ImDrawData, ptr %302, i32 0, i32 2
  %304 = load ptr, ptr %303, align 8, !tbaa !41
  %305 = load i32, ptr %25, align 4, !tbaa !16
  %306 = sext i32 %305 to i64
  %307 = getelementptr inbounds ptr, ptr %304, i64 %306
  %308 = load ptr, ptr %307, align 8, !tbaa !5
  store ptr %308, ptr %26, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #8
  store i32 0, ptr %27, align 4, !tbaa !16
  br label %309

309:                                              ; preds = %465, %301
  %310 = load i32, ptr %27, align 4, !tbaa !16
  %311 = load ptr, ptr %26, align 8, !tbaa !5
  %312 = getelementptr inbounds %struct.ImDrawList, ptr %311, i32 0, i32 0
  %313 = getelementptr inbounds %struct.ImVector, ptr %312, i32 0, i32 0
  %314 = load i32, ptr %313, align 8, !tbaa !66
  %315 = icmp slt i32 %310, %314
  br i1 %315, label %317, label %316

316:                                              ; preds = %309
  store i32 8, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #8
  br label %468

317:                                              ; preds = %309
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #8
  %318 = load ptr, ptr %26, align 8, !tbaa !5
  %319 = getelementptr inbounds %struct.ImDrawList, ptr %318, i32 0, i32 0
  %320 = load i32, ptr %27, align 4, !tbaa !16
  %321 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNK8ImVectorI9ImDrawCmdEixEi(ptr noundef nonnull align 8 dereferenceable(16) %319, i32 noundef %320)
  store ptr %321, ptr %28, align 8, !tbaa !5
  %322 = load ptr, ptr %28, align 8, !tbaa !5
  %323 = getelementptr inbounds %struct.ImDrawCmd, ptr %322, i32 0, i32 5
  %324 = load ptr, ptr %323, align 8, !tbaa !67
  %325 = icmp ne ptr %324, null
  br i1 %325, label %326, label %345

326:                                              ; preds = %317
  %327 = load ptr, ptr %28, align 8, !tbaa !5
  %328 = getelementptr inbounds %struct.ImDrawCmd, ptr %327, i32 0, i32 5
  %329 = load ptr, ptr %328, align 8, !tbaa !67
  %330 = icmp eq ptr %329, inttoptr (i64 -1 to ptr)
  br i1 %330, label %331, label %338

331:                                              ; preds = %326
  %332 = load ptr, ptr %4, align 8, !tbaa !5
  %333 = load ptr, ptr %6, align 8, !tbaa !5
  %334 = load ptr, ptr %5, align 8, !tbaa !5
  %335 = load ptr, ptr %12, align 8, !tbaa !5
  %336 = load i32, ptr %7, align 4, !tbaa !16
  %337 = load i32, ptr %8, align 4, !tbaa !16
  call void @_ZL33ImGui_ImplVulkan_SetupRenderStateP10ImDrawDataP12VkPipeline_TP17VkCommandBuffer_TP36ImGui_ImplVulkanH_FrameRenderBuffersii(ptr noundef %332, ptr noundef %333, ptr noundef %334, ptr noundef %335, i32 noundef %336, i32 noundef %337)
  br label %344

338:                                              ; preds = %326
  %339 = load ptr, ptr %28, align 8, !tbaa !5
  %340 = getelementptr inbounds %struct.ImDrawCmd, ptr %339, i32 0, i32 5
  %341 = load ptr, ptr %340, align 8, !tbaa !67
  %342 = load ptr, ptr %26, align 8, !tbaa !5
  %343 = load ptr, ptr %28, align 8, !tbaa !5
  call void %341(ptr noundef %342, ptr noundef %343)
  br label %344

344:                                              ; preds = %338, %331
  br label %464

345:                                              ; preds = %317
  call void @llvm.lifetime.start.p0(i64 16, ptr %29) #8
  call void @_ZN6ImVec4C2Ev(ptr noundef nonnull align 4 dereferenceable(16) %29)
  %346 = load ptr, ptr %28, align 8, !tbaa !5
  %347 = getelementptr inbounds %struct.ImDrawCmd, ptr %346, i32 0, i32 0
  %348 = getelementptr inbounds %struct.ImVec4, ptr %347, i32 0, i32 0
  %349 = load float, ptr %348, align 8, !tbaa !69
  %350 = getelementptr inbounds %struct.ImVec2, ptr %21, i32 0, i32 0
  %351 = load float, ptr %350, align 4, !tbaa !70
  %352 = fsub float %349, %351
  %353 = getelementptr inbounds %struct.ImVec2, ptr %22, i32 0, i32 0
  %354 = load float, ptr %353, align 4, !tbaa !70
  %355 = fmul float %352, %354
  %356 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 0
  store float %355, ptr %356, align 4, !tbaa !71
  %357 = load ptr, ptr %28, align 8, !tbaa !5
  %358 = getelementptr inbounds %struct.ImDrawCmd, ptr %357, i32 0, i32 0
  %359 = getelementptr inbounds %struct.ImVec4, ptr %358, i32 0, i32 1
  %360 = load float, ptr %359, align 4, !tbaa !72
  %361 = getelementptr inbounds %struct.ImVec2, ptr %21, i32 0, i32 1
  %362 = load float, ptr %361, align 4, !tbaa !73
  %363 = fsub float %360, %362
  %364 = getelementptr inbounds %struct.ImVec2, ptr %22, i32 0, i32 1
  %365 = load float, ptr %364, align 4, !tbaa !73
  %366 = fmul float %363, %365
  %367 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 1
  store float %366, ptr %367, align 4, !tbaa !74
  %368 = load ptr, ptr %28, align 8, !tbaa !5
  %369 = getelementptr inbounds %struct.ImDrawCmd, ptr %368, i32 0, i32 0
  %370 = getelementptr inbounds %struct.ImVec4, ptr %369, i32 0, i32 2
  %371 = load float, ptr %370, align 8, !tbaa !75
  %372 = getelementptr inbounds %struct.ImVec2, ptr %21, i32 0, i32 0
  %373 = load float, ptr %372, align 4, !tbaa !70
  %374 = fsub float %371, %373
  %375 = getelementptr inbounds %struct.ImVec2, ptr %22, i32 0, i32 0
  %376 = load float, ptr %375, align 4, !tbaa !70
  %377 = fmul float %374, %376
  %378 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 2
  store float %377, ptr %378, align 4, !tbaa !76
  %379 = load ptr, ptr %28, align 8, !tbaa !5
  %380 = getelementptr inbounds %struct.ImDrawCmd, ptr %379, i32 0, i32 0
  %381 = getelementptr inbounds %struct.ImVec4, ptr %380, i32 0, i32 3
  %382 = load float, ptr %381, align 4, !tbaa !77
  %383 = getelementptr inbounds %struct.ImVec2, ptr %21, i32 0, i32 1
  %384 = load float, ptr %383, align 4, !tbaa !73
  %385 = fsub float %382, %384
  %386 = getelementptr inbounds %struct.ImVec2, ptr %22, i32 0, i32 1
  %387 = load float, ptr %386, align 4, !tbaa !73
  %388 = fmul float %385, %387
  %389 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 3
  store float %388, ptr %389, align 4, !tbaa !78
  %390 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 0
  %391 = load float, ptr %390, align 4, !tbaa !71
  %392 = load i32, ptr %7, align 4, !tbaa !16
  %393 = sitofp i32 %392 to float
  %394 = fcmp olt float %391, %393
  br i1 %394, label %395, label %463

395:                                              ; preds = %345
  %396 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 1
  %397 = load float, ptr %396, align 4, !tbaa !74
  %398 = load i32, ptr %8, align 4, !tbaa !16
  %399 = sitofp i32 %398 to float
  %400 = fcmp olt float %397, %399
  br i1 %400, label %401, label %463

401:                                              ; preds = %395
  %402 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 2
  %403 = load float, ptr %402, align 4, !tbaa !76
  %404 = fcmp oge float %403, 0.000000e+00
  br i1 %404, label %405, label %463

405:                                              ; preds = %401
  %406 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 3
  %407 = load float, ptr %406, align 4, !tbaa !78
  %408 = fcmp oge float %407, 0.000000e+00
  br i1 %408, label %409, label %463

409:                                              ; preds = %405
  %410 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 0
  %411 = load float, ptr %410, align 4, !tbaa !71
  %412 = fcmp olt float %411, 0.000000e+00
  br i1 %412, label %413, label %415

413:                                              ; preds = %409
  %414 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 0
  store float 0.000000e+00, ptr %414, align 4, !tbaa !71
  br label %415

415:                                              ; preds = %413, %409
  %416 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 1
  %417 = load float, ptr %416, align 4, !tbaa !74
  %418 = fcmp olt float %417, 0.000000e+00
  br i1 %418, label %419, label %421

419:                                              ; preds = %415
  %420 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 1
  store float 0.000000e+00, ptr %420, align 4, !tbaa !74
  br label %421

421:                                              ; preds = %419, %415
  call void @llvm.lifetime.start.p0(i64 16, ptr %30) #8
  %422 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 0
  %423 = load float, ptr %422, align 4, !tbaa !71
  %424 = fptosi float %423 to i32
  %425 = getelementptr inbounds %struct.VkRect2D, ptr %30, i32 0, i32 0
  %426 = getelementptr inbounds %struct.VkOffset2D, ptr %425, i32 0, i32 0
  store i32 %424, ptr %426, align 4, !tbaa !79
  %427 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 1
  %428 = load float, ptr %427, align 4, !tbaa !74
  %429 = fptosi float %428 to i32
  %430 = getelementptr inbounds %struct.VkRect2D, ptr %30, i32 0, i32 0
  %431 = getelementptr inbounds %struct.VkOffset2D, ptr %430, i32 0, i32 1
  store i32 %429, ptr %431, align 4, !tbaa !83
  %432 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 2
  %433 = load float, ptr %432, align 4, !tbaa !76
  %434 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 0
  %435 = load float, ptr %434, align 4, !tbaa !71
  %436 = fsub float %433, %435
  %437 = fptoui float %436 to i32
  %438 = getelementptr inbounds %struct.VkRect2D, ptr %30, i32 0, i32 1
  %439 = getelementptr inbounds %struct.VkExtent2D, ptr %438, i32 0, i32 0
  store i32 %437, ptr %439, align 4, !tbaa !84
  %440 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 3
  %441 = load float, ptr %440, align 4, !tbaa !78
  %442 = getelementptr inbounds %struct.ImVec4, ptr %29, i32 0, i32 1
  %443 = load float, ptr %442, align 4, !tbaa !74
  %444 = fsub float %441, %443
  %445 = fptoui float %444 to i32
  %446 = getelementptr inbounds %struct.VkRect2D, ptr %30, i32 0, i32 1
  %447 = getelementptr inbounds %struct.VkExtent2D, ptr %446, i32 0, i32 1
  store i32 %445, ptr %447, align 4, !tbaa !85
  %448 = load ptr, ptr %5, align 8, !tbaa !5
  call void @vkCmdSetScissor(ptr noundef %448, i32 noundef 0, i32 noundef 1, ptr noundef %30)
  %449 = load ptr, ptr %5, align 8, !tbaa !5
  %450 = load ptr, ptr %28, align 8, !tbaa !5
  %451 = getelementptr inbounds %struct.ImDrawCmd, ptr %450, i32 0, i32 4
  %452 = load i32, ptr %451, align 8, !tbaa !86
  %453 = load ptr, ptr %28, align 8, !tbaa !5
  %454 = getelementptr inbounds %struct.ImDrawCmd, ptr %453, i32 0, i32 3
  %455 = load i32, ptr %454, align 4, !tbaa !87
  %456 = load i32, ptr %24, align 4, !tbaa !16
  %457 = add i32 %455, %456
  %458 = load ptr, ptr %28, align 8, !tbaa !5
  %459 = getelementptr inbounds %struct.ImDrawCmd, ptr %458, i32 0, i32 2
  %460 = load i32, ptr %459, align 8, !tbaa !88
  %461 = load i32, ptr %23, align 4, !tbaa !16
  %462 = add i32 %460, %461
  call void @vkCmdDrawIndexed(ptr noundef %449, i32 noundef %452, i32 noundef 1, i32 noundef %457, i32 noundef %462, i32 noundef 0)
  call void @llvm.lifetime.end.p0(i64 16, ptr %30) #8
  br label %463

463:                                              ; preds = %421, %405, %401, %395, %345
  call void @llvm.lifetime.end.p0(i64 16, ptr %29) #8
  br label %464

464:                                              ; preds = %463, %344
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #8
  br label %465

465:                                              ; preds = %464
  %466 = load i32, ptr %27, align 4, !tbaa !16
  %467 = add nsw i32 %466, 1
  store i32 %467, ptr %27, align 4, !tbaa !16
  br label %309, !llvm.loop !89

468:                                              ; preds = %316
  %469 = load ptr, ptr %26, align 8, !tbaa !5
  %470 = getelementptr inbounds %struct.ImDrawList, ptr %469, i32 0, i32 1
  %471 = getelementptr inbounds %struct.ImVector.0, ptr %470, i32 0, i32 0
  %472 = load i32, ptr %471, align 8, !tbaa !56
  %473 = load i32, ptr %24, align 4, !tbaa !16
  %474 = add nsw i32 %473, %472
  store i32 %474, ptr %24, align 4, !tbaa !16
  %475 = load ptr, ptr %26, align 8, !tbaa !5
  %476 = getelementptr inbounds %struct.ImDrawList, ptr %475, i32 0, i32 2
  %477 = getelementptr inbounds %struct.ImVector.1, ptr %476, i32 0, i32 0
  %478 = load i32, ptr %477, align 8, !tbaa !54
  %479 = load i32, ptr %23, align 4, !tbaa !16
  %480 = add nsw i32 %479, %478
  store i32 %480, ptr %23, align 4, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  br label %481

481:                                              ; preds = %468
  %482 = load i32, ptr %25, align 4, !tbaa !16
  %483 = add nsw i32 %482, 1
  store i32 %483, ptr %25, align 4, !tbaa !16
  br label %294, !llvm.loop !90

484:                                              ; preds = %300
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #8
  store i32 0, ptr %9, align 4
  br label %485

485:                                              ; preds = %484, %56
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  %486 = load i32, ptr %9, align 4
  switch i32 %486, label %488 [
    i32 0, label %487
    i32 1, label %487
  ]

487:                                              ; preds = %485, %485
  ret void

488:                                              ; preds = %485
  unreachable
}

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

declare noundef ptr @_ZN5ImGui8MemAllocEm(i64 noundef) #2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL20CreateOrResizeBufferRP10VkBuffer_TRP16VkDeviceMemory_TRmm21VkBufferUsageFlagBits(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8), i64 noundef, i32 noundef) #0

declare i32 @vkMapMemory(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL15check_vk_result8VkResult(i32 noundef) #0

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #5

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

declare i32 @vkFlushMappedMemoryRanges(ptr noundef, i32 noundef, ptr noundef) #2

declare void @vkUnmapMemory(ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL33ImGui_ImplVulkan_SetupRenderStateP10ImDrawDataP12VkPipeline_TP17VkCommandBuffer_TP36ImGui_ImplVulkanH_FrameRenderBuffersii(ptr noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef) #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(56) ptr @_ZNK8ImVectorI9ImDrawCmdEixEi(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6ImVec4C2Ev(ptr noundef nonnull align 4 dereferenceable(16)) unnamed_addr #7 align 2

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

declare void @vkCmdDrawIndexed(ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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 #5 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { 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 #7 = { 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 #8 = { nounwind }
attributes #9 = { 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !14, i64 36}
!10 = !{!"_ZTS10ImDrawData", !11, i64 0, !6, i64 8, !12, i64 16, !12, i64 20, !12, i64 24, !13, i64 28, !13, i64 36, !13, i64 44}
!11 = !{!"bool", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!"_ZTS6ImVec2", !14, i64 0, !14, i64 4}
!14 = !{!"float", !7, i64 0}
!15 = !{!10, !14, i64 44}
!16 = !{!12, !12, i64 0}
!17 = !{!10, !14, i64 40}
!18 = !{!10, !14, i64 48}
!19 = !{!20, !6, i64 8}
!20 = !{!"_ZTS37ImGui_ImplVulkanH_WindowRenderBuffers", !12, i64 0, !12, i64 4, !6, i64 8}
!21 = !{!20, !12, i64 0}
!22 = !{!23, !12, i64 64}
!23 = !{!"_ZTS25ImGui_ImplVulkan_InitInfo", !6, i64 0, !6, i64 8, !6, i64 16, !12, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !12, i64 56, !12, i64 60, !12, i64 64, !24, i64 68, !6, i64 72, !6, i64 80}
!24 = !{!"_ZTS21VkSampleCountFlagBits", !7, i64 0}
!25 = !{!20, !12, i64 4}
!26 = !{!10, !12, i64 24}
!27 = !{!28, !28, i64 0}
!28 = !{!"long", !7, i64 0}
!29 = !{!10, !12, i64 20}
!30 = !{!31, !6, i64 32}
!31 = !{!"_ZTS36ImGui_ImplVulkanH_FrameRenderBuffers", !6, i64 0, !6, i64 8, !28, i64 16, !28, i64 24, !6, i64 32, !6, i64 40}
!32 = !{!31, !28, i64 16}
!33 = !{!31, !6, i64 40}
!34 = !{!31, !28, i64 24}
!35 = !{!23, !6, i64 16}
!36 = !{!31, !6, i64 0}
!37 = !{!38, !38, i64 0}
!38 = !{!"_ZTS8VkResult", !7, i64 0}
!39 = !{!31, !6, i64 8}
!40 = !{!10, !12, i64 16}
!41 = !{!10, !6, i64 8}
!42 = !{!43, !6, i64 40}
!43 = !{!"_ZTS10ImDrawList", !44, i64 0, !45, i64 16, !46, i64 32, !12, i64 48, !12, i64 52, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !47, i64 88, !48, i64 104, !49, i64 120, !50, i64 136, !52, i64 168, !14, i64 192}
!44 = !{!"_ZTS8ImVectorI9ImDrawCmdE", !12, i64 0, !12, i64 4, !6, i64 8}
!45 = !{!"_ZTS8ImVectorItE", !12, i64 0, !12, i64 4, !6, i64 8}
!46 = !{!"_ZTS8ImVectorI10ImDrawVertE", !12, i64 0, !12, i64 4, !6, i64 8}
!47 = !{!"_ZTS8ImVectorI6ImVec4E", !12, i64 0, !12, i64 4, !6, i64 8}
!48 = !{!"_ZTS8ImVectorIPvE", !12, i64 0, !12, i64 4, !6, i64 8}
!49 = !{!"_ZTS8ImVectorI6ImVec2E", !12, i64 0, !12, i64 4, !6, i64 8}
!50 = !{!"_ZTS15ImDrawCmdHeader", !51, i64 0, !6, i64 16, !12, i64 24}
!51 = !{!"_ZTS6ImVec4", !14, i64 0, !14, i64 4, !14, i64 8, !14, i64 12}
!52 = !{!"_ZTS18ImDrawListSplitter", !12, i64 0, !12, i64 4, !53, i64 8}
!53 = !{!"_ZTS8ImVectorI13ImDrawChannelE", !12, i64 0, !12, i64 4, !6, i64 8}
!54 = !{!43, !12, i64 32}
!55 = !{!43, !6, i64 24}
!56 = !{!43, !12, i64 16}
!57 = distinct !{!57, !58}
!58 = !{!"llvm.loop.mustprogress"}
!59 = !{!60, !61, i64 0}
!60 = !{!"_ZTS19VkMappedMemoryRange", !61, i64 0, !6, i64 8, !6, i64 16, !28, i64 24, !28, i64 32}
!61 = !{!"_ZTS15VkStructureType", !7, i64 0}
!62 = !{!60, !6, i64 16}
!63 = !{!60, !28, i64 32}
!64 = !{i64 0, i64 4, !65, i64 4, i64 4, !65}
!65 = !{!14, !14, i64 0}
!66 = !{!43, !12, i64 0}
!67 = !{!68, !6, i64 40}
!68 = !{!"_ZTS9ImDrawCmd", !51, i64 0, !6, i64 16, !12, i64 24, !12, i64 28, !12, i64 32, !6, i64 40, !6, i64 48}
!69 = !{!68, !14, i64 0}
!70 = !{!13, !14, i64 0}
!71 = !{!51, !14, i64 0}
!72 = !{!68, !14, i64 4}
!73 = !{!13, !14, i64 4}
!74 = !{!51, !14, i64 4}
!75 = !{!68, !14, i64 8}
!76 = !{!51, !14, i64 8}
!77 = !{!68, !14, i64 12}
!78 = !{!51, !14, i64 12}
!79 = !{!80, !12, i64 0}
!80 = !{!"_ZTS8VkRect2D", !81, i64 0, !82, i64 8}
!81 = !{!"_ZTS10VkOffset2D", !12, i64 0, !12, i64 4}
!82 = !{!"_ZTS10VkExtent2D", !12, i64 0, !12, i64 4}
!83 = !{!80, !12, i64 4}
!84 = !{!80, !12, i64 8}
!85 = !{!80, !12, i64 12}
!86 = !{!68, !12, i64 32}
!87 = !{!68, !12, i64 28}
!88 = !{!68, !12, i64 24}
!89 = distinct !{!89, !58}
!90 = distinct !{!90, !58}


; 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.ImGui_ImplVulkan_InitInfo = type { ptr, ptr, ptr, i32, ptr, ptr, ptr, i32, i32, i32, i32, ptr, ptr }
%struct.ImGui_ImplVulkanH_WindowRenderBuffers = type { i32, i32, ptr }
%struct.VkMappedMemoryRange = type { i32, ptr, ptr, i64, i64 }
%struct.ImVec4 = type { float, float, float, float }
%struct.VkRect2D = type { %struct.VkOffset2D, %struct.VkExtent2D }
%struct.VkOffset2D = type { i32, i32 }
%struct.VkExtent2D = type { i32, i32 }
%struct.ImGui_ImplVulkanH_FrameRenderBuffers = type { ptr, ptr, i64, i64, ptr, ptr }
%struct.ImDrawVert = type { %struct.ImVec2, %struct.ImVec2, i32 }
%struct.ImVec2 = type { float, float }

@_ZL16g_VulkanInitInfo = external hidden local_unnamed_addr global %struct.ImGui_ImplVulkan_InitInfo, align 8
@_ZL10g_Pipeline = external hidden local_unnamed_addr global ptr, align 8
@_ZL25g_MainWindowRenderBuffers = external hidden local_unnamed_addr global %struct.ImGui_ImplVulkanH_WindowRenderBuffers, align 8
@.str = external hidden unnamed_addr constant [28 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [103 x i8], align 1
@__PRETTY_FUNCTION__._Z31ImGui_ImplVulkan_RenderDrawDataP10ImDrawDataP17VkCommandBuffer_TP12VkPipeline_T = external hidden unnamed_addr constant [80 x i8], align 1

; Function Attrs: mustprogress uwtable
define dso_local void @_Z31ImGui_ImplVulkan_RenderDrawDataP10ImDrawDataP17VkCommandBuffer_TP12VkPipeline_T(ptr noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca [2 x %struct.VkMappedMemoryRange], align 16
  %7 = alloca %struct.ImVec4, align 8
  %8 = alloca %struct.VkRect2D, align 8
  %9 = getelementptr inbounds i8, ptr %0, i64 36
  %10 = getelementptr inbounds i8, ptr %0, i64 44
  %11 = load <2 x float>, ptr %9, align 4, !tbaa !5
  %12 = load <2 x float>, ptr %10, align 4, !tbaa !5
  %13 = fmul <2 x float> %11, %12
  %14 = fptosi <2 x float> %13 to <2 x i32>
  %15 = icmp slt <2 x i32> %14, <i32 1, i32 1>
  %16 = extractelement <2 x i1> %15, i64 0
  %17 = extractelement <2 x i1> %15, i64 1
  %or.cond = select i1 %16, i1 true, i1 %17
  br i1 %or.cond, label %.loopexit, label %18

18:                                               ; preds = %3
  %19 = icmp eq ptr %2, null
  %20 = load ptr, ptr @_ZL10g_Pipeline, align 8
  %spec.select = select i1 %19, ptr %20, ptr %2
  %21 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL25g_MainWindowRenderBuffers, i64 8), align 8, !tbaa !9
  %22 = icmp eq ptr %21, null
  br i1 %22, label %23, label %31

23:                                               ; preds = %18
  store i32 0, ptr @_ZL25g_MainWindowRenderBuffers, align 8, !tbaa !13
  %24 = load i32, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 64), align 8, !tbaa !14
  store i32 %24, ptr getelementptr inbounds (i8, ptr @_ZL25g_MainWindowRenderBuffers, i64 4), align 4, !tbaa !17
  %25 = zext i32 %24 to i64
  %26 = mul nuw nsw i64 %25, 48
  %27 = tail call noundef ptr @_ZN5ImGui8MemAllocEm(i64 noundef %26)
  store ptr %27, ptr getelementptr inbounds (i8, ptr @_ZL25g_MainWindowRenderBuffers, i64 8), align 8, !tbaa !9
  %28 = load i32, ptr getelementptr inbounds (i8, ptr @_ZL25g_MainWindowRenderBuffers, i64 4), align 4, !tbaa !17
  %29 = zext i32 %28 to i64
  %30 = mul nuw nsw i64 %29, 48
  tail call void @llvm.memset.p0.i64(ptr align 8 %27, i8 0, i64 %30, i1 false)
  br label %31

31:                                               ; preds = %23, %18
  %32 = load i32, ptr getelementptr inbounds (i8, ptr @_ZL25g_MainWindowRenderBuffers, i64 4), align 4, !tbaa !17
  %33 = load i32, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 64), align 8, !tbaa !14
  %34 = icmp eq i32 %32, %33
  br i1 %34, label %36, label %35

35:                                               ; preds = %31
  tail call void @__assert_fail(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 340, ptr noundef nonnull @__PRETTY_FUNCTION__._Z31ImGui_ImplVulkan_RenderDrawDataP10ImDrawDataP17VkCommandBuffer_TP12VkPipeline_T) #8
  unreachable

36:                                               ; preds = %31
  %37 = load i32, ptr @_ZL25g_MainWindowRenderBuffers, align 8, !tbaa !13
  %38 = add i32 %37, 1
  %39 = urem i32 %38, %32
  store i32 %39, ptr @_ZL25g_MainWindowRenderBuffers, align 8, !tbaa !13
  %40 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL25g_MainWindowRenderBuffers, i64 8), align 8, !tbaa !9
  %41 = zext i32 %39 to i64
  %42 = getelementptr inbounds %struct.ImGui_ImplVulkanH_FrameRenderBuffers, ptr %40, i64 %41
  %43 = getelementptr inbounds i8, ptr %0, i64 24
  %44 = load i32, ptr %43, align 8, !tbaa !18
  %45 = icmp sgt i32 %44, 0
  br i1 %45, label %46, label %127

46:                                               ; preds = %36
  %47 = zext nneg i32 %44 to i64
  %48 = mul nuw nsw i64 %47, 20
  %49 = getelementptr inbounds i8, ptr %0, i64 20
  %50 = load i32, ptr %49, align 4, !tbaa !22
  %51 = sext i32 %50 to i64
  %52 = shl nsw i64 %51, 1
  %53 = getelementptr inbounds i8, ptr %42, i64 32
  %54 = load ptr, ptr %53, align 8, !tbaa !23
  %55 = icmp eq ptr %54, null
  br i1 %55, label %60, label %56

56:                                               ; preds = %46
  %57 = getelementptr inbounds i8, ptr %42, i64 16
  %58 = load i64, ptr %57, align 8, !tbaa !26
  %59 = icmp ult i64 %58, %48
  br i1 %59, label %60, label %62

60:                                               ; preds = %56, %46
  %61 = getelementptr inbounds i8, ptr %42, i64 16
  tail call void @_ZL20CreateOrResizeBufferRP10VkBuffer_TRP16VkDeviceMemory_TRmm21VkBufferUsageFlagBits(ptr noundef nonnull align 8 dereferenceable(8) %53, ptr noundef nonnull align 8 dereferenceable(8) %42, ptr noundef nonnull align 8 dereferenceable(8) %61, i64 noundef %48, i32 noundef 128)
  br label %62

62:                                               ; preds = %60, %56
  %63 = getelementptr inbounds i8, ptr %42, i64 40
  %64 = load ptr, ptr %63, align 8, !tbaa !27
  %65 = icmp eq ptr %64, null
  br i1 %65, label %70, label %66

66:                                               ; preds = %62
  %67 = getelementptr inbounds i8, ptr %42, i64 24
  %68 = load i64, ptr %67, align 8, !tbaa !28
  %69 = icmp ult i64 %68, %52
  br i1 %69, label %70, label %73

70:                                               ; preds = %66, %62
  %71 = getelementptr inbounds i8, ptr %42, i64 8
  %72 = getelementptr inbounds i8, ptr %42, i64 24
  tail call void @_ZL20CreateOrResizeBufferRP10VkBuffer_TRP16VkDeviceMemory_TRmm21VkBufferUsageFlagBits(ptr noundef nonnull align 8 dereferenceable(8) %63, ptr noundef nonnull align 8 dereferenceable(8) %71, ptr noundef nonnull align 8 dereferenceable(8) %72, i64 noundef %52, i32 noundef 64)
  br label %73

73:                                               ; preds = %70, %66
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #9
  store ptr null, ptr %4, align 8, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #9
  store ptr null, ptr %5, align 8, !tbaa !29
  %74 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 16), align 8, !tbaa !30
  %75 = load ptr, ptr %42, align 8, !tbaa !31
  %76 = call i32 @vkMapMemory(ptr noundef %74, ptr noundef %75, i64 noundef 0, i64 noundef %48, i32 noundef 0, ptr noundef nonnull %4)
  call void @_ZL15check_vk_result8VkResult(i32 noundef %76)
  %77 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 16), align 8, !tbaa !30
  %78 = getelementptr inbounds i8, ptr %42, i64 8
  %79 = load ptr, ptr %78, align 8, !tbaa !32
  %80 = call i32 @vkMapMemory(ptr noundef %77, ptr noundef %79, i64 noundef 0, i64 noundef %52, i32 noundef 0, ptr noundef nonnull %5)
  call void @_ZL15check_vk_result8VkResult(i32 noundef %80)
  %81 = getelementptr inbounds i8, ptr %0, i64 16
  %82 = load i32, ptr %81, align 8, !tbaa !33
  %83 = icmp sgt i32 %82, 0
  br i1 %83, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %73
  %84 = getelementptr inbounds i8, ptr %0, i64 8
  %.pre = load ptr, ptr %4, align 8, !tbaa !29
  br label %98

._crit_edge:                                      ; preds = %98, %73
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %6) #9
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(80) %6, i8 0, i64 80, i1 false)
  store i32 6, ptr %6, align 16, !tbaa !34
  %85 = load ptr, ptr %42, align 8, !tbaa !31
  %86 = getelementptr inbounds i8, ptr %6, i64 16
  store ptr %85, ptr %86, align 16, !tbaa !37
  %87 = getelementptr inbounds i8, ptr %6, i64 32
  store i64 -1, ptr %87, align 16, !tbaa !38
  %88 = getelementptr inbounds i8, ptr %6, i64 40
  store i32 6, ptr %88, align 8, !tbaa !34
  %89 = load ptr, ptr %78, align 8, !tbaa !32
  %90 = getelementptr inbounds i8, ptr %6, i64 56
  store ptr %89, ptr %90, align 8, !tbaa !37
  %91 = getelementptr inbounds i8, ptr %6, i64 72
  store i64 -1, ptr %91, align 8, !tbaa !38
  %92 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 16), align 8, !tbaa !30
  %93 = call i32 @vkFlushMappedMemoryRanges(ptr noundef %92, i32 noundef 2, ptr noundef nonnull %6)
  call void @_ZL15check_vk_result8VkResult(i32 noundef %93)
  %94 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 16), align 8, !tbaa !30
  %95 = load ptr, ptr %42, align 8, !tbaa !31
  call void @vkUnmapMemory(ptr noundef %94, ptr noundef %95)
  %96 = load ptr, ptr getelementptr inbounds (i8, ptr @_ZL16g_VulkanInitInfo, i64 16), align 8, !tbaa !30
  %97 = load ptr, ptr %78, align 8, !tbaa !32
  call void @vkUnmapMemory(ptr noundef %96, ptr noundef %97)
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #9
  br label %127

98:                                               ; preds = %.lr.ph, %98
  %99 = phi ptr [ %.pre, %.lr.ph ], [ %119, %98 ]
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %98 ]
  %100 = load ptr, ptr %84, align 8, !tbaa !39
  %101 = getelementptr inbounds ptr, ptr %100, i64 %indvars.iv
  %102 = load ptr, ptr %101, align 8, !tbaa !29
  %103 = getelementptr inbounds i8, ptr %102, i64 32
  %104 = getelementptr inbounds i8, ptr %102, i64 40
  %105 = load ptr, ptr %104, align 8, !tbaa !40
  %106 = load i32, ptr %103, align 8, !tbaa !52
  %107 = sext i32 %106 to i64
  %108 = mul nsw i64 %107, 20
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %99, ptr align 4 %105, i64 %108, i1 false)
  %109 = load ptr, ptr %5, align 8, !tbaa !29
  %110 = getelementptr inbounds i8, ptr %102, i64 16
  %111 = getelementptr inbounds i8, ptr %102, i64 24
  %112 = load ptr, ptr %111, align 8, !tbaa !53
  %113 = load i32, ptr %110, align 8, !tbaa !54
  %114 = sext i32 %113 to i64
  %115 = shl nsw i64 %114, 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 2 %109, ptr align 2 %112, i64 %115, i1 false)
  %116 = load i32, ptr %103, align 8, !tbaa !52
  %117 = load ptr, ptr %4, align 8, !tbaa !29
  %118 = sext i32 %116 to i64
  %119 = getelementptr inbounds %struct.ImDrawVert, ptr %117, i64 %118
  store ptr %119, ptr %4, align 8, !tbaa !29
  %120 = load i32, ptr %110, align 8, !tbaa !54
  %121 = load ptr, ptr %5, align 8, !tbaa !29
  %122 = sext i32 %120 to i64
  %123 = getelementptr inbounds i16, ptr %121, i64 %122
  store ptr %123, ptr %5, align 8, !tbaa !29
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %124 = load i32, ptr %81, align 8, !tbaa !33
  %125 = sext i32 %124 to i64
  %126 = icmp slt i64 %indvars.iv.next, %125
  br i1 %126, label %98, label %._crit_edge, !llvm.loop !55

127:                                              ; preds = %._crit_edge, %36
  %128 = extractelement <2 x i32> %14, i64 0
  %129 = extractelement <2 x i32> %14, i64 1
  call void @_ZL33ImGui_ImplVulkan_SetupRenderStateP10ImDrawDataP12VkPipeline_TP17VkCommandBuffer_TP36ImGui_ImplVulkanH_FrameRenderBuffersii(ptr noundef nonnull %0, ptr noundef %spec.select, ptr noundef %1, ptr noundef %42, i32 noundef %128, i32 noundef %129)
  %130 = getelementptr inbounds i8, ptr %0, i64 28
  %131 = load <2 x float>, ptr %130, align 4, !tbaa !5
  %132 = load <2 x float>, ptr %10, align 4, !tbaa !5
  %133 = getelementptr inbounds i8, ptr %0, i64 16
  %134 = load i32, ptr %133, align 8, !tbaa !33
  %135 = icmp sgt i32 %134, 0
  br i1 %135, label %.lr.ph145, label %.loopexit

.lr.ph145:                                        ; preds = %127
  %136 = getelementptr inbounds i8, ptr %0, i64 8
  %137 = getelementptr inbounds i8, ptr %7, i64 4
  %138 = getelementptr inbounds i8, ptr %7, i64 8
  %139 = uitofp nneg i32 %128 to float
  %140 = uitofp nneg i32 %129 to float
  %141 = getelementptr inbounds i8, ptr %8, i64 8
  br label %142

142:                                              ; preds = %.lr.ph145, %._crit_edge140
  %143 = phi i32 [ %134, %.lr.ph145 ], [ %149, %._crit_edge140 ]
  %indvars.iv147 = phi i64 [ 0, %.lr.ph145 ], [ %indvars.iv.next148, %._crit_edge140 ]
  %.0126142 = phi i32 [ 0, %.lr.ph145 ], [ %152, %._crit_edge140 ]
  %.0127141 = phi i32 [ 0, %.lr.ph145 ], [ %155, %._crit_edge140 ]
  %144 = load ptr, ptr %136, align 8, !tbaa !39
  %145 = getelementptr inbounds ptr, ptr %144, i64 %indvars.iv147
  %146 = load ptr, ptr %145, align 8, !tbaa !29
  %147 = load i32, ptr %146, align 8, !tbaa !57
  %148 = icmp sgt i32 %147, 0
  br i1 %148, label %.lr.ph139, label %._crit_edge140

._crit_edge140.loopexit:                          ; preds = %203
  %.pre150 = load i32, ptr %133, align 8, !tbaa !33
  br label %._crit_edge140

._crit_edge140:                                   ; preds = %._crit_edge140.loopexit, %142
  %149 = phi i32 [ %.pre150, %._crit_edge140.loopexit ], [ %143, %142 ]
  %150 = getelementptr inbounds i8, ptr %146, i64 16
  %151 = load i32, ptr %150, align 8, !tbaa !54
  %152 = add nsw i32 %151, %.0126142
  %153 = getelementptr inbounds i8, ptr %146, i64 32
  %154 = load i32, ptr %153, align 8, !tbaa !52
  %155 = add nsw i32 %154, %.0127141
  %indvars.iv.next148 = add nuw nsw i64 %indvars.iv147, 1
  %156 = sext i32 %149 to i64
  %157 = icmp slt i64 %indvars.iv.next148, %156
  br i1 %157, label %142, label %.loopexit, !llvm.loop !58

.lr.ph139:                                        ; preds = %142, %203
  %.0124137 = phi i32 [ %204, %203 ], [ 0, %142 ]
  %158 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNK8ImVectorI9ImDrawCmdEixEi(ptr noundef nonnull align 8 dereferenceable(16) %146, i32 noundef %.0124137)
  %159 = getelementptr inbounds i8, ptr %158, i64 40
  %160 = load ptr, ptr %159, align 8, !tbaa !59
  %magicptr = ptrtoint ptr %160 to i64
  switch i64 %magicptr, label %162 [
    i64 0, label %163
    i64 -1, label %161
  ]

161:                                              ; preds = %.lr.ph139
  call void @_ZL33ImGui_ImplVulkan_SetupRenderStateP10ImDrawDataP12VkPipeline_TP17VkCommandBuffer_TP36ImGui_ImplVulkanH_FrameRenderBuffersii(ptr noundef %0, ptr noundef %spec.select, ptr noundef %1, ptr noundef %42, i32 noundef %128, i32 noundef %129)
  br label %203

162:                                              ; preds = %.lr.ph139
  call void %160(ptr noundef nonnull %146, ptr noundef nonnull %158)
  br label %203

163:                                              ; preds = %.lr.ph139
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #9
  call void @_ZN6ImVec4C2Ev(ptr noundef nonnull align 4 dereferenceable(16) %7)
  %164 = load <2 x float>, ptr %158, align 8, !tbaa !5
  %165 = fsub <2 x float> %164, %131
  %166 = fmul <2 x float> %132, %165
  store <2 x float> %166, ptr %7, align 8, !tbaa !5
  %167 = getelementptr inbounds i8, ptr %158, i64 8
  %168 = load <2 x float>, ptr %167, align 8, !tbaa !5
  %169 = fsub <2 x float> %168, %131
  %170 = fmul <2 x float> %132, %169
  store <2 x float> %170, ptr %138, align 8, !tbaa !5
  %171 = extractelement <2 x float> %166, i64 0
  %172 = fcmp olt float %171, %139
  br i1 %172, label %173, label %202

173:                                              ; preds = %163
  %174 = extractelement <2 x float> %166, i64 1
  %175 = fcmp olt float %174, %140
  %176 = extractelement <2 x float> %170, i64 0
  %177 = fcmp oge float %176, 0.000000e+00
  %or.cond4 = select i1 %175, i1 %177, i1 false
  %178 = extractelement <2 x float> %170, i64 1
  %179 = fcmp oge float %178, 0.000000e+00
  %or.cond7 = select i1 %or.cond4, i1 %179, i1 false
  br i1 %or.cond7, label %180, label %202

180:                                              ; preds = %173
  %181 = fcmp olt float %171, 0.000000e+00
  br i1 %181, label %182, label %183

182:                                              ; preds = %180
  store float 0.000000e+00, ptr %7, align 8, !tbaa !61
  br label %183

183:                                              ; preds = %182, %180
  %184 = phi float [ 0.000000e+00, %182 ], [ %171, %180 ]
  %185 = fcmp olt float %174, 0.000000e+00
  br i1 %185, label %186, label %187

186:                                              ; preds = %183
  store float 0.000000e+00, ptr %137, align 4, !tbaa !62
  br label %187

187:                                              ; preds = %186, %183
  %188 = phi float [ 0.000000e+00, %186 ], [ %174, %183 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %8) #9
  %189 = insertelement <2 x float> poison, float %184, i64 0
  %190 = insertelement <2 x float> %189, float %188, i64 1
  %191 = fptosi <2 x float> %190 to <2 x i32>
  store <2 x i32> %191, ptr %8, align 8, !tbaa !63
  %192 = fsub <2 x float> %170, %190
  %193 = fptoui <2 x float> %192 to <2 x i32>
  store <2 x i32> %193, ptr %141, align 8, !tbaa !63
  call void @vkCmdSetScissor(ptr noundef %1, i32 noundef 0, i32 noundef 1, ptr noundef nonnull %8)
  %194 = getelementptr inbounds i8, ptr %158, i64 32
  %195 = load i32, ptr %194, align 8, !tbaa !64
  %196 = getelementptr inbounds i8, ptr %158, i64 28
  %197 = load i32, ptr %196, align 4, !tbaa !65
  %198 = add i32 %197, %.0126142
  %199 = getelementptr inbounds i8, ptr %158, i64 24
  %200 = load i32, ptr %199, align 8, !tbaa !66
  %201 = add i32 %200, %.0127141
  call void @vkCmdDrawIndexed(ptr noundef %1, i32 noundef %195, i32 noundef 1, i32 noundef %198, i32 noundef %201, i32 noundef 0)
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #9
  br label %202

202:                                              ; preds = %187, %173, %163
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #9
  br label %203

203:                                              ; preds = %161, %162, %202
  %204 = add nuw nsw i32 %.0124137, 1
  %205 = load i32, ptr %146, align 8, !tbaa !57
  %206 = icmp slt i32 %204, %205
  br i1 %206, label %.lr.ph139, label %._crit_edge140.loopexit, !llvm.loop !67

.loopexit:                                        ; preds = %._crit_edge140, %127, %3
  ret void
}

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

declare noundef ptr @_ZN5ImGui8MemAllocEm(i64 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL20CreateOrResizeBufferRP10VkBuffer_TRP16VkDeviceMemory_TRmm21VkBufferUsageFlagBits(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8), i64 noundef, i32 noundef) local_unnamed_addr #0

declare i32 @vkMapMemory(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i32 noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL15check_vk_result8VkResult(i32 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #5

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

declare i32 @vkFlushMappedMemoryRanges(ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #2

declare void @vkUnmapMemory(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL33ImGui_ImplVulkan_SetupRenderStateP10ImDrawDataP12VkPipeline_TP17VkCommandBuffer_TP36ImGui_ImplVulkanH_FrameRenderBuffersii(ptr noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(56) ptr @_ZNK8ImVectorI9ImDrawCmdEixEi(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6ImVec4C2Ev(ptr noundef nonnull align 4 dereferenceable(16)) unnamed_addr #7 align 2

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

declare void @vkCmdDrawIndexed(ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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 #5 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { 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 #7 = { 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 #8 = { noreturn nounwind }
attributes #9 = { 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 = !{!"float", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !12, i64 8}
!10 = !{!"_ZTS37ImGui_ImplVulkanH_WindowRenderBuffers", !11, i64 0, !11, i64 4, !12, i64 8}
!11 = !{!"int", !7, i64 0}
!12 = !{!"any pointer", !7, i64 0}
!13 = !{!10, !11, i64 0}
!14 = !{!15, !11, i64 64}
!15 = !{!"_ZTS25ImGui_ImplVulkan_InitInfo", !12, i64 0, !12, i64 8, !12, i64 16, !11, i64 24, !12, i64 32, !12, i64 40, !12, i64 48, !11, i64 56, !11, i64 60, !11, i64 64, !16, i64 68, !12, i64 72, !12, i64 80}
!16 = !{!"_ZTS21VkSampleCountFlagBits", !7, i64 0}
!17 = !{!10, !11, i64 4}
!18 = !{!19, !11, i64 24}
!19 = !{!"_ZTS10ImDrawData", !20, i64 0, !12, i64 8, !11, i64 16, !11, i64 20, !11, i64 24, !21, i64 28, !21, i64 36, !21, i64 44}
!20 = !{!"bool", !7, i64 0}
!21 = !{!"_ZTS6ImVec2", !6, i64 0, !6, i64 4}
!22 = !{!19, !11, i64 20}
!23 = !{!24, !12, i64 32}
!24 = !{!"_ZTS36ImGui_ImplVulkanH_FrameRenderBuffers", !12, i64 0, !12, i64 8, !25, i64 16, !25, i64 24, !12, i64 32, !12, i64 40}
!25 = !{!"long", !7, i64 0}
!26 = !{!24, !25, i64 16}
!27 = !{!24, !12, i64 40}
!28 = !{!24, !25, i64 24}
!29 = !{!12, !12, i64 0}
!30 = !{!15, !12, i64 16}
!31 = !{!24, !12, i64 0}
!32 = !{!24, !12, i64 8}
!33 = !{!19, !11, i64 16}
!34 = !{!35, !36, i64 0}
!35 = !{!"_ZTS19VkMappedMemoryRange", !36, i64 0, !12, i64 8, !12, i64 16, !25, i64 24, !25, i64 32}
!36 = !{!"_ZTS15VkStructureType", !7, i64 0}
!37 = !{!35, !12, i64 16}
!38 = !{!35, !25, i64 32}
!39 = !{!19, !12, i64 8}
!40 = !{!41, !12, i64 40}
!41 = !{!"_ZTS10ImDrawList", !42, i64 0, !43, i64 16, !44, i64 32, !11, i64 48, !11, i64 52, !12, i64 56, !12, i64 64, !12, i64 72, !12, i64 80, !45, i64 88, !46, i64 104, !47, i64 120, !48, i64 136, !50, i64 168, !6, i64 192}
!42 = !{!"_ZTS8ImVectorI9ImDrawCmdE", !11, i64 0, !11, i64 4, !12, i64 8}
!43 = !{!"_ZTS8ImVectorItE", !11, i64 0, !11, i64 4, !12, i64 8}
!44 = !{!"_ZTS8ImVectorI10ImDrawVertE", !11, i64 0, !11, i64 4, !12, i64 8}
!45 = !{!"_ZTS8ImVectorI6ImVec4E", !11, i64 0, !11, i64 4, !12, i64 8}
!46 = !{!"_ZTS8ImVectorIPvE", !11, i64 0, !11, i64 4, !12, i64 8}
!47 = !{!"_ZTS8ImVectorI6ImVec2E", !11, i64 0, !11, i64 4, !12, i64 8}
!48 = !{!"_ZTS15ImDrawCmdHeader", !49, i64 0, !12, i64 16, !11, i64 24}
!49 = !{!"_ZTS6ImVec4", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12}
!50 = !{!"_ZTS18ImDrawListSplitter", !11, i64 0, !11, i64 4, !51, i64 8}
!51 = !{!"_ZTS8ImVectorI13ImDrawChannelE", !11, i64 0, !11, i64 4, !12, i64 8}
!52 = !{!41, !11, i64 32}
!53 = !{!41, !12, i64 24}
!54 = !{!41, !11, i64 16}
!55 = distinct !{!55, !56}
!56 = !{!"llvm.loop.mustprogress"}
!57 = !{!41, !11, i64 0}
!58 = distinct !{!58, !56}
!59 = !{!60, !12, i64 40}
!60 = !{!"_ZTS9ImDrawCmd", !49, i64 0, !12, i64 16, !11, i64 24, !11, i64 28, !11, i64 32, !12, i64 40, !12, i64 48}
!61 = !{!49, !6, i64 0}
!62 = !{!49, !6, i64 4}
!63 = !{!11, !11, i64 0}
!64 = !{!60, !11, i64 32}
!65 = !{!60, !11, i64 28}
!66 = !{!60, !11, i64 24}
!67 = distinct !{!67, !56}


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