; LLVM IR from thalium/icebox :: third_party/virtualbox/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg (Int13GetDeviceParameters)

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

%union.EFI_IA32_REGISTER_SET = type { %struct.EFI_DWORD_REGS }
%struct.EFI_DWORD_REGS = type { i32, i32, i32, i32, i32, i32, %struct.EFI_EFLAGS_REG, i16, i16, i16, i16, i16, i16, i32, i32 }
%struct.EFI_EFLAGS_REG = type { i32 }
%struct.EFI_BYTE_REGS = type { i8, i8, i16, i8, i8, i16, i8, i8, i16, i8, i8, i16 }
%struct.BIOS_LEGACY_DRIVE = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, ptr, i8, i8, i8, i8, i16, i16, %struct.EDD_DRIVE_PARAMETERS }
%struct.EDD_DRIVE_PARAMETERS = type <{ i16, i16, i32, i32, i32, i64, i16, i32, i16, i8, i8, i16, [4 x i8], [8 x i8], %union.EDD_INTERFACE_PATH, %union.EDD_DEVICE_PATH, i8, i8 }>
%union.EDD_INTERFACE_PATH = type { %struct.EDD_PCI }
%struct.EDD_PCI = type { i8, i8, i8, i8, i32 }
%union.EDD_DEVICE_PATH = type { %struct.EDD_USB }
%struct.EDD_USB = type { i64, i64 }
%struct.BIOS_BLOCK_IO_DEV = type { i64, ptr, ptr, %struct._EFI_BLOCK_IO_PROTOCOL, %struct.EFI_BLOCK_IO_MEDIA, ptr, ptr, ptr, %struct.BIOS_LEGACY_DRIVE }
%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._EFI_LEGACY_BIOS_PROTOCOL = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }

@.str.1 = external hidden unnamed_addr constant [61 x i8], align 1

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

; Function Attrs: nounwind uwtable
define dso_local i64 @Int13GetDeviceParameters(ptr noundef %0, ptr noundef %1) #1 {
  %3 = alloca i64, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %7 = alloca i16, align 2
  %8 = alloca %union.EFI_IA32_REGISTER_SET, align 4
  %9 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr %7) #3
  call void @llvm.lifetime.start.p0(i64 48, ptr %8) #3
  %10 = call ptr @ZeroMem(ptr noundef %8, i64 noundef 48)
  %11 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 1
  store i8 8, ptr %11, align 1, !tbaa !9
  %12 = load ptr, ptr %5, align 8, !tbaa !5
  %13 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %12, i32 0, i32 1
  %14 = load i8, ptr %13, align 1, !tbaa !10
  %15 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 9
  store i8 %14, ptr %15, align 4, !tbaa !9
  %16 = load ptr, ptr %4, align 8, !tbaa !5
  %17 = getelementptr inbounds %struct.BIOS_BLOCK_IO_DEV, ptr %16, i32 0, i32 7
  %18 = load ptr, ptr %17, align 8, !tbaa !16
  %19 = getelementptr inbounds %struct._EFI_LEGACY_BIOS_PROTOCOL, ptr %18, i32 0, i32 0
  %20 = load ptr, ptr %19, align 8, !tbaa !20
  %21 = load ptr, ptr %4, align 8, !tbaa !5
  %22 = getelementptr inbounds %struct.BIOS_BLOCK_IO_DEV, ptr %21, i32 0, i32 7
  %23 = load ptr, ptr %22, align 8, !tbaa !16
  %24 = call zeroext i8 %20(ptr noundef %23, i8 noundef zeroext 19, ptr noundef %8)
  %25 = zext i8 %24 to i64
  store i64 %25, ptr %6, align 8, !tbaa !22
  br label %26

26:                                               ; preds = %2
  %27 = call zeroext i8 @DebugPrintEnabled()
  %28 = icmp ne i8 %27, 0
  br i1 %28, label %29, label %45

29:                                               ; preds = %26
  br label %30

30:                                               ; preds = %29
  %31 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 1)
  %32 = icmp ne i8 %31, 0
  br i1 %32, label %33, label %42

33:                                               ; preds = %30
  %34 = load ptr, ptr %5, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %34, i32 0, i32 1
  %36 = load i8, ptr %35, align 1, !tbaa !10
  %37 = zext i8 %36 to i32
  %38 = load i64, ptr %6, align 8, !tbaa !22
  %39 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 1
  %40 = load i8, ptr %39, align 1, !tbaa !9
  %41 = zext i8 %40 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 1, ptr noundef @.str.1, i32 noundef %37, i64 noundef %38, i32 noundef %41)
  br label %42

42:                                               ; preds = %33, %30
  br label %43

43:                                               ; preds = %42
  br label %44

44:                                               ; preds = %43
  br label %45

45:                                               ; preds = %44, %26
  br label %46

46:                                               ; preds = %45
  br label %47

47:                                               ; preds = %46
  %48 = load i64, ptr %6, align 8, !tbaa !22
  %49 = icmp ne i64 %48, 0
  br i1 %49, label %55, label %50

50:                                               ; preds = %47
  %51 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 1
  %52 = load i8, ptr %51, align 1, !tbaa !9
  %53 = zext i8 %52 to i32
  %54 = icmp ne i32 %53, 0
  br i1 %54, label %55, label %60

55:                                               ; preds = %50, %47
  %56 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 1
  %57 = load i8, ptr %56, align 1, !tbaa !9
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %58, i32 0, i32 8
  store i8 %57, ptr %59, align 8, !tbaa !23
  store i64 0, ptr %3, align 8
  store i32 1, ptr %9, align 4
  br label %137

60:                                               ; preds = %50
  %61 = load ptr, ptr %5, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %61, i32 0, i32 10
  %63 = load i8, ptr %62, align 8, !tbaa !24
  %64 = icmp ne i8 %63, 0
  br i1 %64, label %65, label %95

65:                                               ; preds = %60
  %66 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 3
  %67 = load i8, ptr %66, align 4, !tbaa !9
  %68 = zext i8 %67 to i32
  %69 = icmp eq i32 %68, 16
  br i1 %69, label %70, label %73

70:                                               ; preds = %65
  %71 = load ptr, ptr %5, align 8, !tbaa !5
  %72 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %71, i32 0, i32 11
  store i8 1, ptr %72, align 1, !tbaa !25
  br label %94

73:                                               ; preds = %65
  %74 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 10
  %75 = load i8, ptr %74, align 1, !tbaa !9
  %76 = load ptr, ptr %5, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %76, i32 0, i32 12
  store i8 %75, ptr %77, align 2, !tbaa !26
  %78 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 6
  %79 = load i8, ptr %78, align 4, !tbaa !9
  %80 = load ptr, ptr %5, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %80, i32 0, i32 13
  store i8 %79, ptr %81, align 1, !tbaa !27
  %82 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 7
  %83 = load i8, ptr %82, align 1, !tbaa !9
  %84 = zext i8 %83 to i16
  %85 = load ptr, ptr %5, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %85, i32 0, i32 14
  store i16 %84, ptr %86, align 4, !tbaa !28
  %87 = load ptr, ptr %5, align 8, !tbaa !5
  %88 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %87, i32 0, i32 13
  %89 = load i8, ptr %88, align 1, !tbaa !27
  %90 = zext i8 %89 to i32
  %91 = icmp eq i32 %90, 0
  br i1 %91, label %92, label %93

92:                                               ; preds = %73
  store i64 0, ptr %3, align 8
  store i32 1, ptr %9, align 4
  br label %137

93:                                               ; preds = %73
  br label %94

94:                                               ; preds = %93, %70
  br label %136

95:                                               ; preds = %60
  %96 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 10
  %97 = load i8, ptr %96, align 1, !tbaa !9
  %98 = zext i8 %97 to i32
  %99 = and i32 %98, 63
  %100 = trunc i32 %99 to i8
  %101 = load ptr, ptr %5, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %101, i32 0, i32 12
  store i8 %100, ptr %102, align 2, !tbaa !26
  %103 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 10
  %104 = load i8, ptr %103, align 1, !tbaa !9
  %105 = zext i8 %104 to i16
  %106 = zext i16 %105 to i32
  %107 = and i32 %106, 192
  %108 = shl i32 %107, 4
  %109 = trunc i32 %108 to i16
  store i16 %109, ptr %7, align 2, !tbaa !29
  %110 = load i16, ptr %7, align 2, !tbaa !29
  %111 = zext i16 %110 to i32
  %112 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 6
  %113 = load i8, ptr %112, align 4, !tbaa !9
  %114 = zext i8 %113 to i16
  %115 = zext i16 %114 to i32
  %116 = and i32 %115, 192
  %117 = shl i32 %116, 2
  %118 = or i32 %111, %117
  %119 = trunc i32 %118 to i16
  store i16 %119, ptr %7, align 2, !tbaa !29
  %120 = load i16, ptr %7, align 2, !tbaa !29
  %121 = zext i16 %120 to i32
  %122 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 7
  %123 = load i8, ptr %122, align 1, !tbaa !9
  %124 = zext i8 %123 to i32
  %125 = add nsw i32 %121, %124
  %126 = trunc i32 %125 to i16
  %127 = load ptr, ptr %5, align 8, !tbaa !5
  %128 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %127, i32 0, i32 14
  store i16 %126, ptr %128, align 4, !tbaa !28
  %129 = getelementptr inbounds %struct.EFI_BYTE_REGS, ptr %8, i32 0, i32 6
  %130 = load i8, ptr %129, align 4, !tbaa !9
  %131 = zext i8 %130 to i32
  %132 = and i32 %131, 63
  %133 = trunc i32 %132 to i8
  %134 = load ptr, ptr %5, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.BIOS_LEGACY_DRIVE, ptr %134, i32 0, i32 13
  store i8 %133, ptr %135, align 1, !tbaa !27
  br label %136

136:                                              ; preds = %95, %94
  store i64 1, ptr %3, align 8
  store i32 1, ptr %9, align 4
  br label %137

137:                                              ; preds = %136, %92, %55
  call void @llvm.lifetime.end.p0(i64 48, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #3
  %138 = load i64, ptr %3, align 8
  ret i64 %138
}

declare zeroext i8 @DebugPrintEnabled() #2

declare zeroext i8 @DebugPrintLevelEnabled(i64 noundef) #2

declare void @DebugPrint(i64 noundef, ptr noundef, ...) #2

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

declare ptr @ZeroMem(ptr noundef, i64 noundef) #2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 = { 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 = !{!7, !7, i64 0}
!10 = !{!11, !7, i64 1}
!11 = !{!"", !7, i64 0, !7, i64 1, !7, i64 2, !7, i64 3, !7, i64 4, !7, i64 5, !7, i64 6, !7, i64 7, !7, i64 8, !6, i64 16, !7, i64 24, !7, i64 25, !7, i64 26, !7, i64 27, !12, i64 28, !12, i64 30, !13, i64 32}
!12 = !{!"short", !7, i64 0}
!13 = !{!"", !12, i64 0, !12, i64 2, !14, i64 4, !14, i64 8, !14, i64 12, !15, i64 16, !12, i64 24, !14, i64 26, !12, i64 30, !7, i64 32, !7, i64 33, !12, i64 34, !7, i64 36, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 72, !7, i64 73}
!14 = !{!"int", !7, i64 0}
!15 = !{!"long long", !7, i64 0}
!16 = !{!17, !6, i64 136}
!17 = !{!"", !15, i64 0, !6, i64 8, !6, i64 16, !18, i64 24, !19, i64 72, !6, i64 120, !6, i64 128, !6, i64 136, !11, i64 144}
!18 = !{!"_EFI_BLOCK_IO_PROTOCOL", !15, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40}
!19 = !{!"", !14, i64 0, !7, i64 4, !7, i64 5, !7, i64 6, !7, i64 7, !7, i64 8, !14, i64 12, !14, i64 16, !15, i64 24, !15, i64 32, !14, i64 40, !14, i64 44}
!20 = !{!21, !6, i64 0}
!21 = !{!"_EFI_LEGACY_BIOS_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}
!22 = !{!15, !15, i64 0}
!23 = !{!11, !7, i64 8}
!24 = !{!11, !7, i64 24}
!25 = !{!11, !7, i64 25}
!26 = !{!11, !7, i64 26}
!27 = !{!11, !7, i64 27}
!28 = !{!11, !12, i64 28}
!29 = !{!12, !12, i64 0}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%union.EFI_IA32_REGISTER_SET = type { %struct.EFI_DWORD_REGS }
%struct.EFI_DWORD_REGS = type { i32, i32, i32, i32, i32, i32, %struct.EFI_EFLAGS_REG, i16, i16, i16, i16, i16, i16, i32, i32 }
%struct.EFI_EFLAGS_REG = type { i32 }

@.str.1 = external hidden unnamed_addr constant [61 x i8], align 1

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

; Function Attrs: nounwind uwtable
define dso_local range(i64 0, 2) i64 @Int13GetDeviceParameters(ptr nocapture noundef readonly %0, ptr nocapture noundef %1) local_unnamed_addr #1 {
  %3 = alloca %union.EFI_IA32_REGISTER_SET, align 4
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %3) #3
  %4 = call ptr @ZeroMem(ptr noundef nonnull %3, i64 noundef 48) #3
  %5 = getelementptr inbounds i8, ptr %3, i64 1
  store i8 8, ptr %5, align 1, !tbaa !5
  %6 = getelementptr inbounds i8, ptr %1, i64 1
  %7 = load i8, ptr %6, align 1, !tbaa !8
  %8 = getelementptr inbounds i8, ptr %3, i64 12
  store i8 %7, ptr %8, align 4, !tbaa !5
  %9 = getelementptr inbounds i8, ptr %0, i64 136
  %10 = load ptr, ptr %9, align 8, !tbaa !15
  %11 = load ptr, ptr %10, align 8, !tbaa !19
  %12 = call zeroext i8 %11(ptr noundef nonnull %10, i8 noundef zeroext 19, ptr noundef nonnull %3) #3
  %13 = zext i8 %12 to i64
  %14 = call zeroext i8 @DebugPrintEnabled() #3
  %.not = icmp eq i8 %14, 0
  br i1 %.not, label %22, label %15

15:                                               ; preds = %2
  %16 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 1) #3
  %.not21 = icmp eq i8 %16, 0
  br i1 %.not21, label %22, label %17

17:                                               ; preds = %15
  %18 = load i8, ptr %6, align 1, !tbaa !8
  %19 = zext i8 %18 to i32
  %20 = load i8, ptr %5, align 1, !tbaa !5
  %21 = zext i8 %20 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 1, ptr noundef nonnull @.str.1, i32 noundef %19, i64 noundef %13, i32 noundef %21) #3
  br label %22

22:                                               ; preds = %15, %17, %2
  %23 = icmp ne i8 %12, 0
  %24 = load i8, ptr %5, align 1
  %25 = icmp ne i8 %24, 0
  %or.cond = select i1 %23, i1 true, i1 %25
  br i1 %or.cond, label %26, label %28

26:                                               ; preds = %22
  %27 = getelementptr inbounds i8, ptr %1, i64 8
  store i8 %24, ptr %27, align 8, !tbaa !21
  br label %69

28:                                               ; preds = %22
  %29 = getelementptr inbounds i8, ptr %1, i64 24
  %30 = load i8, ptr %29, align 8, !tbaa !22
  %.not22 = icmp eq i8 %30, 0
  br i1 %.not22, label %47, label %31

31:                                               ; preds = %28
  %32 = getelementptr inbounds i8, ptr %3, i64 4
  %33 = load i8, ptr %32, align 4, !tbaa !5
  %34 = icmp eq i8 %33, 16
  br i1 %34, label %.sink.split, label %35

35:                                               ; preds = %31
  %36 = getelementptr inbounds i8, ptr %3, i64 13
  %37 = load i8, ptr %36, align 1, !tbaa !5
  %38 = getelementptr inbounds i8, ptr %1, i64 26
  store i8 %37, ptr %38, align 2, !tbaa !23
  %39 = getelementptr inbounds i8, ptr %3, i64 8
  %40 = load i8, ptr %39, align 4, !tbaa !5
  %41 = getelementptr inbounds i8, ptr %1, i64 27
  store i8 %40, ptr %41, align 1, !tbaa !24
  %42 = getelementptr inbounds i8, ptr %3, i64 9
  %43 = load i8, ptr %42, align 1, !tbaa !5
  %44 = zext i8 %43 to i16
  %45 = getelementptr inbounds i8, ptr %1, i64 28
  store i16 %44, ptr %45, align 4, !tbaa !25
  %46 = icmp eq i8 %40, 0
  br i1 %46, label %69, label %68

47:                                               ; preds = %28
  %48 = getelementptr inbounds i8, ptr %3, i64 13
  %49 = load i8, ptr %48, align 1, !tbaa !5
  %50 = and i8 %49, 63
  %51 = getelementptr inbounds i8, ptr %1, i64 26
  store i8 %50, ptr %51, align 2, !tbaa !23
  %52 = and i8 %49, -64
  %53 = zext i8 %52 to i16
  %54 = shl nuw nsw i16 %53, 4
  %55 = getelementptr inbounds i8, ptr %3, i64 8
  %56 = load i8, ptr %55, align 4, !tbaa !5
  %57 = and i8 %56, -64
  %58 = zext i8 %57 to i16
  %59 = shl nuw nsw i16 %58, 2
  %60 = or disjoint i16 %59, %54
  %61 = getelementptr inbounds i8, ptr %3, i64 9
  %62 = load i8, ptr %61, align 1, !tbaa !5
  %63 = zext i8 %62 to i16
  %64 = or disjoint i16 %60, %63
  %65 = getelementptr inbounds i8, ptr %1, i64 28
  store i16 %64, ptr %65, align 4, !tbaa !25
  %66 = and i8 %56, 63
  br label %.sink.split

.sink.split:                                      ; preds = %31, %47
  %.sink24 = phi i64 [ 27, %47 ], [ 25, %31 ]
  %.sink = phi i8 [ %66, %47 ], [ 1, %31 ]
  %67 = getelementptr inbounds i8, ptr %1, i64 %.sink24
  store i8 %.sink, ptr %67, align 1, !tbaa !5
  br label %68

68:                                               ; preds = %.sink.split, %35
  br label %69

69:                                               ; preds = %35, %68, %26
  %.0 = phi i64 [ 0, %26 ], [ 1, %68 ], [ 0, %35 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %3) #3
  ret i64 %.0
}

declare zeroext i8 @DebugPrintEnabled() local_unnamed_addr #2

declare zeroext i8 @DebugPrintLevelEnabled(i64 noundef) local_unnamed_addr #2

declare void @DebugPrint(i64 noundef, ptr noundef, ...) local_unnamed_addr #2

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

declare ptr @ZeroMem(ptr noundef, i64 noundef) local_unnamed_addr #2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 = { 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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C/C++ TBAA"}
!8 = !{!9, !6, i64 1}
!9 = !{!"", !6, i64 0, !6, i64 1, !6, i64 2, !6, i64 3, !6, i64 4, !6, i64 5, !6, i64 6, !6, i64 7, !6, i64 8, !10, i64 16, !6, i64 24, !6, i64 25, !6, i64 26, !6, i64 27, !11, i64 28, !11, i64 30, !12, i64 32}
!10 = !{!"any pointer", !6, i64 0}
!11 = !{!"short", !6, i64 0}
!12 = !{!"", !11, i64 0, !11, i64 2, !13, i64 4, !13, i64 8, !13, i64 12, !14, i64 16, !11, i64 24, !13, i64 26, !11, i64 30, !6, i64 32, !6, i64 33, !11, i64 34, !6, i64 36, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 72, !6, i64 73}
!13 = !{!"int", !6, i64 0}
!14 = !{!"long long", !6, i64 0}
!15 = !{!16, !10, i64 136}
!16 = !{!"", !14, i64 0, !10, i64 8, !10, i64 16, !17, i64 24, !18, i64 72, !10, i64 120, !10, i64 128, !10, i64 136, !9, i64 144}
!17 = !{!"_EFI_BLOCK_IO_PROTOCOL", !14, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40}
!18 = !{!"", !13, i64 0, !6, i64 4, !6, i64 5, !6, i64 6, !6, i64 7, !6, i64 8, !13, i64 12, !13, i64 16, !14, i64 24, !14, i64 32, !13, i64 40, !13, i64 44}
!19 = !{!20, !10, i64 0}
!20 = !{!"_EFI_LEGACY_BIOS_PROTOCOL", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88}
!21 = !{!9, !6, i64 8}
!22 = !{!9, !6, i64 24}
!23 = !{!9, !6, i64 26}
!24 = !{!9, !6, i64 27}
!25 = !{!9, !11, i64 28}


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