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

; 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_transmit = type { i64, i32, i16, i16 }

@.str.2 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [32 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

declare zeroext i8 @DebugPrintEnabled() #1

declare zeroext i8 @DebugPrintLevelEnabled(i64 noundef) #1

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

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

; Function Attrs: nounwind uwtable
define dso_local i64 @PxeTransmit(ptr noundef %0, ptr noundef %1, i64 noundef %2) #2 {
  %4 = alloca i64, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store i64 %2, ptr %7, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #3
  %11 = load ptr, ptr %5, align 8, !tbaa !5
  %12 = getelementptr inbounds %struct.SNP_DRIVER, ptr %11, i32 0, i32 22
  %13 = load ptr, ptr %12, align 8, !tbaa !11
  store ptr %13, ptr %8, align 8, !tbaa !5
  %14 = load ptr, ptr %6, align 8, !tbaa !5
  %15 = ptrtoint ptr %14 to i64
  %16 = load ptr, ptr %8, align 8, !tbaa !5
  %17 = getelementptr inbounds %struct.s_pxe_cpb_transmit, ptr %16, i32 0, i32 0
  store i64 %15, ptr %17, align 1, !tbaa !21
  %18 = load i64, ptr %7, align 8, !tbaa !9
  %19 = trunc i64 %18 to i32
  %20 = load ptr, ptr %8, align 8, !tbaa !5
  %21 = getelementptr inbounds %struct.s_pxe_cpb_transmit, ptr %20, i32 0, i32 1
  store i32 %19, ptr %21, align 1, !tbaa !23
  %22 = load ptr, ptr %8, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct.s_pxe_cpb_transmit, ptr %22, i32 0, i32 2
  store i16 0, ptr %23, align 1, !tbaa !24
  %24 = load ptr, ptr %8, align 8, !tbaa !5
  %25 = getelementptr inbounds %struct.s_pxe_cpb_transmit, ptr %24, i32 0, i32 3
  store i16 0, ptr %25, align 1, !tbaa !25
  %26 = load ptr, ptr %5, align 8, !tbaa !5
  %27 = getelementptr inbounds %struct.SNP_DRIVER, ptr %26, i32 0, i32 20
  %28 = getelementptr inbounds %struct.s_pxe_cdb, ptr %27, i32 0, i32 1
  store i16 0, ptr %28, align 2, !tbaa !26
  %29 = load ptr, ptr %5, align 8, !tbaa !5
  %30 = getelementptr inbounds %struct.SNP_DRIVER, ptr %29, i32 0, i32 20
  %31 = getelementptr inbounds %struct.s_pxe_cdb, ptr %30, i32 0, i32 2
  store i16 16, ptr %31, align 2, !tbaa !27
  %32 = load ptr, ptr %8, align 8, !tbaa !5
  %33 = ptrtoint ptr %32 to i64
  %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 4
  store i64 %33, ptr %36, align 2, !tbaa !28
  %37 = load ptr, ptr %5, align 8, !tbaa !5
  %38 = getelementptr inbounds %struct.SNP_DRIVER, ptr %37, i32 0, i32 20
  %39 = getelementptr inbounds %struct.s_pxe_cdb, ptr %38, i32 0, i32 0
  store i16 16, ptr %39, align 2, !tbaa !29
  %40 = load ptr, ptr %5, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.SNP_DRIVER, ptr %40, i32 0, i32 20
  %42 = getelementptr inbounds %struct.s_pxe_cdb, ptr %41, i32 0, i32 3
  store i16 0, ptr %42, align 2, !tbaa !30
  %43 = load ptr, ptr %5, align 8, !tbaa !5
  %44 = getelementptr inbounds %struct.SNP_DRIVER, ptr %43, i32 0, i32 20
  %45 = getelementptr inbounds %struct.s_pxe_cdb, ptr %44, i32 0, i32 5
  store i64 0, ptr %45, align 2, !tbaa !31
  %46 = load ptr, ptr %5, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.SNP_DRIVER, ptr %46, i32 0, i32 20
  %48 = getelementptr inbounds %struct.s_pxe_cdb, ptr %47, i32 0, i32 6
  store i16 0, ptr %48, align 2, !tbaa !32
  %49 = load ptr, ptr %5, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.SNP_DRIVER, ptr %49, i32 0, i32 20
  %51 = getelementptr inbounds %struct.s_pxe_cdb, ptr %50, i32 0, i32 7
  store i16 0, ptr %51, align 2, !tbaa !33
  %52 = load ptr, ptr %5, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.SNP_DRIVER, ptr %52, i32 0, i32 10
  %54 = load i16, ptr %53, align 2, !tbaa !34
  %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 8
  store i16 %54, ptr %57, align 2, !tbaa !35
  %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 9
  store i16 0, ptr %60, align 2, !tbaa !36
  br label %61

61:                                               ; preds = %3
  %62 = call zeroext i8 @DebugPrintEnabled()
  %63 = icmp ne i8 %62, 0
  br i1 %63, label %64, label %72

64:                                               ; preds = %61
  br label %65

65:                                               ; preds = %64
  %66 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %67 = icmp ne i8 %66, 0
  br i1 %67, label %68, label %69

68:                                               ; preds = %65
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.2)
  br label %69

69:                                               ; preds = %68, %65
  br label %70

70:                                               ; preds = %69
  br label %71

71:                                               ; preds = %70
  br label %72

72:                                               ; preds = %71, %61
  br label %73

73:                                               ; preds = %72
  br label %74

74:                                               ; preds = %73
  br label %75

75:                                               ; preds = %74
  %76 = call zeroext i8 @DebugPrintEnabled()
  %77 = icmp ne i8 %76, 0
  br i1 %77, label %78, label %91

78:                                               ; preds = %75
  br label %79

79:                                               ; preds = %78
  %80 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %81 = icmp ne i8 %80, 0
  br i1 %81, label %82, label %88

82:                                               ; preds = %79
  %83 = load ptr, ptr %5, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.SNP_DRIVER, ptr %83, i32 0, i32 20
  %85 = getelementptr inbounds %struct.s_pxe_cdb, ptr %84, i32 0, i32 0
  %86 = load i16, ptr %85, align 2, !tbaa !29
  %87 = zext i16 %86 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.3, i32 noundef %87)
  br label %88

88:                                               ; preds = %82, %79
  br label %89

89:                                               ; preds = %88
  br label %90

90:                                               ; preds = %89
  br label %91

91:                                               ; preds = %90, %75
  br label %92

92:                                               ; preds = %91
  br label %93

93:                                               ; preds = %92
  br label %94

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

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 %106

101:                                              ; preds = %98
  %102 = load ptr, ptr %5, 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 4
  %105 = load i64, ptr %104, align 2, !tbaa !28
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.4, i64 noundef %105)
  br label %106

106:                                              ; preds = %101, %98
  br label %107

107:                                              ; preds = %106
  br label %108

108:                                              ; preds = %107
  br label %109

109:                                              ; preds = %108, %94
  br label %110

110:                                              ; preds = %109
  br label %111

111:                                              ; preds = %110
  br label %112

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

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 %124

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 5
  %123 = load i64, ptr %122, align 2, !tbaa !31
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.5, i64 noundef %123)
  br label %124

124:                                              ; preds = %119, %116
  br label %125

125:                                              ; preds = %124
  br label %126

126:                                              ; preds = %125
  br label %127

127:                                              ; preds = %126, %112
  br label %128

128:                                              ; preds = %127
  br label %129

129:                                              ; preds = %128
  br label %130

130:                                              ; preds = %129
  %131 = call zeroext i8 @DebugPrintEnabled()
  %132 = icmp ne i8 %131, 0
  br i1 %132, label %133, label %144

133:                                              ; preds = %130
  br label %134

134:                                              ; preds = %133
  %135 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %136 = icmp ne i8 %135, 0
  br i1 %136, label %137, label %141

137:                                              ; preds = %134
  %138 = load ptr, ptr %8, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.s_pxe_cpb_transmit, ptr %138, i32 0, i32 0
  %140 = load i64, ptr %139, align 1, !tbaa !21
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.6, i64 noundef %140)
  br label %141

141:                                              ; preds = %137, %134
  br label %142

142:                                              ; preds = %141
  br label %143

143:                                              ; preds = %142
  br label %144

144:                                              ; preds = %143, %130
  br label %145

145:                                              ; preds = %144
  br label %146

146:                                              ; preds = %145
  %147 = load ptr, ptr %5, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.SNP_DRIVER, ptr %147, i32 0, i32 7
  %149 = load ptr, ptr %148, align 8, !tbaa !37
  %150 = load ptr, ptr %5, align 8, !tbaa !5
  %151 = getelementptr inbounds %struct.SNP_DRIVER, ptr %150, i32 0, i32 20
  %152 = ptrtoint ptr %151 to i64
  %153 = call i64 %149(i64 noundef %152)
  br label %154

154:                                              ; preds = %146
  %155 = call zeroext i8 @DebugPrintEnabled()
  %156 = icmp ne i8 %155, 0
  br i1 %156, label %157, label %165

157:                                              ; preds = %154
  br label %158

158:                                              ; preds = %157
  %159 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %160 = icmp ne i8 %159, 0
  br i1 %160, label %161, label %162

161:                                              ; preds = %158
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.7)
  br label %162

162:                                              ; preds = %161, %158
  br label %163

163:                                              ; preds = %162
  br label %164

164:                                              ; preds = %163
  br label %165

165:                                              ; preds = %164, %154
  br label %166

166:                                              ; preds = %165
  br label %167

167:                                              ; preds = %166
  br label %168

168:                                              ; preds = %167
  %169 = call zeroext i8 @DebugPrintEnabled()
  %170 = icmp ne i8 %169, 0
  br i1 %170, label %171, label %184

171:                                              ; preds = %168
  br label %172

172:                                              ; preds = %171
  %173 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384)
  %174 = icmp ne i8 %173, 0
  br i1 %174, label %175, label %181

175:                                              ; preds = %172
  %176 = load ptr, ptr %5, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct.SNP_DRIVER, ptr %176, i32 0, i32 20
  %178 = getelementptr inbounds %struct.s_pxe_cdb, ptr %177, i32 0, i32 6
  %179 = load i16, ptr %178, align 2, !tbaa !32
  %180 = zext i16 %179 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef @.str.8, i32 noundef %180)
  br label %181

181:                                              ; preds = %175, %172
  br label %182

182:                                              ; preds = %181
  br label %183

183:                                              ; preds = %182
  br label %184

184:                                              ; preds = %183, %168
  br label %185

185:                                              ; preds = %184
  br label %186

186:                                              ; preds = %185
  %187 = load ptr, ptr %5, align 8, !tbaa !5
  %188 = getelementptr inbounds %struct.SNP_DRIVER, ptr %187, i32 0, i32 20
  %189 = getelementptr inbounds %struct.s_pxe_cdb, ptr %188, i32 0, i32 6
  %190 = load i16, ptr %189, align 2, !tbaa !32
  %191 = zext i16 %190 to i32
  switch i32 %191, label %194 [
    i32 0, label %192
    i32 4, label %193
    i32 3, label %193
  ]

192:                                              ; preds = %186
  store i64 0, ptr %4, align 8
  store i32 1, ptr %10, align 4
  br label %221

193:                                              ; preds = %186, %186
  store i64 -9223372036854775802, ptr %9, align 8, !tbaa !9
  br label %195

194:                                              ; preds = %186
  store i64 -9223372036854775801, ptr %9, align 8, !tbaa !9
  br label %195

195:                                              ; preds = %194, %193
  br label %196

196:                                              ; preds = %195
  %197 = call zeroext i8 @DebugPrintEnabled()
  %198 = icmp ne i8 %197, 0
  br i1 %198, label %199, label %217

199:                                              ; preds = %196
  br label %200

200:                                              ; preds = %199
  %201 = call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 2147483648)
  %202 = icmp ne i8 %201, 0
  br i1 %202, label %203, label %214

203:                                              ; preds = %200
  %204 = load ptr, ptr %5, align 8, !tbaa !5
  %205 = getelementptr inbounds %struct.SNP_DRIVER, ptr %204, i32 0, i32 20
  %206 = getelementptr inbounds %struct.s_pxe_cdb, ptr %205, i32 0, i32 7
  %207 = load i16, ptr %206, align 2, !tbaa !33
  %208 = zext i16 %207 to i32
  %209 = load ptr, ptr %5, align 8, !tbaa !5
  %210 = getelementptr inbounds %struct.SNP_DRIVER, ptr %209, i32 0, i32 20
  %211 = getelementptr inbounds %struct.s_pxe_cdb, ptr %210, i32 0, i32 6
  %212 = load i16, ptr %211, align 2, !tbaa !32
  %213 = zext i16 %212 to i32
  call void (i64, ptr, ...) @DebugPrint(i64 noundef 2147483648, ptr noundef @.str.9, i32 noundef %208, i32 noundef %213)
  br label %214

214:                                              ; preds = %203, %200
  br label %215

215:                                              ; preds = %214
  br label %216

216:                                              ; preds = %215
  br label %217

217:                                              ; preds = %216, %196
  br label %218

218:                                              ; preds = %217
  br label %219

219:                                              ; preds = %218
  %220 = load i64, ptr %9, align 8, !tbaa !9
  store i64 %220, ptr %4, align 8
  store i32 1, ptr %10, align 4
  br label %221

221:                                              ; preds = %219, %192
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #3
  %222 = load i64, ptr %4, align 8
  ret i64 %222
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 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 #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 = !{!12, !6, i64 936}
!12 = !{!"", !13, i64 0, !14, i64 8, !15, i64 32, !16, i64 160, !6, i64 816, !6, i64 824, !6, i64 832, !7, i64 840, !18, i64 842, !13, 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}
!13 = !{!"int", !7, i64 0}
!14 = !{!"", !10, i64 0, !10, i64 8, !13, i64 16}
!15 = !{!"_EFI_SIMPLE_NETWORK_PROTOCOL", !10, 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 = !{!"", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !13, i64 24, !13, i64 28, !13, i64 32, !13, 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, !10, i64 8, !10, i64 16, !18, i64 24, !18, i64 26, !18, i64 28, !18, i64 30}
!20 = !{!"s_pxe_db_get_init_info", !13, i64 0, !13, i64 4, !7, i64 8, !13, 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 = !{!22, !10, i64 0}
!22 = !{!"s_pxe_cpb_transmit", !10, i64 0, !13, i64 8, !18, i64 12, !18, i64 14}
!23 = !{!22, !13, i64 8}
!24 = !{!22, !18, i64 12}
!25 = !{!22, !18, i64 14}
!26 = !{!12, !18, i64 900}
!27 = !{!12, !18, i64 902}
!28 = !{!12, !10, i64 906}
!29 = !{!12, !18, i64 898}
!30 = !{!12, !18, i64 904}
!31 = !{!12, !10, i64 914}
!32 = !{!12, !18, i64 922}
!33 = !{!12, !18, i64 924}
!34 = !{!12, !18, i64 842}
!35 = !{!12, !18, i64 926}
!36 = !{!12, !18, i64 928}
!37 = !{!12, !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.2 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [32 x i8], align 1

declare zeroext i8 @DebugPrintEnabled() local_unnamed_addr #0

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

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

; Function Attrs: nounwind uwtable
define dso_local range(i64 -9223372036854775802, 1) i64 @PxeTransmit(ptr noundef %0, ptr noundef %1, i64 noundef %2) local_unnamed_addr #1 {
  %4 = getelementptr inbounds i8, ptr %0, i64 936
  %5 = load ptr, ptr %4, align 8, !tbaa !5
  %6 = ptrtoint ptr %1 to i64
  store i64 %6, ptr %5, align 1, !tbaa !19
  %7 = trunc i64 %2 to i32
  %8 = getelementptr inbounds i8, ptr %5, i64 8
  store i32 %7, ptr %8, align 1, !tbaa !21
  %9 = getelementptr inbounds i8, ptr %5, i64 12
  store i16 0, ptr %9, align 1, !tbaa !22
  %10 = getelementptr inbounds i8, ptr %5, i64 14
  store i16 0, ptr %10, align 1, !tbaa !23
  %11 = getelementptr inbounds i8, ptr %0, i64 898
  %12 = ptrtoint ptr %5 to i64
  %13 = getelementptr inbounds i8, ptr %0, i64 906
  store i64 %12, ptr %13, align 2, !tbaa !24
  store <4 x i16> <i16 16, i16 0, i16 16, i16 0>, ptr %11, align 2, !tbaa !25
  %14 = getelementptr inbounds i8, ptr %0, i64 914
  store i64 0, ptr %14, align 2, !tbaa !26
  %15 = getelementptr inbounds i8, ptr %0, i64 922
  store i16 0, ptr %15, align 2, !tbaa !27
  %16 = getelementptr inbounds i8, ptr %0, i64 924
  store i16 0, ptr %16, align 2, !tbaa !28
  %17 = getelementptr inbounds i8, ptr %0, i64 842
  %18 = load i16, ptr %17, align 2, !tbaa !29
  %19 = getelementptr inbounds i8, ptr %0, i64 926
  store i16 %18, ptr %19, align 2, !tbaa !30
  %20 = getelementptr inbounds i8, ptr %0, i64 928
  store i16 0, ptr %20, align 2, !tbaa !31
  %21 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not = icmp eq i8 %21, 0
  br i1 %.not, label %25, label %22

22:                                               ; preds = %3
  %23 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not31 = icmp eq i8 %23, 0
  br i1 %.not31, label %25, label %24

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

25:                                               ; preds = %3, %24, %22
  %26 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not32 = icmp eq i8 %26, 0
  br i1 %.not32, label %32, label %27

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

29:                                               ; preds = %27
  %30 = load i16, ptr %11, align 2, !tbaa !32
  %31 = zext i16 %30 to i32
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.3, i32 noundef %31) #2
  br label %32

32:                                               ; preds = %25, %29, %27
  %33 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not34 = icmp eq i8 %33, 0
  br i1 %.not34, label %38, label %34

34:                                               ; preds = %32
  %35 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not35 = icmp eq i8 %35, 0
  br i1 %.not35, label %38, label %36

36:                                               ; preds = %34
  %37 = load i64, ptr %13, align 2, !tbaa !24
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.4, i64 noundef %37) #2
  br label %38

38:                                               ; preds = %32, %36, %34
  %39 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not36 = icmp eq i8 %39, 0
  br i1 %.not36, label %44, label %40

40:                                               ; preds = %38
  %41 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not37 = icmp eq i8 %41, 0
  br i1 %.not37, label %44, label %42

42:                                               ; preds = %40
  %43 = load i64, ptr %14, align 2, !tbaa !26
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.5, i64 noundef %43) #2
  br label %44

44:                                               ; preds = %38, %42, %40
  %45 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not38 = icmp eq i8 %45, 0
  br i1 %.not38, label %50, label %46

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

48:                                               ; preds = %46
  %49 = load i64, ptr %5, align 1, !tbaa !19
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.6, i64 noundef %49) #2
  br label %50

50:                                               ; preds = %46, %48, %44
  %51 = getelementptr inbounds i8, ptr %0, i64 832
  %52 = load ptr, ptr %51, align 8, !tbaa !33
  %53 = ptrtoint ptr %11 to i64
  %54 = tail call i64 %52(i64 noundef %53) #2
  %55 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not40 = icmp eq i8 %55, 0
  br i1 %.not40, label %59, label %56

56:                                               ; preds = %50
  %57 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not41 = icmp eq i8 %57, 0
  br i1 %.not41, label %59, label %58

58:                                               ; preds = %56
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.7) #2
  br label %59

59:                                               ; preds = %50, %58, %56
  %60 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not42 = icmp eq i8 %60, 0
  br i1 %.not42, label %66, label %61

61:                                               ; preds = %59
  %62 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 16384) #2
  %.not43 = icmp eq i8 %62, 0
  br i1 %.not43, label %66, label %63

63:                                               ; preds = %61
  %64 = load i16, ptr %15, align 2, !tbaa !27
  %65 = zext i16 %64 to i32
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 16384, ptr noundef nonnull @.str.8, i32 noundef %65) #2
  br label %66

66:                                               ; preds = %61, %63, %59
  %67 = load i16, ptr %15, align 2, !tbaa !27
  switch i16 %67, label %68 [
    i16 0, label %78
    i16 4, label %69
    i16 3, label %69
  ]

68:                                               ; preds = %66
  br label %69

69:                                               ; preds = %66, %66, %68
  %.0 = phi i64 [ -9223372036854775801, %68 ], [ -9223372036854775802, %66 ], [ -9223372036854775802, %66 ]
  %70 = tail call zeroext i8 @DebugPrintEnabled() #2
  %.not44 = icmp eq i8 %70, 0
  br i1 %.not44, label %78, label %71

71:                                               ; preds = %69
  %72 = tail call zeroext i8 @DebugPrintLevelEnabled(i64 noundef 2147483648) #2
  %.not45 = icmp eq i8 %72, 0
  br i1 %.not45, label %78, label %73

73:                                               ; preds = %71
  %74 = load i16, ptr %16, align 2, !tbaa !28
  %75 = zext i16 %74 to i32
  %76 = load i16, ptr %15, align 2, !tbaa !27
  %77 = zext i16 %76 to i32
  tail call void (i64, ptr, ...) @DebugPrint(i64 noundef 2147483648, ptr noundef nonnull @.str.9, i32 noundef %75, i32 noundef %77) #2
  br label %78

78:                                               ; preds = %69, %73, %71, %66
  %.030 = phi i64 [ 0, %66 ], [ %.0, %71 ], [ %.0, %73 ], [ %.0, %69 ]
  ret i64 %.030
}

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 = { 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 = !{!20, !11, i64 0}
!20 = !{!"s_pxe_cpb_transmit", !11, i64 0, !7, i64 8, !16, i64 12, !16, i64 14}
!21 = !{!20, !7, i64 8}
!22 = !{!20, !16, i64 12}
!23 = !{!20, !16, i64 14}
!24 = !{!6, !11, i64 906}
!25 = !{!16, !16, i64 0}
!26 = !{!6, !11, i64 914}
!27 = !{!6, !16, i64 922}
!28 = !{!6, !16, i64 924}
!29 = !{!6, !16, i64 842}
!30 = !{!6, !16, i64 926}
!31 = !{!6, !16, i64 928}
!32 = !{!6, !16, i64 898}
!33 = !{!6, !13, i64 832}


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