; LLVM IR from thalium/icebox :: third_party/virtualbox/src/VBox/Devices/EFI/Firmware/ShellPkg/Library (HDiskImageRead)

; 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.HEFI_EDITOR_DISK_IMAGE = type { ptr, i64, i64, i64 }
%struct.HEFI_EDITOR_BUFFER_IMAGE = type { ptr, ptr, i64, ptr, %struct.HEFI_EDITOR_POSITION, %struct.HEFI_EDITOR_POSITION, %struct.HEFI_EDITOR_POSITION, i64, i8, i8, i32, ptr, ptr, ptr }
%struct.HEFI_EDITOR_POSITION = type { i64, i64 }
%struct.GUID = type { i32, i16, i16, [8 x i8] }
%struct.HEFI_EDITOR_GLOBAL_EDITOR = type { ptr, %union.HEFI_EDITOR_COLOR_UNION, %struct.HEFI_EDITOR_POSITION, i8, ptr, i32, i32, i64, i64 }
%union.HEFI_EDITOR_COLOR_UNION = type { i64 }
%struct._EFI_SHELL_PROTOCOL = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, ptr, ptr, ptr }
%struct.EFI_BOOT_SERVICES = type { %struct.EFI_TABLE_HEADER, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.EFI_TABLE_HEADER = type { i64, i32, i32, i32, i32 }
%struct._EFI_BLOCK_IO_PROTOCOL = type { i64, ptr, ptr, ptr, ptr, ptr }
%struct.EFI_BLOCK_IO_MEDIA = type { i32, i8, i8, i8, i8, i8, i32, i32, i64, i64, i32, i32 }
%struct._LIST_ENTRY = type { ptr, ptr }
%struct._HEFI_EDITOR_LINE = type { i64, [16 x i8], i64, %struct._LIST_ENTRY }

@HDiskImage = external dso_local global %struct.HEFI_EDITOR_DISK_IMAGE, align 8
@HBufferImage = external global %struct.HEFI_EDITOR_BUFFER_IMAGE, align 8
@gEfiShellProtocol = external global ptr, align 8
@.str.1 = external hidden unnamed_addr constant [19 x i32], align 4
@gBS = external global ptr, align 8
@gEfiBlockIoProtocolGuid = external global %struct.GUID, align 4
@.str.2 = external hidden unnamed_addr constant [17 x i32], align 4
@gImageHandle = external global ptr, align 8
@.str.3 = external hidden unnamed_addr constant [22 x i32], align 4
@.str.4 = external hidden unnamed_addr constant [14 x i32], align 4
@HMainEditor = external global %struct.HEFI_EDITOR_GLOBAL_EDITOR, align 8
@.str.5 = external hidden unnamed_addr constant [165 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [21 x i8], align 1
@HBufferImageNeedRefresh = external global i8, align 1
@HBufferImageOnlyLineNeedRefresh = external global i8, align 1
@HBufferImageMouseNeedRefresh = external global i8, align 1

declare void @FreePool(ptr noundef) #0

declare ptr @CatSPrint(ptr noundef, ptr noundef, ...) #0

; Function Attrs: nounwind uwtable
declare dso_local i64 @HDiskImageSetDiskNameOffsetSize(ptr noundef, i64 noundef, i64 noundef) #1

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

declare ptr @AllocateZeroPool(i64 noundef) #0

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

; Function Attrs: nounwind uwtable
define dso_local i64 @HDiskImageRead(ptr noundef %0, i64 noundef %1, i64 noundef %2, i8 noundef zeroext %3) #1 {
  %5 = alloca i64, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca i8, align 1
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i64, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca i64, align 8
  %19 = alloca ptr, align 8
  %20 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store i64 %1, ptr %7, align 8, !tbaa !9
  store i64 %2, ptr %8, align 8, !tbaa !9
  store i8 %3, ptr %9, align 1, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #3
  store i32 3, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 10), align 4, !tbaa !12
  %21 = load ptr, ptr @gEfiShellProtocol, align 8, !tbaa !5
  %22 = getelementptr inbounds %struct._EFI_SHELL_PROTOCOL, ptr %21, i32 0, i32 6
  %23 = load ptr, ptr %22, align 8, !tbaa !16
  %24 = load ptr, ptr %6, align 8, !tbaa !5
  %25 = call ptr %23(ptr noundef %24)
  store ptr %25, ptr %10, align 8, !tbaa !5
  %26 = load ptr, ptr %10, align 8, !tbaa !5
  %27 = icmp eq ptr %26, null
  br i1 %27, label %28, label %30

28:                                               ; preds = %4
  %29 = call i64 @StatusBarSetStatusString(ptr noundef @.str.1)
  store i64 -9223372036854775806, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

30:                                               ; preds = %4
  %31 = load ptr, ptr %10, align 8, !tbaa !5
  %32 = call ptr @DuplicateDevicePath(ptr noundef %31)
  store ptr %32, ptr %11, align 8, !tbaa !5
  %33 = load ptr, ptr %11, align 8, !tbaa !5
  store ptr %33, ptr %12, align 8, !tbaa !5
  %34 = load ptr, ptr @gBS, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.EFI_BOOT_SERVICES, ptr %34, i32 0, i32 21
  %36 = load ptr, ptr %35, align 8, !tbaa !18
  %37 = call i64 %36(ptr noundef @gEfiBlockIoProtocolGuid, ptr noundef %11, ptr noundef %13)
  store i64 %37, ptr %15, align 8, !tbaa !9
  %38 = load ptr, ptr %12, align 8, !tbaa !5
  call void @FreePool(ptr noundef %38)
  %39 = load i64, ptr %15, align 8, !tbaa !9
  %40 = icmp slt i64 %39, 0
  br i1 %40, label %41, label %44

41:                                               ; preds = %30
  %42 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  %43 = load i64, ptr %15, align 8, !tbaa !9
  store i64 %43, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

44:                                               ; preds = %30
  %45 = load ptr, ptr @gBS, align 8, !tbaa !5
  %46 = getelementptr inbounds %struct.EFI_BOOT_SERVICES, ptr %45, i32 0, i32 33
  %47 = load ptr, ptr %46, align 8, !tbaa !21
  %48 = load ptr, ptr %13, align 8, !tbaa !5
  %49 = load ptr, ptr @gImageHandle, align 8, !tbaa !5
  %50 = call i64 %47(ptr noundef %48, ptr noundef @gEfiBlockIoProtocolGuid, ptr noundef %14, ptr noundef %49, ptr noundef null, i32 noundef 2)
  store i64 %50, ptr %15, align 8, !tbaa !9
  %51 = load i64, ptr %15, align 8, !tbaa !9
  %52 = icmp slt i64 %51, 0
  br i1 %52, label %53, label %56

53:                                               ; preds = %44
  %54 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  %55 = load i64, ptr %15, align 8, !tbaa !9
  store i64 %55, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

56:                                               ; preds = %44
  %57 = load i64, ptr %7, align 8, !tbaa !9
  %58 = load ptr, ptr %14, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct._EFI_BLOCK_IO_PROTOCOL, ptr %58, i32 0, i32 1
  %60 = load ptr, ptr %59, align 8, !tbaa !22
  %61 = getelementptr inbounds %struct.EFI_BLOCK_IO_MEDIA, ptr %60, i32 0, i32 8
  %62 = load i64, ptr %61, align 8, !tbaa !24
  %63 = icmp ugt i64 %57, %62
  br i1 %63, label %74, label %64

64:                                               ; preds = %56
  %65 = load i64, ptr %7, align 8, !tbaa !9
  %66 = load i64, ptr %8, align 8, !tbaa !9
  %67 = add i64 %65, %66
  %68 = load ptr, ptr %14, align 8, !tbaa !5
  %69 = getelementptr inbounds %struct._EFI_BLOCK_IO_PROTOCOL, ptr %68, i32 0, i32 1
  %70 = load ptr, ptr %69, align 8, !tbaa !22
  %71 = getelementptr inbounds %struct.EFI_BLOCK_IO_MEDIA, ptr %70, i32 0, i32 8
  %72 = load i64, ptr %71, align 8, !tbaa !24
  %73 = icmp ugt i64 %67, %72
  br i1 %73, label %74, label %76

74:                                               ; preds = %64, %56
  %75 = call i64 @StatusBarSetStatusString(ptr noundef @.str.3)
  store i64 -9223372036854775807, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

76:                                               ; preds = %64
  %77 = load ptr, ptr %14, align 8, !tbaa !5
  %78 = getelementptr inbounds %struct._EFI_BLOCK_IO_PROTOCOL, ptr %77, i32 0, i32 1
  %79 = load ptr, ptr %78, align 8, !tbaa !22
  %80 = getelementptr inbounds %struct.EFI_BLOCK_IO_MEDIA, ptr %79, i32 0, i32 6
  %81 = load i32, ptr %80, align 4, !tbaa !26
  %82 = zext i32 %81 to i64
  %83 = load i64, ptr %8, align 8, !tbaa !9
  %84 = mul i64 %82, %83
  store i64 %84, ptr %18, align 8, !tbaa !9
  %85 = load i64, ptr %18, align 8, !tbaa !9
  %86 = call ptr @AllocateZeroPool(i64 noundef %85)
  store ptr %86, ptr %16, align 8, !tbaa !5
  %87 = load ptr, ptr %16, align 8, !tbaa !5
  %88 = icmp eq ptr %87, null
  br i1 %88, label %89, label %91

89:                                               ; preds = %76
  %90 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  store i64 -9223372036854775799, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

91:                                               ; preds = %76
  %92 = load ptr, ptr %14, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct._EFI_BLOCK_IO_PROTOCOL, ptr %92, i32 0, i32 3
  %94 = load ptr, ptr %93, align 8, !tbaa !27
  %95 = load ptr, ptr %14, align 8, !tbaa !5
  %96 = load ptr, ptr %14, align 8, !tbaa !5
  %97 = getelementptr inbounds %struct._EFI_BLOCK_IO_PROTOCOL, ptr %96, i32 0, i32 1
  %98 = load ptr, ptr %97, align 8, !tbaa !22
  %99 = getelementptr inbounds %struct.EFI_BLOCK_IO_MEDIA, ptr %98, i32 0, i32 0
  %100 = load i32, ptr %99, align 8, !tbaa !28
  %101 = load i64, ptr %7, align 8, !tbaa !9
  %102 = load i64, ptr %18, align 8, !tbaa !9
  %103 = load ptr, ptr %16, align 8, !tbaa !5
  %104 = call i64 %94(ptr noundef %95, i32 noundef %100, i64 noundef %101, i64 noundef %102, ptr noundef %103)
  store i64 %104, ptr %15, align 8, !tbaa !9
  %105 = load i64, ptr %15, align 8, !tbaa !9
  %106 = icmp slt i64 %105, 0
  br i1 %106, label %107, label %110

107:                                              ; preds = %91
  %108 = load ptr, ptr %16, align 8, !tbaa !5
  call void @FreePool(ptr noundef %108)
  %109 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  store i64 -9223372036854775807, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

110:                                              ; preds = %91
  %111 = call i64 @HBufferImageFree()
  %112 = load ptr, ptr %16, align 8, !tbaa !5
  %113 = load i64, ptr %18, align 8, !tbaa !9
  %114 = call i64 @HBufferImageBufferToList(ptr noundef %112, i64 noundef %113)
  store i64 %114, ptr %15, align 8, !tbaa !9
  %115 = load ptr, ptr %16, align 8, !tbaa !5
  call void @FreePool(ptr noundef %115)
  %116 = load i64, ptr %15, align 8, !tbaa !9
  %117 = icmp slt i64 %116, 0
  br i1 %117, label %118, label %121

118:                                              ; preds = %110
  %119 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  %120 = load i64, ptr %15, align 8, !tbaa !9
  store i64 %120, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

121:                                              ; preds = %110
  %122 = load ptr, ptr %6, align 8, !tbaa !5
  %123 = load i64, ptr %7, align 8, !tbaa !9
  %124 = load i64, ptr %8, align 8, !tbaa !9
  %125 = call i64 @HDiskImageSetDiskNameOffsetSize(ptr noundef %122, i64 noundef %123, i64 noundef %124)
  store i64 %125, ptr %15, align 8, !tbaa !9
  %126 = load i64, ptr %15, align 8, !tbaa !9
  %127 = icmp slt i64 %126, 0
  br i1 %127, label %128, label %130

128:                                              ; preds = %121
  %129 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  store i64 -9223372036854775799, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

130:                                              ; preds = %121
  %131 = load ptr, ptr %14, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct._EFI_BLOCK_IO_PROTOCOL, ptr %131, i32 0, i32 1
  %133 = load ptr, ptr %132, align 8, !tbaa !22
  %134 = getelementptr inbounds %struct.EFI_BLOCK_IO_MEDIA, ptr %133, i32 0, i32 6
  %135 = load i32, ptr %134, align 4, !tbaa !26
  %136 = zext i32 %135 to i64
  store i64 %136, ptr getelementptr inbounds (%struct.HEFI_EDITOR_DISK_IMAGE, ptr @HDiskImage, i32 0, i32 1), align 8, !tbaa !29
  store i64 2, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 4), align 8, !tbaa !31
  store i64 10, ptr getelementptr inbounds (%struct.HEFI_EDITOR_POSITION, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 4), i32 0, i32 1), align 8, !tbaa !32
  store i64 2, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 5), align 8, !tbaa !33
  store i64 10, ptr getelementptr inbounds (%struct.HEFI_EDITOR_POSITION, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 5), i32 0, i32 1), align 8, !tbaa !34
  store i64 1, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 7), align 8, !tbaa !35
  store i8 1, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 8), align 8, !tbaa !36
  store i64 1, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 6), align 8, !tbaa !37
  store i64 1, ptr getelementptr inbounds (%struct.HEFI_EDITOR_POSITION, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 6), i32 0, i32 1), align 8, !tbaa !38
  %137 = load i8, ptr %9, align 1, !tbaa !11
  %138 = icmp ne i8 %137, 0
  br i1 %138, label %157, label %139

139:                                              ; preds = %130
  %140 = load i64, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 2), align 8, !tbaa !39
  %141 = call ptr (ptr, ptr, ...) @CatSPrint(ptr noundef null, ptr noundef @.str.4, i64 noundef %140)
  store ptr %141, ptr %17, align 8, !tbaa !5
  %142 = load ptr, ptr %17, align 8, !tbaa !5
  %143 = icmp eq ptr %142, null
  br i1 %143, label %144, label %146

144:                                              ; preds = %139
  %145 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  store i64 -9223372036854775799, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

146:                                              ; preds = %139
  %147 = load ptr, ptr %17, align 8, !tbaa !5
  %148 = call i64 @StatusBarSetStatusString(ptr noundef %147)
  br label %149

149:                                              ; preds = %146
  %150 = load ptr, ptr %17, align 8, !tbaa !5
  %151 = icmp ne ptr %150, null
  br i1 %151, label %152, label %154

152:                                              ; preds = %149
  %153 = load ptr, ptr %17, align 8, !tbaa !5
  call void @FreePool(ptr noundef %153)
  store ptr null, ptr %17, align 8, !tbaa !5
  br label %154

154:                                              ; preds = %152, %149
  br label %155

155:                                              ; preds = %154
  br label %156

156:                                              ; preds = %155
  store i64 0, ptr getelementptr inbounds (%struct.HEFI_EDITOR_GLOBAL_EDITOR, ptr @HMainEditor, i32 0, i32 7), align 8, !tbaa !40
  store i64 0, ptr getelementptr inbounds (%struct.HEFI_EDITOR_GLOBAL_EDITOR, ptr @HMainEditor, i32 0, i32 8), align 8, !tbaa !42
  br label %157

157:                                              ; preds = %156, %130
  %158 = load ptr, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 1), align 8, !tbaa !43
  %159 = icmp ne ptr %158, null
  br i1 %159, label %160, label %187

160:                                              ; preds = %157
  %161 = call zeroext i8 @DebugAssertEnabled()
  %162 = zext i8 %161 to i32
  %163 = icmp ne i32 %162, 0
  br i1 %163, label %164, label %178

164:                                              ; preds = %160
  %165 = load ptr, ptr @HBufferImage, align 8, !tbaa !44
  %166 = getelementptr inbounds %struct._LIST_ENTRY, ptr %165, i32 0, i32 0
  %167 = load ptr, ptr %166, align 8, !tbaa !45
  %168 = ptrtoint ptr %167 to i64
  %169 = sub i64 %168, ptrtoint (ptr getelementptr inbounds (%struct._HEFI_EDITOR_LINE, ptr null, i32 0, i32 3) to i64)
  %170 = inttoptr i64 %169 to ptr
  %171 = getelementptr inbounds %struct._HEFI_EDITOR_LINE, ptr %170, i32 0, i32 0
  %172 = load i64, ptr %171, align 8, !tbaa !47
  %173 = icmp ne i64 %172, 1819043173
  br i1 %173, label %174, label %178

174:                                              ; preds = %164
  call void @DebugAssert(ptr noundef @.str.5, i64 noundef 301, ptr noundef @.str.6)
  %175 = load ptr, ptr @HBufferImage, align 8, !tbaa !44
  %176 = getelementptr inbounds %struct._LIST_ENTRY, ptr %175, i32 0, i32 0
  %177 = load ptr, ptr %176, align 8, !tbaa !45
  br label %185

178:                                              ; preds = %164, %160
  %179 = load ptr, ptr @HBufferImage, align 8, !tbaa !44
  %180 = getelementptr inbounds %struct._LIST_ENTRY, ptr %179, i32 0, i32 0
  %181 = load ptr, ptr %180, align 8, !tbaa !45
  %182 = ptrtoint ptr %181 to i64
  %183 = sub i64 %182, ptrtoint (ptr getelementptr inbounds (%struct._HEFI_EDITOR_LINE, ptr null, i32 0, i32 3) to i64)
  %184 = inttoptr i64 %183 to ptr
  br label %185

185:                                              ; preds = %178, %174
  %186 = phi ptr [ %177, %174 ], [ %184, %178 ]
  store ptr %186, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 3), align 8, !tbaa !49
  br label %195

187:                                              ; preds = %157
  %188 = call ptr @HBufferImageCreateLine()
  store ptr %188, ptr %19, align 8, !tbaa !5
  %189 = load ptr, ptr %19, align 8, !tbaa !5
  %190 = icmp eq ptr %189, null
  br i1 %190, label %191, label %193

191:                                              ; preds = %187
  %192 = call i64 @StatusBarSetStatusString(ptr noundef @.str.2)
  store i64 -9223372036854775799, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

193:                                              ; preds = %187
  %194 = load ptr, ptr %19, align 8, !tbaa !5
  store ptr %194, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 3), align 8, !tbaa !49
  br label %195

195:                                              ; preds = %193, %185
  store i8 0, ptr getelementptr inbounds (%struct.HEFI_EDITOR_BUFFER_IMAGE, ptr @HBufferImage, i32 0, i32 9), align 1, !tbaa !50
  store i8 1, ptr @HBufferImageNeedRefresh, align 1, !tbaa !11
  store i8 0, ptr @HBufferImageOnlyLineNeedRefresh, align 1, !tbaa !11
  store i8 1, ptr @HBufferImageMouseNeedRefresh, align 1, !tbaa !11
  store i64 0, ptr %5, align 8
  store i32 1, ptr %20, align 4
  br label %196

196:                                              ; preds = %195, %191, %144, %128, %118, %107, %89, %74, %53, %41, %28
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #3
  %197 = load i64, ptr %5, align 8
  ret i64 %197
}

declare i64 @StatusBarSetStatusString(ptr noundef) #0

declare ptr @DuplicateDevicePath(ptr noundef) #0

declare i64 @HBufferImageFree() #0

declare i64 @HBufferImageBufferToList(ptr noundef, i64 noundef) #0

declare zeroext i8 @DebugAssertEnabled() #0

declare void @DebugAssert(ptr noundef, i64 noundef, ptr noundef) #0

declare ptr @HBufferImageCreateLine() #0

attributes #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 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long long", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !15, i64 92}
!13 = !{!"", !6, i64 0, !6, i64 8, !10, i64 16, !6, i64 24, !14, i64 32, !14, i64 48, !14, i64 64, !10, i64 80, !7, i64 88, !7, i64 89, !15, i64 92, !6, i64 96, !6, i64 104, !6, i64 112}
!14 = !{!"", !10, i64 0, !10, i64 8}
!15 = !{!"int", !7, i64 0}
!16 = !{!17, !6, i64 48}
!17 = !{!"_EFI_SHELL_PROTOCOL", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !15, i64 320, !15, i64 324, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352}
!18 = !{!19, !6, i64 184}
!19 = !{!"", !20, i64 0, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368}
!20 = !{!"", !10, i64 0, !15, i64 8, !15, i64 12, !15, i64 16, !15, i64 20}
!21 = !{!19, !6, i64 280}
!22 = !{!23, !6, i64 8}
!23 = !{!"_EFI_BLOCK_IO_PROTOCOL", !10, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40}
!24 = !{!25, !10, i64 24}
!25 = !{!"", !15, i64 0, !7, i64 4, !7, i64 5, !7, i64 6, !7, i64 7, !7, i64 8, !15, i64 12, !15, i64 16, !10, i64 24, !10, i64 32, !15, i64 40, !15, i64 44}
!26 = !{!25, !15, i64 12}
!27 = !{!23, !6, i64 24}
!28 = !{!25, !15, i64 0}
!29 = !{!30, !10, i64 8}
!30 = !{!"", !6, i64 0, !10, i64 8, !10, i64 16, !10, i64 24}
!31 = !{!13, !10, i64 32}
!32 = !{!13, !10, i64 40}
!33 = !{!13, !10, i64 48}
!34 = !{!13, !10, i64 56}
!35 = !{!13, !10, i64 80}
!36 = !{!13, !7, i64 88}
!37 = !{!13, !10, i64 64}
!38 = !{!13, !10, i64 72}
!39 = !{!13, !10, i64 16}
!40 = !{!41, !10, i64 56}
!41 = !{!"", !6, i64 0, !7, i64 8, !14, i64 16, !7, i64 32, !6, i64 40, !15, i64 48, !15, i64 52, !10, i64 56, !10, i64 64}
!42 = !{!41, !10, i64 64}
!43 = !{!13, !6, i64 8}
!44 = !{!13, !6, i64 0}
!45 = !{!46, !6, i64 0}
!46 = !{!"_LIST_ENTRY", !6, i64 0, !6, i64 8}
!47 = !{!48, !10, i64 0}
!48 = !{!"_HEFI_EDITOR_LINE", !10, i64 0, !7, i64 8, !10, i64 24, !46, i64 32}
!49 = !{!13, !6, i64 24}
!50 = !{!13, !7, i64 89}


; 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.HEFI_EDITOR_DISK_IMAGE = type { ptr, i64, i64, i64 }
%struct.HEFI_EDITOR_BUFFER_IMAGE = type { ptr, ptr, i64, ptr, %struct.HEFI_EDITOR_POSITION, %struct.HEFI_EDITOR_POSITION, %struct.HEFI_EDITOR_POSITION, i64, i8, i8, i32, ptr, ptr, ptr }
%struct.HEFI_EDITOR_POSITION = type { i64, i64 }
%struct.GUID = type { i32, i16, i16, [8 x i8] }
%struct.HEFI_EDITOR_GLOBAL_EDITOR = type { ptr, %union.HEFI_EDITOR_COLOR_UNION, %struct.HEFI_EDITOR_POSITION, i8, ptr, i32, i32, i64, i64 }
%union.HEFI_EDITOR_COLOR_UNION = type { i64 }

@HDiskImage = external dso_local local_unnamed_addr global %struct.HEFI_EDITOR_DISK_IMAGE, align 8
@HBufferImage = external local_unnamed_addr global %struct.HEFI_EDITOR_BUFFER_IMAGE, align 8
@gEfiShellProtocol = external local_unnamed_addr global ptr, align 8
@.str.1 = external hidden unnamed_addr constant [19 x i32], align 4
@gBS = external local_unnamed_addr global ptr, align 8
@gEfiBlockIoProtocolGuid = external global %struct.GUID, align 4
@.str.2 = external hidden unnamed_addr constant [17 x i32], align 4
@gImageHandle = external local_unnamed_addr global ptr, align 8
@.str.3 = external hidden unnamed_addr constant [22 x i32], align 4
@.str.4 = external hidden unnamed_addr constant [14 x i32], align 4
@HMainEditor = external local_unnamed_addr global %struct.HEFI_EDITOR_GLOBAL_EDITOR, align 8
@.str.5 = external hidden unnamed_addr constant [165 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [21 x i8], align 1
@HBufferImageNeedRefresh = external local_unnamed_addr global i8, align 1
@HBufferImageOnlyLineNeedRefresh = external local_unnamed_addr global i8, align 1
@HBufferImageMouseNeedRefresh = external local_unnamed_addr global i8, align 1

declare void @FreePool(ptr noundef) local_unnamed_addr #0

declare ptr @CatSPrint(ptr noundef, ptr noundef, ...) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
declare dso_local i64 @HDiskImageSetDiskNameOffsetSize(ptr noundef, i64 noundef, i64 noundef) local_unnamed_addr #1

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

declare ptr @AllocateZeroPool(i64 noundef) local_unnamed_addr #0

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

; Function Attrs: nounwind uwtable
define dso_local range(i64 -9223372036854775808, 1) i64 @HDiskImageRead(ptr noundef %0, i64 noundef %1, i64 noundef %2, i8 noundef zeroext %3) local_unnamed_addr #1 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #4
  store i32 3, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 92), align 4, !tbaa !5
  %8 = load ptr, ptr @gEfiShellProtocol, align 8, !tbaa !13
  %9 = getelementptr inbounds i8, ptr %8, i64 48
  %10 = load ptr, ptr %9, align 8, !tbaa !14
  %11 = tail call ptr %10(ptr noundef %0) #4
  %12 = icmp eq ptr %11, null
  br i1 %12, label %13, label %15

13:                                               ; preds = %4
  %14 = tail call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.1) #4
  br label %105

15:                                               ; preds = %4
  %16 = tail call ptr @DuplicateDevicePath(ptr noundef nonnull %11) #4
  store ptr %16, ptr %5, align 8, !tbaa !13
  %17 = load ptr, ptr @gBS, align 8, !tbaa !13
  %18 = getelementptr inbounds i8, ptr %17, i64 184
  %19 = load ptr, ptr %18, align 8, !tbaa !16
  %20 = call i64 %19(ptr noundef nonnull @gEfiBlockIoProtocolGuid, ptr noundef nonnull %5, ptr noundef nonnull %6) #4
  call void @FreePool(ptr noundef %16) #4
  %21 = icmp slt i64 %20, 0
  br i1 %21, label %22, label %24

22:                                               ; preds = %15
  %23 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

24:                                               ; preds = %15
  %25 = load ptr, ptr @gBS, align 8, !tbaa !13
  %26 = getelementptr inbounds i8, ptr %25, i64 280
  %27 = load ptr, ptr %26, align 8, !tbaa !19
  %28 = load ptr, ptr %6, align 8, !tbaa !13
  %29 = load ptr, ptr @gImageHandle, align 8, !tbaa !13
  %30 = call i64 %27(ptr noundef %28, ptr noundef nonnull @gEfiBlockIoProtocolGuid, ptr noundef nonnull %7, ptr noundef %29, ptr noundef null, i32 noundef 2) #4
  %31 = icmp slt i64 %30, 0
  br i1 %31, label %32, label %34

32:                                               ; preds = %24
  %33 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

34:                                               ; preds = %24
  %35 = load ptr, ptr %7, align 8, !tbaa !13
  %36 = getelementptr inbounds i8, ptr %35, i64 8
  %37 = load ptr, ptr %36, align 8, !tbaa !20
  %38 = getelementptr inbounds i8, ptr %37, i64 24
  %39 = load i64, ptr %38, align 8, !tbaa !22
  %40 = icmp ult i64 %39, %1
  %41 = add i64 %2, %1
  %42 = icmp ugt i64 %41, %39
  %or.cond = or i1 %40, %42
  br i1 %or.cond, label %43, label %45

43:                                               ; preds = %34
  %44 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.3) #4
  br label %105

45:                                               ; preds = %34
  %46 = getelementptr inbounds i8, ptr %37, i64 12
  %47 = load i32, ptr %46, align 4, !tbaa !24
  %48 = zext i32 %47 to i64
  %49 = mul i64 %48, %2
  %50 = call ptr @AllocateZeroPool(i64 noundef %49) #4
  %51 = icmp eq ptr %50, null
  br i1 %51, label %52, label %54

52:                                               ; preds = %45
  %53 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

54:                                               ; preds = %45
  %55 = load ptr, ptr %7, align 8, !tbaa !13
  %56 = getelementptr inbounds i8, ptr %55, i64 24
  %57 = load ptr, ptr %56, align 8, !tbaa !25
  %58 = getelementptr inbounds i8, ptr %55, i64 8
  %59 = load ptr, ptr %58, align 8, !tbaa !20
  %60 = load i32, ptr %59, align 8, !tbaa !26
  %61 = call i64 %57(ptr noundef %55, i32 noundef %60, i64 noundef %1, i64 noundef %49, ptr noundef nonnull %50) #4
  %62 = icmp slt i64 %61, 0
  br i1 %62, label %63, label %65

63:                                               ; preds = %54
  call void @FreePool(ptr noundef nonnull %50) #4
  %64 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

65:                                               ; preds = %54
  %66 = call i64 @HBufferImageFree() #4
  %67 = call i64 @HBufferImageBufferToList(ptr noundef nonnull %50, i64 noundef %49) #4
  call void @FreePool(ptr noundef nonnull %50) #4
  %68 = icmp slt i64 %67, 0
  br i1 %68, label %69, label %71

69:                                               ; preds = %65
  %70 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

71:                                               ; preds = %65
  %72 = call i64 @HDiskImageSetDiskNameOffsetSize(ptr noundef %0, i64 noundef %1, i64 noundef %2)
  %73 = icmp slt i64 %72, 0
  br i1 %73, label %74, label %76

74:                                               ; preds = %71
  %75 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

76:                                               ; preds = %71
  %77 = load ptr, ptr %7, align 8, !tbaa !13
  %78 = getelementptr inbounds i8, ptr %77, i64 8
  %79 = load ptr, ptr %78, align 8, !tbaa !20
  %80 = getelementptr inbounds i8, ptr %79, i64 12
  %81 = load i32, ptr %80, align 4, !tbaa !24
  %82 = zext i32 %81 to i64
  store i64 %82, ptr getelementptr inbounds (i8, ptr @HDiskImage, i64 8), align 8, !tbaa !27
  store i64 2, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 32), align 8, !tbaa !29
  store i64 10, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 40), align 8, !tbaa !30
  store i64 2, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 48), align 8, !tbaa !31
  store i64 10, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 56), align 8, !tbaa !32
  store i64 1, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 80), align 8, !tbaa !33
  store i8 1, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 88), align 8, !tbaa !34
  store i64 1, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 64), align 8, !tbaa !35
  store i64 1, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 72), align 8, !tbaa !36
  %.not = icmp eq i8 %3, 0
  br i1 %.not, label %83, label %91

83:                                               ; preds = %76
  %84 = load i64, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 16), align 8, !tbaa !37
  %85 = call ptr (ptr, ptr, ...) @CatSPrint(ptr noundef null, ptr noundef nonnull @.str.4, i64 noundef %84) #4
  %86 = icmp eq ptr %85, null
  br i1 %86, label %87, label %89

87:                                               ; preds = %83
  %88 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

89:                                               ; preds = %83
  %90 = call i64 @StatusBarSetStatusString(ptr noundef nonnull %85) #4
  call void @FreePool(ptr noundef nonnull %85) #4
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @HMainEditor, i64 56), i8 0, i64 16, i1 false)
  br label %91

91:                                               ; preds = %89, %76
  %92 = load ptr, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 8), align 8, !tbaa !38
  %.not44 = icmp eq ptr %92, null
  br i1 %.not44, label %100, label %93

93:                                               ; preds = %91
  %94 = call zeroext i8 @DebugAssertEnabled() #4
  %.not45 = icmp eq i8 %94, 0
  %.pre = load ptr, ptr @HBufferImage, align 8, !tbaa !39
  %.pre48 = load ptr, ptr %.pre, align 8, !tbaa !40
  %.pre49 = ptrtoint ptr %.pre48 to i64
  %.pre50 = add i64 %.pre49, -32
  %.pre52 = inttoptr i64 %.pre50 to ptr
  br i1 %.not45, label %._crit_edge, label %95

95:                                               ; preds = %93
  %96 = load i64, ptr %.pre52, align 8, !tbaa !42
  %.not46 = icmp eq i64 %96, 1819043173
  br i1 %.not46, label %._crit_edge, label %97

97:                                               ; preds = %95
  call void @DebugAssert(ptr noundef nonnull @.str.5, i64 noundef 301, ptr noundef nonnull @.str.6) #4
  %98 = load ptr, ptr @HBufferImage, align 8, !tbaa !39
  %99 = load ptr, ptr %98, align 8, !tbaa !40
  br label %._crit_edge

100:                                              ; preds = %91
  %101 = call ptr @HBufferImageCreateLine() #4
  %102 = icmp eq ptr %101, null
  br i1 %102, label %103, label %._crit_edge

103:                                              ; preds = %100
  %104 = call i64 @StatusBarSetStatusString(ptr noundef nonnull @.str.2) #4
  br label %105

._crit_edge:                                      ; preds = %93, %95, %100, %97
  %storemerge = phi ptr [ %99, %97 ], [ %101, %100 ], [ %.pre52, %95 ], [ %.pre52, %93 ]
  store ptr %storemerge, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 24), align 8, !tbaa !44
  store i8 0, ptr getelementptr inbounds (i8, ptr @HBufferImage, i64 89), align 1, !tbaa !45
  store i8 1, ptr @HBufferImageNeedRefresh, align 1, !tbaa !46
  store i8 0, ptr @HBufferImageOnlyLineNeedRefresh, align 1, !tbaa !46
  store i8 1, ptr @HBufferImageMouseNeedRefresh, align 1, !tbaa !46
  br label %105

105:                                              ; preds = %._crit_edge, %103, %87, %74, %69, %63, %52, %43, %32, %22, %13
  %.0 = phi i64 [ -9223372036854775806, %13 ], [ %20, %22 ], [ %30, %32 ], [ -9223372036854775807, %43 ], [ -9223372036854775799, %52 ], [ -9223372036854775807, %63 ], [ %67, %69 ], [ -9223372036854775799, %74 ], [ 0, %._crit_edge ], [ -9223372036854775799, %103 ], [ -9223372036854775799, %87 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  ret i64 %.0
}

declare i64 @StatusBarSetStatusString(ptr noundef) local_unnamed_addr #0

declare ptr @DuplicateDevicePath(ptr noundef) local_unnamed_addr #0

declare i64 @HBufferImageFree() local_unnamed_addr #0

declare i64 @HBufferImageBufferToList(ptr noundef, i64 noundef) local_unnamed_addr #0

declare zeroext i8 @DebugAssertEnabled() local_unnamed_addr #0

declare void @DebugAssert(ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #0

declare ptr @HBufferImageCreateLine() local_unnamed_addr #0

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

attributes #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 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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, !12, i64 92}
!6 = !{!"", !7, i64 0, !7, i64 8, !10, i64 16, !7, i64 24, !11, i64 32, !11, i64 48, !11, i64 64, !10, i64 80, !8, i64 88, !8, i64 89, !12, i64 92, !7, i64 96, !7, i64 104, !7, i64 112}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"long long", !8, i64 0}
!11 = !{!"", !10, i64 0, !10, i64 8}
!12 = !{!"int", !8, i64 0}
!13 = !{!7, !7, i64 0}
!14 = !{!15, !7, i64 48}
!15 = !{!"_EFI_SHELL_PROTOCOL", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !7, i64 216, !7, i64 224, !7, i64 232, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !7, i64 272, !7, i64 280, !7, i64 288, !7, i64 296, !7, i64 304, !7, i64 312, !12, i64 320, !12, i64 324, !7, i64 328, !7, i64 336, !7, i64 344, !7, i64 352}
!16 = !{!17, !7, i64 184}
!17 = !{!"", !18, i64 0, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !7, i64 216, !7, i64 224, !7, i64 232, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !7, i64 272, !7, i64 280, !7, i64 288, !7, i64 296, !7, i64 304, !7, i64 312, !7, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !7, i64 352, !7, i64 360, !7, i64 368}
!18 = !{!"", !10, i64 0, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20}
!19 = !{!17, !7, i64 280}
!20 = !{!21, !7, i64 8}
!21 = !{!"_EFI_BLOCK_IO_PROTOCOL", !10, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40}
!22 = !{!23, !10, i64 24}
!23 = !{!"", !12, i64 0, !8, i64 4, !8, i64 5, !8, i64 6, !8, i64 7, !8, i64 8, !12, i64 12, !12, i64 16, !10, i64 24, !10, i64 32, !12, i64 40, !12, i64 44}
!24 = !{!23, !12, i64 12}
!25 = !{!21, !7, i64 24}
!26 = !{!23, !12, i64 0}
!27 = !{!28, !10, i64 8}
!28 = !{!"", !7, i64 0, !10, i64 8, !10, i64 16, !10, i64 24}
!29 = !{!6, !10, i64 32}
!30 = !{!6, !10, i64 40}
!31 = !{!6, !10, i64 48}
!32 = !{!6, !10, i64 56}
!33 = !{!6, !10, i64 80}
!34 = !{!6, !8, i64 88}
!35 = !{!6, !10, i64 64}
!36 = !{!6, !10, i64 72}
!37 = !{!6, !10, i64 16}
!38 = !{!6, !7, i64 8}
!39 = !{!6, !7, i64 0}
!40 = !{!41, !7, i64 0}
!41 = !{!"_LIST_ENTRY", !7, i64 0, !7, i64 8}
!42 = !{!43, !10, i64 0}
!43 = !{!"_HEFI_EDITOR_LINE", !10, i64 0, !8, i64 8, !10, i64 24, !41, i64 32}
!44 = !{!6, !7, i64 24}
!45 = !{!6, !8, i64 89}
!46 = !{!8, !8, i64 0}


; Effective O3 passes: BDCEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,MemCpyOptPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass