; LLVM IR from fast-pack/simdcomp :: src (simdfor)

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

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_set1_epi32(i32 noundef) #1

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

; Function Attrs: nounwind uwtable
define dso_local ptr @simdpackFOR_length(i32 noundef %0, ptr noundef %1, i32 noundef %2, ptr noundef %3, i32 noundef %4) #2 {
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca <2 x i64>, align 16
  %15 = alloca i32, align 4
  %16 = alloca <2 x i64>, align 16
  %17 = alloca i32, align 4
  %18 = alloca <2 x i64>, align 16
  %19 = alloca [4 x i32], align 16
  %20 = alloca <2 x i64>, align 16
  store i32 %0, ptr %7, align 4, !tbaa !5
  store ptr %1, ptr %8, align 8, !tbaa !9
  store i32 %2, ptr %9, align 4, !tbaa !5
  store ptr %3, ptr %10, align 8, !tbaa !9
  store i32 %4, ptr %11, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %16) #4
  %21 = load i32, ptr %11, align 4, !tbaa !5
  %22 = icmp eq i32 %21, 0
  br i1 %22, label %23, label %25

23:                                               ; preds = %5
  %24 = load ptr, ptr %10, align 8, !tbaa !9
  store ptr %24, ptr %6, align 8
  store i32 1, ptr %17, align 4
  br label %166

25:                                               ; preds = %5
  %26 = load i32, ptr %11, align 4, !tbaa !5
  %27 = icmp eq i32 %26, 32
  br i1 %27, label %28, label %38

28:                                               ; preds = %25
  %29 = load ptr, ptr %10, align 8, !tbaa !9
  %30 = load ptr, ptr %8, align 8, !tbaa !9
  %31 = load i32, ptr %9, align 4, !tbaa !5
  %32 = sext i32 %31 to i64
  %33 = mul i64 %32, 4
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %29, ptr align 4 %30, i64 %33, i1 false)
  %34 = load ptr, ptr %10, align 8, !tbaa !9
  %35 = load i32, ptr %9, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds i32, ptr %34, i64 %36
  store ptr %37, ptr %6, align 8
  store i32 1, ptr %17, align 4
  br label %166

38:                                               ; preds = %25
  %39 = load i32, ptr %7, align 4, !tbaa !5
  %40 = call <2 x i64> @_mm_set1_epi32(i32 noundef %39)
  store <2 x i64> %40, ptr %16, align 16, !tbaa !11
  store i32 0, ptr %13, align 4, !tbaa !5
  %41 = call <2 x i64> @_mm_setzero_si128()
  store <2 x i64> %41, ptr %14, align 16, !tbaa !11
  store i32 0, ptr %12, align 4, !tbaa !5
  br label %42

42:                                               ; preds = %82, %38
  %43 = load i32, ptr %12, align 4, !tbaa !5
  %44 = load i32, ptr %9, align 4, !tbaa !5
  %45 = sdiv i32 %44, 4
  %46 = icmp slt i32 %43, %45
  br i1 %46, label %47, label %85

47:                                               ; preds = %42
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #4
  %48 = load ptr, ptr %8, align 8, !tbaa !9
  %49 = load i32, ptr %12, align 4, !tbaa !5
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds <2 x i64>, ptr %48, i64 %50
  %52 = call <2 x i64> @_mm_loadu_si128(ptr noundef %51)
  %53 = load <2 x i64>, ptr %16, align 16, !tbaa !11
  %54 = call <2 x i64> @_mm_sub_epi32(<2 x i64> noundef %52, <2 x i64> noundef %53)
  store <2 x i64> %54, ptr %18, align 16, !tbaa !11
  %55 = load <2 x i64>, ptr %14, align 16, !tbaa !11
  %56 = load <2 x i64>, ptr %18, align 16, !tbaa !11
  %57 = load i32, ptr %13, align 4, !tbaa !5
  %58 = call <2 x i64> @_mm_slli_epi32(<2 x i64> noundef %56, i32 noundef %57)
  %59 = call <2 x i64> @_mm_or_si128(<2 x i64> noundef %55, <2 x i64> noundef %58)
  store <2 x i64> %59, ptr %14, align 16, !tbaa !11
  %60 = load i32, ptr %13, align 4, !tbaa !5
  %61 = sext i32 %60 to i64
  %62 = sub i64 32, %61
  %63 = trunc i64 %62 to i32
  store i32 %63, ptr %15, align 4, !tbaa !5
  %64 = load i32, ptr %11, align 4, !tbaa !5
  %65 = load i32, ptr %15, align 4, !tbaa !5
  %66 = icmp ult i32 %64, %65
  br i1 %66, label %67, label %71

67:                                               ; preds = %47
  %68 = load i32, ptr %11, align 4, !tbaa !5
  %69 = load i32, ptr %13, align 4, !tbaa !5
  %70 = add i32 %69, %68
  store i32 %70, ptr %13, align 4, !tbaa !5
  br label %81

71:                                               ; preds = %47
  %72 = load ptr, ptr %10, align 8, !tbaa !9
  %73 = getelementptr inbounds <2 x i64>, ptr %72, i32 1
  store ptr %73, ptr %10, align 8, !tbaa !9
  %74 = load <2 x i64>, ptr %14, align 16, !tbaa !11
  call void @_mm_storeu_si128(ptr noundef %72, <2 x i64> noundef %74)
  %75 = load <2 x i64>, ptr %18, align 16, !tbaa !11
  %76 = load i32, ptr %15, align 4, !tbaa !5
  %77 = call <2 x i64> @_mm_srli_epi32(<2 x i64> noundef %75, i32 noundef %76)
  store <2 x i64> %77, ptr %14, align 16, !tbaa !11
  %78 = load i32, ptr %11, align 4, !tbaa !5
  %79 = load i32, ptr %15, align 4, !tbaa !5
  %80 = sub i32 %78, %79
  store i32 %80, ptr %13, align 4, !tbaa !5
  br label %81

81:                                               ; preds = %71, %67
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #4
  br label %82

82:                                               ; preds = %81
  %83 = load i32, ptr %12, align 4, !tbaa !5
  %84 = add nsw i32 %83, 1
  store i32 %84, ptr %12, align 4, !tbaa !5
  br label %42, !llvm.loop !12

85:                                               ; preds = %42
  %86 = load i32, ptr %9, align 4, !tbaa !5
  %87 = srem i32 %86, 4
  %88 = icmp ne i32 %87, 0
  br i1 %88, label %89, label %157

89:                                               ; preds = %85
  call void @llvm.lifetime.start.p0(i64 16, ptr %19) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #4
  store i32 0, ptr %12, align 4, !tbaa !5
  br label %90

90:                                               ; preds = %108, %89
  %91 = load i32, ptr %12, align 4, !tbaa !5
  %92 = load i32, ptr %9, align 4, !tbaa !5
  %93 = srem i32 %92, 4
  %94 = icmp slt i32 %91, %93
  br i1 %94, label %95, label %111

95:                                               ; preds = %90
  %96 = load ptr, ptr %8, align 8, !tbaa !9
  %97 = load i32, ptr %9, align 4, !tbaa !5
  %98 = sdiv i32 %97, 4
  %99 = mul nsw i32 %98, 4
  %100 = load i32, ptr %12, align 4, !tbaa !5
  %101 = add nsw i32 %99, %100
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds i32, ptr %96, i64 %102
  %104 = load i32, ptr %103, align 4, !tbaa !5
  %105 = load i32, ptr %12, align 4, !tbaa !5
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds [4 x i32], ptr %19, i64 0, i64 %106
  store i32 %104, ptr %107, align 4, !tbaa !5
  br label %108

108:                                              ; preds = %95
  %109 = load i32, ptr %12, align 4, !tbaa !5
  %110 = add nsw i32 %109, 1
  store i32 %110, ptr %12, align 4, !tbaa !5
  br label %90, !llvm.loop !14

111:                                              ; preds = %90
  %112 = load i32, ptr %9, align 4, !tbaa !5
  %113 = srem i32 %112, 4
  store i32 %113, ptr %12, align 4, !tbaa !5
  br label %114

114:                                              ; preds = %122, %111
  %115 = load i32, ptr %12, align 4, !tbaa !5
  %116 = icmp slt i32 %115, 4
  br i1 %116, label %117, label %125

117:                                              ; preds = %114
  %118 = load i32, ptr %7, align 4, !tbaa !5
  %119 = load i32, ptr %12, align 4, !tbaa !5
  %120 = sext i32 %119 to i64
  %121 = getelementptr inbounds [4 x i32], ptr %19, i64 0, i64 %120
  store i32 %118, ptr %121, align 4, !tbaa !5
  br label %122

122:                                              ; preds = %117
  %123 = load i32, ptr %12, align 4, !tbaa !5
  %124 = add nsw i32 %123, 1
  store i32 %124, ptr %12, align 4, !tbaa !5
  br label %114, !llvm.loop !15

125:                                              ; preds = %114
  %126 = getelementptr inbounds [4 x i32], ptr %19, i64 0, i64 0
  %127 = call <2 x i64> @_mm_loadu_si128(ptr noundef %126)
  %128 = load <2 x i64>, ptr %16, align 16, !tbaa !11
  %129 = call <2 x i64> @_mm_sub_epi32(<2 x i64> noundef %127, <2 x i64> noundef %128)
  store <2 x i64> %129, ptr %20, align 16, !tbaa !11
  %130 = load <2 x i64>, ptr %14, align 16, !tbaa !11
  %131 = load <2 x i64>, ptr %20, align 16, !tbaa !11
  %132 = load i32, ptr %13, align 4, !tbaa !5
  %133 = call <2 x i64> @_mm_slli_epi32(<2 x i64> noundef %131, i32 noundef %132)
  %134 = call <2 x i64> @_mm_or_si128(<2 x i64> noundef %130, <2 x i64> noundef %133)
  store <2 x i64> %134, ptr %14, align 16, !tbaa !11
  %135 = load i32, ptr %13, align 4, !tbaa !5
  %136 = sext i32 %135 to i64
  %137 = sub i64 32, %136
  %138 = trunc i64 %137 to i32
  store i32 %138, ptr %15, align 4, !tbaa !5
  %139 = load i32, ptr %11, align 4, !tbaa !5
  %140 = load i32, ptr %15, align 4, !tbaa !5
  %141 = icmp ult i32 %139, %140
  br i1 %141, label %142, label %146

142:                                              ; preds = %125
  %143 = load i32, ptr %11, align 4, !tbaa !5
  %144 = load i32, ptr %13, align 4, !tbaa !5
  %145 = add i32 %144, %143
  store i32 %145, ptr %13, align 4, !tbaa !5
  br label %156

146:                                              ; preds = %125
  %147 = load ptr, ptr %10, align 8, !tbaa !9
  %148 = getelementptr inbounds <2 x i64>, ptr %147, i32 1
  store ptr %148, ptr %10, align 8, !tbaa !9
  %149 = load <2 x i64>, ptr %14, align 16, !tbaa !11
  call void @_mm_storeu_si128(ptr noundef %147, <2 x i64> noundef %149)
  %150 = load <2 x i64>, ptr %20, align 16, !tbaa !11
  %151 = load i32, ptr %15, align 4, !tbaa !5
  %152 = call <2 x i64> @_mm_srli_epi32(<2 x i64> noundef %150, i32 noundef %151)
  store <2 x i64> %152, ptr %14, align 16, !tbaa !11
  %153 = load i32, ptr %11, align 4, !tbaa !5
  %154 = load i32, ptr %15, align 4, !tbaa !5
  %155 = sub i32 %153, %154
  store i32 %155, ptr %13, align 4, !tbaa !5
  br label %156

156:                                              ; preds = %146, %142
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #4
  br label %157

157:                                              ; preds = %156, %85
  %158 = load i32, ptr %13, align 4, !tbaa !5
  %159 = icmp ne i32 %158, 0
  br i1 %159, label %160, label %164

160:                                              ; preds = %157
  %161 = load ptr, ptr %10, align 8, !tbaa !9
  %162 = getelementptr inbounds <2 x i64>, ptr %161, i32 1
  store ptr %162, ptr %10, align 8, !tbaa !9
  %163 = load <2 x i64>, ptr %14, align 16, !tbaa !11
  call void @_mm_storeu_si128(ptr noundef %161, <2 x i64> noundef %163)
  br label %164

164:                                              ; preds = %160, %157
  %165 = load ptr, ptr %10, align 8, !tbaa !9
  store ptr %165, ptr %6, align 8
  store i32 1, ptr %17, align 4
  br label %166

166:                                              ; preds = %164, %28, %23
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  %167 = load ptr, ptr %6, align 8
  ret ptr %167
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_setzero_si128() #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_sub_epi32(<2 x i64> noundef, <2 x i64> noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_loadu_si128(ptr noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_or_si128(<2 x i64> noundef, <2 x i64> noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_slli_epi32(<2 x i64> noundef, i32 noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @_mm_storeu_si128(ptr noundef, <2 x i64> noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_srli_epi32(<2 x i64> noundef, i32 noundef) #1

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

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_set1_epi32(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

; Function Attrs: nounwind uwtable
define dso_local ptr @simdpackFOR_length(i32 noundef %0, ptr noundef %1, i32 noundef %2, ptr noundef %3, i32 noundef %4) local_unnamed_addr #2 {
  %6 = alloca [4 x i32], align 16
  switch i32 %4, label %11 [
    i32 0, label %80
    i32 32, label %7
  ]

7:                                                ; preds = %5
  %8 = sext i32 %2 to i64
  %9 = shl nsw i64 %8, 2
  tail call void @llvm.memcpy.p0.p0.i64(ptr align 16 %3, ptr align 4 %1, i64 %9, i1 false)
  %10 = getelementptr inbounds i32, ptr %3, i64 %8
  br label %80

11:                                               ; preds = %5
  %12 = tail call <2 x i64> @_mm_set1_epi32(i32 noundef %0)
  %13 = tail call <2 x i64> @_mm_setzero_si128()
  %14 = sdiv i32 %2, 4
  %15 = srem i32 %2, 4
  %16 = icmp sgt i32 %2, 3
  br i1 %16, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %11
  %wide.trip.count = zext nneg i32 %14 to i64
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %30
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %30 ]
  %.06182 = phi ptr [ %3, %.lr.ph.preheader ], [ %.1, %30 ]
  %.06580 = phi <2 x i64> [ %13, %.lr.ph.preheader ], [ %.166, %30 ]
  %.06979 = phi i32 [ 0, %.lr.ph.preheader ], [ %.170, %30 ]
  %17 = getelementptr inbounds <2 x i64>, ptr %1, i64 %indvars.iv
  %18 = tail call <2 x i64> @_mm_loadu_si128(ptr noundef %17)
  %19 = tail call <2 x i64> @_mm_sub_epi32(<2 x i64> noundef %18, <2 x i64> noundef %12)
  %20 = tail call <2 x i64> @_mm_slli_epi32(<2 x i64> noundef %19, i32 noundef %.06979)
  %21 = tail call <2 x i64> @_mm_or_si128(<2 x i64> noundef %.06580, <2 x i64> noundef %20)
  %22 = sub i32 32, %.06979
  %23 = icmp ugt i32 %22, %4
  br i1 %23, label %24, label %26

24:                                               ; preds = %.lr.ph
  %25 = add i32 %.06979, %4
  br label %30

26:                                               ; preds = %.lr.ph
  %27 = getelementptr inbounds i8, ptr %.06182, i64 16
  tail call void @_mm_storeu_si128(ptr noundef %.06182, <2 x i64> noundef %21)
  %28 = tail call <2 x i64> @_mm_srli_epi32(<2 x i64> noundef %19, i32 noundef %22)
  %29 = sub i32 %4, %22
  br label %30

30:                                               ; preds = %26, %24
  %.170 = phi i32 [ %25, %24 ], [ %29, %26 ]
  %.166 = phi <2 x i64> [ %21, %24 ], [ %28, %26 ]
  %.1 = phi ptr [ %.06182, %24 ], [ %27, %26 ]
  %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 %.lr.ph, !llvm.loop !5

._crit_edge:                                      ; preds = %30, %11
  %.069.lcssa = phi i32 [ 0, %11 ], [ %.170, %30 ]
  %.065.lcssa = phi <2 x i64> [ %13, %11 ], [ %.166, %30 ]
  %.061.lcssa = phi ptr [ %3, %11 ], [ %.1, %30 ]
  %.not = icmp eq i32 %15, 0
  br i1 %.not, label %77, label %31

31:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #4
  %32 = icmp sgt i32 %15, 0
  br i1 %32, label %.lr.ph88, label %.preheader

.lr.ph88:                                         ; preds = %31
  %33 = shl nsw i32 %14, 2
  %34 = sext i32 %33 to i64
  %35 = shl nsw i64 %34, 2
  %scevgep = getelementptr i8, ptr %1, i64 %35
  %36 = zext nneg i32 %15 to i64
  %37 = shl nuw nsw i64 %36, 2
  call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 16 %6, ptr align 4 %scevgep, i64 %37, i1 false), !tbaa !7
  br label %.preheader

.preheader:                                       ; preds = %.lr.ph88, %31
  %38 = sext i32 %15 to i64
  %n.rnd.up = sub nsw i64 7, %38
  %n.vec = and i64 %n.rnd.up, -4
  %trip.count.minus.1 = sub nsw i64 3, %38
  %broadcast.splatinsert98 = insertelement <4 x i64> poison, i64 %trip.count.minus.1, i64 0
  %broadcast.splat99 = shufflevector <4 x i64> %broadcast.splatinsert98, <4 x i64> poison, <4 x i32> zeroinitializer
  %39 = icmp uge <4 x i64> %broadcast.splat99, <i64 0, i64 1, i64 2, i64 3>
  %40 = extractelement <4 x i1> %39, i64 0
  br i1 %40, label %pred.store.if, label %pred.store.continue

pred.store.if:                                    ; preds = %.preheader
  %41 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %38
  store i32 %0, ptr %41, align 4, !tbaa !7
  br label %pred.store.continue

pred.store.continue:                              ; preds = %pred.store.if, %.preheader
  %42 = extractelement <4 x i1> %39, i64 1
  br i1 %42, label %pred.store.if100, label %pred.store.continue101

pred.store.if100:                                 ; preds = %pred.store.continue
  %43 = add nsw i64 %38, 1
  %44 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %43
  store i32 %0, ptr %44, align 4, !tbaa !7
  br label %pred.store.continue101

pred.store.continue101:                           ; preds = %pred.store.if100, %pred.store.continue
  %45 = extractelement <4 x i1> %39, i64 2
  br i1 %45, label %pred.store.if102, label %pred.store.continue103

pred.store.if102:                                 ; preds = %pred.store.continue101
  %46 = add nsw i64 %38, 2
  %47 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %46
  store i32 %0, ptr %47, align 4, !tbaa !7
  br label %pred.store.continue103

pred.store.continue103:                           ; preds = %pred.store.if102, %pred.store.continue101
  %48 = extractelement <4 x i1> %39, i64 3
  br i1 %48, label %pred.store.if104, label %pred.store.continue105

pred.store.if104:                                 ; preds = %pred.store.continue103
  %49 = add nsw i64 %38, 3
  %50 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %49
  store i32 %0, ptr %50, align 4, !tbaa !7
  br label %pred.store.continue105

pred.store.continue105:                           ; preds = %pred.store.if104, %pred.store.continue103
  %51 = icmp eq i64 %n.vec, 4
  br i1 %51, label %middle.block, label %vector.body.1, !llvm.loop !11

vector.body.1:                                    ; preds = %pred.store.continue105
  %52 = icmp ugt <4 x i64> %broadcast.splat99, <i64 3, i64 4, i64 5, i64 6>
  %53 = extractelement <4 x i1> %52, i64 0
  br i1 %53, label %pred.store.if.1, label %pred.store.continue.1

pred.store.if.1:                                  ; preds = %vector.body.1
  %offset.idx.1 = add nsw i64 %38, 4
  %54 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %offset.idx.1
  store i32 %0, ptr %54, align 4, !tbaa !7
  br label %pred.store.continue.1

pred.store.continue.1:                            ; preds = %pred.store.if.1, %vector.body.1
  %55 = extractelement <4 x i1> %52, i64 1
  br i1 %55, label %pred.store.if100.1, label %pred.store.continue101.1

pred.store.if100.1:                               ; preds = %pred.store.continue.1
  %56 = add nsw i64 %38, 5
  %57 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %56
  store i32 %0, ptr %57, align 4, !tbaa !7
  br label %pred.store.continue101.1

pred.store.continue101.1:                         ; preds = %pred.store.if100.1, %pred.store.continue.1
  %58 = extractelement <4 x i1> %52, i64 2
  br i1 %58, label %pred.store.if102.1, label %pred.store.continue103.1

pred.store.if102.1:                               ; preds = %pred.store.continue101.1
  %59 = add nsw i64 %38, 6
  %60 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %59
  store i32 %0, ptr %60, align 4, !tbaa !7
  br label %pred.store.continue103.1

pred.store.continue103.1:                         ; preds = %pred.store.if102.1, %pred.store.continue101.1
  %61 = extractelement <4 x i1> %52, i64 3
  br i1 %61, label %pred.store.if104.1, label %middle.block

pred.store.if104.1:                               ; preds = %pred.store.continue103.1
  %62 = add nsw i64 %38, 7
  %63 = getelementptr inbounds [4 x i32], ptr %6, i64 0, i64 %62
  store i32 %0, ptr %63, align 4, !tbaa !7
  br label %middle.block

middle.block:                                     ; preds = %pred.store.continue103.1, %pred.store.if104.1, %pred.store.continue105
  %64 = call <2 x i64> @_mm_loadu_si128(ptr noundef nonnull %6)
  %65 = call <2 x i64> @_mm_sub_epi32(<2 x i64> noundef %64, <2 x i64> noundef %12)
  %66 = call <2 x i64> @_mm_slli_epi32(<2 x i64> noundef %65, i32 noundef %.069.lcssa)
  %67 = call <2 x i64> @_mm_or_si128(<2 x i64> noundef %.065.lcssa, <2 x i64> noundef %66)
  %68 = sub i32 32, %.069.lcssa
  %69 = icmp ugt i32 %68, %4
  br i1 %69, label %70, label %72

70:                                               ; preds = %middle.block
  %71 = add i32 %.069.lcssa, %4
  br label %76

72:                                               ; preds = %middle.block
  %73 = getelementptr inbounds i8, ptr %.061.lcssa, i64 16
  call void @_mm_storeu_si128(ptr noundef %.061.lcssa, <2 x i64> noundef %67)
  %74 = call <2 x i64> @_mm_srli_epi32(<2 x i64> noundef %65, i32 noundef %68)
  %75 = sub i32 %4, %68
  br label %76

76:                                               ; preds = %72, %70
  %.271 = phi i32 [ %71, %70 ], [ %75, %72 ]
  %.267 = phi <2 x i64> [ %67, %70 ], [ %74, %72 ]
  %.2 = phi ptr [ %.061.lcssa, %70 ], [ %73, %72 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #4
  br label %77

77:                                               ; preds = %76, %._crit_edge
  %.372 = phi i32 [ %.271, %76 ], [ %.069.lcssa, %._crit_edge ]
  %.368 = phi <2 x i64> [ %.267, %76 ], [ %.065.lcssa, %._crit_edge ]
  %.3 = phi ptr [ %.2, %76 ], [ %.061.lcssa, %._crit_edge ]
  %.not78 = icmp eq i32 %.372, 0
  br i1 %.not78, label %80, label %78

78:                                               ; preds = %77
  %79 = getelementptr inbounds i8, ptr %.3, i64 16
  call void @_mm_storeu_si128(ptr noundef %.3, <2 x i64> noundef %.368)
  br label %80

80:                                               ; preds = %77, %78, %5, %7
  %.0 = phi ptr [ %10, %7 ], [ %3, %5 ], [ %79, %78 ], [ %.3, %77 ]
  ret ptr %.0
}

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_setzero_si128() local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_sub_epi32(<2 x i64> noundef, <2 x i64> noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_loadu_si128(ptr noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_or_si128(<2 x i64> noundef, <2 x i64> noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_slli_epi32(<2 x i64> noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @_mm_storeu_si128(ptr noundef, <2 x i64> noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden <2 x i64> @_mm_srli_epi32(<2 x i64> noundef, i32 noundef) local_unnamed_addr #1

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { alwaysinline nounwind uwtable "min-legal-vector-width"="128" "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"="128" "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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = distinct !{!5, !6}
!6 = !{!"llvm.loop.mustprogress"}
!7 = !{!8, !8, i64 0}
!8 = !{!"int", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C/C++ TBAA"}
!11 = distinct !{!11, !6, !12, !13}
!12 = !{!"llvm.loop.isvectorized", i32 1}
!13 = !{!"llvm.loop.unroll.runtime.disable"}


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