; LLVM IR from lichen-community-systems/signaletic :: hosts/daisy/vendor/libDaisy/src/util (usbh_diskio)

; 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._USBH_HandleTypeDef = type { i32, i32, i32, %struct.USBH_CtrlTypeDef, %struct.USBH_DeviceTypeDef, [1 x ptr], ptr, i32, [16 x i32], i32, i32, i8, ptr, ptr }
%struct.USBH_CtrlTypeDef = type { i8, i8, i8, ptr, i16, i16, %union._USB_Setup, i32, i8 }
%union._USB_Setup = type { [2 x i32] }
%struct.USBH_DeviceTypeDef = type { [256 x i8], [512 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i8, %struct._DeviceDescriptor, %struct._ConfigurationDescriptor }
%struct._DeviceDescriptor = type { i8, i8, i16, i8, i8, i8, i8, i16, i16, i16, i8, i8, i8, i8 }
%struct._ConfigurationDescriptor = type { i8, i8, i16, i8, i8, i8, i8, i8, [2 x %struct._InterfaceDescriptor] }
%struct._InterfaceDescriptor = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, [2 x %struct._EndpointDescriptor] }
%struct._EndpointDescriptor = type { i8, i8, i8, i8, i16, i8 }
%struct.MSC_LUNTypeDef = type { i32, i32, i32, %struct.SCSI_CapacityTypeDef, %struct.SCSI_SenseTypeDef, %struct.SCSI_StdInquiryDataTypeDef, i8 }
%struct.SCSI_CapacityTypeDef = type { i32, i16 }
%struct.SCSI_SenseTypeDef = type { i8, i8, i8 }
%struct.SCSI_StdInquiryDataTypeDef = type { i8, i8, i8, [9 x i8], [17 x i8], [5 x i8] }
%struct.HCD_HandleTypeDef = type { ptr, %struct.USB_OTG_CfgTypeDef, [16 x %struct.USB_OTG_HCTypeDef], i32, i32, i32, ptr }
%struct.USB_OTG_CfgTypeDef = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%struct.USB_OTG_HCTypeDef = type { i8, i8, i8, i8, i8, i8, i8, i8, i16, i8, ptr, i32, i32, i8, i8, i32, i32, i32, i32 }

@hUsbHostHS = external global %struct._USBH_HandleTypeDef, align 8
@scratch = external hidden global [128 x i64], section ".sram1_bss", align 16

; Function Attrs: nounwind uwtable
define dso_local i32 @USBH_read(i8 noundef zeroext %0, ptr noundef %1, i64 noundef %2, i32 noundef %3) #0 {
  %5 = alloca i8, align 1
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca %struct.MSC_LUNTypeDef, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  store i8 %0, ptr %5, align 1, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !8
  store i64 %2, ptr %7, align 8, !tbaa !10
  store i32 %3, ptr %8, align 4, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 1, ptr %9, align 4, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 60, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  store i32 0, ptr %11, align 4, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  %13 = load ptr, ptr %6, align 8, !tbaa !8
  %14 = ptrtoint ptr %13 to i32
  %15 = and i32 %14, -32
  store i32 %15, ptr %12, align 4, !tbaa !12
  %16 = load i32, ptr %12, align 4, !tbaa !12
  %17 = zext i32 %16 to i64
  %18 = inttoptr i64 %17 to ptr
  %19 = load i32, ptr %8, align 4, !tbaa !12
  %20 = mul i32 %19, 512
  %21 = load ptr, ptr %6, align 8, !tbaa !8
  %22 = ptrtoint ptr %21 to i32
  %23 = load i32, ptr %12, align 4, !tbaa !12
  %24 = sub i32 %22, %23
  %25 = add i32 %20, %24
  call void @SCB_CleanDCache_by_Addr(ptr noundef %18, i32 noundef %25)
  %26 = load ptr, ptr %6, align 8, !tbaa !8
  %27 = ptrtoint ptr %26 to i64
  %28 = and i64 %27, 3
  %29 = icmp ne i64 %28, 0
  br i1 %29, label %30, label %65

30:                                               ; preds = %4
  %31 = load ptr, ptr getelementptr inbounds (%struct._USBH_HandleTypeDef, ptr @hUsbHostHS, i32 0, i32 12), align 8, !tbaa !14
  %32 = getelementptr inbounds %struct.HCD_HandleTypeDef, ptr %31, i32 0, i32 1
  %33 = getelementptr inbounds %struct.USB_OTG_CfgTypeDef, ptr %32, i32 0, i32 3
  %34 = load i32, ptr %33, align 4, !tbaa !21
  %35 = icmp ne i32 %34, 0
  br i1 %35, label %36, label %65

36:                                               ; preds = %30
  br label %37

37:                                               ; preds = %63, %36
  %38 = load i32, ptr %8, align 4, !tbaa !12
  %39 = add i32 %38, -1
  store i32 %39, ptr %8, align 4, !tbaa !12
  %40 = icmp ne i32 %38, 0
  br i1 %40, label %41, label %44

41:                                               ; preds = %37
  %42 = load i32, ptr %11, align 4, !tbaa !12
  %43 = icmp eq i32 %42, 0
  br label %44

44:                                               ; preds = %41, %37
  %45 = phi i1 [ false, %37 ], [ %43, %41 ]
  br i1 %45, label %46, label %64

46:                                               ; preds = %44
  %47 = load i8, ptr %5, align 1, !tbaa !5
  %48 = load i64, ptr %7, align 8, !tbaa !10
  %49 = load i32, ptr %8, align 4, !tbaa !12
  %50 = zext i32 %49 to i64
  %51 = add i64 %48, %50
  %52 = trunc i64 %51 to i32
  %53 = call i32 @USBH_MSC_Read(ptr noundef @hUsbHostHS, i8 noundef zeroext %47, i32 noundef %52, ptr noundef @scratch, i32 noundef 1)
  store i32 %53, ptr %11, align 4, !tbaa !12
  %54 = load i32, ptr %11, align 4, !tbaa !12
  %55 = icmp eq i32 %54, 0
  br i1 %55, label %56, label %62

56:                                               ; preds = %46
  %57 = load ptr, ptr %6, align 8, !tbaa !8
  %58 = load i32, ptr %8, align 4, !tbaa !12
  %59 = mul i32 %58, 512
  %60 = zext i32 %59 to i64
  %61 = getelementptr inbounds i8, ptr %57, i64 %60
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %61, ptr align 16 @scratch, i64 512, i1 false)
  br label %63

62:                                               ; preds = %46
  br label %64

63:                                               ; preds = %56
  br label %37, !llvm.loop !24

64:                                               ; preds = %62, %44
  br label %72

65:                                               ; preds = %30, %4
  %66 = load i8, ptr %5, align 1, !tbaa !5
  %67 = load i64, ptr %7, align 8, !tbaa !10
  %68 = trunc i64 %67 to i32
  %69 = load ptr, ptr %6, align 8, !tbaa !8
  %70 = load i32, ptr %8, align 4, !tbaa !12
  %71 = call i32 @USBH_MSC_Read(ptr noundef @hUsbHostHS, i8 noundef zeroext %66, i32 noundef %68, ptr noundef %69, i32 noundef %70)
  store i32 %71, ptr %11, align 4, !tbaa !12
  br label %72

72:                                               ; preds = %65, %64
  %73 = load i32, ptr %12, align 4, !tbaa !12
  %74 = zext i32 %73 to i64
  %75 = inttoptr i64 %74 to ptr
  %76 = load i32, ptr %8, align 4, !tbaa !12
  %77 = mul i32 %76, 512
  %78 = load ptr, ptr %6, align 8, !tbaa !8
  %79 = ptrtoint ptr %78 to i32
  %80 = load i32, ptr %12, align 4, !tbaa !12
  %81 = sub i32 %79, %80
  %82 = add i32 %77, %81
  call void @SCB_InvalidateDCache_by_Addr(ptr noundef %75, i32 noundef %82)
  %83 = load i32, ptr %11, align 4, !tbaa !12
  %84 = icmp eq i32 %83, 0
  br i1 %84, label %85, label %86

85:                                               ; preds = %72
  store i32 0, ptr %9, align 4, !tbaa !12
  br label %99

86:                                               ; preds = %72
  %87 = load i8, ptr %5, align 1, !tbaa !5
  %88 = call i32 @USBH_MSC_GetLUNInfo(ptr noundef @hUsbHostHS, i8 noundef zeroext %87, ptr noundef %10)
  %89 = getelementptr inbounds %struct.MSC_LUNTypeDef, ptr %10, i32 0, i32 4
  %90 = getelementptr inbounds %struct.SCSI_SenseTypeDef, ptr %89, i32 0, i32 1
  %91 = load i8, ptr %90, align 1, !tbaa !26
  %92 = zext i8 %91 to i32
  switch i32 %92, label %97 [
    i32 4, label %93
    i32 58, label %93
    i32 40, label %93
  ]

93:                                               ; preds = %86, %86, %86
  br label %94

94:                                               ; preds = %93
  br label %95

95:                                               ; preds = %94
  br label %96

96:                                               ; preds = %95
  store i32 3, ptr %9, align 4, !tbaa !12
  br label %98

97:                                               ; preds = %86
  store i32 1, ptr %9, align 4, !tbaa !12
  br label %98

98:                                               ; preds = %97, %96
  br label %99

99:                                               ; preds = %98, %85
  %100 = load i32, ptr %9, align 4, !tbaa !12
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 60, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  ret i32 %100
}

; 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: inlinehint nounwind uwtable
declare hidden void @SCB_CleanDCache_by_Addr(ptr noundef, i32 noundef) #2

declare i32 @USBH_MSC_Read(ptr noundef, i8 noundef zeroext, i32 noundef, ptr noundef, i32 noundef) #3

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #4

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @SCB_InvalidateDCache_by_Addr(ptr noundef, i32 noundef) #2

declare i32 @USBH_MSC_GetLUNInfo(ptr noundef, i8 noundef zeroext, ptr noundef) #3

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 = { inlinehint 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 = { "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 #4 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C/C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"any pointer", !6, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"long", !6, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !6, i64 0}
!14 = !{!15, !9, i64 1016}
!15 = !{!"_USBH_HandleTypeDef", !13, i64 0, !13, i64 4, !13, i64 8, !16, i64 16, !18, i64 56, !6, i64 920, !9, i64 928, !13, i64 936, !6, i64 940, !13, i64 1004, !13, i64 1008, !6, i64 1012, !9, i64 1016, !9, i64 1024}
!16 = !{!"", !6, i64 0, !6, i64 1, !6, i64 2, !9, i64 8, !17, i64 16, !17, i64 18, !6, i64 20, !13, i64 28, !6, i64 32}
!17 = !{!"short", !6, i64 0}
!18 = !{!"", !6, i64 0, !6, i64 256, !6, i64 768, !6, i64 769, !6, i64 770, !6, i64 771, !6, i64 772, !6, i64 773, !6, i64 774, !6, i64 775, !6, i64 776, !19, i64 778, !20, i64 796}
!19 = !{!"_DeviceDescriptor", !6, i64 0, !6, i64 1, !17, i64 2, !6, i64 4, !6, i64 5, !6, i64 6, !6, i64 7, !17, i64 8, !17, i64 10, !17, i64 12, !6, i64 14, !6, i64 15, !6, i64 16, !6, i64 17}
!20 = !{!"_ConfigurationDescriptor", !6, i64 0, !6, i64 1, !17, i64 2, !6, i64 4, !6, i64 5, !6, i64 6, !6, i64 7, !6, i64 8, !6, i64 10}
!21 = !{!22, !13, i64 20}
!22 = !{!"", !9, i64 0, !23, i64 8, !6, i64 64, !13, i64 960, !13, i64 964, !13, i64 968, !9, i64 976}
!23 = !{!"", !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, !13, i64 40, !13, i64 44, !13, i64 48}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.mustprogress"}
!26 = !{!27, !6, i64 21}
!27 = !{!"", !13, i64 0, !13, i64 4, !13, i64 8, !28, i64 12, !29, i64 20, !30, i64 23, !6, i64 57}
!28 = !{!"", !13, i64 0, !17, i64 4}
!29 = !{!"", !6, i64 0, !6, i64 1, !6, i64 2}
!30 = !{!"", !6, i64 0, !6, i64 1, !6, i64 2, !6, i64 3, !6, i64 12, !6, i64 29}


; 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._USBH_HandleTypeDef = type { i32, i32, i32, %struct.USBH_CtrlTypeDef, %struct.USBH_DeviceTypeDef, [1 x ptr], ptr, i32, [16 x i32], i32, i32, i8, ptr, ptr }
%struct.USBH_CtrlTypeDef = type { i8, i8, i8, ptr, i16, i16, %union._USB_Setup, i32, i8 }
%union._USB_Setup = type { [2 x i32] }
%struct.USBH_DeviceTypeDef = type { [256 x i8], [512 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i8, %struct._DeviceDescriptor, %struct._ConfigurationDescriptor }
%struct._DeviceDescriptor = type { i8, i8, i16, i8, i8, i8, i8, i16, i16, i16, i8, i8, i8, i8 }
%struct._ConfigurationDescriptor = type { i8, i8, i16, i8, i8, i8, i8, i8, [2 x %struct._InterfaceDescriptor] }
%struct._InterfaceDescriptor = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, [2 x %struct._EndpointDescriptor] }
%struct._EndpointDescriptor = type { i8, i8, i8, i8, i16, i8 }
%struct.MSC_LUNTypeDef = type { i32, i32, i32, %struct.SCSI_CapacityTypeDef, %struct.SCSI_SenseTypeDef, %struct.SCSI_StdInquiryDataTypeDef, i8 }
%struct.SCSI_CapacityTypeDef = type { i32, i16 }
%struct.SCSI_SenseTypeDef = type { i8, i8, i8 }
%struct.SCSI_StdInquiryDataTypeDef = type { i8, i8, i8, [9 x i8], [17 x i8], [5 x i8] }

@hUsbHostHS = external global %struct._USBH_HandleTypeDef, align 8
@scratch = external hidden global [128 x i64], section ".sram1_bss", align 16

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 4) i32 @USBH_read(i8 noundef zeroext %0, ptr noundef %1, i64 noundef %2, i32 noundef %3) local_unnamed_addr #0 {
  %5 = alloca %struct.MSC_LUNTypeDef, align 4
  call void @llvm.lifetime.start.p0(i64 60, ptr nonnull %5) #5
  %6 = ptrtoint ptr %1 to i64
  %7 = trunc i64 %6 to i32
  %8 = and i64 %6, 4294967264
  %9 = inttoptr i64 %8 to ptr
  %10 = shl i32 %3, 9
  %11 = and i32 %7, 31
  %12 = or disjoint i32 %10, %11
  tail call void @SCB_CleanDCache_by_Addr(ptr noundef %9, i32 noundef %12)
  %13 = and i64 %6, 3
  %.not = icmp eq i64 %13, 0
  br i1 %.not, label %28, label %14

14:                                               ; preds = %4
  %15 = load ptr, ptr getelementptr inbounds (i8, ptr @hUsbHostHS, i64 1016), align 8, !tbaa !5
  %16 = getelementptr inbounds i8, ptr %15, i64 20
  %17 = load i32, ptr %16, align 4, !tbaa !16
  %.not29 = icmp eq i32 %17, 0
  br i1 %.not29, label %28, label %.preheader

.preheader:                                       ; preds = %14
  %.not3034 = icmp eq i32 %3, 0
  br i1 %.not3034, label %.critedge32, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader
  %18 = trunc i64 %2 to i32
  %19 = zext i32 %3 to i64
  br label %20

20:                                               ; preds = %.lr.ph, %24
  %indvars.iv = phi i64 [ %19, %.lr.ph ], [ %indvars.iv.next, %24 ]
  %indvars.iv.next = add nsw i64 %indvars.iv, -1
  %indvars = trunc i64 %indvars.iv.next to i32
  %21 = add i32 %indvars, %18
  %22 = tail call i32 @USBH_MSC_Read(ptr noundef nonnull @hUsbHostHS, i8 noundef zeroext %0, i32 noundef %21, ptr noundef nonnull @scratch, i32 noundef 1) #5
  %23 = icmp eq i32 %22, 0
  br i1 %23, label %24, label %.critedge

24:                                               ; preds = %20
  %25 = shl i64 %indvars.iv.next, 9
  %26 = and i64 %25, 4294966784
  %27 = getelementptr inbounds i8, ptr %1, i64 %26
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(512) %27, ptr noundef nonnull align 16 dereferenceable(512) @scratch, i64 512, i1 false)
  %.not30 = icmp eq i32 %indvars, 0
  br i1 %.not30, label %.critedge32, label %20, !llvm.loop !19

28:                                               ; preds = %14, %4
  %29 = trunc i64 %2 to i32
  %30 = tail call i32 @USBH_MSC_Read(ptr noundef nonnull @hUsbHostHS, i8 noundef zeroext %0, i32 noundef %29, ptr noundef %1, i32 noundef %3) #5
  %31 = icmp eq i32 %30, 0
  tail call void @SCB_InvalidateDCache_by_Addr(ptr noundef %9, i32 noundef %12)
  br i1 %31, label %40, label %35

.critedge32:                                      ; preds = %24, %.preheader
  %32 = or disjoint i32 %11, -512
  tail call void @SCB_InvalidateDCache_by_Addr(ptr noundef %9, i32 noundef %32)
  br label %40

.critedge:                                        ; preds = %20
  %33 = shl i32 %indvars, 9
  %34 = or disjoint i32 %33, %11
  tail call void @SCB_InvalidateDCache_by_Addr(ptr noundef %9, i32 noundef %34)
  br label %35

35:                                               ; preds = %.critedge, %28
  %36 = call i32 @USBH_MSC_GetLUNInfo(ptr noundef nonnull @hUsbHostHS, i8 noundef zeroext %0, ptr noundef nonnull %5) #5
  %37 = getelementptr inbounds i8, ptr %5, i64 21
  %38 = load i8, ptr %37, align 1, !tbaa !21
  switch i8 %38, label %39 [
    i8 4, label %40
    i8 58, label %40
    i8 40, label %40
  ]

39:                                               ; preds = %35
  br label %40

40:                                               ; preds = %35, %35, %35, %28, %.critedge32, %39
  %.026 = phi i32 [ 1, %39 ], [ 0, %.critedge32 ], [ 0, %28 ], [ 3, %35 ], [ 3, %35 ], [ 3, %35 ]
  call void @llvm.lifetime.end.p0(i64 60, ptr nonnull %5) #5
  ret i32 %.026
}

; 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: inlinehint nounwind uwtable
declare hidden void @SCB_CleanDCache_by_Addr(ptr noundef, i32 noundef) local_unnamed_addr #2

declare i32 @USBH_MSC_Read(ptr noundef, i8 noundef zeroext, i32 noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #4

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @SCB_InvalidateDCache_by_Addr(ptr noundef, i32 noundef) local_unnamed_addr #2

declare i32 @USBH_MSC_GetLUNInfo(ptr noundef, i8 noundef zeroext, ptr noundef) local_unnamed_addr #3

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 = { inlinehint 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 = { "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 #4 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { 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, !11, i64 1016}
!6 = !{!"_USBH_HandleTypeDef", !7, i64 0, !7, i64 4, !7, i64 8, !10, i64 16, !13, i64 56, !8, i64 920, !11, i64 928, !7, i64 936, !8, i64 940, !7, i64 1004, !7, i64 1008, !8, i64 1012, !11, i64 1016, !11, i64 1024}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"", !8, i64 0, !8, i64 1, !8, i64 2, !11, i64 8, !12, i64 16, !12, i64 18, !8, i64 20, !7, i64 28, !8, i64 32}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!"short", !8, i64 0}
!13 = !{!"", !8, i64 0, !8, i64 256, !8, i64 768, !8, i64 769, !8, i64 770, !8, i64 771, !8, i64 772, !8, i64 773, !8, i64 774, !8, i64 775, !8, i64 776, !14, i64 778, !15, i64 796}
!14 = !{!"_DeviceDescriptor", !8, i64 0, !8, i64 1, !12, i64 2, !8, i64 4, !8, i64 5, !8, i64 6, !8, i64 7, !12, i64 8, !12, i64 10, !12, i64 12, !8, i64 14, !8, i64 15, !8, i64 16, !8, i64 17}
!15 = !{!"_ConfigurationDescriptor", !8, i64 0, !8, i64 1, !12, i64 2, !8, i64 4, !8, i64 5, !8, i64 6, !8, i64 7, !8, i64 8, !8, i64 10}
!16 = !{!17, !7, i64 20}
!17 = !{!"", !11, i64 0, !18, i64 8, !8, i64 64, !7, i64 960, !7, i64 964, !7, i64 968, !11, i64 976}
!18 = !{!"", !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, !7, i64 40, !7, i64 44, !7, i64 48}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!22, !8, i64 21}
!22 = !{!"", !7, i64 0, !7, i64 4, !7, i64 8, !23, i64 12, !24, i64 20, !25, i64 23, !8, i64 57}
!23 = !{!"", !7, i64 0, !12, i64 4}
!24 = !{!"", !8, i64 0, !8, i64 1, !8, i64 2}
!25 = !{!"", !8, i64 0, !8, i64 1, !8, i64 2, !8, i64 3, !8, i64 12, !8, i64 29}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass