; LLVM IR from OpenMathLib/OpenBLAS :: lapack-netlib/SRC (dspgv)

; 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 [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [9 x i8], align 1
@c__1 = external hidden global i32, align 4

; Function Attrs: nounwind uwtable
define dso_local void @dspgv_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8, ptr noundef %9, ptr noundef %10) #0 {
  %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 ptr, align 8
  %19 = alloca ptr, align 8
  %20 = alloca ptr, align 8
  %21 = alloca ptr, align 8
  %22 = alloca ptr, align 8
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca [1 x i8], align 1
  %29 = alloca i32, align 4
  %30 = alloca i32, align 4
  %31 = alloca i32, align 4
  store ptr %0, ptr %12, align 8, !tbaa !5
  store ptr %1, ptr %13, align 8, !tbaa !5
  store ptr %2, ptr %14, align 8, !tbaa !5
  store ptr %3, ptr %15, align 8, !tbaa !5
  store ptr %4, ptr %16, align 8, !tbaa !5
  store ptr %5, ptr %17, align 8, !tbaa !5
  store ptr %6, ptr %18, align 8, !tbaa !5
  store ptr %7, ptr %19, align 8, !tbaa !5
  store ptr %8, ptr %20, align 8, !tbaa !5
  store ptr %9, ptr %21, align 8, !tbaa !5
  store ptr %10, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %28) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #3
  %32 = load ptr, ptr %16, align 8, !tbaa !5
  %33 = getelementptr inbounds double, ptr %32, i32 -1
  store ptr %33, ptr %16, align 8, !tbaa !5
  %34 = load ptr, ptr %17, align 8, !tbaa !5
  %35 = getelementptr inbounds double, ptr %34, i32 -1
  store ptr %35, ptr %17, align 8, !tbaa !5
  %36 = load ptr, ptr %18, align 8, !tbaa !5
  %37 = getelementptr inbounds double, ptr %36, i32 -1
  store ptr %37, ptr %18, align 8, !tbaa !5
  %38 = load ptr, ptr %20, align 8, !tbaa !5
  %39 = load i32, ptr %38, align 4, !tbaa !9
  store i32 %39, ptr %23, align 4, !tbaa !9
  %40 = load i32, ptr %23, align 4, !tbaa !9
  %41 = mul nsw i32 %40, 1
  %42 = add nsw i32 1, %41
  store i32 %42, ptr %24, align 4, !tbaa !9
  %43 = load i32, ptr %24, align 4, !tbaa !9
  %44 = load ptr, ptr %19, align 8, !tbaa !5
  %45 = sext i32 %43 to i64
  %46 = sub i64 0, %45
  %47 = getelementptr inbounds double, ptr %44, i64 %46
  store ptr %47, ptr %19, align 8, !tbaa !5
  %48 = load ptr, ptr %21, align 8, !tbaa !5
  %49 = getelementptr inbounds double, ptr %48, i32 -1
  store ptr %49, ptr %21, align 8, !tbaa !5
  %50 = load ptr, ptr %13, align 8, !tbaa !5
  %51 = call i32 @lsame_(ptr noundef %50, ptr noundef @.str)
  store i32 %51, ptr %30, align 4, !tbaa !9
  %52 = load ptr, ptr %14, align 8, !tbaa !5
  %53 = call i32 @lsame_(ptr noundef %52, ptr noundef @.str.1)
  store i32 %53, ptr %29, align 4, !tbaa !9
  %54 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 0, ptr %54, align 4, !tbaa !9
  %55 = load ptr, ptr %12, align 8, !tbaa !5
  %56 = load i32, ptr %55, align 4, !tbaa !9
  %57 = icmp slt i32 %56, 1
  br i1 %57, label %62, label %58

58:                                               ; preds = %11
  %59 = load ptr, ptr %12, align 8, !tbaa !5
  %60 = load i32, ptr %59, align 4, !tbaa !9
  %61 = icmp sgt i32 %60, 3
  br i1 %61, label %62, label %64

62:                                               ; preds = %58, %11
  %63 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -1, ptr %63, align 4, !tbaa !9
  br label %107

64:                                               ; preds = %58
  %65 = load i32, ptr %30, align 4, !tbaa !9
  %66 = icmp ne i32 %65, 0
  br i1 %66, label %73, label %67

67:                                               ; preds = %64
  %68 = load ptr, ptr %13, align 8, !tbaa !5
  %69 = call i32 @lsame_(ptr noundef %68, ptr noundef @.str.2)
  %70 = icmp ne i32 %69, 0
  br i1 %70, label %73, label %71

71:                                               ; preds = %67
  %72 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -2, ptr %72, align 4, !tbaa !9
  br label %106

73:                                               ; preds = %67, %64
  %74 = load i32, ptr %29, align 4, !tbaa !9
  %75 = icmp ne i32 %74, 0
  br i1 %75, label %82, label %76

76:                                               ; preds = %73
  %77 = load ptr, ptr %14, align 8, !tbaa !5
  %78 = call i32 @lsame_(ptr noundef %77, ptr noundef @.str.3)
  %79 = icmp ne i32 %78, 0
  br i1 %79, label %82, label %80

80:                                               ; preds = %76
  %81 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -3, ptr %81, align 4, !tbaa !9
  br label %105

82:                                               ; preds = %76, %73
  %83 = load ptr, ptr %15, align 8, !tbaa !5
  %84 = load i32, ptr %83, align 4, !tbaa !9
  %85 = icmp slt i32 %84, 0
  br i1 %85, label %86, label %88

86:                                               ; preds = %82
  %87 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -4, ptr %87, align 4, !tbaa !9
  br label %104

88:                                               ; preds = %82
  %89 = load ptr, ptr %20, align 8, !tbaa !5
  %90 = load i32, ptr %89, align 4, !tbaa !9
  %91 = icmp slt i32 %90, 1
  br i1 %91, label %101, label %92

92:                                               ; preds = %88
  %93 = load i32, ptr %30, align 4, !tbaa !9
  %94 = icmp ne i32 %93, 0
  br i1 %94, label %95, label %103

95:                                               ; preds = %92
  %96 = load ptr, ptr %20, align 8, !tbaa !5
  %97 = load i32, ptr %96, align 4, !tbaa !9
  %98 = load ptr, ptr %15, align 8, !tbaa !5
  %99 = load i32, ptr %98, align 4, !tbaa !9
  %100 = icmp slt i32 %97, %99
  br i1 %100, label %101, label %103

101:                                              ; preds = %95, %88
  %102 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -9, ptr %102, align 4, !tbaa !9
  br label %103

103:                                              ; preds = %101, %95, %92
  br label %104

104:                                              ; preds = %103, %86
  br label %105

105:                                              ; preds = %104, %80
  br label %106

106:                                              ; preds = %105, %71
  br label %107

107:                                              ; preds = %106, %62
  %108 = load ptr, ptr %22, align 8, !tbaa !5
  %109 = load i32, ptr %108, align 4, !tbaa !9
  %110 = icmp ne i32 %109, 0
  br i1 %110, label %111, label %116

111:                                              ; preds = %107
  %112 = load ptr, ptr %22, align 8, !tbaa !5
  %113 = load i32, ptr %112, align 4, !tbaa !9
  %114 = sub nsw i32 0, %113
  store i32 %114, ptr %25, align 4, !tbaa !9
  %115 = call i32 @xerbla_(ptr noundef @.str.4, ptr noundef %25, i32 noundef 6)
  store i32 1, ptr %31, align 4
  br label %248

116:                                              ; preds = %107
  %117 = load ptr, ptr %15, align 8, !tbaa !5
  %118 = load i32, ptr %117, align 4, !tbaa !9
  %119 = icmp eq i32 %118, 0
  br i1 %119, label %120, label %121

120:                                              ; preds = %116
  store i32 1, ptr %31, align 4
  br label %248

121:                                              ; preds = %116
  %122 = load ptr, ptr %14, align 8, !tbaa !5
  %123 = load ptr, ptr %15, align 8, !tbaa !5
  %124 = load ptr, ptr %17, align 8, !tbaa !5
  %125 = getelementptr inbounds double, ptr %124, i64 1
  %126 = load ptr, ptr %22, align 8, !tbaa !5
  call void @dpptrf_(ptr noundef %122, ptr noundef %123, ptr noundef %125, ptr noundef %126)
  %127 = load ptr, ptr %22, align 8, !tbaa !5
  %128 = load i32, ptr %127, align 4, !tbaa !9
  %129 = icmp ne i32 %128, 0
  br i1 %129, label %130, label %137

130:                                              ; preds = %121
  %131 = load ptr, ptr %15, align 8, !tbaa !5
  %132 = load i32, ptr %131, align 4, !tbaa !9
  %133 = load ptr, ptr %22, align 8, !tbaa !5
  %134 = load i32, ptr %133, align 4, !tbaa !9
  %135 = add nsw i32 %132, %134
  %136 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 %135, ptr %136, align 4, !tbaa !9
  store i32 1, ptr %31, align 4
  br label %248

137:                                              ; preds = %121
  %138 = load ptr, ptr %12, align 8, !tbaa !5
  %139 = load ptr, ptr %14, align 8, !tbaa !5
  %140 = load ptr, ptr %15, align 8, !tbaa !5
  %141 = load ptr, ptr %16, align 8, !tbaa !5
  %142 = getelementptr inbounds double, ptr %141, i64 1
  %143 = load ptr, ptr %17, align 8, !tbaa !5
  %144 = getelementptr inbounds double, ptr %143, i64 1
  %145 = load ptr, ptr %22, align 8, !tbaa !5
  call void @dspgst_(ptr noundef %138, ptr noundef %139, ptr noundef %140, ptr noundef %142, ptr noundef %144, ptr noundef %145)
  %146 = load ptr, ptr %13, align 8, !tbaa !5
  %147 = load ptr, ptr %14, align 8, !tbaa !5
  %148 = load ptr, ptr %15, align 8, !tbaa !5
  %149 = load ptr, ptr %16, align 8, !tbaa !5
  %150 = getelementptr inbounds double, ptr %149, i64 1
  %151 = load ptr, ptr %18, align 8, !tbaa !5
  %152 = getelementptr inbounds double, ptr %151, i64 1
  %153 = load ptr, ptr %19, align 8, !tbaa !5
  %154 = load i32, ptr %24, align 4, !tbaa !9
  %155 = sext i32 %154 to i64
  %156 = getelementptr inbounds double, ptr %153, i64 %155
  %157 = load ptr, ptr %20, align 8, !tbaa !5
  %158 = load ptr, ptr %21, align 8, !tbaa !5
  %159 = getelementptr inbounds double, ptr %158, i64 1
  %160 = load ptr, ptr %22, align 8, !tbaa !5
  call void @dspev_(ptr noundef %146, ptr noundef %147, ptr noundef %148, ptr noundef %150, ptr noundef %152, ptr noundef %156, ptr noundef %157, ptr noundef %159, ptr noundef %160)
  %161 = load i32, ptr %30, align 4, !tbaa !9
  %162 = icmp ne i32 %161, 0
  br i1 %162, label %163, label %247

163:                                              ; preds = %137
  %164 = load ptr, ptr %15, align 8, !tbaa !5
  %165 = load i32, ptr %164, align 4, !tbaa !9
  store i32 %165, ptr %26, align 4, !tbaa !9
  %166 = load ptr, ptr %22, align 8, !tbaa !5
  %167 = load i32, ptr %166, align 4, !tbaa !9
  %168 = icmp sgt i32 %167, 0
  br i1 %168, label %169, label %173

169:                                              ; preds = %163
  %170 = load ptr, ptr %22, align 8, !tbaa !5
  %171 = load i32, ptr %170, align 4, !tbaa !9
  %172 = sub nsw i32 %171, 1
  store i32 %172, ptr %26, align 4, !tbaa !9
  br label %173

173:                                              ; preds = %169, %163
  %174 = load ptr, ptr %12, align 8, !tbaa !5
  %175 = load i32, ptr %174, align 4, !tbaa !9
  %176 = icmp eq i32 %175, 1
  br i1 %176, label %181, label %177

177:                                              ; preds = %173
  %178 = load ptr, ptr %12, align 8, !tbaa !5
  %179 = load i32, ptr %178, align 4, !tbaa !9
  %180 = icmp eq i32 %179, 2
  br i1 %180, label %181, label %211

181:                                              ; preds = %177, %173
  %182 = load i32, ptr %29, align 4, !tbaa !9
  %183 = icmp ne i32 %182, 0
  br i1 %183, label %184, label %186

184:                                              ; preds = %181
  %185 = getelementptr inbounds [1 x i8], ptr %28, i64 0, i64 0
  store i8 78, ptr %185, align 1, !tbaa !11
  br label %188

186:                                              ; preds = %181
  %187 = getelementptr inbounds [1 x i8], ptr %28, i64 0, i64 0
  store i8 84, ptr %187, align 1, !tbaa !11
  br label %188

188:                                              ; preds = %186, %184
  %189 = load i32, ptr %26, align 4, !tbaa !9
  store i32 %189, ptr %25, align 4, !tbaa !9
  store i32 1, ptr %27, align 4, !tbaa !9
  br label %190

190:                                              ; preds = %207, %188
  %191 = load i32, ptr %27, align 4, !tbaa !9
  %192 = load i32, ptr %25, align 4, !tbaa !9
  %193 = icmp sle i32 %191, %192
  br i1 %193, label %194, label %210

194:                                              ; preds = %190
  %195 = load ptr, ptr %14, align 8, !tbaa !5
  %196 = getelementptr inbounds [1 x i8], ptr %28, i64 0, i64 0
  %197 = load ptr, ptr %15, align 8, !tbaa !5
  %198 = load ptr, ptr %17, align 8, !tbaa !5
  %199 = getelementptr inbounds double, ptr %198, i64 1
  %200 = load ptr, ptr %19, align 8, !tbaa !5
  %201 = load i32, ptr %27, align 4, !tbaa !9
  %202 = load i32, ptr %23, align 4, !tbaa !9
  %203 = mul nsw i32 %201, %202
  %204 = add nsw i32 %203, 1
  %205 = sext i32 %204 to i64
  %206 = getelementptr inbounds double, ptr %200, i64 %205
  call void @dtpsv_(ptr noundef %195, ptr noundef %196, ptr noundef @.str.5, ptr noundef %197, ptr noundef %199, ptr noundef %206, ptr noundef @c__1)
  br label %207

207:                                              ; preds = %194
  %208 = load i32, ptr %27, align 4, !tbaa !9
  %209 = add nsw i32 %208, 1
  store i32 %209, ptr %27, align 4, !tbaa !9
  br label %190, !llvm.loop !12

210:                                              ; preds = %190
  br label %246

211:                                              ; preds = %177
  %212 = load ptr, ptr %12, align 8, !tbaa !5
  %213 = load i32, ptr %212, align 4, !tbaa !9
  %214 = icmp eq i32 %213, 3
  br i1 %214, label %215, label %245

215:                                              ; preds = %211
  %216 = load i32, ptr %29, align 4, !tbaa !9
  %217 = icmp ne i32 %216, 0
  br i1 %217, label %218, label %220

218:                                              ; preds = %215
  %219 = getelementptr inbounds [1 x i8], ptr %28, i64 0, i64 0
  store i8 84, ptr %219, align 1, !tbaa !11
  br label %222

220:                                              ; preds = %215
  %221 = getelementptr inbounds [1 x i8], ptr %28, i64 0, i64 0
  store i8 78, ptr %221, align 1, !tbaa !11
  br label %222

222:                                              ; preds = %220, %218
  %223 = load i32, ptr %26, align 4, !tbaa !9
  store i32 %223, ptr %25, align 4, !tbaa !9
  store i32 1, ptr %27, align 4, !tbaa !9
  br label %224

224:                                              ; preds = %241, %222
  %225 = load i32, ptr %27, align 4, !tbaa !9
  %226 = load i32, ptr %25, align 4, !tbaa !9
  %227 = icmp sle i32 %225, %226
  br i1 %227, label %228, label %244

228:                                              ; preds = %224
  %229 = load ptr, ptr %14, align 8, !tbaa !5
  %230 = getelementptr inbounds [1 x i8], ptr %28, i64 0, i64 0
  %231 = load ptr, ptr %15, align 8, !tbaa !5
  %232 = load ptr, ptr %17, align 8, !tbaa !5
  %233 = getelementptr inbounds double, ptr %232, i64 1
  %234 = load ptr, ptr %19, align 8, !tbaa !5
  %235 = load i32, ptr %27, align 4, !tbaa !9
  %236 = load i32, ptr %23, align 4, !tbaa !9
  %237 = mul nsw i32 %235, %236
  %238 = add nsw i32 %237, 1
  %239 = sext i32 %238 to i64
  %240 = getelementptr inbounds double, ptr %234, i64 %239
  call void @dtpmv_(ptr noundef %229, ptr noundef %230, ptr noundef @.str.5, ptr noundef %231, ptr noundef %233, ptr noundef %240, ptr noundef @c__1)
  br label %241

241:                                              ; preds = %228
  %242 = load i32, ptr %27, align 4, !tbaa !9
  %243 = add nsw i32 %242, 1
  store i32 %243, ptr %27, align 4, !tbaa !9
  br label %224, !llvm.loop !14

244:                                              ; preds = %224
  br label %245

245:                                              ; preds = %244, %211
  br label %246

246:                                              ; preds = %245, %210
  br label %247

247:                                              ; preds = %246, %137
  store i32 1, ptr %31, align 4
  br label %248

248:                                              ; preds = %247, %130, %120, %111
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %28) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #3
  ret void
}

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

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

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

declare void @dpptrf_(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare void @dspgst_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare void @dspev_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare void @dtpsv_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare void @dtpmv_(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 }

!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 = !{!"int", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}
!14 = distinct !{!14, !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"

@.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 [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [9 x i8], align 1
@c__1 = external hidden global i32, align 4

; Function Attrs: nounwind uwtable
define dso_local void @dspgv_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8, ptr noundef %9, ptr noundef %10) local_unnamed_addr #0 {
  %12 = alloca i32, align 4
  %13 = alloca [1 x i8], align 1
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %13) #3
  %14 = load i32, ptr %8, align 4, !tbaa !5
  %narrow = xor i32 %14, -1
  %15 = sext i32 %narrow to i64
  %16 = getelementptr inbounds double, ptr %7, i64 %15
  %17 = tail call i32 @lsame_(ptr noundef %1, ptr noundef nonnull @.str) #3
  %18 = tail call i32 @lsame_(ptr noundef %2, ptr noundef nonnull @.str.1) #3
  store i32 0, ptr %10, align 4, !tbaa !5
  %19 = load i32, ptr %0, align 4, !tbaa !5
  %20 = add i32 %19, -4
  %or.cond = icmp ult i32 %20, -3
  br i1 %or.cond, label %.thread.sink.split, label %21

21:                                               ; preds = %11
  %.not = icmp ne i32 %17, 0
  br i1 %.not, label %24, label %22

22:                                               ; preds = %21
  %23 = tail call i32 @lsame_(ptr noundef %1, ptr noundef nonnull @.str.2) #3
  %.not88 = icmp eq i32 %23, 0
  br i1 %.not88, label %.thread.sink.split, label %24

24:                                               ; preds = %22, %21
  %.not89 = icmp eq i32 %18, 0
  br i1 %.not89, label %25, label %27

25:                                               ; preds = %24
  %26 = tail call i32 @lsame_(ptr noundef %2, ptr noundef nonnull @.str.3) #3
  %.not90 = icmp eq i32 %26, 0
  br i1 %.not90, label %.thread.sink.split, label %27

27:                                               ; preds = %25, %24
  %28 = load i32, ptr %3, align 4, !tbaa !5
  %29 = icmp slt i32 %28, 0
  br i1 %29, label %.thread.sink.split, label %30

30:                                               ; preds = %27
  %31 = load i32, ptr %8, align 4, !tbaa !5
  %32 = icmp slt i32 %31, 1
  %33 = icmp ult i32 %31, %28
  %or.cond99 = and i1 %.not, %33
  %or.cond102 = or i1 %32, %or.cond99
  br i1 %or.cond102, label %.thread.sink.split, label %34

34:                                               ; preds = %30
  %.pr = load i32, ptr %10, align 4, !tbaa !5
  %.not91 = icmp eq i32 %.pr, 0
  br i1 %.not91, label %38, label %.thread

.thread.sink.split:                               ; preds = %30, %27, %25, %22, %11
  %.sink = phi i32 [ -1, %11 ], [ -2, %22 ], [ -3, %25 ], [ -4, %27 ], [ -9, %30 ]
  store i32 %.sink, ptr %10, align 4, !tbaa !5
  br label %.thread

.thread:                                          ; preds = %.thread.sink.split, %34
  %35 = phi i32 [ %.pr, %34 ], [ %.sink, %.thread.sink.split ]
  %36 = sub nsw i32 0, %35
  store i32 %36, ptr %12, align 4, !tbaa !5
  %37 = call i32 @xerbla_(ptr noundef nonnull @.str.4, ptr noundef nonnull %12, i32 noundef 6) #3
  br label %.loopexit

38:                                               ; preds = %34
  %39 = icmp eq i32 %28, 0
  br i1 %39, label %.loopexit, label %40

40:                                               ; preds = %38
  tail call void @dpptrf_(ptr noundef %2, ptr noundef nonnull %3, ptr noundef %5, ptr noundef nonnull %10) #3
  %41 = load i32, ptr %10, align 4, !tbaa !5
  %.not92 = icmp eq i32 %41, 0
  br i1 %.not92, label %45, label %42

42:                                               ; preds = %40
  %43 = load i32, ptr %3, align 4, !tbaa !5
  %44 = add nsw i32 %43, %41
  store i32 %44, ptr %10, align 4, !tbaa !5
  br label %.loopexit

45:                                               ; preds = %40
  tail call void @dspgst_(ptr noundef nonnull %0, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %4, ptr noundef %5, ptr noundef nonnull %10) #3
  tail call void @dspev_(ptr noundef %1, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %4, ptr noundef %6, ptr noundef %7, ptr noundef nonnull %8, ptr noundef %9, ptr noundef nonnull %10) #3
  %.not93 = icmp eq i32 %17, 0
  br i1 %.not93, label %.loopexit, label %46

46:                                               ; preds = %45
  %47 = load i32, ptr %3, align 4, !tbaa !5
  %48 = load i32, ptr %10, align 4, !tbaa !5
  %49 = icmp sgt i32 %48, 0
  %50 = add nsw i32 %48, -1
  %spec.select = select i1 %49, i32 %50, i32 %47
  %51 = load i32, ptr %0, align 4, !tbaa !5
  switch i32 %51, label %.loopexit [
    i32 1, label %52
    i32 2, label %52
    i32 3, label %56
  ]

52:                                               ; preds = %46, %46
  %. = select i1 %.not89, i8 84, i8 78
  store i8 %., ptr %13, align 1, !tbaa !9
  %invariant.gep106 = getelementptr i8, ptr %16, i64 8
  %.not98108 = icmp slt i32 %spec.select, 1
  br i1 %.not98108, label %.loopexit, label %.lr.ph110.preheader

.lr.ph110.preheader:                              ; preds = %52
  %53 = sext i32 %14 to i64
  %54 = zext nneg i32 %spec.select to i64
  br label %.lr.ph110

.lr.ph110:                                        ; preds = %.lr.ph110.preheader, %.lr.ph110
  %indvars.iv113 = phi i64 [ 1, %.lr.ph110.preheader ], [ %indvars.iv.next114, %.lr.ph110 ]
  %55 = mul nsw i64 %indvars.iv113, %53
  %gep107 = getelementptr double, ptr %invariant.gep106, i64 %55
  call void @dtpsv_(ptr noundef %2, ptr noundef nonnull %13, ptr noundef nonnull @.str.5, ptr noundef nonnull %3, ptr noundef %5, ptr noundef %gep107, ptr noundef nonnull @c__1) #3
  %indvars.iv.next114 = add nuw nsw i64 %indvars.iv113, 1
  %.not98.not = icmp ult i64 %indvars.iv113, %54
  br i1 %.not98.not, label %.lr.ph110, label %.loopexit, !llvm.loop !10

56:                                               ; preds = %46
  %.100 = select i1 %.not89, i8 78, i8 84
  store i8 %.100, ptr %13, align 1, !tbaa !9
  %invariant.gep = getelementptr i8, ptr %16, i64 8
  %.not95104 = icmp slt i32 %spec.select, 1
  br i1 %.not95104, label %.loopexit, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %56
  %57 = sext i32 %14 to i64
  %58 = zext nneg i32 %spec.select to i64
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 1, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %59 = mul nsw i64 %indvars.iv, %57
  %gep = getelementptr double, ptr %invariant.gep, i64 %59
  call void @dtpmv_(ptr noundef %2, ptr noundef nonnull %13, ptr noundef nonnull @.str.5, ptr noundef nonnull %3, ptr noundef %5, ptr noundef %gep, ptr noundef nonnull @c__1) #3
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %.not95.not = icmp ult i64 %indvars.iv, %58
  br i1 %.not95.not, label %.lr.ph, label %.loopexit, !llvm.loop !12

.loopexit:                                        ; preds = %.lr.ph, %.lr.ph110, %56, %52, %45, %46, %38, %42, %.thread
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #3
  ret void
}

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

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

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

declare void @dpptrf_(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare void @dspgst_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare void @dspev_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare void @dtpsv_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare void @dtpmv_(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

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 }

!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 = !{!7, !7, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass