; LLVM IR from fast-pack/simdcomp :: benchmarks (bitpackingbenchmark)

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

@.str = external hidden unnamed_addr constant [10 x i8], align 1
@__func__.demo128 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [71 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [3 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local ptr @get_random_array_from_bit_width(i32 noundef, i32 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: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #2

; 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
define dso_local void @demo128() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i64, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %1) #5
  store i32 128, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  %23 = call i32 (ptr, ...) @printf(ptr noundef @.str, ptr noundef @__func__.demo128)
  %24 = call i32 (ptr, ...) @printf(ptr noundef @.str.1, i32 noundef 128)
  %25 = call i32 (ptr, ...) @printf(ptr noundef @.str.2)
  store i32 1, ptr %2, align 4, !tbaa !5
  br label %26

26:                                               ; preds = %140, %0
  %27 = load i32, ptr %2, align 4, !tbaa !5
  %28 = icmp ule i32 %27, 32
  br i1 %28, label %29, label %143

29:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #5
  %30 = load i32, ptr %2, align 4, !tbaa !5
  %31 = call ptr @get_random_array_from_bit_width(i32 noundef 128, i32 noundef %30)
  store ptr %31, ptr %4, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  %32 = call noalias ptr @malloc(i64 noundef 512) #6
  store ptr %32, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %33 = call noalias ptr @malloc(i64 noundef 512) #6
  store ptr %33, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  store i32 500, ptr %7, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %34 = load i32, ptr %2, align 4, !tbaa !5
  %35 = call i32 (ptr, ...) @printf(ptr noundef @.str.3, i32 noundef %34)
  store i64 -1, ptr %8, align 8, !tbaa !11
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %36

36:                                               ; preds = %77, %29
  %37 = load i32, ptr %3, align 4, !tbaa !5
  %38 = load i32, ptr %7, align 4, !tbaa !5
  %39 = icmp ult i32 %37, %38
  br i1 %39, label %40, label %80

40:                                               ; preds = %36
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  call void asm sideeffect "", "~{memory},~{dirflag},~{fpsr},~{flags}"() #5, !srcloc !13
  br label %41

41:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  %42 = call { i32, i32 } asm sideeffect "cpuid\0A\09rdtsc\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #5, !srcloc !14
  %43 = extractvalue { i32, i32 } %42, 0
  %44 = extractvalue { i32, i32 } %42, 1
  store i32 %43, ptr %12, align 4, !tbaa !5
  store i32 %44, ptr %13, align 4, !tbaa !5
  %45 = load i32, ptr %12, align 4, !tbaa !5
  %46 = zext i32 %45 to i64
  %47 = shl i64 %46, 32
  %48 = load i32, ptr %13, align 4, !tbaa !5
  %49 = zext i32 %48 to i64
  %50 = or i64 %47, %49
  store i64 %50, ptr %9, align 8, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %51

51:                                               ; preds = %41
  br label %52

52:                                               ; preds = %51
  %53 = load ptr, ptr %4, align 8, !tbaa !9
  %54 = load ptr, ptr %5, align 8, !tbaa !9
  %55 = load i32, ptr %2, align 4, !tbaa !5
  call void @simdpackwithoutmask(ptr noundef %53, ptr noundef %54, i32 noundef %55)
  br label %56

56:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %57 = call { i32, i32 } asm sideeffect "rdtscp\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09cpuid\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #5, !srcloc !15
  %58 = extractvalue { i32, i32 } %57, 0
  %59 = extractvalue { i32, i32 } %57, 1
  store i32 %58, ptr %14, align 4, !tbaa !5
  store i32 %59, ptr %15, align 4, !tbaa !5
  %60 = load i32, ptr %14, align 4, !tbaa !5
  %61 = zext i32 %60 to i64
  %62 = shl i64 %61, 32
  %63 = load i32, ptr %15, align 4, !tbaa !5
  %64 = zext i32 %63 to i64
  %65 = or i64 %62, %64
  store i64 %65, ptr %10, align 8, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %66

66:                                               ; preds = %56
  br label %67

67:                                               ; preds = %66
  %68 = load i64, ptr %10, align 8, !tbaa !11
  %69 = load i64, ptr %9, align 8, !tbaa !11
  %70 = sub i64 %68, %69
  store i64 %70, ptr %11, align 8, !tbaa !11
  %71 = load i64, ptr %11, align 8, !tbaa !11
  %72 = load i64, ptr %8, align 8, !tbaa !11
  %73 = icmp ult i64 %71, %72
  br i1 %73, label %74, label %76

74:                                               ; preds = %67
  %75 = load i64, ptr %11, align 8, !tbaa !11
  store i64 %75, ptr %8, align 8, !tbaa !11
  br label %76

76:                                               ; preds = %74, %67
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %77

77:                                               ; preds = %76
  %78 = load i32, ptr %3, align 4, !tbaa !5
  %79 = add i32 %78, 1
  store i32 %79, ptr %3, align 4, !tbaa !5
  br label %36, !llvm.loop !16

80:                                               ; preds = %36
  %81 = load i64, ptr %8, align 8, !tbaa !11
  %82 = uitofp i64 %81 to double
  %83 = fmul double %82, 1.000000e+00
  %84 = fdiv double %83, 1.280000e+02
  %85 = call i32 (ptr, ...) @printf(ptr noundef @.str.4, double noundef %84)
  store i64 -1, ptr %8, align 8, !tbaa !11
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %86

86:                                               ; preds = %127, %80
  %87 = load i32, ptr %3, align 4, !tbaa !5
  %88 = load i32, ptr %7, align 4, !tbaa !5
  %89 = icmp ult i32 %87, %88
  br i1 %89, label %90, label %130

90:                                               ; preds = %86
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  call void asm sideeffect "", "~{memory},~{dirflag},~{fpsr},~{flags}"() #5, !srcloc !18
  br label %91

91:                                               ; preds = %90
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  %92 = call { i32, i32 } asm sideeffect "cpuid\0A\09rdtsc\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #5, !srcloc !19
  %93 = extractvalue { i32, i32 } %92, 0
  %94 = extractvalue { i32, i32 } %92, 1
  store i32 %93, ptr %19, align 4, !tbaa !5
  store i32 %94, ptr %20, align 4, !tbaa !5
  %95 = load i32, ptr %19, align 4, !tbaa !5
  %96 = zext i32 %95 to i64
  %97 = shl i64 %96, 32
  %98 = load i32, ptr %20, align 4, !tbaa !5
  %99 = zext i32 %98 to i64
  %100 = or i64 %97, %99
  store i64 %100, ptr %16, align 8, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  br label %101

101:                                              ; preds = %91
  br label %102

102:                                              ; preds = %101
  %103 = load ptr, ptr %5, align 8, !tbaa !9
  %104 = load ptr, ptr %6, align 8, !tbaa !9
  %105 = load i32, ptr %2, align 4, !tbaa !5
  call void @simdunpack(ptr noundef %103, ptr noundef %104, i32 noundef %105)
  br label %106

106:                                              ; preds = %102
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #5
  %107 = call { i32, i32 } asm sideeffect "rdtscp\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09cpuid\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #5, !srcloc !20
  %108 = extractvalue { i32, i32 } %107, 0
  %109 = extractvalue { i32, i32 } %107, 1
  store i32 %108, ptr %21, align 4, !tbaa !5
  store i32 %109, ptr %22, align 4, !tbaa !5
  %110 = load i32, ptr %21, align 4, !tbaa !5
  %111 = zext i32 %110 to i64
  %112 = shl i64 %111, 32
  %113 = load i32, ptr %22, align 4, !tbaa !5
  %114 = zext i32 %113 to i64
  %115 = or i64 %112, %114
  store i64 %115, ptr %17, align 8, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #5
  br label %116

116:                                              ; preds = %106
  br label %117

117:                                              ; preds = %116
  %118 = load i64, ptr %17, align 8, !tbaa !11
  %119 = load i64, ptr %16, align 8, !tbaa !11
  %120 = sub i64 %118, %119
  store i64 %120, ptr %18, align 8, !tbaa !11
  %121 = load i64, ptr %18, align 8, !tbaa !11
  %122 = load i64, ptr %8, align 8, !tbaa !11
  %123 = icmp ult i64 %121, %122
  br i1 %123, label %124, label %126

124:                                              ; preds = %117
  %125 = load i64, ptr %18, align 8, !tbaa !11
  store i64 %125, ptr %8, align 8, !tbaa !11
  br label %126

126:                                              ; preds = %124, %117
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  br label %127

127:                                              ; preds = %126
  %128 = load i32, ptr %3, align 4, !tbaa !5
  %129 = add i32 %128, 1
  store i32 %129, ptr %3, align 4, !tbaa !5
  br label %86, !llvm.loop !21

130:                                              ; preds = %86
  %131 = load i64, ptr %8, align 8, !tbaa !11
  %132 = uitofp i64 %131 to double
  %133 = fmul double %132, 1.000000e+00
  %134 = fdiv double %133, 1.280000e+02
  %135 = call i32 (ptr, ...) @printf(ptr noundef @.str.4, double noundef %134)
  %136 = load ptr, ptr %4, align 8, !tbaa !9
  call void @free(ptr noundef %136) #5
  %137 = load ptr, ptr %5, align 8, !tbaa !9
  call void @free(ptr noundef %137) #5
  %138 = load ptr, ptr %6, align 8, !tbaa !9
  call void @free(ptr noundef %138) #5
  %139 = call i32 (ptr, ...) @printf(ptr noundef @.str.5)
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  br label %140

140:                                              ; preds = %130
  %141 = load i32, ptr %2, align 4, !tbaa !5
  %142 = add i32 %141, 1
  store i32 %142, ptr %2, align 4, !tbaa !5
  br label %26, !llvm.loop !22

143:                                              ; preds = %26
  %144 = call i32 (ptr, ...) @printf(ptr noundef @.str.6)
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %1) #5
  ret void
}

declare i32 @printf(ptr noundef, ...) #3

declare void @simdpackwithoutmask(ptr noundef, ptr noundef, i32 noundef) #3

declare void @simdunpack(ptr noundef, ptr noundef, i32 noundef) #3

; Function Attrs: nounwind
declare void @free(ptr noundef) #4

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 = { nounwind allocsize(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 "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 #5 = { nounwind }
attributes #6 = { nounwind allocsize(0) }

!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 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = !{i64 3113}
!14 = !{i64 2151560295, i64 2151560303, i64 2151560383, i64 2151560471, i64 2151560551}
!15 = !{i64 2151561040, i64 2151561049, i64 2151561136, i64 2151561216, i64 2151561288}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = !{i64 3623}
!19 = !{i64 2151561785, i64 2151561793, i64 2151561873, i64 2151561961, i64 2151562041}
!20 = !{i64 2151562530, i64 2151562539, i64 2151562626, i64 2151562706, i64 2151562778}
!21 = distinct !{!21, !17}
!22 = distinct !{!22, !17}


; 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 = external hidden unnamed_addr constant [10 x i8], align 1
@__func__.demo128 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [71 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [3 x i8], align 1

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

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local void @demo128() local_unnamed_addr #0 {
  %1 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str, ptr noundef nonnull @__func__.demo128)
  %2 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 128)
  %3 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2)
  br label %4

4:                                                ; preds = %0, %41
  %.053 = phi i32 [ 1, %0 ], [ %46, %41 ]
  %5 = tail call ptr @get_random_array_from_bit_width(i32 noundef 128, i32 noundef %.053)
  %6 = tail call noalias dereferenceable_or_null(512) ptr @malloc(i64 noundef 512) #6
  %7 = tail call noalias dereferenceable_or_null(512) ptr @malloc(i64 noundef 512) #6
  %8 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i32 noundef %.053)
  br label %9

9:                                                ; preds = %4, %9
  %.03850 = phi i32 [ 0, %4 ], [ %22, %9 ]
  %.03949 = phi i64 [ -1, %4 ], [ %spec.select, %9 ]
  tail call void asm sideeffect "", "~{memory},~{dirflag},~{fpsr},~{flags}"() #7, !srcloc !5
  %10 = tail call { i32, i32 } asm sideeffect "cpuid\0A\09rdtsc\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #7, !srcloc !6
  %11 = extractvalue { i32, i32 } %10, 0
  %12 = extractvalue { i32, i32 } %10, 1
  %.neg55 = sub i32 0, %11
  %.neg55.z = zext i32 %.neg55 to i64
  %.neg54 = shl nuw i64 %.neg55.z, 32
  %13 = zext i32 %12 to i64
  tail call void @simdpackwithoutmask(ptr noundef %5, ptr noundef %6, i32 noundef %.053) #7
  %14 = tail call { i32, i32 } asm sideeffect "rdtscp\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09cpuid\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #7, !srcloc !7
  %15 = extractvalue { i32, i32 } %14, 0
  %16 = extractvalue { i32, i32 } %14, 1
  %17 = zext i32 %15 to i64
  %18 = shl nuw i64 %17, 32
  %19 = zext i32 %16 to i64
  %.neg48 = sub i64 %.neg54, %13
  %20 = add i64 %.neg48, %19
  %21 = add i64 %20, %18
  %spec.select = tail call i64 @llvm.umin.i64(i64 %21, i64 %.03949)
  %22 = add nuw nsw i32 %.03850, 1
  %exitcond.not = icmp eq i32 %22, 500
  br i1 %exitcond.not, label %23, label %9, !llvm.loop !8

23:                                               ; preds = %9
  %24 = uitofp i64 %spec.select to double
  %25 = fmul double %24, 7.812500e-03
  %26 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4, double noundef %25)
  br label %27

27:                                               ; preds = %23, %27
  %.152 = phi i32 [ 0, %23 ], [ %40, %27 ]
  %.251 = phi i64 [ -1, %23 ], [ %spec.select43, %27 ]
  tail call void asm sideeffect "", "~{memory},~{dirflag},~{fpsr},~{flags}"() #7, !srcloc !10
  %28 = tail call { i32, i32 } asm sideeffect "cpuid\0A\09rdtsc\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #7, !srcloc !11
  %29 = extractvalue { i32, i32 } %28, 0
  %30 = extractvalue { i32, i32 } %28, 1
  %.neg57 = sub i32 0, %29
  %.neg57.z = zext i32 %.neg57 to i64
  %.neg56 = shl nuw i64 %.neg57.z, 32
  %31 = zext i32 %30 to i64
  tail call void @simdunpack(ptr noundef %6, ptr noundef %7, i32 noundef %.053) #7
  %32 = tail call { i32, i32 } asm sideeffect "rdtscp\0A\09mov %edx, $0\0A\09mov %eax, $1\0A\09cpuid\0A\09", "=r,=r,~{rax},~{rbx},~{rcx},~{rdx},~{dirflag},~{fpsr},~{flags}"() #7, !srcloc !12
  %33 = extractvalue { i32, i32 } %32, 0
  %34 = extractvalue { i32, i32 } %32, 1
  %35 = zext i32 %33 to i64
  %36 = shl nuw i64 %35, 32
  %37 = zext i32 %34 to i64
  %.neg45 = sub i64 %.neg56, %31
  %38 = add i64 %.neg45, %37
  %39 = add i64 %38, %36
  %spec.select43 = tail call i64 @llvm.umin.i64(i64 %39, i64 %.251)
  %40 = add nuw nsw i32 %.152, 1
  %exitcond58.not = icmp eq i32 %40, 500
  br i1 %exitcond58.not, label %41, label %27, !llvm.loop !13

41:                                               ; preds = %27
  %42 = uitofp i64 %spec.select43 to double
  %43 = fmul double %42, 7.812500e-03
  %44 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4, double noundef %43)
  tail call void @free(ptr noundef %5) #7
  tail call void @free(ptr noundef %6) #7
  tail call void @free(ptr noundef %7) #7
  %45 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5)
  %46 = add nuw nsw i32 %.053, 1
  %exitcond59.not = icmp eq i32 %46, 33
  br i1 %exitcond59.not, label %47, label %4, !llvm.loop !14

47:                                               ; preds = %41
  %48 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.6)
  ret void
}

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

declare void @simdpackwithoutmask(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

declare void @simdunpack(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.umin.i64(i64, i64) #5

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 nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 = { nofree nounwind "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 nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite) "alloc-family"="malloc" "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 #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nounwind allocsize(0) }
attributes #7 = { 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 = !{i64 3113}
!6 = !{i64 2151560295, i64 2151560303, i64 2151560383, i64 2151560471, i64 2151560551}
!7 = !{i64 2151561040, i64 2151561049, i64 2151561136, i64 2151561216, i64 2151561288}
!8 = distinct !{!8, !9}
!9 = !{!"llvm.loop.mustprogress"}
!10 = !{i64 3623}
!11 = !{i64 2151561785, i64 2151561793, i64 2151561873, i64 2151561961, i64 2151562041}
!12 = !{i64 2151562530, i64 2151562539, i64 2151562626, i64 2151562706, i64 2151562778}
!13 = distinct !{!13, !9}
!14 = distinct !{!14, !9}


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