; LLVM IR from niuyishuai/PDCABB :: LAPACK_BLAS/LAPACK (spteqr)

; 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 [2 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [5 x i8], align 1
@c_b7 = external hidden global float, align 4
@c_b8 = external hidden global float, align 4
@.str.5 = external hidden unnamed_addr constant [6 x i8], align 1
@c__0 = external hidden global i64, align 8
@c__1 = external hidden global i64, align 8

; Function Attrs: nounwind uwtable
define dso_local i32 @spteqr_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7) #0 {
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca i64, align 8
  %21 = alloca [1 x float], align 4
  %22 = alloca i64, align 8
  %23 = alloca [1 x float], align 4
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca i32, align 4
  store ptr %0, ptr %10, align 8, !tbaa !5
  store ptr %1, ptr %11, align 8, !tbaa !5
  store ptr %2, ptr %12, align 8, !tbaa !5
  store ptr %3, ptr %13, align 8, !tbaa !5
  store ptr %4, ptr %14, align 8, !tbaa !5
  store ptr %5, ptr %15, align 8, !tbaa !5
  store ptr %6, ptr %16, align 8, !tbaa !5
  store ptr %7, ptr %17, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #4
  %27 = load ptr, ptr %12, align 8, !tbaa !5
  %28 = getelementptr inbounds float, ptr %27, i32 -1
  store ptr %28, ptr %12, align 8, !tbaa !5
  %29 = load ptr, ptr %13, align 8, !tbaa !5
  %30 = getelementptr inbounds float, ptr %29, i32 -1
  store ptr %30, ptr %13, align 8, !tbaa !5
  %31 = load ptr, ptr %15, align 8, !tbaa !5
  %32 = load i64, ptr %31, align 8, !tbaa !9
  store i64 %32, ptr %18, align 8, !tbaa !9
  %33 = load i64, ptr %18, align 8, !tbaa !9
  %34 = add nsw i64 1, %33
  store i64 %34, ptr %19, align 8, !tbaa !9
  %35 = load i64, ptr %19, align 8, !tbaa !9
  %36 = load ptr, ptr %14, align 8, !tbaa !5
  %37 = sub i64 0, %35
  %38 = getelementptr inbounds float, ptr %36, i64 %37
  store ptr %38, ptr %14, align 8, !tbaa !5
  %39 = load ptr, ptr %16, align 8, !tbaa !5
  %40 = getelementptr inbounds float, ptr %39, i32 -1
  store ptr %40, ptr %16, align 8, !tbaa !5
  %41 = load ptr, ptr %17, align 8, !tbaa !5
  store i64 0, ptr %41, align 8, !tbaa !9
  %42 = load ptr, ptr %10, align 8, !tbaa !5
  %43 = call i64 @lsame_(ptr noundef %42, ptr noundef @.str)
  %44 = icmp ne i64 %43, 0
  br i1 %44, label %45, label %46

45:                                               ; preds = %8
  store i64 0, ptr %25, align 8, !tbaa !9
  br label %59

46:                                               ; preds = %8
  %47 = load ptr, ptr %10, align 8, !tbaa !5
  %48 = call i64 @lsame_(ptr noundef %47, ptr noundef @.str.1)
  %49 = icmp ne i64 %48, 0
  br i1 %49, label %50, label %51

50:                                               ; preds = %46
  store i64 1, ptr %25, align 8, !tbaa !9
  br label %58

51:                                               ; preds = %46
  %52 = load ptr, ptr %10, align 8, !tbaa !5
  %53 = call i64 @lsame_(ptr noundef %52, ptr noundef @.str.2)
  %54 = icmp ne i64 %53, 0
  br i1 %54, label %55, label %56

55:                                               ; preds = %51
  store i64 2, ptr %25, align 8, !tbaa !9
  br label %57

56:                                               ; preds = %51
  store i64 -1, ptr %25, align 8, !tbaa !9
  br label %57

57:                                               ; preds = %56, %55
  br label %58

58:                                               ; preds = %57, %50
  br label %59

59:                                               ; preds = %58, %45
  %60 = load i64, ptr %25, align 8, !tbaa !9
  %61 = icmp slt i64 %60, 0
  br i1 %61, label %62, label %64

62:                                               ; preds = %59
  %63 = load ptr, ptr %17, align 8, !tbaa !5
  store i64 -1, ptr %63, align 8, !tbaa !9
  br label %94

64:                                               ; preds = %59
  %65 = load ptr, ptr %11, align 8, !tbaa !5
  %66 = load i64, ptr %65, align 8, !tbaa !9
  %67 = icmp slt i64 %66, 0
  br i1 %67, label %68, label %70

68:                                               ; preds = %64
  %69 = load ptr, ptr %17, align 8, !tbaa !5
  store i64 -2, ptr %69, align 8, !tbaa !9
  br label %93

70:                                               ; preds = %64
  %71 = load ptr, ptr %15, align 8, !tbaa !5
  %72 = load i64, ptr %71, align 8, !tbaa !9
  %73 = icmp slt i64 %72, 1
  br i1 %73, label %90, label %74

74:                                               ; preds = %70
  %75 = load i64, ptr %25, align 8, !tbaa !9
  %76 = icmp sgt i64 %75, 0
  br i1 %76, label %77, label %92

77:                                               ; preds = %74
  %78 = load ptr, ptr %15, align 8, !tbaa !5
  %79 = load i64, ptr %78, align 8, !tbaa !9
  %80 = load ptr, ptr %11, align 8, !tbaa !5
  %81 = load i64, ptr %80, align 8, !tbaa !9
  %82 = icmp sge i64 1, %81
  br i1 %82, label %83, label %84

83:                                               ; preds = %77
  br label %87

84:                                               ; preds = %77
  %85 = load ptr, ptr %11, align 8, !tbaa !5
  %86 = load i64, ptr %85, align 8, !tbaa !9
  br label %87

87:                                               ; preds = %84, %83
  %88 = phi i64 [ 1, %83 ], [ %86, %84 ]
  %89 = icmp slt i64 %79, %88
  br i1 %89, label %90, label %92

90:                                               ; preds = %87, %70
  %91 = load ptr, ptr %17, align 8, !tbaa !5
  store i64 -6, ptr %91, align 8, !tbaa !9
  br label %92

92:                                               ; preds = %90, %87, %74
  br label %93

93:                                               ; preds = %92, %68
  br label %94

94:                                               ; preds = %93, %62
  %95 = load ptr, ptr %17, align 8, !tbaa !5
  %96 = load i64, ptr %95, align 8, !tbaa !9
  %97 = icmp ne i64 %96, 0
  br i1 %97, label %98, label %103

98:                                               ; preds = %94
  %99 = load ptr, ptr %17, align 8, !tbaa !5
  %100 = load i64, ptr %99, align 8, !tbaa !9
  %101 = sub nsw i64 0, %100
  store i64 %101, ptr %20, align 8, !tbaa !9
  %102 = call i32 @xerbla_(ptr noundef @.str.3, ptr noundef %20)
  store i32 0, ptr %9, align 4
  store i32 1, ptr %26, align 4
  br label %241

103:                                              ; preds = %94
  %104 = load ptr, ptr %11, align 8, !tbaa !5
  %105 = load i64, ptr %104, align 8, !tbaa !9
  %106 = icmp eq i64 %105, 0
  br i1 %106, label %107, label %108

107:                                              ; preds = %103
  store i32 0, ptr %9, align 4
  store i32 1, ptr %26, align 4
  br label %241

108:                                              ; preds = %103
  %109 = load ptr, ptr %11, align 8, !tbaa !5
  %110 = load i64, ptr %109, align 8, !tbaa !9
  %111 = icmp eq i64 %110, 1
  br i1 %111, label %112, label %121

112:                                              ; preds = %108
  %113 = load i64, ptr %25, align 8, !tbaa !9
  %114 = icmp sgt i64 %113, 0
  br i1 %114, label %115, label %120

115:                                              ; preds = %112
  %116 = load ptr, ptr %14, align 8, !tbaa !5
  %117 = load i64, ptr %18, align 8, !tbaa !9
  %118 = add nsw i64 %117, 1
  %119 = getelementptr inbounds float, ptr %116, i64 %118
  store float 1.000000e+00, ptr %119, align 4, !tbaa !11
  br label %120

120:                                              ; preds = %115, %112
  store i32 0, ptr %9, align 4
  store i32 1, ptr %26, align 4
  br label %241

121:                                              ; preds = %108
  %122 = load i64, ptr %25, align 8, !tbaa !9
  %123 = icmp eq i64 %122, 2
  br i1 %123, label %124, label %132

124:                                              ; preds = %121
  %125 = load ptr, ptr %11, align 8, !tbaa !5
  %126 = load ptr, ptr %11, align 8, !tbaa !5
  %127 = load ptr, ptr %14, align 8, !tbaa !5
  %128 = load i64, ptr %19, align 8, !tbaa !9
  %129 = getelementptr inbounds float, ptr %127, i64 %128
  %130 = load ptr, ptr %15, align 8, !tbaa !5
  %131 = call i32 @slaset_(ptr noundef @.str.4, ptr noundef %125, ptr noundef %126, ptr noundef @c_b7, ptr noundef @c_b8, ptr noundef %129, ptr noundef %130)
  br label %132

132:                                              ; preds = %124, %121
  %133 = load ptr, ptr %11, align 8, !tbaa !5
  %134 = load ptr, ptr %12, align 8, !tbaa !5
  %135 = getelementptr inbounds float, ptr %134, i64 1
  %136 = load ptr, ptr %13, align 8, !tbaa !5
  %137 = getelementptr inbounds float, ptr %136, i64 1
  %138 = load ptr, ptr %17, align 8, !tbaa !5
  %139 = call i32 @spttrf_(ptr noundef %133, ptr noundef %135, ptr noundef %137, ptr noundef %138)
  %140 = load ptr, ptr %17, align 8, !tbaa !5
  %141 = load i64, ptr %140, align 8, !tbaa !9
  %142 = icmp ne i64 %141, 0
  br i1 %142, label %143, label %144

143:                                              ; preds = %132
  store i32 0, ptr %9, align 4
  store i32 1, ptr %26, align 4
  br label %241

144:                                              ; preds = %132
  %145 = load ptr, ptr %11, align 8, !tbaa !5
  %146 = load i64, ptr %145, align 8, !tbaa !9
  store i64 %146, ptr %20, align 8, !tbaa !9
  store i64 1, ptr %22, align 8, !tbaa !9
  br label %147

147:                                              ; preds = %162, %144
  %148 = load i64, ptr %22, align 8, !tbaa !9
  %149 = load i64, ptr %20, align 8, !tbaa !9
  %150 = icmp sle i64 %148, %149
  br i1 %150, label %151, label %165

151:                                              ; preds = %147
  %152 = load ptr, ptr %12, align 8, !tbaa !5
  %153 = load i64, ptr %22, align 8, !tbaa !9
  %154 = getelementptr inbounds float, ptr %152, i64 %153
  %155 = load float, ptr %154, align 4, !tbaa !11
  %156 = fpext float %155 to double
  %157 = call double @sqrt(double noundef %156) #4
  %158 = fptrunc double %157 to float
  %159 = load ptr, ptr %12, align 8, !tbaa !5
  %160 = load i64, ptr %22, align 8, !tbaa !9
  %161 = getelementptr inbounds float, ptr %159, i64 %160
  store float %158, ptr %161, align 4, !tbaa !11
  br label %162

162:                                              ; preds = %151
  %163 = load i64, ptr %22, align 8, !tbaa !9
  %164 = add nsw i64 %163, 1
  store i64 %164, ptr %22, align 8, !tbaa !9
  br label %147, !llvm.loop !13

165:                                              ; preds = %147
  %166 = load ptr, ptr %11, align 8, !tbaa !5
  %167 = load i64, ptr %166, align 8, !tbaa !9
  %168 = sub nsw i64 %167, 1
  store i64 %168, ptr %20, align 8, !tbaa !9
  store i64 1, ptr %22, align 8, !tbaa !9
  br label %169

169:                                              ; preds = %183, %165
  %170 = load i64, ptr %22, align 8, !tbaa !9
  %171 = load i64, ptr %20, align 8, !tbaa !9
  %172 = icmp sle i64 %170, %171
  br i1 %172, label %173, label %186

173:                                              ; preds = %169
  %174 = load ptr, ptr %12, align 8, !tbaa !5
  %175 = load i64, ptr %22, align 8, !tbaa !9
  %176 = getelementptr inbounds float, ptr %174, i64 %175
  %177 = load float, ptr %176, align 4, !tbaa !11
  %178 = load ptr, ptr %13, align 8, !tbaa !5
  %179 = load i64, ptr %22, align 8, !tbaa !9
  %180 = getelementptr inbounds float, ptr %178, i64 %179
  %181 = load float, ptr %180, align 4, !tbaa !11
  %182 = fmul float %181, %177
  store float %182, ptr %180, align 4, !tbaa !11
  br label %183

183:                                              ; preds = %173
  %184 = load i64, ptr %22, align 8, !tbaa !9
  %185 = add nsw i64 %184, 1
  store i64 %185, ptr %22, align 8, !tbaa !9
  br label %169, !llvm.loop !15

186:                                              ; preds = %169
  %187 = load i64, ptr %25, align 8, !tbaa !9
  %188 = icmp sgt i64 %187, 0
  br i1 %188, label %189, label %192

189:                                              ; preds = %186
  %190 = load ptr, ptr %11, align 8, !tbaa !5
  %191 = load i64, ptr %190, align 8, !tbaa !9
  store i64 %191, ptr %24, align 8, !tbaa !9
  br label %193

192:                                              ; preds = %186
  store i64 0, ptr %24, align 8, !tbaa !9
  br label %193

193:                                              ; preds = %192, %189
  %194 = load ptr, ptr %11, align 8, !tbaa !5
  %195 = load ptr, ptr %12, align 8, !tbaa !5
  %196 = getelementptr inbounds float, ptr %195, i64 1
  %197 = load ptr, ptr %13, align 8, !tbaa !5
  %198 = getelementptr inbounds float, ptr %197, i64 1
  %199 = getelementptr inbounds [1 x float], ptr %23, i64 0, i64 0
  %200 = load ptr, ptr %14, align 8, !tbaa !5
  %201 = load i64, ptr %19, align 8, !tbaa !9
  %202 = getelementptr inbounds float, ptr %200, i64 %201
  %203 = load ptr, ptr %15, align 8, !tbaa !5
  %204 = getelementptr inbounds [1 x float], ptr %21, i64 0, i64 0
  %205 = load ptr, ptr %16, align 8, !tbaa !5
  %206 = getelementptr inbounds float, ptr %205, i64 1
  %207 = load ptr, ptr %17, align 8, !tbaa !5
  %208 = call i32 @sbdsqr_(ptr noundef @.str.5, ptr noundef %194, ptr noundef @c__0, ptr noundef %24, ptr noundef @c__0, ptr noundef %196, ptr noundef %198, ptr noundef %199, ptr noundef @c__1, ptr noundef %202, ptr noundef %203, ptr noundef %204, ptr noundef @c__1, ptr noundef %206, ptr noundef %207)
  %209 = load ptr, ptr %17, align 8, !tbaa !5
  %210 = load i64, ptr %209, align 8, !tbaa !9
  %211 = icmp eq i64 %210, 0
  br i1 %211, label %212, label %233

212:                                              ; preds = %193
  %213 = load ptr, ptr %11, align 8, !tbaa !5
  %214 = load i64, ptr %213, align 8, !tbaa !9
  store i64 %214, ptr %20, align 8, !tbaa !9
  store i64 1, ptr %22, align 8, !tbaa !9
  br label %215

215:                                              ; preds = %229, %212
  %216 = load i64, ptr %22, align 8, !tbaa !9
  %217 = load i64, ptr %20, align 8, !tbaa !9
  %218 = icmp sle i64 %216, %217
  br i1 %218, label %219, label %232

219:                                              ; preds = %215
  %220 = load ptr, ptr %12, align 8, !tbaa !5
  %221 = load i64, ptr %22, align 8, !tbaa !9
  %222 = getelementptr inbounds float, ptr %220, i64 %221
  %223 = load float, ptr %222, align 4, !tbaa !11
  %224 = load ptr, ptr %12, align 8, !tbaa !5
  %225 = load i64, ptr %22, align 8, !tbaa !9
  %226 = getelementptr inbounds float, ptr %224, i64 %225
  %227 = load float, ptr %226, align 4, !tbaa !11
  %228 = fmul float %227, %223
  store float %228, ptr %226, align 4, !tbaa !11
  br label %229

229:                                              ; preds = %219
  %230 = load i64, ptr %22, align 8, !tbaa !9
  %231 = add nsw i64 %230, 1
  store i64 %231, ptr %22, align 8, !tbaa !9
  br label %215, !llvm.loop !16

232:                                              ; preds = %215
  br label %240

233:                                              ; preds = %193
  %234 = load ptr, ptr %11, align 8, !tbaa !5
  %235 = load i64, ptr %234, align 8, !tbaa !9
  %236 = load ptr, ptr %17, align 8, !tbaa !5
  %237 = load i64, ptr %236, align 8, !tbaa !9
  %238 = add nsw i64 %235, %237
  %239 = load ptr, ptr %17, align 8, !tbaa !5
  store i64 %238, ptr %239, align 8, !tbaa !9
  br label %240

240:                                              ; preds = %233, %232
  store i32 0, ptr %9, align 4
  store i32 1, ptr %26, align 4
  br label %241

241:                                              ; preds = %240, %143, %120, %107, %98
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  %242 = load i32, ptr %9, align 4
  ret i32 %242
}

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

declare i64 @lsame_(ptr noundef, ptr noundef) #2

declare i32 @xerbla_(ptr noundef, ptr noundef) #2

declare i32 @slaset_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare i32 @spttrf_(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: nounwind
declare double @sqrt(double noundef) #3

declare i32 @sbdsqr_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

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

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}
!16 = distinct !{!16, !14}


; 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 [2 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [5 x i8], align 1
@c_b7 = external hidden global float, align 4
@c_b8 = external hidden global float, align 4
@.str.5 = external hidden unnamed_addr constant [6 x i8], align 1
@c__0 = external hidden global i64, align 8
@c__1 = external hidden global i64, align 8

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @spteqr_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7) local_unnamed_addr #0 {
  %9 = alloca i64, align 8
  %10 = alloca [1 x float], align 4
  %11 = alloca [1 x float], align 4
  %12 = alloca i64, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #3
  %13 = getelementptr inbounds i8, ptr %2, i64 -4
  %14 = getelementptr inbounds i8, ptr %3, i64 -4
  store i64 0, ptr %7, align 8, !tbaa !5
  %15 = tail call i64 @lsame_(ptr noundef %0, ptr noundef nonnull @.str) #3
  %.not = icmp eq i64 %15, 0
  br i1 %.not, label %16, label %.thread

16:                                               ; preds = %8
  %17 = tail call i64 @lsame_(ptr noundef %0, ptr noundef nonnull @.str.1) #3
  %.not81 = icmp eq i64 %17, 0
  br i1 %.not81, label %18, label %.thread

18:                                               ; preds = %16
  %19 = tail call i64 @lsame_(ptr noundef %0, ptr noundef nonnull @.str.2) #3
  %.not82 = icmp eq i64 %19, 0
  br i1 %.not82, label %.thread93.sink.split, label %.thread

.thread:                                          ; preds = %16, %8, %18
  %20 = phi i1 [ true, %18 ], [ false, %8 ], [ false, %16 ]
  %21 = load i64, ptr %1, align 8, !tbaa !5
  %22 = icmp slt i64 %21, 0
  br i1 %22, label %.thread93.sink.split, label %23

23:                                               ; preds = %.thread
  %24 = load i64, ptr %5, align 8, !tbaa !5
  %25 = icmp slt i64 %24, 1
  %26 = icmp ugt i64 %21, %24
  %or.cond = and i1 %.not, %26
  %or.cond110 = or i1 %25, %or.cond
  br i1 %or.cond110, label %.thread93.sink.split, label %27

27:                                               ; preds = %23
  %.pr = load i64, ptr %7, align 8, !tbaa !5
  %.not83 = icmp eq i64 %.pr, 0
  br i1 %.not83, label %31, label %.thread93

.thread93.sink.split:                             ; preds = %23, %.thread, %18
  %.sink = phi i64 [ -1, %18 ], [ -2, %.thread ], [ -6, %23 ]
  store i64 %.sink, ptr %7, align 8, !tbaa !5
  br label %.thread93

.thread93:                                        ; preds = %.thread93.sink.split, %27
  %28 = phi i64 [ %.pr, %27 ], [ %.sink, %.thread93.sink.split ]
  %29 = sub nsw i64 0, %28
  store i64 %29, ptr %9, align 8, !tbaa !5
  %30 = call i32 @xerbla_(ptr noundef nonnull @.str.3, ptr noundef nonnull %9) #3
  br label %.loopexit

31:                                               ; preds = %27
  switch i64 %21, label %34 [
    i64 0, label %.loopexit
    i64 1, label %32
  ]

32:                                               ; preds = %31
  br i1 %.not, label %33, label %.loopexit

33:                                               ; preds = %32
  store float 1.000000e+00, ptr %4, align 4, !tbaa !9
  br label %.loopexit

34:                                               ; preds = %31
  br i1 %20, label %35, label %37

35:                                               ; preds = %34
  %36 = tail call i32 @slaset_(ptr noundef nonnull @.str.4, ptr noundef nonnull %1, ptr noundef nonnull %1, ptr noundef nonnull @c_b7, ptr noundef nonnull @c_b8, ptr noundef %4, ptr noundef nonnull %5) #3
  br label %37

37:                                               ; preds = %35, %34
  %38 = tail call i32 @spttrf_(ptr noundef nonnull %1, ptr noundef %2, ptr noundef %3, ptr noundef nonnull %7) #3
  %39 = load i64, ptr %7, align 8, !tbaa !5
  %.not84 = icmp eq i64 %39, 0
  br i1 %.not84, label %40, label %.loopexit

40:                                               ; preds = %37
  %41 = load i64, ptr %1, align 8, !tbaa !5
  %.not8596 = icmp slt i64 %41, 1
  br i1 %.not8596, label %._crit_edge102, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %40
  %xtraiter = and i64 %41, 3
  %42 = icmp ult i64 %41, 4
  br i1 %42, label %._crit_edge.unr-lcssa, label %.lr.ph.preheader.new

.lr.ph.preheader.new:                             ; preds = %.lr.ph.preheader
  %unroll_iter = and i64 %41, 9223372036854775804
  %invariant.gep = getelementptr i8, ptr %13, i64 8
  %invariant.gep135 = getelementptr i8, ptr %13, i64 12
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph, %.lr.ph.preheader.new
  %.07497 = phi i64 [ 1, %.lr.ph.preheader.new ], [ %49, %.lr.ph ]
  %niter = phi i64 [ 0, %.lr.ph.preheader.new ], [ %niter.next.3, %.lr.ph ]
  %43 = getelementptr inbounds float, ptr %13, i64 %.07497
  %44 = load float, ptr %43, align 4, !tbaa !9
  %sqrtf = tail call float @sqrtf(float noundef %44) #4
  store float %sqrtf, ptr %43, align 4, !tbaa !9
  %45 = getelementptr float, ptr %2, i64 %.07497
  %46 = load float, ptr %45, align 4, !tbaa !9
  %sqrtf.1 = tail call float @sqrtf(float noundef %46) #4
  store float %sqrtf.1, ptr %45, align 4, !tbaa !9
  %gep = getelementptr float, ptr %invariant.gep, i64 %.07497
  %47 = load float, ptr %gep, align 4, !tbaa !9
  %sqrtf.2 = tail call float @sqrtf(float noundef %47) #4
  store float %sqrtf.2, ptr %gep, align 4, !tbaa !9
  %gep136 = getelementptr float, ptr %invariant.gep135, i64 %.07497
  %48 = load float, ptr %gep136, align 4, !tbaa !9
  %sqrtf.3 = tail call float @sqrtf(float noundef %48) #4
  store float %sqrtf.3, ptr %gep136, align 4, !tbaa !9
  %49 = add nuw i64 %.07497, 4
  %niter.next.3 = add i64 %niter, 4
  %niter.ncmp.3 = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3, label %._crit_edge.unr-lcssa, label %.lr.ph, !llvm.loop !11

._crit_edge.unr-lcssa:                            ; preds = %.lr.ph, %.lr.ph.preheader
  %.07497.unr = phi i64 [ 1, %.lr.ph.preheader ], [ %49, %.lr.ph ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge, label %.lr.ph.epil

.lr.ph.epil:                                      ; preds = %._crit_edge.unr-lcssa, %.lr.ph.epil
  %.07497.epil = phi i64 [ %52, %.lr.ph.epil ], [ %.07497.unr, %._crit_edge.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph.epil ], [ 0, %._crit_edge.unr-lcssa ]
  %50 = getelementptr inbounds float, ptr %13, i64 %.07497.epil
  %51 = load float, ptr %50, align 4, !tbaa !9
  %sqrtf.epil = tail call float @sqrtf(float noundef %51) #4
  store float %sqrtf.epil, ptr %50, align 4, !tbaa !9
  %52 = add nuw i64 %.07497.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %._crit_edge, label %.lr.ph.epil, !llvm.loop !13

._crit_edge:                                      ; preds = %.lr.ph.epil, %._crit_edge.unr-lcssa
  %.pre = load i64, ptr %1, align 8, !tbaa !5
  %.not86.not98 = icmp sgt i64 %.pre, 1
  br i1 %.not86.not98, label %.lr.ph101.preheader, label %._crit_edge102

.lr.ph101.preheader:                              ; preds = %._crit_edge
  %53 = add nsw i64 %.pre, -1
  %min.iters.check = icmp ult i64 %.pre, 9
  br i1 %min.iters.check, label %.lr.ph101.preheader131, label %vector.memcheck

vector.memcheck:                                  ; preds = %.lr.ph101.preheader
  %54 = shl i64 %.pre, 2
  %55 = add i64 %54, -4
  %scevgep = getelementptr i8, ptr %3, i64 %55
  %scevgep111 = getelementptr i8, ptr %2, i64 %55
  %bound0 = icmp ugt ptr %scevgep111, %3
  %bound1 = icmp ugt ptr %scevgep, %2
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %.lr.ph101.preheader131, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %53, -8
  %ind.end = or disjoint i64 %n.vec, 1
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %56 = getelementptr float, ptr %2, i64 %index
  %57 = getelementptr inbounds i8, ptr %56, i64 16
  %wide.load = load <4 x float>, ptr %56, align 4, !tbaa !9, !alias.scope !15
  %wide.load112 = load <4 x float>, ptr %57, align 4, !tbaa !9, !alias.scope !15
  %58 = getelementptr float, ptr %3, i64 %index
  %59 = getelementptr inbounds i8, ptr %58, i64 16
  %wide.load113 = load <4 x float>, ptr %58, align 4, !tbaa !9, !alias.scope !18, !noalias !15
  %wide.load114 = load <4 x float>, ptr %59, align 4, !tbaa !9, !alias.scope !18, !noalias !15
  %60 = fmul <4 x float> %wide.load, %wide.load113
  %61 = fmul <4 x float> %wide.load112, %wide.load114
  store <4 x float> %60, ptr %58, align 4, !tbaa !9, !alias.scope !18, !noalias !15
  store <4 x float> %61, ptr %59, align 4, !tbaa !9, !alias.scope !18, !noalias !15
  %index.next = add nuw i64 %index, 8
  %62 = icmp eq i64 %index.next, %n.vec
  br i1 %62, label %middle.block, label %vector.body, !llvm.loop !20

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %53, %n.vec
  br i1 %cmp.n, label %._crit_edge102, label %.lr.ph101.preheader131

.lr.ph101.preheader131:                           ; preds = %middle.block, %vector.memcheck, %.lr.ph101.preheader
  %.199.ph = phi i64 [ 1, %vector.memcheck ], [ 1, %.lr.ph101.preheader ], [ %ind.end, %middle.block ]
  %63 = sub i64 %.pre, %.199.ph
  %xtraiter132 = and i64 %63, 3
  %lcmp.mod133.not = icmp eq i64 %xtraiter132, 0
  br i1 %lcmp.mod133.not, label %.lr.ph101.prol.loopexit, label %.lr.ph101.prol

.lr.ph101.prol:                                   ; preds = %.lr.ph101.preheader131, %.lr.ph101.prol
  %.199.prol = phi i64 [ %69, %.lr.ph101.prol ], [ %.199.ph, %.lr.ph101.preheader131 ]
  %prol.iter = phi i64 [ %prol.iter.next, %.lr.ph101.prol ], [ 0, %.lr.ph101.preheader131 ]
  %64 = getelementptr inbounds float, ptr %13, i64 %.199.prol
  %65 = load float, ptr %64, align 4, !tbaa !9
  %66 = getelementptr inbounds float, ptr %14, i64 %.199.prol
  %67 = load float, ptr %66, align 4, !tbaa !9
  %68 = fmul float %65, %67
  store float %68, ptr %66, align 4, !tbaa !9
  %69 = add nuw nsw i64 %.199.prol, 1
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter132
  br i1 %prol.iter.cmp.not, label %.lr.ph101.prol.loopexit, label %.lr.ph101.prol, !llvm.loop !23

.lr.ph101.prol.loopexit:                          ; preds = %.lr.ph101.prol, %.lr.ph101.preheader131
  %.199.unr = phi i64 [ %.199.ph, %.lr.ph101.preheader131 ], [ %69, %.lr.ph101.prol ]
  %70 = sub i64 %.199.ph, %.pre
  %71 = icmp ugt i64 %70, -4
  br i1 %71, label %._crit_edge102, label %.lr.ph101

.lr.ph101:                                        ; preds = %.lr.ph101.prol.loopexit, %.lr.ph101
  %.199 = phi i64 [ %94, %.lr.ph101 ], [ %.199.unr, %.lr.ph101.prol.loopexit ]
  %72 = getelementptr inbounds float, ptr %13, i64 %.199
  %73 = load float, ptr %72, align 4, !tbaa !9
  %74 = getelementptr inbounds float, ptr %14, i64 %.199
  %75 = load float, ptr %74, align 4, !tbaa !9
  %76 = fmul float %73, %75
  store float %76, ptr %74, align 4, !tbaa !9
  %77 = getelementptr float, ptr %2, i64 %.199
  %78 = load float, ptr %77, align 4, !tbaa !9
  %79 = getelementptr float, ptr %3, i64 %.199
  %80 = load float, ptr %79, align 4, !tbaa !9
  %81 = fmul float %78, %80
  store float %81, ptr %79, align 4, !tbaa !9
  %82 = add nuw nsw i64 %.199, 2
  %83 = getelementptr inbounds float, ptr %13, i64 %82
  %84 = load float, ptr %83, align 4, !tbaa !9
  %85 = getelementptr inbounds float, ptr %14, i64 %82
  %86 = load float, ptr %85, align 4, !tbaa !9
  %87 = fmul float %84, %86
  store float %87, ptr %85, align 4, !tbaa !9
  %88 = add nuw nsw i64 %.199, 3
  %89 = getelementptr inbounds float, ptr %13, i64 %88
  %90 = load float, ptr %89, align 4, !tbaa !9
  %91 = getelementptr inbounds float, ptr %14, i64 %88
  %92 = load float, ptr %91, align 4, !tbaa !9
  %93 = fmul float %90, %92
  store float %93, ptr %91, align 4, !tbaa !9
  %94 = add nuw nsw i64 %.199, 4
  %exitcond107.not.3 = icmp eq i64 %94, %.pre
  br i1 %exitcond107.not.3, label %._crit_edge102, label %.lr.ph101, !llvm.loop !24

._crit_edge102:                                   ; preds = %.lr.ph101.prol.loopexit, %.lr.ph101, %middle.block, %40, %._crit_edge
  %95 = phi i64 [ %.pre, %._crit_edge ], [ %41, %40 ], [ %.pre, %middle.block ], [ %.pre, %.lr.ph101 ], [ %.pre, %.lr.ph101.prol.loopexit ]
  %spec.select95 = select i1 %.not, i64 %95, i64 0
  store i64 %spec.select95, ptr %12, align 8, !tbaa !5
  %96 = call i32 @sbdsqr_(ptr noundef nonnull @.str.5, ptr noundef nonnull %1, ptr noundef nonnull @c__0, ptr noundef nonnull %12, ptr noundef nonnull @c__0, ptr noundef %2, ptr noundef %3, ptr noundef nonnull %11, ptr noundef nonnull @c__1, ptr noundef %4, ptr noundef nonnull %5, ptr noundef nonnull %10, ptr noundef nonnull @c__1, ptr noundef %6, ptr noundef nonnull %7) #3
  %97 = load i64, ptr %7, align 8, !tbaa !5
  %98 = icmp eq i64 %97, 0
  %99 = load i64, ptr %1, align 8, !tbaa !5
  br i1 %98, label %100, label %110

100:                                              ; preds = %._crit_edge102
  %.not87103 = icmp slt i64 %99, 1
  br i1 %.not87103, label %.loopexit, label %.lr.ph106.preheader

.lr.ph106.preheader:                              ; preds = %100
  %min.iters.check117 = icmp ult i64 %99, 8
  br i1 %min.iters.check117, label %.lr.ph106.preheader130, label %vector.ph118

vector.ph118:                                     ; preds = %.lr.ph106.preheader
  %n.vec120 = and i64 %99, 9223372036854775800
  %ind.end121 = or disjoint i64 %n.vec120, 1
  br label %vector.body123

vector.body123:                                   ; preds = %vector.body123, %vector.ph118
  %index124 = phi i64 [ 0, %vector.ph118 ], [ %index.next128, %vector.body123 ]
  %101 = getelementptr float, ptr %2, i64 %index124
  %102 = getelementptr inbounds i8, ptr %101, i64 16
  %wide.load126 = load <4 x float>, ptr %101, align 4, !tbaa !9
  %wide.load127 = load <4 x float>, ptr %102, align 4, !tbaa !9
  %103 = fmul <4 x float> %wide.load126, %wide.load126
  %104 = fmul <4 x float> %wide.load127, %wide.load127
  store <4 x float> %103, ptr %101, align 4, !tbaa !9
  store <4 x float> %104, ptr %102, align 4, !tbaa !9
  %index.next128 = add nuw i64 %index124, 8
  %105 = icmp eq i64 %index.next128, %n.vec120
  br i1 %105, label %middle.block115, label %vector.body123, !llvm.loop !25

middle.block115:                                  ; preds = %vector.body123
  %cmp.n129 = icmp eq i64 %99, %n.vec120
  br i1 %cmp.n129, label %.loopexit, label %.lr.ph106.preheader130

.lr.ph106.preheader130:                           ; preds = %middle.block115, %.lr.ph106.preheader
  %.2104.ph = phi i64 [ 1, %.lr.ph106.preheader ], [ %ind.end121, %middle.block115 ]
  br label %.lr.ph106

.lr.ph106:                                        ; preds = %.lr.ph106.preheader130, %.lr.ph106
  %.2104 = phi i64 [ %109, %.lr.ph106 ], [ %.2104.ph, %.lr.ph106.preheader130 ]
  %106 = getelementptr inbounds float, ptr %13, i64 %.2104
  %107 = load float, ptr %106, align 4, !tbaa !9
  %108 = fmul float %107, %107
  store float %108, ptr %106, align 4, !tbaa !9
  %109 = add nuw i64 %.2104, 1
  %exitcond108.not = icmp eq i64 %.2104, %99
  br i1 %exitcond108.not, label %.loopexit, label %.lr.ph106, !llvm.loop !26

110:                                              ; preds = %._crit_edge102
  %111 = add nsw i64 %99, %97
  store i64 %111, ptr %7, align 8, !tbaa !5
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph106, %middle.block115, %100, %110, %37, %32, %33, %31, %.thread93
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #3
  ret i32 0
}

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

declare i64 @lsame_(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @xerbla_(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @slaset_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @spttrf_(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @sbdsqr_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

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

declare float @sqrtf(float) local_unnamed_addr

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 }
attributes #4 = { mustprogress nofree nounwind willreturn memory(write) "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" }

!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 = !{!"long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.unroll.disable"}
!15 = !{!16}
!16 = distinct !{!16, !17}
!17 = distinct !{!17, !"LVerDomain"}
!18 = !{!19}
!19 = distinct !{!19, !17}
!20 = distinct !{!20, !12, !21, !22}
!21 = !{!"llvm.loop.isvectorized", i32 1}
!22 = !{!"llvm.loop.unroll.runtime.disable"}
!23 = distinct !{!23, !14}
!24 = distinct !{!24, !12, !21}
!25 = distinct !{!25, !12, !21, !22}
!26 = distinct !{!26, !12, !22, !21}


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