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

; 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_db_get_status = type { i32, i32, [32 x i64] }

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

; Function Attrs: nounwind uwtable
define dso_local i64 @PxeGetStatus(ptr noundef %0, ptr noundef %1, ptr noundef %2) #0 {
  %4 = alloca i64, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i16, align 2
  %10 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr %9) #3
  %11 = load ptr, ptr %5, align 8, !tbaa !5
  %12 = getelementptr inbounds %struct.SNP_DRIVER, ptr %11, i32 0, i32 24
  %13 = load ptr, ptr %12, align 8, !tbaa !9
  store ptr %13, ptr %8, align 8, !tbaa !5
  %14 = load ptr, ptr %5, align 8, !tbaa !5
  %15 = getelementptr inbounds %struct.SNP_DRIVER, ptr %14, i32 0, i32 20
  %16 = getelementptr inbounds %struct.s_pxe_cdb, ptr %15, i32 0, i32 0
  store i16 14, ptr %16, align 2, !tbaa !20
  %17 = load ptr, ptr %5, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.SNP_DRIVER, ptr %17, i32 0, i32 20
  %19 = getelementptr inbounds %struct.s_pxe_cdb, ptr %18, i32 0, i32 1
  store i16 0, ptr %19, align 2, !tbaa !21
  %20 = load ptr, ptr %7, align 8, !tbaa !5
  %21 = icmp ne ptr %20, null
  br i1 %21, label %22, label %30

22:                                               ; preds = %3
  %23 = load ptr, ptr %5, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.SNP_DRIVER, ptr %23, i32 0, i32 20
  %25 = getelementptr inbounds %struct.s_pxe_cdb, ptr %24, i32 0, i32 1
  %26 = load i16, ptr %25, align 2, !tbaa !21
  %27 = zext i16 %26 to i32
  %28 = or i32 %27, 2
  %29 = trunc i32 %28 to i16
  store i16 %29, ptr %25, align 2, !tbaa !21
  br label %30

30:                                               ; preds = %22, %3
  %31 = load ptr, ptr %6, align 8, !tbaa !5
  %32 = icmp ne ptr %31, null
  br i1 %32, label %33, label %41

33:                                               ; preds = %30
  %34 = load ptr, ptr %5, 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 1
  %37 = load i16, ptr %36, align 2, !tbaa !21
  %38 = zext i16 %37 to i32
  %39 = or i32 %38, 1
  %40 = trunc i32 %39 to i16
  store i16 %40, ptr %36, align 2, !tbaa !21
  br label %41

41:                                               ; preds = %33, %30
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.SNP_DRIVER, ptr %42, i32 0, i32 30
  %44 = load i8, ptr %43, align 8, !tbaa !22
  %45 = icmp ne i8 %44, 0
  br i1 %45, label %46, label %54

46:                                               ; preds = %41
  %47 = load ptr, ptr %5, 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 1
  %50 = load i16, ptr %49, align 2, !tbaa !21
  %51 = zext i16 %50 to i32
  %52 = or i32 %51, 4
  %53 = trunc i32 %52 to i16
  store i16 %53, ptr %49, align 2, !tbaa !21
  br label %54

54:                                               ; preds = %46, %41
  %55 = load ptr, ptr %5, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.SNP_DRIVER, ptr %55, i32 0, i32 20
  %57 = getelementptr inbounds %struct.s_pxe_cdb, ptr %56, i32 0, i32 2
  store i16 0, ptr %57, align 2, !tbaa !23
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.SNP_DRIVER, ptr %58, i32 0, i32 20
  %60 = getelementptr inbounds %struct.s_pxe_cdb, ptr %59, i32 0, i32 4
  store i64 0, ptr %60, align 2, !tbaa !24
  %61 = load ptr, ptr %5, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.SNP_DRIVER, ptr %61, i32 0, i32 20
  %63 = getelementptr inbounds %struct.s_pxe_cdb, ptr %62, i32 0, i32 3
  store i16 16, ptr %63, align 2, !tbaa !25
  %64 = load ptr, ptr %8, align 8, !tbaa !5
  %65 = ptrtoint ptr %64 to i64
  %66 = load ptr, ptr %5, align 8, !tbaa !5
  %67 = getelementptr inbounds %struct.SNP_DRIVER, ptr %66, i32 0, i32 20
  %68 = getelementptr inbounds %struct.s_pxe_cdb, ptr %67, i32 0, i32 5
  store i64 %65, ptr %68, align 2, !tbaa !26
  %69 = load ptr, ptr %5, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.SNP_DRIVER, ptr %69, i32 0, i32 20
  %71 = getelementptr inbounds %struct.s_pxe_cdb, ptr %70, i32 0, i32 6
  store i16 0, ptr %71, align 2, !tbaa !27
  %72 = load ptr, ptr %5, align 8, !tbaa !5
  %73 = getelementptr inbounds %struct.SNP_DRIVER, ptr %72, i32 0, i32 20
  %74 = getelementptr inbounds %struct.s_pxe_cdb, ptr %73, i32 0, i32 7
  store i16 0, ptr %74, align 2, !tbaa !28
  %75 = load ptr, ptr %5, align 8, !tbaa !5
  %76 = getelementptr inbounds %struct.SNP_DRIVER, ptr %75, i32 0, i32 10
  %77 = load i16, ptr %76, align 2, !tbaa !29
  %78 = load ptr, ptr %5, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct.SNP_DRIVER, ptr %78, i32 0, i32 20
  %80 = getelementptr inbounds %struct.s_pxe_cdb, ptr %79, i32 0, i32 8
  store i16 %77, ptr %80, align 2, !tbaa !30
  %81 = load ptr, ptr %5, align 8, !tbaa !5
  %82 = getelementptr inbounds %struct.SNP_DRIVER, ptr %81, i32 0, i32 20
  %83 = getelementptr inbounds %struct.s_pxe_cdb, ptr %82, i32 0, i32 9
  store i16 0, ptr %83, align 2, !tbaa !31
  br label %84

84:                                               ; preds = %54
  %85 = call zeroext i8 @DebugPrintEnabled()
  %86 = icmp ne i8 %85, 0
  br i1 %86, label %87, label %95

87:                                               ; preds = %84
  br label %88

88:                                               ; preds = %87
  %89 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %90 = icmp ne i8 %89, 0
  br i1 %90, label %91, label %92

91:                                               ; preds = %88
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str)
  br label %92

92:                                               ; preds = %91, %88
  br label %93

93:                                               ; preds = %92
  br label %94

94:                                               ; preds = %93
  br label %95

95:                                               ; preds = %94, %84
  br label %96

96:                                               ; preds = %95
  br label %97

97:                                               ; preds = %96
  %98 = load ptr, ptr %5, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct.SNP_DRIVER, ptr %98, i32 0, i32 7
  %100 = load ptr, ptr %99, align 8, !tbaa !32
  %101 = load ptr, ptr %5, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.SNP_DRIVER, ptr %101, i32 0, i32 20
  %103 = ptrtoint ptr %102 to i64
  %104 = call i64 %100(i64 noundef %103)
  %105 = load ptr, ptr %5, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.SNP_DRIVER, ptr %105, i32 0, i32 20
  %107 = getelementptr inbounds %struct.s_pxe_cdb, ptr %106, i32 0, i32 6
  %108 = load i16, ptr %107, align 2, !tbaa !27
  %109 = zext i16 %108 to i32
  %110 = icmp ne i32 %109, 0
  br i1 %110, label %111, label %136

111:                                              ; preds = %97
  br label %112

112:                                              ; preds = %111
  %113 = call zeroext i8 @DebugPrintEnabled()
  %114 = icmp ne i8 %113, 0
  br i1 %114, label %115, label %133

115:                                              ; preds = %112
  br label %116

116:                                              ; preds = %115
  %117 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %118 = icmp ne i8 %117, 0
  br i1 %118, label %119, label %130

119:                                              ; preds = %116
  %120 = load ptr, ptr %5, align 8, !tbaa !5
  %121 = getelementptr inbounds %struct.SNP_DRIVER, ptr %120, i32 0, i32 20
  %122 = getelementptr inbounds %struct.s_pxe_cdb, ptr %121, i32 0, i32 7
  %123 = load i16, ptr %122, align 2, !tbaa !28
  %124 = zext i16 %123 to i32
  %125 = load ptr, ptr %5, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct.SNP_DRIVER, ptr %125, i32 0, i32 20
  %127 = getelementptr inbounds %struct.s_pxe_cdb, ptr %126, i32 0, i32 7
  %128 = load i16, ptr %127, align 2, !tbaa !28
  %129 = zext i16 %128 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.1, i32 noundef %124, i32 noundef %129)
  br label %130

130:                                              ; preds = %119, %116
  br label %131

131:                                              ; preds = %130
  br label %132

132:                                              ; preds = %131
  br label %133

133:                                              ; preds = %132, %112
  br label %134

134:                                              ; preds = %133
  br label %135

135:                                              ; preds = %134
  store i64 -9223372036854775801, ptr %4, align 8
  store i32 1, ptr %10, align 4
  br label %235

136:                                              ; preds = %97
  %137 = load ptr, ptr %6, align 8, !tbaa !5
  %138 = icmp ne ptr %137, null
  br i1 %138, label %139, label %184

139:                                              ; preds = %136
  %140 = load ptr, ptr %5, align 8, !tbaa !5
  %141 = getelementptr inbounds %struct.SNP_DRIVER, ptr %140, i32 0, i32 20
  %142 = getelementptr inbounds %struct.s_pxe_cdb, ptr %141, i32 0, i32 7
  %143 = load i16, ptr %142, align 2, !tbaa !28
  %144 = zext i16 %143 to i32
  %145 = and i32 %144, 15
  %146 = trunc i32 %145 to i16
  store i16 %146, ptr %9, align 2, !tbaa !33
  %147 = load ptr, ptr %6, align 8, !tbaa !5
  store i32 0, ptr %147, align 4, !tbaa !34
  %148 = load i16, ptr %9, align 2, !tbaa !33
  %149 = zext i16 %148 to i32
  %150 = and i32 %149, 1
  %151 = icmp eq i32 %150, 1
  br i1 %151, label %152, label %156

152:                                              ; preds = %139
  %153 = load ptr, ptr %6, align 8, !tbaa !5
  %154 = load i32, ptr %153, align 4, !tbaa !34
  %155 = or i32 %154, 1
  store i32 %155, ptr %153, align 4, !tbaa !34
  br label %156

156:                                              ; preds = %152, %139
  %157 = load i16, ptr %9, align 2, !tbaa !33
  %158 = zext i16 %157 to i32
  %159 = and i32 %158, 2
  %160 = icmp eq i32 %159, 2
  br i1 %160, label %161, label %165

161:                                              ; preds = %156
  %162 = load ptr, ptr %6, align 8, !tbaa !5
  %163 = load i32, ptr %162, align 4, !tbaa !34
  %164 = or i32 %163, 2
  store i32 %164, ptr %162, align 4, !tbaa !34
  br label %165

165:                                              ; preds = %161, %156
  %166 = load i16, ptr %9, align 2, !tbaa !33
  %167 = zext i16 %166 to i32
  %168 = and i32 %167, 4
  %169 = icmp eq i32 %168, 4
  br i1 %169, label %170, label %174

170:                                              ; preds = %165
  %171 = load ptr, ptr %6, align 8, !tbaa !5
  %172 = load i32, ptr %171, align 4, !tbaa !34
  %173 = or i32 %172, 4
  store i32 %173, ptr %171, align 4, !tbaa !34
  br label %174

174:                                              ; preds = %170, %165
  %175 = load i16, ptr %9, align 2, !tbaa !33
  %176 = zext i16 %175 to i32
  %177 = and i32 %176, 8
  %178 = icmp eq i32 %177, 8
  br i1 %178, label %179, label %183

179:                                              ; preds = %174
  %180 = load ptr, ptr %6, align 8, !tbaa !5
  %181 = load i32, ptr %180, align 4, !tbaa !34
  %182 = or i32 %181, 4
  store i32 %182, ptr %180, align 4, !tbaa !34
  br label %183

183:                                              ; preds = %179, %174
  br label %184

184:                                              ; preds = %183, %136
  %185 = load ptr, ptr %7, align 8, !tbaa !5
  %186 = icmp ne ptr %185, null
  br i1 %186, label %187, label %213

187:                                              ; preds = %184
  %188 = load ptr, ptr %5, align 8, !tbaa !5
  %189 = getelementptr inbounds %struct.SNP_DRIVER, ptr %188, i32 0, i32 20
  %190 = getelementptr inbounds %struct.s_pxe_cdb, ptr %189, i32 0, i32 7
  %191 = load i16, ptr %190, align 2, !tbaa !28
  %192 = zext i16 %191 to i32
  %193 = and i32 %192, 32
  %194 = icmp ne i32 %193, 0
  br i1 %194, label %203, label %195

195:                                              ; preds = %187
  %196 = load ptr, ptr %5, align 8, !tbaa !5
  %197 = getelementptr inbounds %struct.SNP_DRIVER, ptr %196, i32 0, i32 20
  %198 = getelementptr inbounds %struct.s_pxe_cdb, ptr %197, i32 0, i32 7
  %199 = load i16, ptr %198, align 2, !tbaa !28
  %200 = zext i16 %199 to i32
  %201 = and i32 %200, 16
  %202 = icmp ne i32 %201, 0
  br i1 %202, label %203, label %204

203:                                              ; preds = %195, %187
  br label %210

204:                                              ; preds = %195
  %205 = load ptr, ptr %8, align 8, !tbaa !5
  %206 = getelementptr inbounds %struct.s_pxe_db_get_status, ptr %205, i32 0, i32 2
  %207 = getelementptr inbounds [32 x i64], ptr %206, i64 0, i64 0
  %208 = load i64, ptr %207, align 1, !tbaa !35
  %209 = inttoptr i64 %208 to ptr
  br label %210

210:                                              ; preds = %204, %203
  %211 = phi ptr [ null, %203 ], [ %209, %204 ]
  %212 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %211, ptr %212, align 8, !tbaa !5
  br label %213

213:                                              ; preds = %210, %184
  %214 = load ptr, ptr %5, align 8, !tbaa !5
  %215 = getelementptr inbounds %struct.SNP_DRIVER, ptr %214, i32 0, i32 30
  %216 = load i8, ptr %215, align 8, !tbaa !22
  %217 = icmp ne i8 %216, 0
  br i1 %217, label %218, label %234

218:                                              ; preds = %213
  %219 = load ptr, ptr %5, align 8, !tbaa !5
  %220 = getelementptr inbounds %struct.SNP_DRIVER, ptr %219, i32 0, i32 20
  %221 = getelementptr inbounds %struct.s_pxe_cdb, ptr %220, i32 0, i32 7
  %222 = load i16, ptr %221, align 2, !tbaa !28
  %223 = zext i16 %222 to i32
  %224 = and i32 %223, 64
  %225 = icmp ne i32 %224, 0
  %226 = zext i1 %225 to i64
  %227 = select i1 %225, i32 0, i32 1
  %228 = trunc i32 %227 to i8
  %229 = load ptr, ptr %5, align 8, !tbaa !5
  %230 = getelementptr inbounds %struct.SNP_DRIVER, ptr %229, i32 0, i32 3
  %231 = getelementptr inbounds %struct._EFI_SIMPLE_NETWORK_PROTOCOL, ptr %230, i32 0, i32 15
  %232 = load ptr, ptr %231, align 8, !tbaa !36
  %233 = getelementptr inbounds %struct.EFI_SIMPLE_NETWORK_MODE, ptr %232, i32 0, i32 18
  store i8 %228, ptr %233, align 4, !tbaa !37
  br label %234

234:                                              ; preds = %218, %213
  store i64 0, ptr %4, align 8
  store i32 1, ptr %10, align 4
  br label %235

235:                                              ; preds = %234, %135
  call void @llvm.lifetime.end.p0(i64 2, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #3
  %236 = load i64, ptr %4, align 8
  ret i64 %236
}

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

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


; 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 [26 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [34 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local range(i64 -9223372036854775801, 1) i64 @PxeGetStatus(ptr noundef %0, ptr noundef writeonly %1, ptr noundef writeonly %2) local_unnamed_addr #0 {
  %4 = getelementptr inbounds i8, ptr %0, i64 952
  %5 = load ptr, ptr %4, align 8, !tbaa !5
  %6 = getelementptr inbounds i8, ptr %0, i64 898
  store i16 14, ptr %6, align 2, !tbaa !19
  %7 = getelementptr inbounds i8, ptr %0, i64 900
  %.not = icmp eq ptr %2, null
  %spec.select = select i1 %.not, i16 0, i16 2
  %.not45 = icmp ne ptr %1, null
  %8 = zext i1 %.not45 to i16
  %spec.select63 = or disjoint i16 %spec.select, %8
  store i16 %spec.select63, ptr %7, align 2, !tbaa !20
  %9 = getelementptr inbounds i8, ptr %0, i64 2624
  %10 = load i8, ptr %9, align 8, !tbaa !21
  %.not46 = icmp eq i8 %10, 0
  br i1 %.not46, label %13, label %11

11:                                               ; preds = %3
  %12 = or disjoint i16 %spec.select63, 4
  store i16 %12, ptr %7, align 2, !tbaa !20
  br label %13

13:                                               ; preds = %11, %3
  %14 = getelementptr inbounds i8, ptr %0, i64 902
  store i16 0, ptr %14, align 2, !tbaa !22
  %15 = getelementptr inbounds i8, ptr %0, i64 906
  store i64 0, ptr %15, align 2, !tbaa !23
  %16 = getelementptr inbounds i8, ptr %0, i64 904
  store i16 16, ptr %16, align 2, !tbaa !24
  %17 = ptrtoint ptr %5 to i64
  %18 = getelementptr inbounds i8, ptr %0, i64 914
  store i64 %17, ptr %18, align 2, !tbaa !25
  %19 = getelementptr inbounds i8, ptr %0, i64 922
  store i16 0, ptr %19, align 2, !tbaa !26
  %20 = getelementptr inbounds i8, ptr %0, i64 924
  store i16 0, ptr %20, align 2, !tbaa !27
  %21 = getelementptr inbounds i8, ptr %0, i64 842
  %22 = load i16, ptr %21, align 2, !tbaa !28
  %23 = getelementptr inbounds i8, ptr %0, i64 926
  store i16 %22, ptr %23, align 2, !tbaa !29
  %24 = getelementptr inbounds i8, ptr %0, i64 928
  store i16 0, ptr %24, align 2, !tbaa !30
  %25 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not47 = icmp eq i8 %25, 0
  br i1 %.not47, label %29, label %26

26:                                               ; preds = %13
  %27 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not48 = icmp eq i8 %27, 0
  br i1 %.not48, 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, %13
  %30 = getelementptr inbounds i8, ptr %0, i64 832
  %31 = load ptr, ptr %30, align 8, !tbaa !31
  %32 = ptrtoint ptr %6 to i64
  %33 = tail call i64 %31(i64 noundef %32) #2
  %34 = load i16, ptr %19, align 2, !tbaa !26
  %.not49 = icmp eq i16 %34, 0
  br i1 %.not49, label %42, label %35

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

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

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

42:                                               ; preds = %29
  br i1 %.not45, label %43, label %49

43:                                               ; preds = %42
  %44 = load i16, ptr %20, align 2, !tbaa !27
  %45 = and i16 %44, 8
  %46 = and i16 %44, 7
  %spec.select65 = zext nneg i16 %46 to i32
  store i32 %spec.select65, ptr %1, align 4, !tbaa !32
  %.not54.not.not = icmp eq i16 %45, 0
  br i1 %.not54.not.not, label %49, label %47

47:                                               ; preds = %43
  %48 = or i32 %spec.select65, 4
  store i32 %48, ptr %1, align 4, !tbaa !32
  br label %49

49:                                               ; preds = %43, %47, %42
  br i1 %.not, label %59, label %50

50:                                               ; preds = %49
  %51 = load i16, ptr %20, align 2, !tbaa !27
  %52 = and i16 %51, 48
  %or.cond = icmp eq i16 %52, 0
  br i1 %or.cond, label %53, label %57

53:                                               ; preds = %50
  %54 = getelementptr inbounds i8, ptr %5, i64 8
  %55 = load i64, ptr %54, align 1, !tbaa !33
  %56 = inttoptr i64 %55 to ptr
  br label %57

57:                                               ; preds = %50, %53
  %58 = phi ptr [ %56, %53 ], [ null, %50 ]
  store ptr %58, ptr %2, align 8, !tbaa !34
  br label %59

59:                                               ; preds = %57, %49
  %60 = load i8, ptr %9, align 8, !tbaa !21
  %.not57 = icmp eq i8 %60, 0
  br i1 %.not57, label %68, label %61

61:                                               ; preds = %59
  %62 = load i16, ptr %20, align 2, !tbaa !27
  %63 = and i16 %62, 64
  %.not58 = icmp eq i16 %63, 0
  %64 = zext i1 %.not58 to i8
  %65 = getelementptr inbounds i8, ptr %0, i64 152
  %66 = load ptr, ptr %65, align 8, !tbaa !35
  %67 = getelementptr inbounds i8, ptr %66, i64 652
  store i8 %64, ptr %67, align 4, !tbaa !36
  br label %68

68:                                               ; preds = %59, %61, %35, %39, %37
  %.0 = phi i64 [ -9223372036854775801, %37 ], [ -9223372036854775801, %39 ], [ -9223372036854775801, %35 ], [ 0, %61 ], [ 0, %59 ]
  ret i64 %.0
}

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 952}
!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, !16, i64 898}
!20 = !{!6, !16, i64 900}
!21 = !{!6, !8, i64 2624}
!22 = !{!6, !16, i64 902}
!23 = !{!6, !11, i64 906}
!24 = !{!6, !16, i64 904}
!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}
!32 = !{!7, !7, i64 0}
!33 = !{!11, !11, i64 0}
!34 = !{!13, !13, i64 0}
!35 = !{!6, !13, i64 152}
!36 = !{!14, !8, i64 652}


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