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

; 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.GUID = type { i32, i16, i16, [8 x i8] }
%struct.EFI_BOOT_SERVICES = type { %struct.EFI_TABLE_HEADER, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.EFI_TABLE_HEADER = type { i64, i32, i32, i32, i32 }
%struct._EFI_DRIVER_BINDING_PROTOCOL = type { ptr, ptr, ptr, i32, ptr, ptr }
%struct._DHCP_SERVICE = type { i32, %struct._EFI_SERVICE_BINDING_PROTOCOL, i64, ptr, ptr, %struct._LIST_ENTRY, i64, i64, i64, i32, i32, i32, i32, ptr, ptr, ptr, i32, i32, i32, i64, ptr, ptr, ptr, %struct.EFI_MAC_ADDRESS, i8, i8, [16 x i8], ptr, %struct.EFI_DHCP4_CONFIG_DATA, i32, ptr, i32, i32, i64, i64, i32 }
%struct._EFI_SERVICE_BINDING_PROTOCOL = type { ptr, ptr }
%struct._LIST_ENTRY = type { ptr, ptr }
%struct.EFI_MAC_ADDRESS = type { [32 x i8] }
%struct.EFI_DHCP4_CONFIG_DATA = type { i32, ptr, i32, ptr, %struct.EFI_IPv4_ADDRESS, ptr, ptr, i32, ptr }
%struct.EFI_IPv4_ADDRESS = type { [4 x i8] }

@gBS = external global ptr, align 8
@gEfiDhcp4ServiceBindingProtocolGuid = external global %struct.GUID, align 4
@.str = external hidden unnamed_addr constant [155 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [21 x i8], align 1
@gEfiUdp4ProtocolGuid = external global %struct.GUID, align 4
@gDhcpControllerNameTable = external global ptr, align 8

; Function Attrs: nounwind uwtable
define dso_local i64 @Dhcp4DriverBindingStop(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3) #0 {
  %5 = alloca i64, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i64, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i64, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i64, align 8
  %16 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store i64 %2, ptr %8, align 8, !tbaa !9
  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
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  %17 = load ptr, ptr %7, align 8, !tbaa !5
  %18 = call ptr @NetLibGetNicHandle(ptr noundef %17, ptr noundef @gEfiUdp4ProtocolGuid)
  store ptr %18, ptr %12, align 8, !tbaa !5
  %19 = load ptr, ptr %12, align 8, !tbaa !5
  %20 = icmp eq ptr %19, null
  br i1 %20, label %21, label %22

21:                                               ; preds = %4
  store i64 0, ptr %5, align 8
  store i32 1, ptr %16, align 4
  br label %111

22:                                               ; preds = %4
  %23 = load ptr, ptr @gBS, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.EFI_BOOT_SERVICES, ptr %23, i32 0, i32 33
  %25 = load ptr, ptr %24, align 8, !tbaa !11
  %26 = load ptr, ptr %12, align 8, !tbaa !5
  %27 = load ptr, ptr %6, align 8, !tbaa !5
  %28 = getelementptr inbounds %struct._EFI_DRIVER_BINDING_PROTOCOL, ptr %27, i32 0, i32 5
  %29 = load ptr, ptr %28, align 8, !tbaa !15
  %30 = load ptr, ptr %12, align 8, !tbaa !5
  %31 = call i64 %25(ptr noundef %26, ptr noundef @gEfiDhcp4ServiceBindingProtocolGuid, ptr noundef %10, ptr noundef %29, ptr noundef %30, i32 noundef 2)
  store i64 %31, ptr %13, align 8, !tbaa !9
  %32 = load i64, ptr %13, align 8, !tbaa !9
  %33 = icmp slt i64 %32, 0
  br i1 %33, label %34, label %35

34:                                               ; preds = %22
  store i64 -9223372036854775801, ptr %5, align 8
  store i32 1, ptr %16, align 4
  br label %111

35:                                               ; preds = %22
  %36 = call zeroext i8 @DebugAssertEnabled()
  %37 = zext i8 %36 to i32
  %38 = icmp ne i32 %37, 0
  br i1 %38, label %39, label %49

39:                                               ; preds = %35
  %40 = load ptr, ptr %10, align 8, !tbaa !5
  %41 = ptrtoint ptr %40 to i64
  %42 = sub i64 %41, ptrtoint (ptr getelementptr inbounds (%struct._DHCP_SERVICE, ptr null, i32 0, i32 1) to i64)
  %43 = inttoptr i64 %42 to ptr
  %44 = getelementptr inbounds %struct._DHCP_SERVICE, ptr %43, i32 0, i32 0
  %45 = load i32, ptr %44, align 8, !tbaa !17
  %46 = icmp ne i32 %45, 1346586692
  br i1 %46, label %47, label %49

47:                                               ; preds = %39
  call void @DebugAssert(ptr noundef @.str, i64 noundef 444, ptr noundef @.str.2)
  %48 = load ptr, ptr %10, align 8, !tbaa !5
  br label %54

49:                                               ; preds = %39, %35
  %50 = load ptr, ptr %10, align 8, !tbaa !5
  %51 = ptrtoint ptr %50 to i64
  %52 = sub i64 %51, ptrtoint (ptr getelementptr inbounds (%struct._DHCP_SERVICE, ptr null, i32 0, i32 1) to i64)
  %53 = inttoptr i64 %52 to ptr
  br label %54

54:                                               ; preds = %49, %47
  %55 = phi ptr [ %48, %47 ], [ %53, %49 ]
  store ptr %55, ptr %11, align 8, !tbaa !5
  %56 = load ptr, ptr %11, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct._DHCP_SERVICE, ptr %56, i32 0, i32 5
  %58 = call zeroext i8 @IsListEmpty(ptr noundef %57)
  %59 = icmp ne i8 %58, 0
  br i1 %59, label %73, label %60

60:                                               ; preds = %54
  %61 = load ptr, ptr %11, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct._DHCP_SERVICE, ptr %61, i32 0, i32 5
  store ptr %62, ptr %14, align 8, !tbaa !5
  %63 = load ptr, ptr %14, align 8, !tbaa !5
  %64 = load ptr, ptr %10, align 8, !tbaa !5
  %65 = call i64 @NetDestroyLinkList(ptr noundef %63, ptr noundef @Dhcp4DestroyChildEntry, ptr noundef %64, ptr noundef %15)
  store i64 %65, ptr %13, align 8, !tbaa !9
  %66 = load i64, ptr %13, align 8, !tbaa !9
  %67 = icmp slt i64 %66, 0
  br i1 %67, label %71, label %68

68:                                               ; preds = %60
  %69 = load i64, ptr %15, align 8, !tbaa !9
  %70 = icmp ne i64 %69, 0
  br i1 %70, label %71, label %72

71:                                               ; preds = %68, %60
  store i64 -9223372036854775801, ptr %13, align 8, !tbaa !9
  br label %72

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

73:                                               ; preds = %72, %54
  %74 = load i64, ptr %8, align 8, !tbaa !9
  %75 = icmp eq i64 %74, 0
  br i1 %75, label %76, label %82

76:                                               ; preds = %73
  %77 = load ptr, ptr %11, align 8, !tbaa !5
  %78 = getelementptr inbounds %struct._DHCP_SERVICE, ptr %77, i32 0, i32 5
  %79 = call zeroext i8 @IsListEmpty(ptr noundef %78)
  %80 = icmp ne i8 %79, 0
  br i1 %80, label %82, label %81

81:                                               ; preds = %76
  store i64 -9223372036854775801, ptr %13, align 8, !tbaa !9
  br label %82

82:                                               ; preds = %81, %76, %73
  %83 = load i64, ptr %8, align 8, !tbaa !9
  %84 = icmp eq i64 %83, 0
  br i1 %84, label %85, label %109

85:                                               ; preds = %82
  %86 = load ptr, ptr %11, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct._DHCP_SERVICE, ptr %86, i32 0, i32 5
  %88 = call zeroext i8 @IsListEmpty(ptr noundef %87)
  %89 = zext i8 %88 to i32
  %90 = icmp ne i32 %89, 0
  br i1 %90, label %91, label %109

91:                                               ; preds = %85
  %92 = load ptr, ptr %11, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct._DHCP_SERVICE, ptr %92, i32 0, i32 2
  store i64 2, ptr %93, align 8, !tbaa !23
  %94 = load ptr, ptr @gBS, align 8, !tbaa !5
  %95 = getelementptr inbounds %struct.EFI_BOOT_SERVICES, ptr %94, i32 0, i32 16
  %96 = load ptr, ptr %95, align 8, !tbaa !24
  %97 = load ptr, ptr %12, align 8, !tbaa !5
  %98 = load ptr, ptr %10, align 8, !tbaa !5
  %99 = call i64 %96(ptr noundef %97, ptr noundef @gEfiDhcp4ServiceBindingProtocolGuid, ptr noundef %98)
  %100 = load ptr, ptr %11, align 8, !tbaa !5
  %101 = call i64 @Dhcp4CloseService(ptr noundef %100)
  %102 = load ptr, ptr @gDhcpControllerNameTable, align 8, !tbaa !5
  %103 = icmp ne ptr %102, null
  br i1 %103, label %104, label %107

104:                                              ; preds = %91
  %105 = load ptr, ptr @gDhcpControllerNameTable, align 8, !tbaa !5
  %106 = call i64 @FreeUnicodeStringTable(ptr noundef %105)
  store ptr null, ptr @gDhcpControllerNameTable, align 8, !tbaa !5
  br label %107

107:                                              ; preds = %104, %91
  %108 = load ptr, ptr %11, align 8, !tbaa !5
  call void @FreePool(ptr noundef %108)
  store i64 0, ptr %13, align 8, !tbaa !9
  br label %109

109:                                              ; preds = %107, %85, %82
  %110 = load i64, ptr %13, align 8, !tbaa !9
  store i64 %110, ptr %5, align 8
  store i32 1, ptr %16, align 4
  br label %111

111:                                              ; preds = %109, %34, %21
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #3
  %112 = load i64, ptr %5, align 8
  ret i64 %112
}

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

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

; Function Attrs: nounwind uwtable
declare dso_local i64 @Dhcp4CloseService(ptr noundef) #0

declare void @FreePool(ptr noundef) #2

declare zeroext i8 @DebugAssertEnabled() #2

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

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

declare ptr @NetLibGetNicHandle(ptr noundef, ptr noundef) #2

declare zeroext i8 @IsListEmpty(ptr noundef) #2

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

declare i64 @FreeUnicodeStringTable(ptr noundef) #2

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, !10, i64 0}
!10 = !{!"long long", !7, i64 0}
!11 = !{!12, !6, i64 280}
!12 = !{!"", !13, i64 0, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368}
!13 = !{!"", !10, i64 0, !14, i64 8, !14, i64 12, !14, i64 16, !14, i64 20}
!14 = !{!"int", !7, i64 0}
!15 = !{!16, !6, i64 40}
!16 = !{!"_EFI_DRIVER_BINDING_PROTOCOL", !6, i64 0, !6, i64 8, !6, i64 16, !14, i64 24, !6, i64 32, !6, i64 40}
!17 = !{!18, !14, i64 0}
!18 = !{!"_DHCP_SERVICE", !14, i64 0, !19, i64 8, !10, i64 24, !6, i64 32, !6, i64 40, !20, i64 48, !10, i64 64, !10, i64 72, !10, i64 80, !14, i64 88, !14, i64 92, !14, i64 96, !14, i64 100, !6, i64 104, !6, i64 112, !6, i64 120, !14, i64 128, !14, i64 132, !14, i64 136, !10, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !21, i64 176, !7, i64 208, !7, i64 209, !7, i64 210, !6, i64 232, !22, i64 240, !14, i64 312, !6, i64 320, !14, i64 328, !14, i64 332, !10, i64 336, !10, i64 344, !14, i64 352}
!19 = !{!"_EFI_SERVICE_BINDING_PROTOCOL", !6, i64 0, !6, i64 8}
!20 = !{!"_LIST_ENTRY", !6, i64 0, !6, i64 8}
!21 = !{!"", !7, i64 0}
!22 = !{!"", !14, i64 0, !6, i64 8, !14, i64 16, !6, i64 24, !21, i64 32, !6, i64 40, !6, i64 48, !14, i64 56, !6, i64 64}
!23 = !{!18, !10, i64 24}
!24 = !{!12, !6, i64 144}


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

%struct.GUID = type { i32, i16, i16, [8 x i8] }

@gBS = external local_unnamed_addr global ptr, align 8
@gEfiDhcp4ServiceBindingProtocolGuid = external global %struct.GUID, align 4
@.str = external hidden unnamed_addr constant [155 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [21 x i8], align 1
@gEfiUdp4ProtocolGuid = external global %struct.GUID, align 4
@gDhcpControllerNameTable = external local_unnamed_addr global ptr, align 8

; Function Attrs: nounwind uwtable
define dso_local i64 @Dhcp4DriverBindingStop(ptr nocapture noundef readonly %0, ptr noundef %1, i64 noundef %2, ptr nocapture noundef readnone %3) local_unnamed_addr #0 {
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #3
  %7 = tail call ptr @NetLibGetNicHandle(ptr noundef %1, ptr noundef nonnull @gEfiUdp4ProtocolGuid) #3
  %8 = icmp eq ptr %7, null
  br i1 %8, label %49, label %9

9:                                                ; preds = %4
  %10 = load ptr, ptr @gBS, align 8, !tbaa !5
  %11 = getelementptr inbounds i8, ptr %10, i64 280
  %12 = load ptr, ptr %11, align 8, !tbaa !9
  %13 = getelementptr inbounds i8, ptr %0, i64 40
  %14 = load ptr, ptr %13, align 8, !tbaa !14
  %15 = call i64 %12(ptr noundef nonnull %7, ptr noundef nonnull @gEfiDhcp4ServiceBindingProtocolGuid, ptr noundef nonnull %5, ptr noundef %14, ptr noundef nonnull %7, i32 noundef 2) #3
  %16 = icmp slt i64 %15, 0
  br i1 %16, label %49, label %17

17:                                               ; preds = %9
  %18 = call zeroext i8 @DebugAssertEnabled() #3
  %.not = icmp eq i8 %18, 0
  %.pre = load ptr, ptr %5, align 8, !tbaa !5
  %.pre31 = ptrtoint ptr %.pre to i64
  %.pre32 = add i64 %.pre31, -8
  %.pre34 = inttoptr i64 %.pre32 to ptr
  br i1 %.not, label %._crit_edge, label %19

19:                                               ; preds = %17
  %20 = load i32, ptr %.pre34, align 8, !tbaa !16
  %.not24 = icmp eq i32 %20, 1346586692
  br i1 %.not24, label %._crit_edge, label %21

21:                                               ; preds = %19
  call void @DebugAssert(ptr noundef nonnull @.str, i64 noundef 444, ptr noundef nonnull @.str.2) #3
  %22 = load ptr, ptr %5, align 8, !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %17, %19, %21
  %23 = phi ptr [ %22, %21 ], [ %.pre34, %19 ], [ %.pre34, %17 ]
  %24 = getelementptr inbounds i8, ptr %23, i64 48
  %25 = call zeroext i8 @IsListEmpty(ptr noundef nonnull %24) #3
  %.not25 = icmp eq i8 %25, 0
  br i1 %.not25, label %26, label %32

26:                                               ; preds = %._crit_edge
  %27 = load ptr, ptr %5, align 8, !tbaa !5
  %28 = call i64 @NetDestroyLinkList(ptr noundef nonnull %24, ptr noundef nonnull @Dhcp4DestroyChildEntry, ptr noundef %27, ptr noundef nonnull %6) #3
  %29 = icmp slt i64 %28, 0
  %30 = load i64, ptr %6, align 8
  %31 = icmp ne i64 %30, 0
  %or.cond = select i1 %29, i1 true, i1 %31
  %spec.store.select = select i1 %or.cond, i64 -9223372036854775801, i64 %28
  br label %32

32:                                               ; preds = %26, %._crit_edge
  %.020 = phi i64 [ %15, %._crit_edge ], [ %spec.store.select, %26 ]
  %33 = icmp eq i64 %2, 0
  br i1 %33, label %34, label %49

34:                                               ; preds = %32
  %35 = call zeroext i8 @IsListEmpty(ptr noundef nonnull %24) #3
  %.not26 = icmp eq i8 %35, 0
  %spec.select = select i1 %.not26, i64 -9223372036854775801, i64 %.020
  %36 = call zeroext i8 @IsListEmpty(ptr noundef nonnull %24) #3
  %.not27 = icmp eq i8 %36, 0
  br i1 %.not27, label %49, label %37

37:                                               ; preds = %34
  %38 = getelementptr inbounds i8, ptr %23, i64 24
  store i64 2, ptr %38, align 8, !tbaa !22
  %39 = load ptr, ptr @gBS, align 8, !tbaa !5
  %40 = getelementptr inbounds i8, ptr %39, i64 144
  %41 = load ptr, ptr %40, align 8, !tbaa !23
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = call i64 %41(ptr noundef nonnull %7, ptr noundef nonnull @gEfiDhcp4ServiceBindingProtocolGuid, ptr noundef %42) #3
  %44 = call i64 @Dhcp4CloseService(ptr noundef %23)
  %45 = load ptr, ptr @gDhcpControllerNameTable, align 8, !tbaa !5
  %.not28 = icmp eq ptr %45, null
  br i1 %.not28, label %48, label %46

46:                                               ; preds = %37
  %47 = call i64 @FreeUnicodeStringTable(ptr noundef nonnull %45) #3
  store ptr null, ptr @gDhcpControllerNameTable, align 8, !tbaa !5
  br label %48

48:                                               ; preds = %46, %37
  call void @FreePool(ptr noundef nonnull %23) #3
  br label %49

49:                                               ; preds = %32, %34, %48, %9, %4
  %.0 = phi i64 [ 0, %4 ], [ -9223372036854775801, %9 ], [ 0, %48 ], [ %spec.select, %34 ], [ %.020, %32 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #3
  ret i64 %.0
}

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

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

; Function Attrs: nounwind uwtable
declare dso_local i64 @Dhcp4CloseService(ptr noundef) local_unnamed_addr #0

declare void @FreePool(ptr noundef) local_unnamed_addr #2

declare zeroext i8 @DebugAssertEnabled() local_unnamed_addr #2

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

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

declare ptr @NetLibGetNicHandle(ptr noundef, ptr noundef) local_unnamed_addr #2

declare zeroext i8 @IsListEmpty(ptr noundef) local_unnamed_addr #2

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

declare i64 @FreeUnicodeStringTable(ptr noundef) local_unnamed_addr #2

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 = { mustprogress 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 280}
!10 = !{!"", !11, i64 0, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368}
!11 = !{!"", !12, i64 0, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20}
!12 = !{!"long long", !7, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!15, !6, i64 40}
!15 = !{!"_EFI_DRIVER_BINDING_PROTOCOL", !6, i64 0, !6, i64 8, !6, i64 16, !13, i64 24, !6, i64 32, !6, i64 40}
!16 = !{!17, !13, i64 0}
!17 = !{!"_DHCP_SERVICE", !13, i64 0, !18, i64 8, !12, i64 24, !6, i64 32, !6, i64 40, !19, i64 48, !12, i64 64, !12, i64 72, !12, i64 80, !13, i64 88, !13, i64 92, !13, i64 96, !13, i64 100, !6, i64 104, !6, i64 112, !6, i64 120, !13, i64 128, !13, i64 132, !13, i64 136, !12, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !20, i64 176, !7, i64 208, !7, i64 209, !7, i64 210, !6, i64 232, !21, i64 240, !13, i64 312, !6, i64 320, !13, i64 328, !13, i64 332, !12, i64 336, !12, i64 344, !13, i64 352}
!18 = !{!"_EFI_SERVICE_BINDING_PROTOCOL", !6, i64 0, !6, i64 8}
!19 = !{!"_LIST_ENTRY", !6, i64 0, !6, i64 8}
!20 = !{!"", !7, i64 0}
!21 = !{!"", !13, i64 0, !6, i64 8, !13, i64 16, !6, i64 24, !20, i64 32, !6, i64 40, !6, i64 48, !13, i64 56, !6, i64 64}
!22 = !{!17, !12, i64 24}
!23 = !{!10, !6, i64 144}


; Effective O3 passes: BDCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass