; LLVM IR from reazon-research/OpenArm :: control/canfd_control/Drivers/STM32H7xx_HAL_Driver/Src (stm32h7xx_hal_spi)

; 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.__SPI_HandleTypeDef = type { ptr, %struct.SPI_InitTypeDef, ptr, i16, i16, ptr, i16, i16, i32, ptr, ptr, ptr, ptr, i32, i32, i32 }
%struct.SPI_InitTypeDef = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%struct.SPI_TypeDef = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, [3 x i32], i32, [3 x i32], i32, i32, i32, i32, i32 }

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

; 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 i32 @HAL_SPI_Transmit_IT(ptr noundef %0, ptr noundef %1, i16 noundef zeroext %2) #1 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i16, align 2
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store i16 %2, ptr %7, align 2, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #2
  store i32 0, ptr %8, align 4, !tbaa !11
  br label %10

10:                                               ; preds = %3
  %11 = load ptr, ptr %5, align 8, !tbaa !5
  %12 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %11, i32 0, i32 13
  %13 = load i32, ptr %12, align 8, !tbaa !13
  %14 = icmp eq i32 %13, 1
  br i1 %14, label %15, label %16

15:                                               ; preds = %10
  store i32 2, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %176

16:                                               ; preds = %10
  %17 = load ptr, ptr %5, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %17, i32 0, i32 13
  store i32 1, ptr %18, align 8, !tbaa !13
  br label %19

19:                                               ; preds = %16
  br label %20

20:                                               ; preds = %19
  br label %21

21:                                               ; preds = %20
  %22 = load ptr, ptr %6, align 8, !tbaa !5
  %23 = icmp eq ptr %22, null
  br i1 %23, label %28, label %24

24:                                               ; preds = %21
  %25 = load i16, ptr %7, align 2, !tbaa !9
  %26 = zext i16 %25 to i64
  %27 = icmp eq i64 %26, 0
  br i1 %27, label %28, label %35

28:                                               ; preds = %24, %21
  store i32 1, ptr %8, align 4, !tbaa !11
  br label %29

29:                                               ; preds = %28
  %30 = load ptr, ptr %5, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %30, i32 0, i32 13
  store i32 0, ptr %31, align 8, !tbaa !13
  br label %32

32:                                               ; preds = %29
  br label %33

33:                                               ; preds = %32
  %34 = load i32, ptr %8, align 4, !tbaa !11
  store i32 %34, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %176

35:                                               ; preds = %24
  %36 = load ptr, ptr %5, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %36, i32 0, i32 14
  %38 = load volatile i32, ptr %37, align 4, !tbaa !16
  %39 = icmp ne i32 %38, 1
  br i1 %39, label %40, label %47

40:                                               ; preds = %35
  store i32 2, ptr %8, align 4, !tbaa !11
  br label %41

41:                                               ; preds = %40
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %42, i32 0, i32 13
  store i32 0, ptr %43, align 8, !tbaa !13
  br label %44

44:                                               ; preds = %41
  br label %45

45:                                               ; preds = %44
  %46 = load i32, ptr %8, align 4, !tbaa !11
  store i32 %46, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %176

47:                                               ; preds = %35
  %48 = load ptr, ptr %5, align 8, !tbaa !5
  %49 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %48, i32 0, i32 14
  store volatile i32 3, ptr %49, align 4, !tbaa !16
  %50 = load ptr, ptr %5, align 8, !tbaa !5
  %51 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %50, i32 0, i32 15
  store volatile i32 0, ptr %51, align 8, !tbaa !17
  %52 = load ptr, ptr %6, align 8, !tbaa !5
  %53 = load ptr, ptr %5, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %53, i32 0, i32 2
  store ptr %52, ptr %54, align 8, !tbaa !18
  %55 = load i16, ptr %7, align 2, !tbaa !9
  %56 = load ptr, ptr %5, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %56, i32 0, i32 3
  store i16 %55, ptr %57, align 8, !tbaa !19
  %58 = load i16, ptr %7, align 2, !tbaa !9
  %59 = load ptr, ptr %5, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %59, i32 0, i32 4
  store volatile i16 %58, ptr %60, align 2, !tbaa !20
  %61 = load ptr, ptr %5, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %61, i32 0, i32 5
  store ptr null, ptr %62, align 8, !tbaa !21
  %63 = load ptr, ptr %5, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %63, i32 0, i32 6
  store i16 0, ptr %64, align 8, !tbaa !22
  %65 = load ptr, ptr %5, align 8, !tbaa !5
  %66 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %65, i32 0, i32 7
  store volatile i16 0, ptr %66, align 2, !tbaa !23
  %67 = load ptr, ptr %5, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %67, i32 0, i32 9
  store ptr null, ptr %68, align 8, !tbaa !24
  %69 = load ptr, ptr %5, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %69, i32 0, i32 1
  %71 = getelementptr inbounds %struct.SPI_InitTypeDef, ptr %70, i32 0, i32 2
  %72 = load i32, ptr %71, align 8, !tbaa !25
  %73 = zext i32 %72 to i64
  %74 = icmp ugt i64 %73, 15
  br i1 %74, label %75, label %78

75:                                               ; preds = %47
  %76 = load ptr, ptr %5, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %76, i32 0, i32 10
  store ptr @SPI_TxISR_32BIT, ptr %77, align 8, !tbaa !26
  br label %92

78:                                               ; preds = %47
  %79 = load ptr, ptr %5, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %79, i32 0, i32 1
  %81 = getelementptr inbounds %struct.SPI_InitTypeDef, ptr %80, i32 0, i32 2
  %82 = load i32, ptr %81, align 8, !tbaa !25
  %83 = zext i32 %82 to i64
  %84 = icmp ugt i64 %83, 7
  br i1 %84, label %85, label %88

85:                                               ; preds = %78
  %86 = load ptr, ptr %5, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %86, i32 0, i32 10
  store ptr @SPI_TxISR_16BIT, ptr %87, align 8, !tbaa !26
  br label %91

88:                                               ; preds = %78
  %89 = load ptr, ptr %5, align 8, !tbaa !5
  %90 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %89, i32 0, i32 10
  store ptr @SPI_TxISR_8BIT, ptr %90, align 8, !tbaa !26
  br label %91

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

92:                                               ; preds = %91, %75
  %93 = load ptr, ptr %5, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %93, i32 0, i32 1
  %95 = getelementptr inbounds %struct.SPI_InitTypeDef, ptr %94, i32 0, i32 1
  %96 = load i32, ptr %95, align 4, !tbaa !27
  %97 = zext i32 %96 to i64
  %98 = icmp eq i64 %97, 393216
  br i1 %98, label %99, label %108

99:                                               ; preds = %92
  %100 = load ptr, ptr %5, align 8, !tbaa !5
  %101 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %100, i32 0, i32 0
  %102 = load ptr, ptr %101, align 8, !tbaa !28
  %103 = getelementptr inbounds %struct.SPI_TypeDef, ptr %102, i32 0, i32 0
  %104 = load volatile i32, ptr %103, align 4, !tbaa !29
  %105 = zext i32 %104 to i64
  %106 = or i64 %105, 2048
  %107 = trunc i64 %106 to i32
  store volatile i32 %107, ptr %103, align 4, !tbaa !29
  br label %122

108:                                              ; preds = %92
  %109 = load ptr, ptr %5, align 8, !tbaa !5
  %110 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %109, i32 0, i32 0
  %111 = load ptr, ptr %110, align 8, !tbaa !28
  %112 = getelementptr inbounds %struct.SPI_TypeDef, ptr %111, i32 0, i32 3
  %113 = load volatile i32, ptr %112, align 4, !tbaa !31
  %114 = zext i32 %113 to i64
  %115 = and i64 %114, -393217
  %116 = or i64 %115, 131072
  %117 = trunc i64 %116 to i32
  %118 = load ptr, ptr %5, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %118, i32 0, i32 0
  %120 = load ptr, ptr %119, align 8, !tbaa !28
  %121 = getelementptr inbounds %struct.SPI_TypeDef, ptr %120, i32 0, i32 3
  store volatile i32 %117, ptr %121, align 4, !tbaa !31
  br label %122

122:                                              ; preds = %108, %99
  %123 = load ptr, ptr %5, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %123, i32 0, i32 0
  %125 = load ptr, ptr %124, align 8, !tbaa !28
  %126 = getelementptr inbounds %struct.SPI_TypeDef, ptr %125, i32 0, i32 1
  %127 = load volatile i32, ptr %126, align 4, !tbaa !32
  %128 = zext i32 %127 to i64
  %129 = and i64 %128, -65536
  %130 = load i16, ptr %7, align 2, !tbaa !9
  %131 = zext i16 %130 to i64
  %132 = or i64 %129, %131
  %133 = trunc i64 %132 to i32
  %134 = load ptr, ptr %5, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %134, i32 0, i32 0
  %136 = load ptr, ptr %135, align 8, !tbaa !28
  %137 = getelementptr inbounds %struct.SPI_TypeDef, ptr %136, i32 0, i32 1
  store volatile i32 %133, ptr %137, align 4, !tbaa !32
  %138 = load ptr, ptr %5, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %138, i32 0, i32 0
  %140 = load ptr, ptr %139, align 8, !tbaa !28
  %141 = getelementptr inbounds %struct.SPI_TypeDef, ptr %140, i32 0, i32 0
  %142 = load volatile i32, ptr %141, align 4, !tbaa !29
  %143 = zext i32 %142 to i64
  %144 = or i64 %143, 1
  %145 = trunc i64 %144 to i32
  store volatile i32 %145, ptr %141, align 4, !tbaa !29
  %146 = load ptr, ptr %5, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %146, i32 0, i32 0
  %148 = load ptr, ptr %147, align 8, !tbaa !28
  %149 = getelementptr inbounds %struct.SPI_TypeDef, ptr %148, i32 0, i32 4
  %150 = load volatile i32, ptr %149, align 4, !tbaa !33
  %151 = zext i32 %150 to i64
  %152 = or i64 %151, 1834
  %153 = trunc i64 %152 to i32
  store volatile i32 %153, ptr %149, align 4, !tbaa !33
  %154 = load ptr, ptr %5, align 8, !tbaa !5
  %155 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %154, i32 0, i32 1
  %156 = getelementptr inbounds %struct.SPI_InitTypeDef, ptr %155, i32 0, i32 0
  %157 = load i32, ptr %156, align 8, !tbaa !34
  %158 = zext i32 %157 to i64
  %159 = icmp eq i64 %158, 4194304
  br i1 %159, label %160, label %169

160:                                              ; preds = %122
  %161 = load ptr, ptr %5, align 8, !tbaa !5
  %162 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %161, i32 0, i32 0
  %163 = load ptr, ptr %162, align 8, !tbaa !28
  %164 = getelementptr inbounds %struct.SPI_TypeDef, ptr %163, i32 0, i32 0
  %165 = load volatile i32, ptr %164, align 4, !tbaa !29
  %166 = zext i32 %165 to i64
  %167 = or i64 %166, 512
  %168 = trunc i64 %167 to i32
  store volatile i32 %168, ptr %164, align 4, !tbaa !29
  br label %169

169:                                              ; preds = %160, %122
  br label %170

170:                                              ; preds = %169
  %171 = load ptr, ptr %5, align 8, !tbaa !5
  %172 = getelementptr inbounds %struct.__SPI_HandleTypeDef, ptr %171, i32 0, i32 13
  store i32 0, ptr %172, align 8, !tbaa !13
  br label %173

173:                                              ; preds = %170
  br label %174

174:                                              ; preds = %173
  %175 = load i32, ptr %8, align 4, !tbaa !11
  store i32 %175, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %176

176:                                              ; preds = %174, %45, %33, %15
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #2
  %177 = load i32, ptr %4, align 4
  ret i32 %177
}

; Function Attrs: nounwind uwtable
declare hidden void @SPI_TxISR_32BIT(ptr noundef) #1

; Function Attrs: nounwind uwtable
declare hidden void @SPI_TxISR_16BIT(ptr noundef) #1

; Function Attrs: nounwind uwtable
declare hidden void @SPI_TxISR_8BIT(ptr noundef) #1

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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, !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 = !{!"short", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!14, !12, i64 160}
!14 = !{!"__SPI_HandleTypeDef", !6, i64 0, !15, i64 8, !6, i64 96, !10, i64 104, !10, i64 106, !6, i64 112, !10, i64 120, !10, i64 122, !12, i64 124, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !12, i64 160, !12, i64 164, !12, i64 168}
!15 = !{!"", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !12, i64 40, !12, i64 44, !12, i64 48, !12, i64 52, !12, i64 56, !12, i64 60, !12, i64 64, !12, i64 68, !12, i64 72, !12, i64 76, !12, i64 80, !12, i64 84}
!16 = !{!14, !12, i64 164}
!17 = !{!14, !12, i64 168}
!18 = !{!14, !6, i64 96}
!19 = !{!14, !10, i64 104}
!20 = !{!14, !10, i64 106}
!21 = !{!14, !6, i64 112}
!22 = !{!14, !10, i64 120}
!23 = !{!14, !10, i64 122}
!24 = !{!14, !6, i64 128}
!25 = !{!14, !12, i64 16}
!26 = !{!14, !6, i64 136}
!27 = !{!14, !12, i64 12}
!28 = !{!14, !6, i64 0}
!29 = !{!30, !12, i64 0}
!30 = !{!"", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20, !12, i64 24, !12, i64 28, !12, i64 32, !7, i64 36, !12, i64 48, !7, i64 52, !12, i64 64, !12, i64 68, !12, i64 72, !12, i64 76, !12, i64 80}
!31 = !{!30, !12, i64 12}
!32 = !{!30, !12, i64 4}
!33 = !{!30, !12, i64 16}
!34 = !{!14, !12, i64 8}


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

; Function Attrs: nofree norecurse nounwind uwtable
define dso_local range(i32 0, 3) i32 @HAL_SPI_Transmit_IT(ptr noundef %0, ptr noundef %1, i16 noundef zeroext %2) local_unnamed_addr #0 {
  %4 = getelementptr inbounds i8, ptr %0, i64 160
  %5 = load i32, ptr %4, align 8, !tbaa !5
  %6 = icmp eq i32 %5, 1
  br i1 %6, label %62, label %7

7:                                                ; preds = %3
  %8 = icmp eq ptr %1, null
  %9 = icmp eq i16 %2, 0
  %or.cond = or i1 %8, %9
  br i1 %or.cond, label %.sink.split, label %10

10:                                               ; preds = %7
  %11 = getelementptr inbounds i8, ptr %0, i64 164
  %12 = load volatile i32, ptr %11, align 4, !tbaa !13
  %.not = icmp eq i32 %12, 1
  br i1 %.not, label %13, label %.sink.split

13:                                               ; preds = %10
  store volatile i32 3, ptr %11, align 4, !tbaa !13
  %14 = getelementptr inbounds i8, ptr %0, i64 168
  store volatile i32 0, ptr %14, align 8, !tbaa !14
  %15 = getelementptr inbounds i8, ptr %0, i64 96
  store ptr %1, ptr %15, align 8, !tbaa !15
  %16 = getelementptr inbounds i8, ptr %0, i64 104
  store i16 %2, ptr %16, align 8, !tbaa !16
  %17 = getelementptr inbounds i8, ptr %0, i64 106
  store volatile i16 %2, ptr %17, align 2, !tbaa !17
  %18 = getelementptr inbounds i8, ptr %0, i64 112
  store ptr null, ptr %18, align 8, !tbaa !18
  %19 = getelementptr inbounds i8, ptr %0, i64 120
  store i16 0, ptr %19, align 8, !tbaa !19
  %20 = getelementptr inbounds i8, ptr %0, i64 122
  store volatile i16 0, ptr %20, align 2, !tbaa !20
  %21 = getelementptr inbounds i8, ptr %0, i64 128
  store ptr null, ptr %21, align 8, !tbaa !21
  %22 = getelementptr inbounds i8, ptr %0, i64 8
  %23 = getelementptr inbounds i8, ptr %0, i64 16
  %24 = load i32, ptr %23, align 8, !tbaa !22
  %25 = icmp ugt i32 %24, 15
  br i1 %25, label %26, label %28

26:                                               ; preds = %13
  %27 = getelementptr inbounds i8, ptr %0, i64 136
  store ptr @SPI_TxISR_32BIT, ptr %27, align 8, !tbaa !23
  br label %33

28:                                               ; preds = %13
  %29 = icmp ugt i32 %24, 7
  %30 = getelementptr inbounds i8, ptr %0, i64 136
  br i1 %29, label %31, label %32

31:                                               ; preds = %28
  store ptr @SPI_TxISR_16BIT, ptr %30, align 8, !tbaa !23
  br label %33

32:                                               ; preds = %28
  store ptr @SPI_TxISR_8BIT, ptr %30, align 8, !tbaa !23
  br label %33

33:                                               ; preds = %31, %32, %26
  %34 = getelementptr inbounds i8, ptr %0, i64 12
  %35 = load i32, ptr %34, align 4, !tbaa !24
  %36 = icmp eq i32 %35, 393216
  %37 = load ptr, ptr %0, align 8, !tbaa !25
  br i1 %36, label %38, label %41

38:                                               ; preds = %33
  %39 = load volatile i32, ptr %37, align 4, !tbaa !26
  %40 = or i32 %39, 2048
  store volatile i32 %40, ptr %37, align 4, !tbaa !26
  br label %46

41:                                               ; preds = %33
  %42 = getelementptr inbounds i8, ptr %37, i64 12
  %43 = load volatile i32, ptr %42, align 4, !tbaa !28
  %44 = and i32 %43, -393217
  %45 = or disjoint i32 %44, 131072
  store volatile i32 %45, ptr %42, align 4, !tbaa !28
  br label %46

46:                                               ; preds = %41, %38
  %47 = getelementptr inbounds i8, ptr %37, i64 4
  %48 = load volatile i32, ptr %47, align 4, !tbaa !29
  %49 = and i32 %48, -65536
  %50 = zext i16 %2 to i32
  %51 = or disjoint i32 %49, %50
  store volatile i32 %51, ptr %47, align 4, !tbaa !29
  %52 = load volatile i32, ptr %37, align 4, !tbaa !26
  %53 = or i32 %52, 1
  store volatile i32 %53, ptr %37, align 4, !tbaa !26
  %54 = getelementptr inbounds i8, ptr %37, i64 16
  %55 = load volatile i32, ptr %54, align 4, !tbaa !30
  %56 = or i32 %55, 1834
  store volatile i32 %56, ptr %54, align 4, !tbaa !30
  %57 = load i32, ptr %22, align 8, !tbaa !31
  %58 = icmp eq i32 %57, 4194304
  br i1 %58, label %59, label %.sink.split

59:                                               ; preds = %46
  %60 = load volatile i32, ptr %37, align 4, !tbaa !26
  %61 = or i32 %60, 512
  store volatile i32 %61, ptr %37, align 4, !tbaa !26
  br label %.sink.split

.sink.split:                                      ; preds = %59, %46, %10, %7
  %.0.ph = phi i32 [ 1, %7 ], [ 2, %10 ], [ 0, %46 ], [ 0, %59 ]
  store i32 0, ptr %4, align 8, !tbaa !5
  br label %62

62:                                               ; preds = %.sink.split, %3
  %.0 = phi i32 [ 2, %3 ], [ %.0.ph, %.sink.split ]
  ret i32 %.0
}

; Function Attrs: nounwind uwtable
declare hidden void @SPI_TxISR_32BIT(ptr noundef) #1

; Function Attrs: nounwind uwtable
declare hidden void @SPI_TxISR_16BIT(ptr noundef) #1

; Function Attrs: nounwind uwtable
declare hidden void @SPI_TxISR_8BIT(ptr noundef) #1

attributes #0 = { nofree norecurse 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 = { 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" }

!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 160}
!6 = !{!"__SPI_HandleTypeDef", !7, i64 0, !10, i64 8, !7, i64 96, !12, i64 104, !12, i64 106, !7, i64 112, !12, i64 120, !12, i64 122, !11, i64 124, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !11, i64 160, !11, i64 164, !11, i64 168}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"", !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, !11, i64 40, !11, i64 44, !11, i64 48, !11, i64 52, !11, i64 56, !11, i64 60, !11, i64 64, !11, i64 68, !11, i64 72, !11, i64 76, !11, i64 80, !11, i64 84}
!11 = !{!"int", !8, i64 0}
!12 = !{!"short", !8, i64 0}
!13 = !{!6, !11, i64 164}
!14 = !{!6, !11, i64 168}
!15 = !{!6, !7, i64 96}
!16 = !{!6, !12, i64 104}
!17 = !{!6, !12, i64 106}
!18 = !{!6, !7, i64 112}
!19 = !{!6, !12, i64 120}
!20 = !{!6, !12, i64 122}
!21 = !{!6, !7, i64 128}
!22 = !{!6, !11, i64 16}
!23 = !{!6, !7, i64 136}
!24 = !{!6, !11, i64 12}
!25 = !{!6, !7, i64 0}
!26 = !{!27, !11, i64 0}
!27 = !{!"", !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, !8, i64 36, !11, i64 48, !8, i64 52, !11, i64 64, !11, i64 68, !11, i64 72, !11, i64 76, !11, i64 80}
!28 = !{!27, !11, i64 12}
!29 = !{!27, !11, i64 4}
!30 = !{!27, !11, i64 16}
!31 = !{!6, !11, i64 8}


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