; LLVM IR from BrunoLevy/learn-fpga :: FemtoRV/FIRMWARE/EXAMPLES (cube)

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

@sintab = external dso_local global [64 x i32], align 16
@vertices = external dso_local global [8 x [3 x i32]], align 16
@faces = external dso_local global [6 x [4 x i8]], align 16
@colors = external dso_local global [6 x i16], align 2
@gl_polygon_mode = external global i32, align 4
@gl_culling_mode = external global i32, align 4
@GL_width = external global i16, align 2
@GL_height = external global i16, align 2

; Function Attrs: nounwind uwtable
declare dso_local void @rot_x(i32 noundef, ptr noundef, ptr noundef) #0

; 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 void @rot_y(i32 noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @init_points() #0

; Function Attrs: nounwind uwtable
define dso_local i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca [8 x i32], align 16
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @GL_init(i32 noundef -3)
  store i32 1, ptr @gl_polygon_mode, align 4, !tbaa !5
  call void (...) @GL_clear()
  call void @llvm.lifetime.start.p0(i64 32, ptr %2) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #3
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %13

13:                                               ; preds = %166, %0
  %14 = load i32, ptr %3, align 4, !tbaa !5
  %15 = and i32 %14, 63
  %16 = icmp ne i32 %15, 0
  br i1 %16, label %18, label %17

17:                                               ; preds = %13
  call void @init_points()
  br label %18

18:                                               ; preds = %17, %13
  %19 = load i32, ptr %3, align 4, !tbaa !5
  %20 = add nsw i32 %19, 1
  store i32 %20, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #3
  %21 = load i32, ptr %3, align 4, !tbaa !5
  %22 = and i32 %21, 63
  %23 = sext i32 %22 to i64
  %24 = getelementptr inbounds [64 x i32], ptr @sintab, i64 0, i64 %23
  %25 = load i32, ptr %24, align 4, !tbaa !5
  %26 = ashr i32 %25, 8
  %27 = add nsw i32 %26, 400
  store i32 %27, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #3
  store i32 1, ptr %5, align 4, !tbaa !5
  call void @rot_x(i32 noundef 1, ptr noundef @vertices, ptr noundef @vertices)
  call void @rot_y(i32 noundef 1, ptr noundef @vertices, ptr noundef @vertices)
  %28 = load i32, ptr %5, align 4, !tbaa !5
  %29 = icmp ne i32 %28, 0
  br i1 %29, label %31, label %30

30:                                               ; preds = %18
  call void (...) @GL_clear()
  br label %31

31:                                               ; preds = %30, %18
  %32 = load i32, ptr %5, align 4, !tbaa !5
  %33 = icmp ne i32 %32, 0
  br i1 %33, label %95, label %34

34:                                               ; preds = %31
  store i32 1, ptr @gl_polygon_mode, align 4, !tbaa !5
  store i32 2, ptr @gl_culling_mode, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #3
  store i32 0, ptr %6, align 4, !tbaa !5
  br label %35

35:                                               ; preds = %91, %34
  %36 = load i32, ptr %6, align 4, !tbaa !5
  %37 = icmp slt i32 %36, 6
  br i1 %37, label %39, label %38

38:                                               ; preds = %35
  store i32 4, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #3
  br label %94

39:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  store i32 0, ptr %8, align 4, !tbaa !5
  br label %40

40:                                               ; preds = %86, %39
  %41 = load i32, ptr %8, align 4, !tbaa !5
  %42 = icmp slt i32 %41, 4
  br i1 %42, label %44, label %43

43:                                               ; preds = %40
  store i32 7, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  br label %89

44:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  %45 = load i32, ptr %6, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds [6 x [4 x i8]], ptr @faces, i64 0, i64 %46
  %48 = load i32, ptr %8, align 4, !tbaa !5
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds [4 x i8], ptr %47, i64 0, i64 %49
  %51 = load i8, ptr %50, align 1, !tbaa !9
  %52 = sext i8 %51 to i32
  store i32 %52, ptr %9, align 4, !tbaa !5
  %53 = load i16, ptr @GL_width, align 2, !tbaa !10
  %54 = zext i16 %53 to i32
  %55 = sdiv i32 %54, 2
  %56 = load i32, ptr %9, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %57
  %59 = getelementptr inbounds [3 x i32], ptr %58, i64 0, i64 0
  %60 = load i32, ptr %59, align 4, !tbaa !5
  %61 = load i32, ptr %4, align 4, !tbaa !5
  %62 = mul nsw i32 %60, %61
  %63 = sdiv i32 %62, 8192
  %64 = add nsw i32 %55, %63
  %65 = load i32, ptr %8, align 4, !tbaa !5
  %66 = mul nsw i32 2, %65
  %67 = sext i32 %66 to i64
  %68 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 %67
  store i32 %64, ptr %68, align 4, !tbaa !5
  %69 = load i16, ptr @GL_height, align 2, !tbaa !10
  %70 = zext i16 %69 to i32
  %71 = sdiv i32 %70, 2
  %72 = load i32, ptr %9, align 4, !tbaa !5
  %73 = sext i32 %72 to i64
  %74 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %73
  %75 = getelementptr inbounds [3 x i32], ptr %74, i64 0, i64 1
  %76 = load i32, ptr %75, align 4, !tbaa !5
  %77 = load i32, ptr %4, align 4, !tbaa !5
  %78 = mul nsw i32 %76, %77
  %79 = sdiv i32 %78, 8192
  %80 = add nsw i32 %71, %79
  %81 = load i32, ptr %8, align 4, !tbaa !5
  %82 = mul nsw i32 2, %81
  %83 = add nsw i32 %82, 1
  %84 = sext i32 %83 to i64
  %85 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 %84
  store i32 %80, ptr %85, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  br label %86

86:                                               ; preds = %44
  %87 = load i32, ptr %8, align 4, !tbaa !5
  %88 = add nsw i32 %87, 1
  store i32 %88, ptr %8, align 4, !tbaa !5
  br label %40, !llvm.loop !12

89:                                               ; preds = %43
  %90 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 0
  call void @GL_fill_poly(i32 noundef 4, ptr noundef %90, i16 noundef zeroext 25356)
  br label %91

91:                                               ; preds = %89
  %92 = load i32, ptr %6, align 4, !tbaa !5
  %93 = add nsw i32 %92, 1
  store i32 %93, ptr %6, align 4, !tbaa !5
  br label %35, !llvm.loop !14

94:                                               ; preds = %38
  br label %95

95:                                               ; preds = %94, %31
  store i32 1, ptr @gl_culling_mode, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %96

96:                                               ; preds = %163, %95
  %97 = load i32, ptr %10, align 4, !tbaa !5
  %98 = icmp slt i32 %97, 6
  br i1 %98, label %100, label %99

99:                                               ; preds = %96
  store i32 10, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  br label %166

100:                                              ; preds = %96
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %101

101:                                              ; preds = %147, %100
  %102 = load i32, ptr %11, align 4, !tbaa !5
  %103 = icmp slt i32 %102, 4
  br i1 %103, label %105, label %104

104:                                              ; preds = %101
  store i32 13, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  br label %150

105:                                              ; preds = %101
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  %106 = load i32, ptr %10, align 4, !tbaa !5
  %107 = sext i32 %106 to i64
  %108 = getelementptr inbounds [6 x [4 x i8]], ptr @faces, i64 0, i64 %107
  %109 = load i32, ptr %11, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [4 x i8], ptr %108, i64 0, i64 %110
  %112 = load i8, ptr %111, align 1, !tbaa !9
  %113 = sext i8 %112 to i32
  store i32 %113, ptr %12, align 4, !tbaa !5
  %114 = load i16, ptr @GL_width, align 2, !tbaa !10
  %115 = zext i16 %114 to i32
  %116 = sdiv i32 %115, 2
  %117 = load i32, ptr %12, align 4, !tbaa !5
  %118 = sext i32 %117 to i64
  %119 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %118
  %120 = getelementptr inbounds [3 x i32], ptr %119, i64 0, i64 0
  %121 = load i32, ptr %120, align 4, !tbaa !5
  %122 = load i32, ptr %4, align 4, !tbaa !5
  %123 = mul nsw i32 %121, %122
  %124 = sdiv i32 %123, 8192
  %125 = add nsw i32 %116, %124
  %126 = load i32, ptr %11, align 4, !tbaa !5
  %127 = mul nsw i32 2, %126
  %128 = sext i32 %127 to i64
  %129 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 %128
  store i32 %125, ptr %129, align 4, !tbaa !5
  %130 = load i16, ptr @GL_height, align 2, !tbaa !10
  %131 = zext i16 %130 to i32
  %132 = sdiv i32 %131, 2
  %133 = load i32, ptr %12, align 4, !tbaa !5
  %134 = sext i32 %133 to i64
  %135 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %134
  %136 = getelementptr inbounds [3 x i32], ptr %135, i64 0, i64 1
  %137 = load i32, ptr %136, align 4, !tbaa !5
  %138 = load i32, ptr %4, align 4, !tbaa !5
  %139 = mul nsw i32 %137, %138
  %140 = sdiv i32 %139, 8192
  %141 = add nsw i32 %132, %140
  %142 = load i32, ptr %11, align 4, !tbaa !5
  %143 = mul nsw i32 2, %142
  %144 = add nsw i32 %143, 1
  %145 = sext i32 %144 to i64
  %146 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 %145
  store i32 %141, ptr %146, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  br label %147

147:                                              ; preds = %105
  %148 = load i32, ptr %11, align 4, !tbaa !5
  %149 = add nsw i32 %148, 1
  store i32 %149, ptr %11, align 4, !tbaa !5
  br label %101, !llvm.loop !15

150:                                              ; preds = %104
  %151 = load i32, ptr %5, align 4, !tbaa !5
  %152 = icmp ne i32 %151, 0
  br i1 %152, label %153, label %160

153:                                              ; preds = %150
  store i32 2, ptr @gl_polygon_mode, align 4, !tbaa !5
  %154 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 0
  %155 = load i32, ptr %10, align 4, !tbaa !5
  %156 = sext i32 %155 to i64
  %157 = getelementptr inbounds [6 x i16], ptr @colors, i64 0, i64 %156
  %158 = load i16, ptr %157, align 2, !tbaa !10
  call void @GL_fill_poly(i32 noundef 4, ptr noundef %154, i16 noundef zeroext %158)
  store i32 1, ptr @gl_polygon_mode, align 4, !tbaa !5
  %159 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 0
  call void @GL_fill_poly(i32 noundef 4, ptr noundef %159, i16 noundef zeroext 0)
  br label %162

160:                                              ; preds = %150
  %161 = getelementptr inbounds [8 x i32], ptr %2, i64 0, i64 0
  call void @GL_fill_poly(i32 noundef 4, ptr noundef %161, i16 noundef zeroext -33)
  br label %162

162:                                              ; preds = %160, %153
  br label %163

163:                                              ; preds = %162
  %164 = load i32, ptr %10, align 4, !tbaa !5
  %165 = add nsw i32 %164, 1
  store i32 %165, ptr %10, align 4, !tbaa !5
  br label %96, !llvm.loop !16

166:                                              ; preds = %99
  call void @milliwait(i32 noundef 15)
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #3
  br label %13
}

declare void @GL_init(i32 noundef) #2

declare void @GL_clear(...) #2

declare void @GL_fill_poly(i32 noundef, ptr noundef, i16 noundef zeroext) #2

declare void @milliwait(i32 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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!7, !7, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"short", !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}
!14 = distinct !{!14, !13}
!15 = distinct !{!15, !13}
!16 = distinct !{!16, !13}


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

@sintab = external dso_local local_unnamed_addr global [64 x i32], align 16
@vertices = external dso_local global [8 x [3 x i32]], align 16
@faces = external dso_local local_unnamed_addr global [6 x [4 x i8]], align 16
@colors = external dso_local local_unnamed_addr global [6 x i16], align 2
@gl_polygon_mode = external local_unnamed_addr global i32, align 4
@gl_culling_mode = external local_unnamed_addr global i32, align 4
@GL_width = external local_unnamed_addr global i16, align 2
@GL_height = external local_unnamed_addr global i16, align 2

; Function Attrs: nounwind uwtable
declare dso_local void @rot_x(i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #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: nounwind uwtable
declare dso_local void @rot_y(i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
declare dso_local void @init_points() local_unnamed_addr #0

; Function Attrs: noreturn nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = alloca [8 x i32], align 16
  tail call void @GL_init(i32 noundef -3) #4
  store i32 1, ptr @gl_polygon_mode, align 4, !tbaa !5
  tail call void (...) @GL_clear() #4
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %1) #4
  %2 = getelementptr inbounds i8, ptr %1, i64 16
  br label %3

3:                                                ; preds = %53, %0
  %.0 = phi i32 [ 0, %0 ], [ %7, %53 ]
  %4 = and i32 %.0, 63
  %.not = icmp eq i32 %4, 0
  br i1 %.not, label %5, label %6

5:                                                ; preds = %3
  call void @init_points()
  br label %6

6:                                                ; preds = %5, %3
  %7 = add nuw nsw i32 %.0, 1
  %8 = and i32 %7, 63
  %9 = zext nneg i32 %8 to i64
  %10 = getelementptr inbounds [64 x i32], ptr @sintab, i64 0, i64 %9
  %11 = load i32, ptr %10, align 4, !tbaa !5
  %12 = ashr i32 %11, 8
  %13 = add nsw i32 %12, 400
  call void @rot_x(i32 noundef 1, ptr noundef nonnull @vertices, ptr noundef nonnull @vertices)
  call void @rot_y(i32 noundef 1, ptr noundef nonnull @vertices, ptr noundef nonnull @vertices)
  store i32 1, ptr @gl_culling_mode, align 4, !tbaa !5
  %14 = insertelement <4 x i32> poison, i32 %13, i64 0
  %15 = shufflevector <4 x i32> %14, <4 x i32> poison, <4 x i32> zeroinitializer
  br label %.preheader

.preheader:                                       ; preds = %6, %.preheader
  %indvars.iv = phi i64 [ 0, %6 ], [ %indvars.iv.next, %.preheader ]
  %16 = load i16, ptr @GL_width, align 2, !tbaa !9
  %17 = load i16, ptr @GL_height, align 2, !tbaa !9
  %18 = getelementptr inbounds [6 x [4 x i8]], ptr @faces, i64 0, i64 %indvars.iv, i64 0
  %19 = load i8, ptr %18, align 4, !tbaa !11
  %20 = sext i8 %19 to i64
  %21 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %20
  %22 = load <2 x i32>, ptr %21, align 4, !tbaa !5
  %23 = getelementptr inbounds [6 x [4 x i8]], ptr @faces, i64 0, i64 %indvars.iv, i64 1
  %24 = load i8, ptr %23, align 1, !tbaa !11
  %25 = sext i8 %24 to i64
  %26 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %25
  %27 = load <2 x i32>, ptr %26, align 4, !tbaa !5
  %28 = insertelement <2 x i16> poison, i16 %16, i64 0
  %29 = insertelement <2 x i16> %28, i16 %17, i64 1
  %30 = lshr <2 x i16> %29, <i16 1, i16 1>
  %31 = zext nneg <2 x i16> %30 to <2 x i32>
  %32 = shufflevector <2 x i32> %31, <2 x i32> poison, <4 x i32> <i32 0, i32 1, i32 0, i32 1>
  %33 = shufflevector <2 x i32> %22, <2 x i32> %27, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
  %34 = mul nsw <4 x i32> %33, %15
  %35 = sdiv <4 x i32> %34, <i32 8192, i32 8192, i32 8192, i32 8192>
  %36 = add nsw <4 x i32> %35, %32
  store <4 x i32> %36, ptr %1, align 16, !tbaa !5
  %37 = getelementptr inbounds [6 x [4 x i8]], ptr @faces, i64 0, i64 %indvars.iv, i64 2
  %38 = load i8, ptr %37, align 2, !tbaa !11
  %39 = sext i8 %38 to i64
  %40 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %39
  %41 = load <2 x i32>, ptr %40, align 4, !tbaa !5
  %42 = getelementptr inbounds [6 x [4 x i8]], ptr @faces, i64 0, i64 %indvars.iv, i64 3
  %43 = load i8, ptr %42, align 1, !tbaa !11
  %44 = sext i8 %43 to i64
  %45 = getelementptr inbounds [8 x [3 x i32]], ptr @vertices, i64 0, i64 %44
  %46 = load <2 x i32>, ptr %45, align 4, !tbaa !5
  %47 = shufflevector <2 x i32> %41, <2 x i32> %46, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
  %48 = mul nsw <4 x i32> %47, %15
  %49 = sdiv <4 x i32> %48, <i32 8192, i32 8192, i32 8192, i32 8192>
  %50 = add nsw <4 x i32> %49, %32
  store <4 x i32> %50, ptr %2, align 16, !tbaa !5
  store i32 2, ptr @gl_polygon_mode, align 4, !tbaa !5
  %51 = getelementptr inbounds [6 x i16], ptr @colors, i64 0, i64 %indvars.iv
  %52 = load i16, ptr %51, align 2, !tbaa !9
  call void @GL_fill_poly(i32 noundef 4, ptr noundef nonnull %1, i16 noundef zeroext %52) #4
  store i32 1, ptr @gl_polygon_mode, align 4, !tbaa !5
  call void @GL_fill_poly(i32 noundef 4, ptr noundef nonnull %1, i16 noundef zeroext 0) #4
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 6
  br i1 %exitcond.not, label %53, label %.preheader, !llvm.loop !12

53:                                               ; preds = %.preheader
  call void @milliwait(i32 noundef 15) #4
  br label %3
}

declare void @GL_init(i32 noundef) local_unnamed_addr #3

declare void @GL_clear(...) local_unnamed_addr #3

declare void @GL_fill_poly(i32 noundef, ptr noundef, i16 noundef zeroext) local_unnamed_addr #3

declare void @milliwait(i32 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 = { noreturn 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 = { 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 = !{!"int", !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 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,LICMPass,LoopRotatePass,LoopSimplifyPass,PostOrderFunctionAttrsPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass,VectorCombinePass