; LLVM IR from thalium/icebox :: third_party/virtualbox/src/VBox/Devices/EFI/Firmware/MdeModulePkg/Universal (PxeIp2Mac)

; 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.SNP_DRIVER = type <{ i32, [4 x i8], %struct.EFI_LOCK, %struct._EFI_SIMPLE_NETWORK_PROTOCOL, %struct.EFI_SIMPLE_NETWORK_MODE, ptr, ptr, ptr, i8, i8, i16, i32, ptr, ptr, ptr, ptr, ptr, ptr, i8, i8, %struct.s_pxe_cdb, [6 x i8], ptr, ptr, ptr, %struct.s_pxe_db_get_init_info, i8, ptr, [100 x %struct.MAP_LIST], ptr, i8, [7 x i8] }>
%struct.EFI_LOCK = type { i64, i64, i32 }
%struct._EFI_SIMPLE_NETWORK_PROTOCOL = type { i64, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.EFI_SIMPLE_NETWORK_MODE = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, [16 x %struct.EFI_MAC_ADDRESS], %struct.EFI_MAC_ADDRESS, %struct.EFI_MAC_ADDRESS, %struct.EFI_MAC_ADDRESS, i8, i8, i8, i8, i8 }
%struct.EFI_MAC_ADDRESS = type { [32 x i8] }
%struct.s_pxe_cdb = type { i16, i16, i16, i16, i64, i64, i16, i16, i16, i16 }
%struct.s_pxe_db_get_init_info = type <{ i32, i32, [4 x i32], i32, i16, i16, i16, i16, i16, i16, i16, i16, i8, i8, i8 }>
%struct.MAP_LIST = type { i64, ptr }
%struct.s_pxe_cpb_mcast_ip_to_mac = type { %union.u_pxe_ip_addr }
%union.u_pxe_ip_addr = type { [4 x i32] }
%struct.s_pxe_db_mcast_ip_to_mac = type { [32 x i8] }

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

; Function Attrs: nounwind uwtable
define dso_local i64 @PxeIp2Mac(ptr noundef %0, i8 noundef zeroext %1, ptr noundef %2, ptr noundef %3) #0 {
  %5 = alloca i64, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i8, align 1
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store i8 %1, ptr %7, align 1, !tbaa !9
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #3
  %13 = load ptr, ptr %6, align 8, !tbaa !5
  %14 = getelementptr inbounds %struct.SNP_DRIVER, ptr %13, i32 0, i32 22
  %15 = load ptr, ptr %14, align 8, !tbaa !10
  store ptr %15, ptr %10, align 8, !tbaa !5
  %16 = load ptr, ptr %6, align 8, !tbaa !5
  %17 = getelementptr inbounds %struct.SNP_DRIVER, ptr %16, i32 0, i32 24
  %18 = load ptr, ptr %17, align 8, !tbaa !21
  store ptr %18, ptr %11, align 8, !tbaa !5
  %19 = load ptr, ptr %6, align 8, !tbaa !5
  %20 = getelementptr inbounds %struct.SNP_DRIVER, ptr %19, i32 0, i32 20
  %21 = getelementptr inbounds %struct.s_pxe_cdb, ptr %20, i32 0, i32 0
  store i16 12, ptr %21, align 2, !tbaa !22
  %22 = load i8, ptr %7, align 1, !tbaa !9
  %23 = zext i8 %22 to i32
  %24 = icmp ne i32 %23, 0
  %25 = zext i1 %24 to i64
  %26 = select i1 %24, i32 1, i32 0
  %27 = trunc i32 %26 to i16
  %28 = load ptr, ptr %6, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.SNP_DRIVER, ptr %28, i32 0, i32 20
  %30 = getelementptr inbounds %struct.s_pxe_cdb, ptr %29, i32 0, i32 1
  store i16 %27, ptr %30, align 2, !tbaa !23
  %31 = load ptr, ptr %6, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct.SNP_DRIVER, ptr %31, i32 0, i32 20
  %33 = getelementptr inbounds %struct.s_pxe_cdb, ptr %32, i32 0, i32 2
  store i16 16, ptr %33, align 2, !tbaa !24
  %34 = load ptr, ptr %6, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.SNP_DRIVER, ptr %34, i32 0, i32 20
  %36 = getelementptr inbounds %struct.s_pxe_cdb, ptr %35, i32 0, i32 3
  store i16 32, ptr %36, align 2, !tbaa !25
  %37 = load ptr, ptr %10, align 8, !tbaa !5
  %38 = ptrtoint ptr %37 to i64
  %39 = load ptr, ptr %6, align 8, !tbaa !5
  %40 = getelementptr inbounds %struct.SNP_DRIVER, ptr %39, i32 0, i32 20
  %41 = getelementptr inbounds %struct.s_pxe_cdb, ptr %40, i32 0, i32 4
  store i64 %38, ptr %41, align 2, !tbaa !26
  %42 = load ptr, ptr %11, align 8, !tbaa !5
  %43 = ptrtoint ptr %42 to i64
  %44 = load ptr, ptr %6, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.SNP_DRIVER, ptr %44, i32 0, i32 20
  %46 = getelementptr inbounds %struct.s_pxe_cdb, ptr %45, i32 0, i32 5
  store i64 %43, ptr %46, align 2, !tbaa !27
  %47 = load ptr, ptr %6, align 8, !tbaa !5
  %48 = getelementptr inbounds %struct.SNP_DRIVER, ptr %47, i32 0, i32 20
  %49 = getelementptr inbounds %struct.s_pxe_cdb, ptr %48, i32 0, i32 6
  store i16 0, ptr %49, align 2, !tbaa !28
  %50 = load ptr, ptr %6, align 8, !tbaa !5
  %51 = getelementptr inbounds %struct.SNP_DRIVER, ptr %50, i32 0, i32 20
  %52 = getelementptr inbounds %struct.s_pxe_cdb, ptr %51, i32 0, i32 7
  store i16 0, ptr %52, align 2, !tbaa !29
  %53 = load ptr, ptr %6, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.SNP_DRIVER, ptr %53, i32 0, i32 10
  %55 = load i16, ptr %54, align 2, !tbaa !30
  %56 = load ptr, ptr %6, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.SNP_DRIVER, ptr %56, i32 0, i32 20
  %58 = getelementptr inbounds %struct.s_pxe_cdb, ptr %57, i32 0, i32 8
  store i16 %55, ptr %58, align 2, !tbaa !31
  %59 = load ptr, ptr %6, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.SNP_DRIVER, ptr %59, i32 0, i32 20
  %61 = getelementptr inbounds %struct.s_pxe_cdb, ptr %60, i32 0, i32 9
  store i16 0, ptr %61, align 2, !tbaa !32
  %62 = load ptr, ptr %10, align 8, !tbaa !5
  %63 = getelementptr inbounds %struct.s_pxe_cpb_mcast_ip_to_mac, ptr %62, i32 0, i32 0
  %64 = load ptr, ptr %8, align 8, !tbaa !5
  %65 = call ptr @CopyMem(ptr noundef %63, ptr noundef %64, i64 noundef 16)
  br label %66

66:                                               ; preds = %4
  %67 = call zeroext i8 @DebugPrintEnabled()
  %68 = icmp ne i8 %67, 0
  br i1 %68, label %69, label %77

69:                                               ; preds = %66
  br label %70

70:                                               ; preds = %69
  %71 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %72 = icmp ne i8 %71, 0
  br i1 %72, label %73, label %74

73:                                               ; preds = %70
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str)
  br label %74

74:                                               ; preds = %73, %70
  br label %75

75:                                               ; preds = %74
  br label %76

76:                                               ; preds = %75
  br label %77

77:                                               ; preds = %76, %66
  br label %78

78:                                               ; preds = %77
  br label %79

79:                                               ; preds = %78
  %80 = load ptr, ptr %6, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.SNP_DRIVER, ptr %80, i32 0, i32 7
  %82 = load ptr, ptr %81, align 8, !tbaa !33
  %83 = load ptr, ptr %6, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.SNP_DRIVER, ptr %83, i32 0, i32 20
  %85 = ptrtoint ptr %84 to i64
  %86 = call i64 %82(i64 noundef %85)
  %87 = load ptr, ptr %6, align 8, !tbaa !5
  %88 = getelementptr inbounds %struct.SNP_DRIVER, ptr %87, i32 0, i32 20
  %89 = getelementptr inbounds %struct.s_pxe_cdb, ptr %88, i32 0, i32 6
  %90 = load i16, ptr %89, align 2, !tbaa !28
  %91 = zext i16 %90 to i32
  switch i32 %91, label %118 [
    i32 0, label %143
    i32 2, label %92
    i32 12, label %93
  ]

92:                                               ; preds = %79
  store i64 -9223372036854775806, ptr %5, align 8
  store i32 1, ptr %12, align 4
  br label %148

93:                                               ; preds = %79
  br label %94

94:                                               ; preds = %93
  %95 = call zeroext i8 @DebugPrintEnabled()
  %96 = icmp ne i8 %95, 0
  br i1 %96, label %97, label %115

97:                                               ; preds = %94
  br label %98

98:                                               ; preds = %97
  %99 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %100 = icmp ne i8 %99, 0
  br i1 %100, label %101, label %112

101:                                              ; preds = %98
  %102 = load ptr, ptr %6, align 8, !tbaa !5
  %103 = getelementptr inbounds %struct.SNP_DRIVER, ptr %102, i32 0, i32 20
  %104 = getelementptr inbounds %struct.s_pxe_cdb, ptr %103, i32 0, i32 7
  %105 = load i16, ptr %104, align 2, !tbaa !29
  %106 = zext i16 %105 to i32
  %107 = load ptr, ptr %6, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.SNP_DRIVER, ptr %107, i32 0, i32 20
  %109 = getelementptr inbounds %struct.s_pxe_cdb, ptr %108, i32 0, i32 6
  %110 = load i16, ptr %109, align 2, !tbaa !28
  %111 = zext i16 %110 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.1, i32 noundef %106, i32 noundef %111)
  br label %112

112:                                              ; preds = %101, %98
  br label %113

113:                                              ; preds = %112
  br label %114

114:                                              ; preds = %113
  br label %115

115:                                              ; preds = %114, %94
  br label %116

116:                                              ; preds = %115
  br label %117

117:                                              ; preds = %116
  store i64 -9223372036854775805, ptr %5, align 8
  store i32 1, ptr %12, align 4
  br label %148

118:                                              ; preds = %79
  br label %119

119:                                              ; preds = %118
  %120 = call zeroext i8 @DebugPrintEnabled()
  %121 = icmp ne i8 %120, 0
  br i1 %121, label %122, label %140

122:                                              ; preds = %119
  br label %123

123:                                              ; preds = %122
  %124 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %125 = icmp ne i8 %124, 0
  br i1 %125, label %126, label %137

126:                                              ; preds = %123
  %127 = load ptr, ptr %6, align 8, !tbaa !5
  %128 = getelementptr inbounds %struct.SNP_DRIVER, ptr %127, i32 0, i32 20
  %129 = getelementptr inbounds %struct.s_pxe_cdb, ptr %128, i32 0, i32 7
  %130 = load i16, ptr %129, align 2, !tbaa !29
  %131 = zext i16 %130 to i32
  %132 = load ptr, ptr %6, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.SNP_DRIVER, ptr %132, i32 0, i32 20
  %134 = getelementptr inbounds %struct.s_pxe_cdb, ptr %133, i32 0, i32 6
  %135 = load i16, ptr %134, align 2, !tbaa !28
  %136 = zext i16 %135 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.1, i32 noundef %131, i32 noundef %136)
  br label %137

137:                                              ; preds = %126, %123
  br label %138

138:                                              ; preds = %137
  br label %139

139:                                              ; preds = %138
  br label %140

140:                                              ; preds = %139, %119
  br label %141

141:                                              ; preds = %140
  br label %142

142:                                              ; preds = %141
  store i64 -9223372036854775801, ptr %5, align 8
  store i32 1, ptr %12, align 4
  br label %148

143:                                              ; preds = %79
  %144 = load ptr, ptr %9, align 8, !tbaa !5
  %145 = load ptr, ptr %11, align 8, !tbaa !5
  %146 = getelementptr inbounds %struct.s_pxe_db_mcast_ip_to_mac, ptr %145, i32 0, i32 0
  %147 = call ptr @CopyMem(ptr noundef %144, ptr noundef %146, i64 noundef 32)
  store i64 0, ptr %5, align 8
  store i32 1, ptr %12, align 4
  br label %148

148:                                              ; preds = %143, %142, %117, %92
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #3
  %149 = load i64, ptr %5, align 8
  ret i64 %149
}

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

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

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) #1

attributes #0 = { 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 #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 = { 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, !6, i64 936}
!11 = !{!"", !12, i64 0, !13, i64 8, !15, i64 32, !16, i64 160, !6, i64 816, !6, i64 824, !6, i64 832, !7, i64 840, !18, i64 842, !12, i64 844, !6, i64 848, !6, i64 856, !6, i64 864, !6, i64 872, !6, i64 880, !6, i64 888, !7, i64 896, !7, i64 897, !19, i64 898, !6, i64 936, !6, i64 944, !6, i64 952, !20, i64 960, !6, i64 1008, !7, i64 1016, !6, i64 2616, !7, i64 2624}
!12 = !{!"int", !7, i64 0}
!13 = !{!"", !14, i64 0, !14, i64 8, !12, i64 16}
!14 = !{!"long long", !7, i64 0}
!15 = !{!"_EFI_SIMPLE_NETWORK_PROTOCOL", !14, 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}
!16 = !{!"", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !7, i64 40, !17, i64 552, !17, i64 584, !17, i64 616, !7, i64 648, !7, i64 649, !7, i64 650, !7, i64 651, !7, i64 652}
!17 = !{!"", !7, i64 0}
!18 = !{!"short", !7, i64 0}
!19 = !{!"s_pxe_cdb", !18, i64 0, !18, i64 2, !18, i64 4, !18, i64 6, !14, i64 8, !14, i64 16, !18, i64 24, !18, i64 26, !18, i64 28, !18, i64 30}
!20 = !{!"s_pxe_db_get_init_info", !12, i64 0, !12, i64 4, !7, i64 8, !12, i64 24, !18, i64 28, !18, i64 30, !18, i64 32, !18, i64 34, !18, i64 36, !18, i64 38, !18, i64 40, !18, i64 42, !7, i64 44, !7, i64 45, !7, i64 46}
!21 = !{!11, !6, i64 952}
!22 = !{!11, !18, i64 898}
!23 = !{!11, !18, i64 900}
!24 = !{!11, !18, i64 902}
!25 = !{!11, !18, i64 904}
!26 = !{!11, !14, i64 906}
!27 = !{!11, !14, i64 914}
!28 = !{!11, !18, i64 922}
!29 = !{!11, !18, i64 924}
!30 = !{!11, !18, i64 842}
!31 = !{!11, !18, i64 926}
!32 = !{!11, !18, i64 928}
!33 = !{!11, !6, i64 832}


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

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

; Function Attrs: nounwind uwtable
define dso_local range(i64 -9223372036854775806, 1) i64 @PxeIp2Mac(ptr noundef %0, i8 noundef zeroext %1, ptr noundef %2, ptr noundef %3) local_unnamed_addr #0 {
  %5 = getelementptr inbounds i8, ptr %0, i64 936
  %6 = load ptr, ptr %5, align 8, !tbaa !5
  %7 = getelementptr inbounds i8, ptr %0, i64 952
  %8 = load ptr, ptr %7, align 8, !tbaa !19
  %9 = getelementptr inbounds i8, ptr %0, i64 898
  store i16 12, ptr %9, align 2, !tbaa !20
  %.not = icmp ne i8 %1, 0
  %10 = zext i1 %.not to i16
  %11 = getelementptr inbounds i8, ptr %0, i64 900
  store i16 %10, ptr %11, align 2, !tbaa !21
  %12 = getelementptr inbounds i8, ptr %0, i64 902
  store i16 16, ptr %12, align 2, !tbaa !22
  %13 = getelementptr inbounds i8, ptr %0, i64 904
  store i16 32, ptr %13, align 2, !tbaa !23
  %14 = ptrtoint ptr %6 to i64
  %15 = getelementptr inbounds i8, ptr %0, i64 906
  store i64 %14, ptr %15, align 2, !tbaa !24
  %16 = ptrtoint ptr %8 to i64
  %17 = getelementptr inbounds i8, ptr %0, i64 914
  store i64 %16, ptr %17, align 2, !tbaa !25
  %18 = getelementptr inbounds i8, ptr %0, i64 922
  store i16 0, ptr %18, align 2, !tbaa !26
  %19 = getelementptr inbounds i8, ptr %0, i64 924
  store i16 0, ptr %19, align 2, !tbaa !27
  %20 = getelementptr inbounds i8, ptr %0, i64 842
  %21 = load i16, ptr %20, align 2, !tbaa !28
  %22 = getelementptr inbounds i8, ptr %0, i64 926
  store i16 %21, ptr %22, align 2, !tbaa !29
  %23 = getelementptr inbounds i8, ptr %0, i64 928
  store i16 0, ptr %23, align 2, !tbaa !30
  %24 = tail call ptr @CopyMem(ptr noundef %6, ptr noundef %2, i64 noundef 16) #2
  %25 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not27 = icmp eq i8 %25, 0
  br i1 %.not27, label %29, label %26

26:                                               ; preds = %4
  %27 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not28 = icmp eq i8 %27, 0
  br i1 %.not28, label %29, label %28

28:                                               ; preds = %26
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str) #2
  br label %29

29:                                               ; preds = %26, %28, %4
  %30 = getelementptr inbounds i8, ptr %0, i64 832
  %31 = load ptr, ptr %30, align 8, !tbaa !31
  %32 = ptrtoint ptr %9 to i64
  %33 = tail call i64 %31(i64 noundef %32) #2
  %34 = load i16, ptr %18, align 2, !tbaa !26
  switch i16 %34, label %44 [
    i16 0, label %53
    i16 2, label %55
    i16 12, label %35
  ]

35:                                               ; preds = %29
  %36 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not29 = icmp eq i8 %36, 0
  br i1 %.not29, label %55, label %37

37:                                               ; preds = %35
  %38 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not30 = icmp eq i8 %38, 0
  br i1 %.not30, label %55, label %39

39:                                               ; preds = %37
  %40 = load i16, ptr %19, align 2, !tbaa !27
  %41 = zext i16 %40 to i32
  %42 = load i16, ptr %18, align 2, !tbaa !26
  %43 = zext i16 %42 to i32
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.1, i32 noundef %41, i32 noundef %43) #2
  br label %55

44:                                               ; preds = %29
  %45 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not31 = icmp eq i8 %45, 0
  br i1 %.not31, label %55, label %46

46:                                               ; preds = %44
  %47 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not32 = icmp eq i8 %47, 0
  br i1 %.not32, label %55, label %48

48:                                               ; preds = %46
  %49 = load i16, ptr %19, align 2, !tbaa !27
  %50 = zext i16 %49 to i32
  %51 = load i16, ptr %18, align 2, !tbaa !26
  %52 = zext i16 %51 to i32
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.1, i32 noundef %50, i32 noundef %52) #2
  br label %55

53:                                               ; preds = %29
  %54 = tail call ptr @CopyMem(ptr noundef %3, ptr noundef %8, i64 noundef 32) #2
  br label %55

55:                                               ; preds = %44, %48, %46, %35, %39, %37, %29, %53
  %.0 = phi i64 [ 0, %53 ], [ -9223372036854775806, %29 ], [ -9223372036854775805, %37 ], [ -9223372036854775805, %39 ], [ -9223372036854775805, %35 ], [ -9223372036854775801, %46 ], [ -9223372036854775801, %48 ], [ -9223372036854775801, %44 ]
  ret i64 %.0
}

declare ptr @CopyMem(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #1

declare zeroext i8 @DebugPrintEnabled() local_unnamed_addr #1

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

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

attributes #0 = { 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 #1 = { "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 = { 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, !13, i64 936}
!6 = !{!"", !7, i64 0, !10, i64 8, !12, i64 32, !14, i64 160, !13, i64 816, !13, i64 824, !13, i64 832, !8, i64 840, !16, i64 842, !7, i64 844, !13, i64 848, !13, i64 856, !13, i64 864, !13, i64 872, !13, i64 880, !13, i64 888, !8, i64 896, !8, i64 897, !17, i64 898, !13, i64 936, !13, i64 944, !13, i64 952, !18, i64 960, !13, i64 1008, !8, i64 1016, !13, i64 2616, !8, i64 2624}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"", !11, i64 0, !11, i64 8, !7, i64 16}
!11 = !{!"long long", !8, i64 0}
!12 = !{!"_EFI_SIMPLE_NETWORK_PROTOCOL", !11, i64 0, !13, i64 8, !13, i64 16, !13, i64 24, !13, i64 32, !13, i64 40, !13, i64 48, !13, i64 56, !13, i64 64, !13, i64 72, !13, i64 80, !13, i64 88, !13, i64 96, !13, i64 104, !13, i64 112, !13, i64 120}
!13 = !{!"any pointer", !8, i64 0}
!14 = !{!"", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28, !7, i64 32, !7, i64 36, !8, i64 40, !15, i64 552, !15, i64 584, !15, i64 616, !8, i64 648, !8, i64 649, !8, i64 650, !8, i64 651, !8, i64 652}
!15 = !{!"", !8, i64 0}
!16 = !{!"short", !8, i64 0}
!17 = !{!"s_pxe_cdb", !16, i64 0, !16, i64 2, !16, i64 4, !16, i64 6, !11, i64 8, !11, i64 16, !16, i64 24, !16, i64 26, !16, i64 28, !16, i64 30}
!18 = !{!"s_pxe_db_get_init_info", !7, i64 0, !7, i64 4, !8, i64 8, !7, i64 24, !16, i64 28, !16, i64 30, !16, i64 32, !16, i64 34, !16, i64 36, !16, i64 38, !16, i64 40, !16, i64 42, !8, i64 44, !8, i64 45, !8, i64 46}
!19 = !{!6, !13, i64 952}
!20 = !{!6, !16, i64 898}
!21 = !{!6, !16, i64 900}
!22 = !{!6, !16, i64 902}
!23 = !{!6, !16, i64 904}
!24 = !{!6, !11, i64 906}
!25 = !{!6, !11, i64 914}
!26 = !{!6, !16, i64 922}
!27 = !{!6, !16, i64 924}
!28 = !{!6, !16, i64 842}
!29 = !{!6, !16, i64 926}
!30 = !{!6, !16, i64 928}
!31 = !{!6, !13, i64 832}


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