; LLVM IR from jgaeddert/liquid-dsp :: src/buffer/tests (cbuffer_autotest)

; 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 [90 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [3 x i8], align 1
@liquid_autotest_verbose = external global i32, align 4
@.str.42 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [50 x i8], align 1

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

declare void @liquid_autotest_passed(...) #1

declare void @liquid_autotest_failed_expr(ptr noundef, i32 noundef, ptr noundef, double noundef, ptr noundef, ptr noundef, double noundef) #1

declare i32 @liquid_autotest_same_data(ptr noundef, ptr noundef, i32 noundef) #1

declare void @liquid_autotest_failed_msg(ptr noundef, i32 noundef, ptr noundef) #1

declare void @liquid_autotest_print_array(ptr noundef, i32 noundef) #1

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

declare ptr @cbuffercf_create(i32 noundef) #1

declare i32 @cbuffercf_read(ptr noundef, i32 noundef, ptr noundef, ptr noundef) #1

declare i32 @cbuffercf_release(ptr noundef, i32 noundef) #1

declare i32 @cbuffercf_push(ptr noundef, <2 x float> noundef) #1

declare i32 @cbuffercf_destroy(ptr noundef) #1

; Function Attrs: nounwind uwtable
define dso_local void @autotest_cbuffer_copy() #2 {
  %1 = alloca i32, align 4
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca { float, float }, align 4
  %5 = alloca { float, float }, align 4
  %6 = alloca ptr, align 8
  %7 = alloca { float, float }, align 4
  %8 = alloca { float, float }, align 4
  %9 = alloca { float, float }, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %1) #3
  store i32 20, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #3
  %15 = load i32, ptr %1, align 4, !tbaa !5
  %16 = call ptr @cbuffercf_create(i32 noundef %15)
  store ptr %16, ptr %2, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #3
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %17

17:                                               ; preds = %38, %0
  %18 = load i32, ptr %3, align 4, !tbaa !5
  %19 = load i32, ptr %1, align 4, !tbaa !5
  %20 = icmp ult i32 %18, %19
  br i1 %20, label %21, label %41

21:                                               ; preds = %17
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #3
  %22 = call float (...) @randnf()
  %23 = call float (...) @randnf()
  %24 = fmul float 0.000000e+00, %23
  %25 = fmul float 1.000000e+00, %23
  %26 = fadd float %22, %24
  %27 = getelementptr inbounds { float, float }, ptr %4, i32 0, i32 0
  %28 = getelementptr inbounds { float, float }, ptr %4, i32 0, i32 1
  store float %26, ptr %27, align 4
  store float %25, ptr %28, align 4
  %29 = load ptr, ptr %2, align 8, !tbaa !9
  %30 = getelementptr inbounds { float, float }, ptr %4, i32 0, i32 0
  %31 = load float, ptr %30, align 4
  %32 = getelementptr inbounds { float, float }, ptr %4, i32 0, i32 1
  %33 = load float, ptr %32, align 4
  %34 = getelementptr inbounds { float, float }, ptr %5, i32 0, i32 0
  %35 = getelementptr inbounds { float, float }, ptr %5, i32 0, i32 1
  store float %31, ptr %34, align 4
  store float %33, ptr %35, align 4
  %36 = load <2 x float>, ptr %5, align 4
  %37 = call i32 @cbuffercf_push(ptr noundef %29, <2 x float> noundef %36)
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #3
  br label %38

38:                                               ; preds = %21
  %39 = load i32, ptr %3, align 4, !tbaa !5
  %40 = add i32 %39, 1
  store i32 %40, ptr %3, align 4, !tbaa !5
  br label %17, !llvm.loop !11

41:                                               ; preds = %17
  %42 = load ptr, ptr %2, align 8, !tbaa !9
  %43 = call i32 @cbuffercf_release(ptr noundef %42, i32 noundef 13)
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #3
  %44 = load ptr, ptr %2, align 8, !tbaa !9
  %45 = call ptr @cbuffercf_copy(ptr noundef %44)
  store ptr %45, ptr %6, align 8, !tbaa !9
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %46

46:                                               ; preds = %75, %41
  %47 = load i32, ptr %3, align 4, !tbaa !5
  %48 = icmp ult i32 %47, 12
  br i1 %48, label %49, label %78

49:                                               ; preds = %46
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #3
  %50 = call float (...) @randnf()
  %51 = call float (...) @randnf()
  %52 = fmul float 0.000000e+00, %51
  %53 = fmul float 1.000000e+00, %51
  %54 = fadd float %50, %52
  %55 = getelementptr inbounds { float, float }, ptr %7, i32 0, i32 0
  %56 = getelementptr inbounds { float, float }, ptr %7, i32 0, i32 1
  store float %54, ptr %55, align 4
  store float %53, ptr %56, align 4
  %57 = load ptr, ptr %2, align 8, !tbaa !9
  %58 = getelementptr inbounds { float, float }, ptr %7, i32 0, i32 0
  %59 = load float, ptr %58, align 4
  %60 = getelementptr inbounds { float, float }, ptr %7, i32 0, i32 1
  %61 = load float, ptr %60, align 4
  %62 = getelementptr inbounds { float, float }, ptr %8, i32 0, i32 0
  %63 = getelementptr inbounds { float, float }, ptr %8, i32 0, i32 1
  store float %59, ptr %62, align 4
  store float %61, ptr %63, align 4
  %64 = load <2 x float>, ptr %8, align 4
  %65 = call i32 @cbuffercf_push(ptr noundef %57, <2 x float> noundef %64)
  %66 = load ptr, ptr %6, align 8, !tbaa !9
  %67 = getelementptr inbounds { float, float }, ptr %7, i32 0, i32 0
  %68 = load float, ptr %67, align 4
  %69 = getelementptr inbounds { float, float }, ptr %7, i32 0, i32 1
  %70 = load float, ptr %69, align 4
  %71 = getelementptr inbounds { float, float }, ptr %9, i32 0, i32 0
  %72 = getelementptr inbounds { float, float }, ptr %9, i32 0, i32 1
  store float %68, ptr %71, align 4
  store float %70, ptr %72, align 4
  %73 = load <2 x float>, ptr %9, align 4
  %74 = call i32 @cbuffercf_push(ptr noundef %66, <2 x float> noundef %73)
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #3
  br label %75

75:                                               ; preds = %49
  %76 = load i32, ptr %3, align 4, !tbaa !5
  %77 = add i32 %76, 1
  store i32 %77, ptr %3, align 4, !tbaa !5
  br label %46, !llvm.loop !13

78:                                               ; preds = %46
  %79 = load ptr, ptr %2, align 8, !tbaa !9
  %80 = call i32 @cbuffercf_release(ptr noundef %79, i32 noundef 4)
  %81 = load ptr, ptr %6, align 8, !tbaa !9
  %82 = call i32 @cbuffercf_release(ptr noundef %81, i32 noundef 4)
  %83 = load ptr, ptr %2, align 8, !tbaa !9
  %84 = call i32 @cbuffercf_space_available(ptr noundef %83)
  %85 = load ptr, ptr %6, align 8, !tbaa !9
  %86 = call i32 @cbuffercf_space_available(ptr noundef %85)
  %87 = icmp ne i32 %84, %86
  br i1 %87, label %88, label %95

88:                                               ; preds = %78
  %89 = load ptr, ptr %2, align 8, !tbaa !9
  %90 = call i32 @cbuffercf_space_available(ptr noundef %89)
  %91 = uitofp i32 %90 to double
  %92 = load ptr, ptr %6, align 8, !tbaa !9
  %93 = call i32 @cbuffercf_space_available(ptr noundef %92)
  %94 = uitofp i32 %93 to double
  call void @liquid_autotest_failed_expr(ptr noundef @.str, i32 noundef 362, ptr noundef @.str.42, double noundef %91, ptr noundef @.str.3, ptr noundef @.str.43, double noundef %94)
  br label %96

95:                                               ; preds = %78
  call void (...) @liquid_autotest_passed()
  br label %96

96:                                               ; preds = %95, %88
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  %97 = load ptr, ptr %2, align 8, !tbaa !9
  %98 = call i32 @cbuffercf_space_available(ptr noundef %97)
  store i32 %98, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 4, 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
  %99 = load ptr, ptr %2, align 8, !tbaa !9
  %100 = load i32, ptr %10, align 4, !tbaa !5
  %101 = call i32 @cbuffercf_read(ptr noundef %99, i32 noundef %100, ptr noundef %13, ptr noundef %11)
  %102 = load ptr, ptr %6, align 8, !tbaa !9
  %103 = load i32, ptr %10, align 4, !tbaa !5
  %104 = call i32 @cbuffercf_read(ptr noundef %102, i32 noundef %103, ptr noundef %14, ptr noundef %12)
  %105 = load i32, ptr %11, align 4, !tbaa !5
  %106 = load i32, ptr %12, align 4, !tbaa !5
  %107 = icmp ne i32 %105, %106
  br i1 %107, label %108, label %113

108:                                              ; preds = %96
  %109 = load i32, ptr %11, align 4, !tbaa !5
  %110 = uitofp i32 %109 to double
  %111 = load i32, ptr %12, align 4, !tbaa !5
  %112 = uitofp i32 %111 to double
  call void @liquid_autotest_failed_expr(ptr noundef @.str, i32 noundef 370, ptr noundef @.str.44, double noundef %110, ptr noundef @.str.3, ptr noundef @.str.45, double noundef %112)
  br label %114

113:                                              ; preds = %96
  call void (...) @liquid_autotest_passed()
  br label %114

114:                                              ; preds = %113, %108
  %115 = load ptr, ptr %13, align 8, !tbaa !9
  %116 = load ptr, ptr %14, align 8, !tbaa !9
  %117 = load i32, ptr %11, align 4, !tbaa !5
  %118 = zext i32 %117 to i64
  %119 = mul i64 %118, 8
  %120 = trunc i64 %119 to i32
  %121 = call i32 @liquid_autotest_same_data(ptr noundef %115, ptr noundef %116, i32 noundef %120)
  %122 = icmp ne i32 %121, 0
  br i1 %122, label %138, label %123

123:                                              ; preds = %114
  call void @liquid_autotest_failed_msg(ptr noundef @.str, i32 noundef 372, ptr noundef @.str.46)
  %124 = load i32, ptr @liquid_autotest_verbose, align 4, !tbaa !5
  %125 = icmp ne i32 %124, 0
  br i1 %125, label %126, label %137

126:                                              ; preds = %123
  %127 = load ptr, ptr %13, align 8, !tbaa !9
  %128 = load i32, ptr %11, align 4, !tbaa !5
  %129 = zext i32 %128 to i64
  %130 = mul i64 %129, 8
  %131 = trunc i64 %130 to i32
  call void @liquid_autotest_print_array(ptr noundef %127, i32 noundef %131)
  %132 = load ptr, ptr %14, align 8, !tbaa !9
  %133 = load i32, ptr %11, align 4, !tbaa !5
  %134 = zext i32 %133 to i64
  %135 = mul i64 %134, 8
  %136 = trunc i64 %135 to i32
  call void @liquid_autotest_print_array(ptr noundef %132, i32 noundef %136)
  br label %137

137:                                              ; preds = %126, %123
  br label %139

138:                                              ; preds = %114
  call void (...) @liquid_autotest_passed()
  br label %139

139:                                              ; preds = %138, %137
  %140 = load ptr, ptr %2, align 8, !tbaa !9
  %141 = call i32 @cbuffercf_destroy(ptr noundef %140)
  %142 = load ptr, ptr %6, align 8, !tbaa !9
  %143 = call i32 @cbuffercf_destroy(ptr noundef %142)
  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 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %1) #3
  ret void
}

declare float @randnf(...) #1

declare ptr @cbuffercf_copy(ptr noundef) #1

declare i32 @cbuffercf_space_available(ptr noundef) #1

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 uwtable "min-legal-vector-width"="64" "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 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}


; 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 [90 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [3 x i8], align 1
@liquid_autotest_verbose = external local_unnamed_addr global i32, align 4
@.str.42 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [50 x i8], align 1

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

declare void @liquid_autotest_passed(...) local_unnamed_addr #1

declare void @liquid_autotest_failed_expr(ptr noundef, i32 noundef, ptr noundef, double noundef, ptr noundef, ptr noundef, double noundef) local_unnamed_addr #1

declare i32 @liquid_autotest_same_data(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

declare void @liquid_autotest_failed_msg(ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

declare void @liquid_autotest_print_array(ptr noundef, i32 noundef) local_unnamed_addr #1

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

declare ptr @cbuffercf_create(i32 noundef) local_unnamed_addr #1

declare i32 @cbuffercf_read(ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @cbuffercf_release(ptr noundef, i32 noundef) local_unnamed_addr #1

declare i32 @cbuffercf_push(ptr noundef, <2 x float> noundef) local_unnamed_addr #1

declare i32 @cbuffercf_destroy(ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local void @autotest_cbuffer_copy() local_unnamed_addr #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = tail call ptr @cbuffercf_create(i32 noundef 20) #3
  %6 = tail call float (...) @randnf() #3
  %7 = tail call float (...) @randnf() #3
  %8 = fmul float %7, 0.000000e+00
  %9 = fadd float %6, %8
  %.sroa.013.0.vec.insert = insertelement <2 x float> poison, float %9, i64 0
  %.sroa.013.4.vec.insert = insertelement <2 x float> %.sroa.013.0.vec.insert, float %7, i64 1
  %10 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert) #3
  %11 = tail call float (...) @randnf() #3
  %12 = tail call float (...) @randnf() #3
  %13 = fmul float %12, 0.000000e+00
  %14 = fadd float %11, %13
  %.sroa.013.0.vec.insert.1 = insertelement <2 x float> poison, float %14, i64 0
  %.sroa.013.4.vec.insert.1 = insertelement <2 x float> %.sroa.013.0.vec.insert.1, float %12, i64 1
  %15 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.1) #3
  %16 = tail call float (...) @randnf() #3
  %17 = tail call float (...) @randnf() #3
  %18 = fmul float %17, 0.000000e+00
  %19 = fadd float %16, %18
  %.sroa.013.0.vec.insert.2 = insertelement <2 x float> poison, float %19, i64 0
  %.sroa.013.4.vec.insert.2 = insertelement <2 x float> %.sroa.013.0.vec.insert.2, float %17, i64 1
  %20 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.2) #3
  %21 = tail call float (...) @randnf() #3
  %22 = tail call float (...) @randnf() #3
  %23 = fmul float %22, 0.000000e+00
  %24 = fadd float %21, %23
  %.sroa.013.0.vec.insert.3 = insertelement <2 x float> poison, float %24, i64 0
  %.sroa.013.4.vec.insert.3 = insertelement <2 x float> %.sroa.013.0.vec.insert.3, float %22, i64 1
  %25 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.3) #3
  %26 = tail call float (...) @randnf() #3
  %27 = tail call float (...) @randnf() #3
  %28 = fmul float %27, 0.000000e+00
  %29 = fadd float %26, %28
  %.sroa.013.0.vec.insert.4 = insertelement <2 x float> poison, float %29, i64 0
  %.sroa.013.4.vec.insert.4 = insertelement <2 x float> %.sroa.013.0.vec.insert.4, float %27, i64 1
  %30 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.4) #3
  %31 = tail call float (...) @randnf() #3
  %32 = tail call float (...) @randnf() #3
  %33 = fmul float %32, 0.000000e+00
  %34 = fadd float %31, %33
  %.sroa.013.0.vec.insert.5 = insertelement <2 x float> poison, float %34, i64 0
  %.sroa.013.4.vec.insert.5 = insertelement <2 x float> %.sroa.013.0.vec.insert.5, float %32, i64 1
  %35 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.5) #3
  %36 = tail call float (...) @randnf() #3
  %37 = tail call float (...) @randnf() #3
  %38 = fmul float %37, 0.000000e+00
  %39 = fadd float %36, %38
  %.sroa.013.0.vec.insert.6 = insertelement <2 x float> poison, float %39, i64 0
  %.sroa.013.4.vec.insert.6 = insertelement <2 x float> %.sroa.013.0.vec.insert.6, float %37, i64 1
  %40 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.6) #3
  %41 = tail call float (...) @randnf() #3
  %42 = tail call float (...) @randnf() #3
  %43 = fmul float %42, 0.000000e+00
  %44 = fadd float %41, %43
  %.sroa.013.0.vec.insert.7 = insertelement <2 x float> poison, float %44, i64 0
  %.sroa.013.4.vec.insert.7 = insertelement <2 x float> %.sroa.013.0.vec.insert.7, float %42, i64 1
  %45 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.7) #3
  %46 = tail call float (...) @randnf() #3
  %47 = tail call float (...) @randnf() #3
  %48 = fmul float %47, 0.000000e+00
  %49 = fadd float %46, %48
  %.sroa.013.0.vec.insert.8 = insertelement <2 x float> poison, float %49, i64 0
  %.sroa.013.4.vec.insert.8 = insertelement <2 x float> %.sroa.013.0.vec.insert.8, float %47, i64 1
  %50 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.8) #3
  %51 = tail call float (...) @randnf() #3
  %52 = tail call float (...) @randnf() #3
  %53 = fmul float %52, 0.000000e+00
  %54 = fadd float %51, %53
  %.sroa.013.0.vec.insert.9 = insertelement <2 x float> poison, float %54, i64 0
  %.sroa.013.4.vec.insert.9 = insertelement <2 x float> %.sroa.013.0.vec.insert.9, float %52, i64 1
  %55 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.9) #3
  %56 = tail call float (...) @randnf() #3
  %57 = tail call float (...) @randnf() #3
  %58 = fmul float %57, 0.000000e+00
  %59 = fadd float %56, %58
  %.sroa.013.0.vec.insert.10 = insertelement <2 x float> poison, float %59, i64 0
  %.sroa.013.4.vec.insert.10 = insertelement <2 x float> %.sroa.013.0.vec.insert.10, float %57, i64 1
  %60 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.10) #3
  %61 = tail call float (...) @randnf() #3
  %62 = tail call float (...) @randnf() #3
  %63 = fmul float %62, 0.000000e+00
  %64 = fadd float %61, %63
  %.sroa.013.0.vec.insert.11 = insertelement <2 x float> poison, float %64, i64 0
  %.sroa.013.4.vec.insert.11 = insertelement <2 x float> %.sroa.013.0.vec.insert.11, float %62, i64 1
  %65 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.11) #3
  %66 = tail call float (...) @randnf() #3
  %67 = tail call float (...) @randnf() #3
  %68 = fmul float %67, 0.000000e+00
  %69 = fadd float %66, %68
  %.sroa.013.0.vec.insert.12 = insertelement <2 x float> poison, float %69, i64 0
  %.sroa.013.4.vec.insert.12 = insertelement <2 x float> %.sroa.013.0.vec.insert.12, float %67, i64 1
  %70 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.12) #3
  %71 = tail call float (...) @randnf() #3
  %72 = tail call float (...) @randnf() #3
  %73 = fmul float %72, 0.000000e+00
  %74 = fadd float %71, %73
  %.sroa.013.0.vec.insert.13 = insertelement <2 x float> poison, float %74, i64 0
  %.sroa.013.4.vec.insert.13 = insertelement <2 x float> %.sroa.013.0.vec.insert.13, float %72, i64 1
  %75 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.13) #3
  %76 = tail call float (...) @randnf() #3
  %77 = tail call float (...) @randnf() #3
  %78 = fmul float %77, 0.000000e+00
  %79 = fadd float %76, %78
  %.sroa.013.0.vec.insert.14 = insertelement <2 x float> poison, float %79, i64 0
  %.sroa.013.4.vec.insert.14 = insertelement <2 x float> %.sroa.013.0.vec.insert.14, float %77, i64 1
  %80 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.14) #3
  %81 = tail call float (...) @randnf() #3
  %82 = tail call float (...) @randnf() #3
  %83 = fmul float %82, 0.000000e+00
  %84 = fadd float %81, %83
  %.sroa.013.0.vec.insert.15 = insertelement <2 x float> poison, float %84, i64 0
  %.sroa.013.4.vec.insert.15 = insertelement <2 x float> %.sroa.013.0.vec.insert.15, float %82, i64 1
  %85 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.15) #3
  %86 = tail call float (...) @randnf() #3
  %87 = tail call float (...) @randnf() #3
  %88 = fmul float %87, 0.000000e+00
  %89 = fadd float %86, %88
  %.sroa.013.0.vec.insert.16 = insertelement <2 x float> poison, float %89, i64 0
  %.sroa.013.4.vec.insert.16 = insertelement <2 x float> %.sroa.013.0.vec.insert.16, float %87, i64 1
  %90 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.16) #3
  %91 = tail call float (...) @randnf() #3
  %92 = tail call float (...) @randnf() #3
  %93 = fmul float %92, 0.000000e+00
  %94 = fadd float %91, %93
  %.sroa.013.0.vec.insert.17 = insertelement <2 x float> poison, float %94, i64 0
  %.sroa.013.4.vec.insert.17 = insertelement <2 x float> %.sroa.013.0.vec.insert.17, float %92, i64 1
  %95 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.17) #3
  %96 = tail call float (...) @randnf() #3
  %97 = tail call float (...) @randnf() #3
  %98 = fmul float %97, 0.000000e+00
  %99 = fadd float %96, %98
  %.sroa.013.0.vec.insert.18 = insertelement <2 x float> poison, float %99, i64 0
  %.sroa.013.4.vec.insert.18 = insertelement <2 x float> %.sroa.013.0.vec.insert.18, float %97, i64 1
  %100 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.18) #3
  %101 = tail call float (...) @randnf() #3
  %102 = tail call float (...) @randnf() #3
  %103 = fmul float %102, 0.000000e+00
  %104 = fadd float %101, %103
  %.sroa.013.0.vec.insert.19 = insertelement <2 x float> poison, float %104, i64 0
  %.sroa.013.4.vec.insert.19 = insertelement <2 x float> %.sroa.013.0.vec.insert.19, float %102, i64 1
  %105 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.013.4.vec.insert.19) #3
  %106 = tail call i32 @cbuffercf_release(ptr noundef %5, i32 noundef 13) #3
  %107 = tail call ptr @cbuffercf_copy(ptr noundef %5) #3
  %108 = tail call float (...) @randnf() #3
  %109 = tail call float (...) @randnf() #3
  %110 = fmul float %109, 0.000000e+00
  %111 = fadd float %108, %110
  %.sroa.03.0.vec.insert = insertelement <2 x float> poison, float %111, i64 0
  %.sroa.03.4.vec.insert = insertelement <2 x float> %.sroa.03.0.vec.insert, float %109, i64 1
  %112 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert) #3
  %113 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert) #3
  %114 = tail call float (...) @randnf() #3
  %115 = tail call float (...) @randnf() #3
  %116 = fmul float %115, 0.000000e+00
  %117 = fadd float %114, %116
  %.sroa.03.0.vec.insert.1 = insertelement <2 x float> poison, float %117, i64 0
  %.sroa.03.4.vec.insert.1 = insertelement <2 x float> %.sroa.03.0.vec.insert.1, float %115, i64 1
  %118 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.1) #3
  %119 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.1) #3
  %120 = tail call float (...) @randnf() #3
  %121 = tail call float (...) @randnf() #3
  %122 = fmul float %121, 0.000000e+00
  %123 = fadd float %120, %122
  %.sroa.03.0.vec.insert.2 = insertelement <2 x float> poison, float %123, i64 0
  %.sroa.03.4.vec.insert.2 = insertelement <2 x float> %.sroa.03.0.vec.insert.2, float %121, i64 1
  %124 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.2) #3
  %125 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.2) #3
  %126 = tail call float (...) @randnf() #3
  %127 = tail call float (...) @randnf() #3
  %128 = fmul float %127, 0.000000e+00
  %129 = fadd float %126, %128
  %.sroa.03.0.vec.insert.3 = insertelement <2 x float> poison, float %129, i64 0
  %.sroa.03.4.vec.insert.3 = insertelement <2 x float> %.sroa.03.0.vec.insert.3, float %127, i64 1
  %130 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.3) #3
  %131 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.3) #3
  %132 = tail call float (...) @randnf() #3
  %133 = tail call float (...) @randnf() #3
  %134 = fmul float %133, 0.000000e+00
  %135 = fadd float %132, %134
  %.sroa.03.0.vec.insert.4 = insertelement <2 x float> poison, float %135, i64 0
  %.sroa.03.4.vec.insert.4 = insertelement <2 x float> %.sroa.03.0.vec.insert.4, float %133, i64 1
  %136 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.4) #3
  %137 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.4) #3
  %138 = tail call float (...) @randnf() #3
  %139 = tail call float (...) @randnf() #3
  %140 = fmul float %139, 0.000000e+00
  %141 = fadd float %138, %140
  %.sroa.03.0.vec.insert.5 = insertelement <2 x float> poison, float %141, i64 0
  %.sroa.03.4.vec.insert.5 = insertelement <2 x float> %.sroa.03.0.vec.insert.5, float %139, i64 1
  %142 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.5) #3
  %143 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.5) #3
  %144 = tail call float (...) @randnf() #3
  %145 = tail call float (...) @randnf() #3
  %146 = fmul float %145, 0.000000e+00
  %147 = fadd float %144, %146
  %.sroa.03.0.vec.insert.6 = insertelement <2 x float> poison, float %147, i64 0
  %.sroa.03.4.vec.insert.6 = insertelement <2 x float> %.sroa.03.0.vec.insert.6, float %145, i64 1
  %148 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.6) #3
  %149 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.6) #3
  %150 = tail call float (...) @randnf() #3
  %151 = tail call float (...) @randnf() #3
  %152 = fmul float %151, 0.000000e+00
  %153 = fadd float %150, %152
  %.sroa.03.0.vec.insert.7 = insertelement <2 x float> poison, float %153, i64 0
  %.sroa.03.4.vec.insert.7 = insertelement <2 x float> %.sroa.03.0.vec.insert.7, float %151, i64 1
  %154 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.7) #3
  %155 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.7) #3
  %156 = tail call float (...) @randnf() #3
  %157 = tail call float (...) @randnf() #3
  %158 = fmul float %157, 0.000000e+00
  %159 = fadd float %156, %158
  %.sroa.03.0.vec.insert.8 = insertelement <2 x float> poison, float %159, i64 0
  %.sroa.03.4.vec.insert.8 = insertelement <2 x float> %.sroa.03.0.vec.insert.8, float %157, i64 1
  %160 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.8) #3
  %161 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.8) #3
  %162 = tail call float (...) @randnf() #3
  %163 = tail call float (...) @randnf() #3
  %164 = fmul float %163, 0.000000e+00
  %165 = fadd float %162, %164
  %.sroa.03.0.vec.insert.9 = insertelement <2 x float> poison, float %165, i64 0
  %.sroa.03.4.vec.insert.9 = insertelement <2 x float> %.sroa.03.0.vec.insert.9, float %163, i64 1
  %166 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.9) #3
  %167 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.9) #3
  %168 = tail call float (...) @randnf() #3
  %169 = tail call float (...) @randnf() #3
  %170 = fmul float %169, 0.000000e+00
  %171 = fadd float %168, %170
  %.sroa.03.0.vec.insert.10 = insertelement <2 x float> poison, float %171, i64 0
  %.sroa.03.4.vec.insert.10 = insertelement <2 x float> %.sroa.03.0.vec.insert.10, float %169, i64 1
  %172 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.10) #3
  %173 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.10) #3
  %174 = tail call float (...) @randnf() #3
  %175 = tail call float (...) @randnf() #3
  %176 = fmul float %175, 0.000000e+00
  %177 = fadd float %174, %176
  %.sroa.03.0.vec.insert.11 = insertelement <2 x float> poison, float %177, i64 0
  %.sroa.03.4.vec.insert.11 = insertelement <2 x float> %.sroa.03.0.vec.insert.11, float %175, i64 1
  %178 = tail call i32 @cbuffercf_push(ptr noundef %5, <2 x float> noundef %.sroa.03.4.vec.insert.11) #3
  %179 = tail call i32 @cbuffercf_push(ptr noundef %107, <2 x float> noundef %.sroa.03.4.vec.insert.11) #3
  %180 = tail call i32 @cbuffercf_release(ptr noundef %5, i32 noundef 4) #3
  %181 = tail call i32 @cbuffercf_release(ptr noundef %107, i32 noundef 4) #3
  %182 = tail call i32 @cbuffercf_space_available(ptr noundef %5) #3
  %183 = tail call i32 @cbuffercf_space_available(ptr noundef %107) #3
  %.not = icmp eq i32 %182, %183
  br i1 %.not, label %189, label %184

184:                                              ; preds = %0
  %185 = tail call i32 @cbuffercf_space_available(ptr noundef %5) #3
  %186 = uitofp i32 %185 to double
  %187 = tail call i32 @cbuffercf_space_available(ptr noundef %107) #3
  %188 = uitofp i32 %187 to double
  tail call void @liquid_autotest_failed_expr(ptr noundef nonnull @.str, i32 noundef 362, ptr noundef nonnull @.str.42, double noundef %186, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.43, double noundef %188) #3
  br label %190

189:                                              ; preds = %0
  tail call void (...) @liquid_autotest_passed() #3
  br label %190

190:                                              ; preds = %189, %184
  %191 = tail call i32 @cbuffercf_space_available(ptr noundef %5) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #3
  %192 = call i32 @cbuffercf_read(ptr noundef %5, i32 noundef %191, ptr noundef nonnull %3, ptr noundef nonnull %1) #3
  %193 = call i32 @cbuffercf_read(ptr noundef %107, i32 noundef %191, ptr noundef nonnull %4, ptr noundef nonnull %2) #3
  %194 = load i32, ptr %1, align 4, !tbaa !5
  %195 = load i32, ptr %2, align 4, !tbaa !5
  %.not34 = icmp eq i32 %194, %195
  br i1 %.not34, label %199, label %196

196:                                              ; preds = %190
  %197 = uitofp i32 %194 to double
  %198 = uitofp i32 %195 to double
  call void @liquid_autotest_failed_expr(ptr noundef nonnull @.str, i32 noundef 370, ptr noundef nonnull @.str.44, double noundef %197, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.45, double noundef %198) #3
  br label %200

199:                                              ; preds = %190
  call void (...) @liquid_autotest_passed() #3
  br label %200

200:                                              ; preds = %199, %196
  %201 = load ptr, ptr %3, align 8, !tbaa !9
  %202 = load ptr, ptr %4, align 8, !tbaa !9
  %203 = load i32, ptr %1, align 4, !tbaa !5
  %204 = shl i32 %203, 3
  %205 = call i32 @liquid_autotest_same_data(ptr noundef %201, ptr noundef %202, i32 noundef %204) #3
  %.not35 = icmp eq i32 %205, 0
  br i1 %.not35, label %206, label %215

206:                                              ; preds = %200
  call void @liquid_autotest_failed_msg(ptr noundef nonnull @.str, i32 noundef 372, ptr noundef nonnull @.str.46) #3
  %207 = load i32, ptr @liquid_autotest_verbose, align 4, !tbaa !5
  %.not36 = icmp eq i32 %207, 0
  br i1 %.not36, label %216, label %208

208:                                              ; preds = %206
  %209 = load ptr, ptr %3, align 8, !tbaa !9
  %210 = load i32, ptr %1, align 4, !tbaa !5
  %211 = shl i32 %210, 3
  call void @liquid_autotest_print_array(ptr noundef %209, i32 noundef %211) #3
  %212 = load ptr, ptr %4, align 8, !tbaa !9
  %213 = load i32, ptr %1, align 4, !tbaa !5
  %214 = shl i32 %213, 3
  call void @liquid_autotest_print_array(ptr noundef %212, i32 noundef %214) #3
  br label %216

215:                                              ; preds = %200
  call void (...) @liquid_autotest_passed() #3
  br label %216

216:                                              ; preds = %206, %208, %215
  %217 = call i32 @cbuffercf_destroy(ptr noundef %5) #3
  %218 = call i32 @cbuffercf_destroy(ptr noundef %107) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #3
  ret void
}

declare float @randnf(...) local_unnamed_addr #1

declare ptr @cbuffercf_copy(ptr noundef) local_unnamed_addr #1

declare i32 @cbuffercf_space_available(ptr noundef) local_unnamed_addr #1

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 uwtable "min-legal-vector-width"="64" "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 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}


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