; LLVM IR from darnstrom/daqp :: codegen (codegen)

; 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.DAQPWorkspace = type { ptr, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, double, ptr, ptr, ptr, ptr, i32, ptr, i32, i32, i32, double, ptr, ptr, i32, ptr }

@.str.34 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.51 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [19 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

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

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #1

; Function Attrs: nounwind uwtable
define dso_local void @write_daqp_workspace_src(ptr noundef %0, ptr noundef %1) #2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %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
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #3
  %10 = load ptr, ptr %4, align 8, !tbaa !5
  %11 = getelementptr inbounds %struct.DAQPWorkspace, ptr %10, i32 0, i32 1
  %12 = load i32, ptr %11, align 8, !tbaa !9
  store i32 %12, ptr %6, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #3
  %13 = load ptr, ptr %4, align 8, !tbaa !5
  %14 = getelementptr inbounds %struct.DAQPWorkspace, ptr %13, i32 0, i32 2
  %15 = load i32, ptr %14, align 4, !tbaa !14
  store i32 %15, ptr %7, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  %16 = load ptr, ptr %4, align 8, !tbaa !5
  %17 = getelementptr inbounds %struct.DAQPWorkspace, ptr %16, i32 0, i32 3
  %18 = load i32, ptr %17, align 8, !tbaa !15
  store i32 %18, ptr %8, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  %19 = load i32, ptr %6, align 4, !tbaa !13
  store i32 %19, ptr %9, align 4, !tbaa !13
  store i32 0, ptr %5, align 4, !tbaa !13
  br label %20

20:                                               ; preds = %38, %2
  %21 = load i32, ptr %5, align 4, !tbaa !13
  %22 = load i32, ptr %7, align 4, !tbaa !13
  %23 = icmp slt i32 %21, %22
  br i1 %23, label %24, label %41

24:                                               ; preds = %20
  %25 = load ptr, ptr %4, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.DAQPWorkspace, ptr %25, i32 0, i32 9
  %27 = load ptr, ptr %26, align 8, !tbaa !16
  %28 = load i32, ptr %5, align 4, !tbaa !13
  %29 = sext i32 %28 to i64
  %30 = getelementptr inbounds i32, ptr %27, i64 %29
  %31 = load i32, ptr %30, align 4, !tbaa !13
  %32 = and i32 %31, 8
  %33 = icmp ne i32 %32, 0
  br i1 %33, label %34, label %37

34:                                               ; preds = %24
  %35 = load i32, ptr %9, align 4, !tbaa !13
  %36 = add nsw i32 %35, 1
  store i32 %36, ptr %9, align 4, !tbaa !13
  br label %37

37:                                               ; preds = %34, %24
  br label %38

38:                                               ; preds = %37
  %39 = load i32, ptr %5, align 4, !tbaa !13
  %40 = add nsw i32 %39, 1
  store i32 %40, ptr %5, align 4, !tbaa !13
  br label %20, !llvm.loop !17

41:                                               ; preds = %20
  %42 = load ptr, ptr %3, align 8, !tbaa !5
  %43 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %42, ptr noundef @.str.34) #3
  %44 = load ptr, ptr %3, align 8, !tbaa !5
  %45 = load ptr, ptr %4, align 8, !tbaa !5
  %46 = getelementptr inbounds %struct.DAQPWorkspace, ptr %45, i32 0, i32 4
  %47 = load ptr, ptr %46, align 8, !tbaa !19
  %48 = load i32, ptr %7, align 4, !tbaa !13
  %49 = load i32, ptr %8, align 4, !tbaa !13
  %50 = sub nsw i32 %48, %49
  %51 = load i32, ptr %6, align 4, !tbaa !13
  %52 = mul nsw i32 %50, %51
  call void @write_float_array(ptr noundef %44, ptr noundef %47, i32 noundef %52, ptr noundef @.str.35)
  %53 = load ptr, ptr %3, align 8, !tbaa !5
  %54 = load i32, ptr %7, align 4, !tbaa !13
  %55 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %53, ptr noundef @.str.36, i32 noundef %54) #3
  %56 = load ptr, ptr %3, align 8, !tbaa !5
  %57 = load i32, ptr %7, align 4, !tbaa !13
  %58 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %56, ptr noundef @.str.37, i32 noundef %57) #3
  %59 = load ptr, ptr %3, align 8, !tbaa !5
  %60 = load ptr, ptr %4, align 8, !tbaa !5
  %61 = getelementptr inbounds %struct.DAQPWorkspace, ptr %60, i32 0, i32 7
  %62 = load ptr, ptr %61, align 8, !tbaa !20
  %63 = load i32, ptr %6, align 4, !tbaa !13
  %64 = load i32, ptr %6, align 4, !tbaa !13
  %65 = add nsw i32 %64, 1
  %66 = mul nsw i32 %63, %65
  %67 = sdiv i32 %66, 2
  call void @write_float_array(ptr noundef %59, ptr noundef %62, i32 noundef %67, ptr noundef @.str.38)
  %68 = load ptr, ptr %3, align 8, !tbaa !5
  %69 = load ptr, ptr %4, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.DAQPWorkspace, ptr %69, i32 0, i32 9
  %71 = load ptr, ptr %70, align 8, !tbaa !16
  %72 = load i32, ptr %7, align 4, !tbaa !13
  call void @write_int_array(ptr noundef %68, ptr noundef %71, i32 noundef %72, ptr noundef @.str.39)
  %73 = load ptr, ptr %3, align 8, !tbaa !5
  %74 = load i32, ptr %6, align 4, !tbaa !13
  %75 = add nsw i32 %74, 1
  %76 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %73, ptr noundef @.str.40, i32 noundef %75) #3
  %77 = load ptr, ptr %3, align 8, !tbaa !5
  %78 = load i32, ptr %6, align 4, !tbaa !13
  %79 = add nsw i32 %78, 1
  %80 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %77, ptr noundef @.str.41, i32 noundef %79) #3
  %81 = load ptr, ptr %3, align 8, !tbaa !5
  %82 = load i32, ptr %9, align 4, !tbaa !13
  %83 = add nsw i32 %82, 1
  %84 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %81, ptr noundef @.str.42, i32 noundef %83) #3
  %85 = load ptr, ptr %3, align 8, !tbaa !5
  %86 = load i32, ptr %9, align 4, !tbaa !13
  %87 = add nsw i32 %86, 1
  %88 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %85, ptr noundef @.str.43, i32 noundef %87) #3
  %89 = load ptr, ptr %3, align 8, !tbaa !5
  %90 = load i32, ptr %6, align 4, !tbaa !13
  %91 = add nsw i32 %90, 1
  %92 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %89, ptr noundef @.str.44, i32 noundef %91) #3
  %93 = load ptr, ptr %3, align 8, !tbaa !5
  %94 = load i32, ptr %9, align 4, !tbaa !13
  %95 = add nsw i32 %94, 1
  %96 = load i32, ptr %9, align 4, !tbaa !13
  %97 = add nsw i32 %96, 2
  %98 = mul nsw i32 %95, %97
  %99 = sdiv i32 %98, 2
  %100 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %93, ptr noundef @.str.45, i32 noundef %99) #3
  %101 = load ptr, ptr %3, align 8, !tbaa !5
  %102 = load i32, ptr %9, align 4, !tbaa !13
  %103 = add nsw i32 %102, 1
  %104 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %101, ptr noundef @.str.46, i32 noundef %103) #3
  %105 = load ptr, ptr %3, align 8, !tbaa !5
  %106 = load i32, ptr %9, align 4, !tbaa !13
  %107 = add nsw i32 %106, 1
  %108 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %105, ptr noundef @.str.47, i32 noundef %107) #3
  %109 = load ptr, ptr %3, align 8, !tbaa !5
  %110 = load i32, ptr %9, align 4, !tbaa !13
  %111 = add nsw i32 %110, 1
  %112 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %109, ptr noundef @.str.48, i32 noundef %111) #3
  %113 = load ptr, ptr %3, align 8, !tbaa !5
  %114 = load i32, ptr %9, align 4, !tbaa !13
  %115 = add nsw i32 %114, 1
  %116 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %113, ptr noundef @.str.49, i32 noundef %115) #3
  %117 = load ptr, ptr %3, align 8, !tbaa !5
  %118 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %117, ptr noundef @.str.50) #3
  %119 = load ptr, ptr %3, align 8, !tbaa !5
  %120 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %119, ptr noundef @.str.51) #3
  %121 = load ptr, ptr %3, align 8, !tbaa !5
  %122 = load i32, ptr %6, align 4, !tbaa !13
  %123 = load i32, ptr %7, align 4, !tbaa !13
  %124 = load i32, ptr %8, align 4, !tbaa !13
  %125 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %121, ptr noundef @.str.52, i32 noundef %122, i32 noundef %123, i32 noundef %124) #3
  %126 = load ptr, ptr %3, align 8, !tbaa !5
  %127 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %126, ptr noundef @.str.53) #3
  %128 = load ptr, ptr %3, align 8, !tbaa !5
  %129 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %128, ptr noundef @.str.51) #3
  %130 = load ptr, ptr %3, align 8, !tbaa !5
  %131 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %130, ptr noundef @.str.51) #3
  %132 = load ptr, ptr %3, align 8, !tbaa !5
  %133 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %132, ptr noundef @.str.54) #3
  %134 = load ptr, ptr %3, align 8, !tbaa !5
  %135 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %134, ptr noundef @.str.55, i32 noundef -1) #3
  %136 = load ptr, ptr %3, align 8, !tbaa !5
  %137 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %136, ptr noundef @.str.56, i32 noundef 0) #3
  %138 = load ptr, ptr %3, align 8, !tbaa !5
  %139 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %138, ptr noundef @.str.57, i32 noundef 0) #3
  %140 = load ptr, ptr %3, align 8, !tbaa !5
  %141 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %140, ptr noundef @.str.58, i32 noundef 0, i32 noundef -1) #3
  %142 = load ptr, ptr %3, align 8, !tbaa !5
  %143 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %142, ptr noundef @.str.59, double noundef 0.000000e+00) #3
  %144 = load ptr, ptr %3, align 8, !tbaa !5
  %145 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %144, ptr noundef @.str.60) #3
  %146 = load ptr, ptr %4, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.DAQPWorkspace, ptr %146, i32 0, i32 29
  %148 = load ptr, ptr %147, align 8, !tbaa !21
  %149 = icmp eq ptr %148, null
  br i1 %149, label %150, label %153

150:                                              ; preds = %41
  %151 = load ptr, ptr %3, align 8, !tbaa !5
  %152 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %151, ptr noundef @.str.61) #3
  br label %156

153:                                              ; preds = %41
  %154 = load ptr, ptr %3, align 8, !tbaa !5
  %155 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %154, ptr noundef @.str.62) #3
  br label %156

156:                                              ; preds = %153, %150
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #3
  ret void
}

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 = { 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, !11, i64 8}
!10 = !{!"", !6, i64 0, !11, i64 8, !11, i64 12, !11, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !12, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !11, i64 168, !6, i64 176, !11, i64 184, !11, i64 188, !11, i64 192, !12, i64 200, !6, i64 208, !6, i64 216, !11, i64 224, !6, i64 232}
!11 = !{!"int", !7, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!11, !11, i64 0}
!14 = !{!10, !11, i64 12}
!15 = !{!10, !11, i64 16}
!16 = !{!10, !6, i64 64}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = !{!10, !6, i64 24}
!20 = !{!10, !6, i64 48}
!21 = !{!10, !6, i64 216}


; 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.34 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.51 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [19 x i8], align 1

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

; Function Attrs: nounwind uwtable
define dso_local void @write_daqp_workspace_src(ptr noundef %0, ptr nocapture noundef readonly %1) local_unnamed_addr #1 {
  %3 = getelementptr inbounds i8, ptr %1, i64 8
  %4 = load i32, ptr %3, align 8, !tbaa !5
  %5 = getelementptr inbounds i8, ptr %1, i64 12
  %6 = load i32, ptr %5, align 4, !tbaa !12
  %7 = getelementptr inbounds i8, ptr %1, i64 16
  %8 = load i32, ptr %7, align 8, !tbaa !13
  %9 = icmp sgt i32 %6, 0
  br i1 %9, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %2
  %10 = getelementptr inbounds i8, ptr %1, i64 64
  %11 = load ptr, ptr %10, align 8, !tbaa !14
  %wide.trip.count = zext nneg i32 %6 to i64
  %min.iters.check = icmp ult i32 %6, 8
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %.lr.ph
  %n.vec = and i64 %wide.trip.count, 2147483640
  %12 = insertelement <4 x i32> <i32 poison, i32 0, i32 0, i32 0>, i32 %4, i64 0
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.phi = phi <4 x i32> [ %12, %vector.ph ], [ %19, %vector.body ]
  %vec.phi71 = phi <4 x i32> [ zeroinitializer, %vector.ph ], [ %20, %vector.body ]
  %13 = getelementptr inbounds i32, ptr %11, i64 %index
  %14 = getelementptr inbounds i8, ptr %13, i64 16
  %wide.load = load <4 x i32>, ptr %13, align 4, !tbaa !15
  %wide.load72 = load <4 x i32>, ptr %14, align 4, !tbaa !15
  %15 = lshr <4 x i32> %wide.load, <i32 3, i32 3, i32 3, i32 3>
  %16 = lshr <4 x i32> %wide.load72, <i32 3, i32 3, i32 3, i32 3>
  %17 = and <4 x i32> %15, <i32 1, i32 1, i32 1, i32 1>
  %18 = and <4 x i32> %16, <i32 1, i32 1, i32 1, i32 1>
  %19 = add <4 x i32> %17, %vec.phi
  %20 = add <4 x i32> %18, %vec.phi71
  %index.next = add nuw i64 %index, 8
  %21 = icmp eq i64 %index.next, %n.vec
  br i1 %21, label %middle.block, label %vector.body, !llvm.loop !16

middle.block:                                     ; preds = %vector.body
  %bin.rdx = add <4 x i32> %20, %19
  %22 = tail call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> %bin.rdx)
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %._crit_edge, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %.lr.ph
  %indvars.iv.ph = phi i64 [ 0, %.lr.ph ], [ %n.vec, %middle.block ]
  %.069.ph = phi i32 [ %4, %.lr.ph ], [ %22, %middle.block ]
  br label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %scalar.ph ], [ %indvars.iv.ph, %scalar.ph.preheader ]
  %.069 = phi i32 [ %spec.select, %scalar.ph ], [ %.069.ph, %scalar.ph.preheader ]
  %23 = getelementptr inbounds i32, ptr %11, i64 %indvars.iv
  %24 = load i32, ptr %23, align 4, !tbaa !15
  %25 = lshr i32 %24, 3
  %26 = and i32 %25, 1
  %spec.select = add i32 %26, %.069
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %scalar.ph, !llvm.loop !20

._crit_edge:                                      ; preds = %scalar.ph, %middle.block, %2
  %.0.lcssa = phi i32 [ %4, %2 ], [ %22, %middle.block ], [ %spec.select, %scalar.ph ]
  %27 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.34) #3
  %28 = getelementptr inbounds i8, ptr %1, i64 24
  %29 = load ptr, ptr %28, align 8, !tbaa !21
  %30 = sub nsw i32 %6, %8
  %31 = mul nsw i32 %30, %4
  tail call void @write_float_array(ptr noundef %0, ptr noundef %29, i32 noundef %31, ptr noundef nonnull @.str.35)
  %32 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.36, i32 noundef %6) #3
  %33 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.37, i32 noundef %6) #3
  %34 = getelementptr inbounds i8, ptr %1, i64 48
  %35 = load ptr, ptr %34, align 8, !tbaa !22
  %36 = add nsw i32 %4, 1
  %37 = mul nsw i32 %36, %4
  %38 = sdiv i32 %37, 2
  tail call void @write_float_array(ptr noundef %0, ptr noundef %35, i32 noundef %38, ptr noundef nonnull @.str.38)
  %39 = getelementptr inbounds i8, ptr %1, i64 64
  %40 = load ptr, ptr %39, align 8, !tbaa !14
  tail call void @write_int_array(ptr noundef %0, ptr noundef %40, i32 noundef %6, ptr noundef nonnull @.str.39)
  %41 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.40, i32 noundef %36) #3
  %42 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.41, i32 noundef %36) #3
  %43 = add nsw i32 %.0.lcssa, 1
  %44 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.42, i32 noundef %43) #3
  %45 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.43, i32 noundef %43) #3
  %46 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.44, i32 noundef %36) #3
  %47 = add nsw i32 %.0.lcssa, 2
  %48 = mul nsw i32 %43, %47
  %49 = sdiv i32 %48, 2
  %50 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.45, i32 noundef %49) #3
  %51 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.46, i32 noundef %43) #3
  %52 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.47, i32 noundef %43) #3
  %53 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.48, i32 noundef %43) #3
  %54 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.49, i32 noundef %43) #3
  %55 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.50) #3
  %56 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.51) #3
  %57 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.52, i32 noundef %4, i32 noundef %6, i32 noundef %8) #3
  %58 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.53) #3
  %59 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.51) #3
  %60 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.51) #3
  %61 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.54) #3
  %62 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.55, i32 noundef -1) #3
  %63 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.56, i32 noundef 0) #3
  %64 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.57, i32 noundef 0) #3
  %65 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.58, i32 noundef 0, i32 noundef -1) #3
  %66 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.59, double noundef 0.000000e+00) #3
  %67 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull @.str.60) #3
  %68 = getelementptr inbounds i8, ptr %1, i64 216
  %69 = load ptr, ptr %68, align 8, !tbaa !23
  %70 = icmp eq ptr %69, null
  %.str.61..str.62 = select i1 %70, ptr @.str.61, ptr @.str.62
  %71 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %0, ptr noundef nonnull %.str.61..str.62) #3
  ret void
}

; Function Attrs: nounwind uwtable
declare dso_local void @write_float_array(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local void @write_int_array(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.vector.reduce.add.v4i32(<4 x i32>) #2

attributes #0 = { 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 #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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !10, i64 8}
!6 = !{!"", !7, i64 0, !10, i64 8, !10, i64 12, !10, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !11, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !10, i64 168, !7, i64 176, !10, i64 184, !10, i64 188, !10, i64 192, !11, i64 200, !7, i64 208, !7, i64 216, !10, i64 224, !7, i64 232}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"double", !8, i64 0}
!12 = !{!6, !10, i64 12}
!13 = !{!6, !10, i64 16}
!14 = !{!6, !7, i64 64}
!15 = !{!10, !10, i64 0}
!16 = distinct !{!16, !17, !18, !19}
!17 = !{!"llvm.loop.mustprogress"}
!18 = !{!"llvm.loop.isvectorized", i32 1}
!19 = !{!"llvm.loop.unroll.runtime.disable"}
!20 = distinct !{!20, !17, !19, !18}
!21 = !{!6, !7, i64 24}
!22 = !{!6, !7, i64 48}
!23 = !{!6, !7, i64 216}


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