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

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.doublecomplex = type { double, double }

@.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 [7 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [9 x i8], align 1
@c__1 = external hidden global i64, align 8
@.str.6 = external hidden unnamed_addr constant [6 x i8], align 1
@c_b16 = external hidden global double, align 8

; Function Attrs: nounwind uwtable
define dso_local i32 @zpptrf_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3) #0 {
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca double, align 8
  %14 = alloca %struct.doublecomplex, align 8
  %15 = alloca %struct.doublecomplex, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca double, align 8
  %20 = alloca i64, align 8
  %21 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  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
  %22 = load ptr, ptr %8, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct.doublecomplex, ptr %22, i32 -1
  store ptr %23, ptr %8, align 8, !tbaa !5
  %24 = load ptr, ptr %9, align 8, !tbaa !5
  store i64 0, ptr %24, align 8, !tbaa !9
  %25 = load ptr, ptr %6, align 8, !tbaa !5
  %26 = call i64 @lsame_(ptr noundef %25, ptr noundef @.str)
  store i64 %26, ptr %20, align 8, !tbaa !9
  %27 = load i64, ptr %20, align 8, !tbaa !9
  %28 = icmp ne i64 %27, 0
  br i1 %28, label %35, label %29

29:                                               ; preds = %4
  %30 = load ptr, ptr %6, align 8, !tbaa !5
  %31 = call i64 @lsame_(ptr noundef %30, ptr noundef @.str.1)
  %32 = icmp ne i64 %31, 0
  br i1 %32, label %35, label %33

33:                                               ; preds = %29
  %34 = load ptr, ptr %9, align 8, !tbaa !5
  store i64 -1, ptr %34, align 8, !tbaa !9
  br label %42

35:                                               ; preds = %29, %4
  %36 = load ptr, ptr %7, align 8, !tbaa !5
  %37 = load i64, ptr %36, align 8, !tbaa !9
  %38 = icmp slt i64 %37, 0
  br i1 %38, label %39, label %41

39:                                               ; preds = %35
  %40 = load ptr, ptr %9, align 8, !tbaa !5
  store i64 -2, ptr %40, align 8, !tbaa !9
  br label %41

41:                                               ; preds = %39, %35
  br label %42

42:                                               ; preds = %41, %33
  %43 = load ptr, ptr %9, align 8, !tbaa !5
  %44 = load i64, ptr %43, align 8, !tbaa !9
  %45 = icmp ne i64 %44, 0
  br i1 %45, label %46, label %51

46:                                               ; preds = %42
  %47 = load ptr, ptr %9, align 8, !tbaa !5
  %48 = load i64, ptr %47, align 8, !tbaa !9
  %49 = sub nsw i64 0, %48
  store i64 %49, ptr %10, align 8, !tbaa !9
  %50 = call i32 @xerbla_(ptr noundef @.str.2, ptr noundef %10)
  store i32 0, ptr %5, align 4
  store i32 1, ptr %21, align 4
  br label %230

51:                                               ; preds = %42
  %52 = load ptr, ptr %7, align 8, !tbaa !5
  %53 = load i64, ptr %52, align 8, !tbaa !9
  %54 = icmp eq i64 %53, 0
  br i1 %54, label %55, label %56

55:                                               ; preds = %51
  store i32 0, ptr %5, align 4
  store i32 1, ptr %21, align 4
  br label %230

56:                                               ; preds = %51
  %57 = load i64, ptr %20, align 8, !tbaa !9
  %58 = icmp ne i64 %57, 0
  br i1 %58, label %59, label %139

59:                                               ; preds = %56
  store i64 0, ptr %18, align 8, !tbaa !9
  %60 = load ptr, ptr %7, align 8, !tbaa !5
  %61 = load i64, ptr %60, align 8, !tbaa !9
  store i64 %61, ptr %10, align 8, !tbaa !9
  store i64 1, ptr %16, align 8, !tbaa !9
  br label %62

62:                                               ; preds = %135, %59
  %63 = load i64, ptr %16, align 8, !tbaa !9
  %64 = load i64, ptr %10, align 8, !tbaa !9
  %65 = icmp sle i64 %63, %64
  br i1 %65, label %66, label %138

66:                                               ; preds = %62
  %67 = load i64, ptr %18, align 8, !tbaa !9
  %68 = add nsw i64 %67, 1
  store i64 %68, ptr %17, align 8, !tbaa !9
  %69 = load i64, ptr %16, align 8, !tbaa !9
  %70 = load i64, ptr %18, align 8, !tbaa !9
  %71 = add nsw i64 %70, %69
  store i64 %71, ptr %18, align 8, !tbaa !9
  %72 = load i64, ptr %16, align 8, !tbaa !9
  %73 = icmp sgt i64 %72, 1
  br i1 %73, label %74, label %83

74:                                               ; preds = %66
  %75 = load i64, ptr %16, align 8, !tbaa !9
  %76 = sub nsw i64 %75, 1
  store i64 %76, ptr %11, align 8, !tbaa !9
  %77 = load ptr, ptr %8, align 8, !tbaa !5
  %78 = getelementptr inbounds %struct.doublecomplex, ptr %77, i64 1
  %79 = load ptr, ptr %8, align 8, !tbaa !5
  %80 = load i64, ptr %17, align 8, !tbaa !9
  %81 = getelementptr inbounds %struct.doublecomplex, ptr %79, i64 %80
  %82 = call i32 @f2c_ztpsv(ptr noundef @.str.3, ptr noundef @.str.4, ptr noundef @.str.5, ptr noundef %11, ptr noundef %78, ptr noundef %81, ptr noundef @c__1)
  br label %83

83:                                               ; preds = %74, %66
  %84 = load i64, ptr %18, align 8, !tbaa !9
  store i64 %84, ptr %11, align 8, !tbaa !9
  %85 = load ptr, ptr %8, align 8, !tbaa !5
  %86 = load i64, ptr %11, align 8, !tbaa !9
  %87 = getelementptr inbounds %struct.doublecomplex, ptr %85, i64 %86
  %88 = getelementptr inbounds %struct.doublecomplex, ptr %87, i32 0, i32 0
  %89 = load double, ptr %88, align 8, !tbaa !11
  store double %89, ptr %13, align 8, !tbaa !14
  %90 = load i64, ptr %16, align 8, !tbaa !9
  %91 = sub nsw i64 %90, 1
  store i64 %91, ptr %12, align 8, !tbaa !9
  %92 = load ptr, ptr %8, align 8, !tbaa !5
  %93 = load i64, ptr %17, align 8, !tbaa !9
  %94 = getelementptr inbounds %struct.doublecomplex, ptr %92, i64 %93
  %95 = load ptr, ptr %8, align 8, !tbaa !5
  %96 = load i64, ptr %17, align 8, !tbaa !9
  %97 = getelementptr inbounds %struct.doublecomplex, ptr %95, i64 %96
  call void @f2c_zdotc(ptr noundef %15, ptr noundef %12, ptr noundef %94, ptr noundef @c__1, ptr noundef %97, ptr noundef @c__1)
  %98 = load double, ptr %13, align 8, !tbaa !14
  %99 = getelementptr inbounds %struct.doublecomplex, ptr %15, i32 0, i32 0
  %100 = load double, ptr %99, align 8, !tbaa !11
  %101 = fsub double %98, %100
  %102 = getelementptr inbounds %struct.doublecomplex, ptr %14, i32 0, i32 0
  store double %101, ptr %102, align 8, !tbaa !11
  %103 = getelementptr inbounds %struct.doublecomplex, ptr %15, i32 0, i32 1
  %104 = load double, ptr %103, align 8, !tbaa !15
  %105 = fneg double %104
  %106 = getelementptr inbounds %struct.doublecomplex, ptr %14, i32 0, i32 1
  store double %105, ptr %106, align 8, !tbaa !15
  %107 = getelementptr inbounds %struct.doublecomplex, ptr %14, i32 0, i32 0
  %108 = load double, ptr %107, align 8, !tbaa !11
  store double %108, ptr %19, align 8, !tbaa !14
  %109 = load double, ptr %19, align 8, !tbaa !14
  %110 = fcmp ole double %109, 0.000000e+00
  br i1 %110, label %111, label %122

111:                                              ; preds = %83
  %112 = load i64, ptr %18, align 8, !tbaa !9
  store i64 %112, ptr %11, align 8, !tbaa !9
  %113 = load double, ptr %19, align 8, !tbaa !14
  %114 = load ptr, ptr %8, align 8, !tbaa !5
  %115 = load i64, ptr %11, align 8, !tbaa !9
  %116 = getelementptr inbounds %struct.doublecomplex, ptr %114, i64 %115
  %117 = getelementptr inbounds %struct.doublecomplex, ptr %116, i32 0, i32 0
  store double %113, ptr %117, align 8, !tbaa !11
  %118 = load ptr, ptr %8, align 8, !tbaa !5
  %119 = load i64, ptr %11, align 8, !tbaa !9
  %120 = getelementptr inbounds %struct.doublecomplex, ptr %118, i64 %119
  %121 = getelementptr inbounds %struct.doublecomplex, ptr %120, i32 0, i32 1
  store double 0.000000e+00, ptr %121, align 8, !tbaa !15
  br label %226

122:                                              ; preds = %83
  %123 = load i64, ptr %18, align 8, !tbaa !9
  store i64 %123, ptr %11, align 8, !tbaa !9
  %124 = load double, ptr %19, align 8, !tbaa !14
  %125 = call double @sqrt(double noundef %124) #4
  store double %125, ptr %13, align 8, !tbaa !14
  %126 = load double, ptr %13, align 8, !tbaa !14
  %127 = load ptr, ptr %8, align 8, !tbaa !5
  %128 = load i64, ptr %11, align 8, !tbaa !9
  %129 = getelementptr inbounds %struct.doublecomplex, ptr %127, i64 %128
  %130 = getelementptr inbounds %struct.doublecomplex, ptr %129, i32 0, i32 0
  store double %126, ptr %130, align 8, !tbaa !11
  %131 = load ptr, ptr %8, align 8, !tbaa !5
  %132 = load i64, ptr %11, align 8, !tbaa !9
  %133 = getelementptr inbounds %struct.doublecomplex, ptr %131, i64 %132
  %134 = getelementptr inbounds %struct.doublecomplex, ptr %133, i32 0, i32 1
  store double 0.000000e+00, ptr %134, align 8, !tbaa !15
  br label %135

135:                                              ; preds = %122
  %136 = load i64, ptr %16, align 8, !tbaa !9
  %137 = add nsw i64 %136, 1
  store i64 %137, ptr %16, align 8, !tbaa !9
  br label %62, !llvm.loop !16

138:                                              ; preds = %62
  br label %225

139:                                              ; preds = %56
  store i64 1, ptr %18, align 8, !tbaa !9
  %140 = load ptr, ptr %7, align 8, !tbaa !5
  %141 = load i64, ptr %140, align 8, !tbaa !9
  store i64 %141, ptr %10, align 8, !tbaa !9
  store i64 1, ptr %16, align 8, !tbaa !9
  br label %142

142:                                              ; preds = %221, %139
  %143 = load i64, ptr %16, align 8, !tbaa !9
  %144 = load i64, ptr %10, align 8, !tbaa !9
  %145 = icmp sle i64 %143, %144
  br i1 %145, label %146, label %224

146:                                              ; preds = %142
  %147 = load i64, ptr %18, align 8, !tbaa !9
  store i64 %147, ptr %11, align 8, !tbaa !9
  %148 = load ptr, ptr %8, align 8, !tbaa !5
  %149 = load i64, ptr %11, align 8, !tbaa !9
  %150 = getelementptr inbounds %struct.doublecomplex, ptr %148, i64 %149
  %151 = getelementptr inbounds %struct.doublecomplex, ptr %150, i32 0, i32 0
  %152 = load double, ptr %151, align 8, !tbaa !11
  store double %152, ptr %19, align 8, !tbaa !14
  %153 = load double, ptr %19, align 8, !tbaa !14
  %154 = fcmp ole double %153, 0.000000e+00
  br i1 %154, label %155, label %166

155:                                              ; preds = %146
  %156 = load i64, ptr %18, align 8, !tbaa !9
  store i64 %156, ptr %11, align 8, !tbaa !9
  %157 = load double, ptr %19, align 8, !tbaa !14
  %158 = load ptr, ptr %8, align 8, !tbaa !5
  %159 = load i64, ptr %11, align 8, !tbaa !9
  %160 = getelementptr inbounds %struct.doublecomplex, ptr %158, i64 %159
  %161 = getelementptr inbounds %struct.doublecomplex, ptr %160, i32 0, i32 0
  store double %157, ptr %161, align 8, !tbaa !11
  %162 = load ptr, ptr %8, align 8, !tbaa !5
  %163 = load i64, ptr %11, align 8, !tbaa !9
  %164 = getelementptr inbounds %struct.doublecomplex, ptr %162, i64 %163
  %165 = getelementptr inbounds %struct.doublecomplex, ptr %164, i32 0, i32 1
  store double 0.000000e+00, ptr %165, align 8, !tbaa !15
  br label %226

166:                                              ; preds = %146
  %167 = load double, ptr %19, align 8, !tbaa !14
  %168 = call double @sqrt(double noundef %167) #4
  store double %168, ptr %19, align 8, !tbaa !14
  %169 = load i64, ptr %18, align 8, !tbaa !9
  store i64 %169, ptr %11, align 8, !tbaa !9
  %170 = load double, ptr %19, align 8, !tbaa !14
  %171 = load ptr, ptr %8, align 8, !tbaa !5
  %172 = load i64, ptr %11, align 8, !tbaa !9
  %173 = getelementptr inbounds %struct.doublecomplex, ptr %171, i64 %172
  %174 = getelementptr inbounds %struct.doublecomplex, ptr %173, i32 0, i32 0
  store double %170, ptr %174, align 8, !tbaa !11
  %175 = load ptr, ptr %8, align 8, !tbaa !5
  %176 = load i64, ptr %11, align 8, !tbaa !9
  %177 = getelementptr inbounds %struct.doublecomplex, ptr %175, i64 %176
  %178 = getelementptr inbounds %struct.doublecomplex, ptr %177, i32 0, i32 1
  store double 0.000000e+00, ptr %178, align 8, !tbaa !15
  %179 = load i64, ptr %16, align 8, !tbaa !9
  %180 = load ptr, ptr %7, align 8, !tbaa !5
  %181 = load i64, ptr %180, align 8, !tbaa !9
  %182 = icmp slt i64 %179, %181
  br i1 %182, label %183, label %220

183:                                              ; preds = %166
  %184 = load ptr, ptr %7, align 8, !tbaa !5
  %185 = load i64, ptr %184, align 8, !tbaa !9
  %186 = load i64, ptr %16, align 8, !tbaa !9
  %187 = sub nsw i64 %185, %186
  store i64 %187, ptr %11, align 8, !tbaa !9
  %188 = load double, ptr %19, align 8, !tbaa !14
  %189 = fdiv double 1.000000e+00, %188
  store double %189, ptr %13, align 8, !tbaa !14
  %190 = load ptr, ptr %8, align 8, !tbaa !5
  %191 = load i64, ptr %18, align 8, !tbaa !9
  %192 = add nsw i64 %191, 1
  %193 = getelementptr inbounds %struct.doublecomplex, ptr %190, i64 %192
  %194 = call i32 @f2c_zdscal(ptr noundef %11, ptr noundef %13, ptr noundef %193, ptr noundef @c__1)
  %195 = load ptr, ptr %7, align 8, !tbaa !5
  %196 = load i64, ptr %195, align 8, !tbaa !9
  %197 = load i64, ptr %16, align 8, !tbaa !9
  %198 = sub nsw i64 %196, %197
  store i64 %198, ptr %11, align 8, !tbaa !9
  %199 = load ptr, ptr %8, align 8, !tbaa !5
  %200 = load i64, ptr %18, align 8, !tbaa !9
  %201 = add nsw i64 %200, 1
  %202 = getelementptr inbounds %struct.doublecomplex, ptr %199, i64 %201
  %203 = load ptr, ptr %8, align 8, !tbaa !5
  %204 = load i64, ptr %18, align 8, !tbaa !9
  %205 = load ptr, ptr %7, align 8, !tbaa !5
  %206 = load i64, ptr %205, align 8, !tbaa !9
  %207 = add nsw i64 %204, %206
  %208 = load i64, ptr %16, align 8, !tbaa !9
  %209 = sub nsw i64 %207, %208
  %210 = add nsw i64 %209, 1
  %211 = getelementptr inbounds %struct.doublecomplex, ptr %203, i64 %210
  %212 = call i32 @f2c_zhpr(ptr noundef @.str.6, ptr noundef %11, ptr noundef @c_b16, ptr noundef %202, ptr noundef @c__1, ptr noundef %211)
  %213 = load i64, ptr %18, align 8, !tbaa !9
  %214 = load ptr, ptr %7, align 8, !tbaa !5
  %215 = load i64, ptr %214, align 8, !tbaa !9
  %216 = add nsw i64 %213, %215
  %217 = load i64, ptr %16, align 8, !tbaa !9
  %218 = sub nsw i64 %216, %217
  %219 = add nsw i64 %218, 1
  store i64 %219, ptr %18, align 8, !tbaa !9
  br label %220

220:                                              ; preds = %183, %166
  br label %221

221:                                              ; preds = %220
  %222 = load i64, ptr %16, align 8, !tbaa !9
  %223 = add nsw i64 %222, 1
  store i64 %223, ptr %16, align 8, !tbaa !9
  br label %142, !llvm.loop !18

224:                                              ; preds = %142
  br label %225

225:                                              ; preds = %224, %138
  br label %229

226:                                              ; preds = %155, %111
  %227 = load i64, ptr %16, align 8, !tbaa !9
  %228 = load ptr, ptr %9, align 8, !tbaa !5
  store i64 %227, ptr %228, align 8, !tbaa !9
  br label %229

229:                                              ; preds = %226, %225
  store i32 0, ptr %5, align 4
  store i32 1, ptr %21, align 4
  br label %230

230:                                              ; preds = %229, %55, %46
  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
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  %231 = load i32, ptr %5, align 4
  ret i32 %231
}

; 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 @f2c_ztpsv(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

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

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

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

declare i32 @f2c_zhpr(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, !13, i64 0}
!12 = !{!"", !13, i64 0, !13, i64 8}
!13 = !{!"double", !7, i64 0}
!14 = !{!13, !13, i64 0}
!15 = !{!12, !13, i64 8}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17}


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

%struct.doublecomplex = type { double, double }

@.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 [7 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [9 x i8], align 1
@c__1 = external hidden global i64, align 8
@.str.6 = external hidden unnamed_addr constant [6 x i8], align 1
@c_b16 = external hidden global double, align 8

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

12:                                               ; preds = %4
  %13 = tail call i64 @lsame_(ptr noundef %0, ptr noundef nonnull @.str.1) #4
  %.not84 = icmp eq i64 %13, 0
  br i1 %.not84, label %.thread.sink.split, label %14

14:                                               ; preds = %12, %4
  %15 = load i64, ptr %1, align 8, !tbaa !5
  %16 = icmp slt i64 %15, 0
  br i1 %16, label %.thread.sink.split, label %17

17:                                               ; preds = %14
  %.pr = load i64, ptr %3, align 8, !tbaa !5
  %.not85 = icmp eq i64 %.pr, 0
  br i1 %.not85, label %21, label %.thread

.thread.sink.split:                               ; preds = %14, %12
  %.sink = phi i64 [ -1, %12 ], [ -2, %14 ]
  store i64 %.sink, ptr %3, align 8, !tbaa !5
  br label %.thread

.thread:                                          ; preds = %.thread.sink.split, %17
  %18 = phi i64 [ %.pr, %17 ], [ %.sink, %.thread.sink.split ]
  %19 = sub nsw i64 0, %18
  store i64 %19, ptr %5, align 8, !tbaa !5
  %20 = call i32 @xerbla_(ptr noundef nonnull @.str.2, ptr noundef nonnull %5) #4
  br label %.loopexit

21:                                               ; preds = %17
  %22 = icmp eq i64 %15, 0
  br i1 %22, label %.loopexit, label %23

23:                                               ; preds = %21
  br i1 %.not, label %.lr.ph102, label %24

24:                                               ; preds = %23
  %.pre = load double, ptr %2, align 8, !tbaa !9
  store i64 1, ptr %6, align 8, !tbaa !5
  store i64 0, ptr %7, align 8, !tbaa !5
  call void @f2c_zdotc(ptr noundef nonnull %9, ptr noundef nonnull %7, ptr noundef nonnull %2, ptr noundef nonnull @c__1, ptr noundef nonnull %2, ptr noundef nonnull @c__1) #4
  %25 = load double, ptr %9, align 8, !tbaa !9
  %26 = fsub double %.pre, %25
  %27 = fcmp ugt double %26, 0.000000e+00
  br i1 %27, label %28, label %.loopexit113

28:                                               ; preds = %24
  store i64 1, ptr %6, align 8, !tbaa !5
  %29 = call double @sqrt(double noundef %26) #4
  %30 = load i64, ptr %6, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %30
  store double %29, ptr %31, align 8, !tbaa !9
  %32 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %30, i32 1
  store double 0.000000e+00, ptr %32, align 8, !tbaa !12
  %.not87.not.peel.not = icmp eq i64 %15, 1
  br i1 %.not87.not.peel.not, label %.loopexit, label %.lr.ph.peel.next

.lr.ph.peel.next:                                 ; preds = %28, %43
  %.07497 = phi i64 [ %33, %43 ], [ 1, %28 ]
  %.07596 = phi i64 [ %48, %43 ], [ 2, %28 ]
  %33 = add nuw nsw i64 %.07497, %.07596
  %34 = add nsw i64 %.07596, -1
  store i64 %34, ptr %6, align 8, !tbaa !5
  %35 = getelementptr %struct.doublecomplex, ptr %2, i64 %.07497
  %36 = call i32 @f2c_ztpsv(ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.5, ptr noundef nonnull %6, ptr noundef nonnull %2, ptr noundef %35, ptr noundef nonnull @c__1) #4
  store i64 %33, ptr %6, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %33
  %38 = load double, ptr %37, align 8, !tbaa !9
  store i64 %34, ptr %7, align 8, !tbaa !5
  %39 = getelementptr %struct.doublecomplex, ptr %2, i64 %.07497
  call void @f2c_zdotc(ptr noundef nonnull %9, ptr noundef nonnull %7, ptr noundef %39, ptr noundef nonnull @c__1, ptr noundef %39, ptr noundef nonnull @c__1) #4
  %40 = load double, ptr %9, align 8, !tbaa !9
  %41 = fsub double %38, %40
  %42 = fcmp ugt double %41, 0.000000e+00
  br i1 %42, label %43, label %.loopexit113

.loopexit113:                                     ; preds = %.lr.ph.peel.next, %24
  %.lcssa110 = phi ptr [ %2, %24 ], [ %37, %.lr.ph.peel.next ]
  %.lcssa108 = phi double [ %26, %24 ], [ %41, %.lr.ph.peel.next ]
  %.07596.lcssa = phi i64 [ 1, %24 ], [ %.07596, %.lr.ph.peel.next ]
  %.lcssa = phi i64 [ 1, %24 ], [ %33, %.lr.ph.peel.next ]
  store double %.lcssa108, ptr %.lcssa110, align 8, !tbaa !9
  br label %.loopexit127

43:                                               ; preds = %.lr.ph.peel.next
  store i64 %33, ptr %6, align 8, !tbaa !5
  %44 = call double @sqrt(double noundef %41) #4
  %45 = load i64, ptr %6, align 8, !tbaa !5
  %46 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %45
  store double %44, ptr %46, align 8, !tbaa !9
  %47 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %45, i32 1
  store double 0.000000e+00, ptr %47, align 8, !tbaa !12
  %48 = add nuw nsw i64 %.07596, 1
  %.not87.not = icmp slt i64 %.07596, %15
  br i1 %.not87.not, label %.lr.ph.peel.next, label %.loopexit, !llvm.loop !13

.lr.ph102:                                        ; preds = %23, %71
  %.176.neg101 = phi i64 [ %.176.neg, %71 ], [ -1, %23 ]
  %.1100 = phi i64 [ %.2, %71 ], [ 1, %23 ]
  %.17699 = phi i64 [ %72, %71 ], [ 1, %23 ]
  %49 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %.1100
  %50 = load double, ptr %49, align 8, !tbaa !9
  %51 = fcmp ugt double %50, 0.000000e+00
  br i1 %51, label %52, label %.loopexit127

52:                                               ; preds = %.lr.ph102
  %53 = call double @sqrt(double noundef %50) #4
  store i64 %.1100, ptr %6, align 8, !tbaa !5
  store double %53, ptr %49, align 8, !tbaa !9
  %54 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %.1100, i32 1
  store double 0.000000e+00, ptr %54, align 8, !tbaa !12
  %55 = load i64, ptr %1, align 8, !tbaa !5
  %56 = icmp slt i64 %.17699, %55
  br i1 %56, label %57, label %71

57:                                               ; preds = %52
  %58 = sub nsw i64 %55, %.17699
  store i64 %58, ptr %6, align 8, !tbaa !5
  %59 = fdiv double 1.000000e+00, %53
  store double %59, ptr %8, align 8, !tbaa !16
  %60 = getelementptr %struct.doublecomplex, ptr %2, i64 %.1100
  %61 = call i32 @f2c_zdscal(ptr noundef nonnull %6, ptr noundef nonnull %8, ptr noundef %60, ptr noundef nonnull @c__1) #4
  %62 = load i64, ptr %1, align 8, !tbaa !5
  %63 = sub nsw i64 %62, %.17699
  store i64 %63, ptr %6, align 8, !tbaa !5
  %64 = getelementptr %struct.doublecomplex, ptr %60, i64 %.176.neg101
  %65 = getelementptr %struct.doublecomplex, ptr %64, i64 %62
  %66 = call i32 @f2c_zhpr(ptr noundef nonnull @.str.6, ptr noundef nonnull %6, ptr noundef nonnull @c_b16, ptr noundef %60, ptr noundef nonnull @c__1, ptr noundef %65) #4
  %67 = load i64, ptr %1, align 8, !tbaa !5
  %68 = add nsw i64 %.176.neg101, 1
  %69 = add i64 %68, %.1100
  %70 = add i64 %69, %67
  br label %71

71:                                               ; preds = %52, %57
  %.2 = phi i64 [ %70, %57 ], [ %.1100, %52 ]
  %72 = add nuw nsw i64 %.17699, 1
  %.176.neg = xor i64 %.17699, -1
  %.not86.not = icmp slt i64 %.17699, %15
  br i1 %.not86.not, label %.lr.ph102, label %.loopexit, !llvm.loop !17

.loopexit127:                                     ; preds = %.lr.ph102, %.loopexit113
  %.1100.lcssa.sink = phi i64 [ %.lcssa, %.loopexit113 ], [ %.1100, %.lr.ph102 ]
  %.277 = phi i64 [ %.07596.lcssa, %.loopexit113 ], [ %.17699, %.lr.ph102 ]
  %73 = getelementptr inbounds %struct.doublecomplex, ptr %10, i64 %.1100.lcssa.sink, i32 1
  store double 0.000000e+00, ptr %73, align 8, !tbaa !12
  store i64 %.277, ptr %3, align 8, !tbaa !5
  br label %.loopexit

.loopexit:                                        ; preds = %43, %71, %28, %.loopexit127, %21, %.thread
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  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 @f2c_ztpsv(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sqrt(double noundef) local_unnamed_addr #3

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

declare i32 @f2c_zhpr(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 = { 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" }
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 = !{!"long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 0}
!10 = !{!"", !11, i64 0, !11, i64 8}
!11 = !{!"double", !7, i64 0}
!12 = !{!10, !11, i64 8}
!13 = distinct !{!13, !14, !15}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!"llvm.loop.peeled.count", i32 1}
!16 = !{!11, !11, i64 0}
!17 = distinct !{!17, !14}


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