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

; 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 [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 [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [2 x i8], align 1
@c__1 = external hidden global i64, align 8

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

64:                                               ; preds = %10
  %65 = load ptr, ptr %12, align 8, !tbaa !5
  %66 = call i64 @lsame_(ptr noundef %65, ptr noundef @.str.1)
  %67 = icmp ne i64 %66, 0
  br i1 %67, label %70, label %68

68:                                               ; preds = %64
  %69 = load ptr, ptr %21, align 8, !tbaa !5
  store i64 -1, ptr %69, align 8, !tbaa !9
  br label %104

70:                                               ; preds = %64, %10
  %71 = load ptr, ptr %13, align 8, !tbaa !5
  %72 = call i64 @lsame_(ptr noundef %71, ptr noundef @.str.2)
  %73 = icmp ne i64 %72, 0
  br i1 %73, label %80, label %74

74:                                               ; preds = %70
  %75 = load ptr, ptr %13, align 8, !tbaa !5
  %76 = call i64 @lsame_(ptr noundef %75, ptr noundef @.str.3)
  %77 = icmp ne i64 %76, 0
  br i1 %77, label %80, label %78

78:                                               ; preds = %74
  %79 = load ptr, ptr %21, align 8, !tbaa !5
  store i64 -2, ptr %79, align 8, !tbaa !9
  br label %103

80:                                               ; preds = %74, %70
  %81 = load ptr, ptr %14, align 8, !tbaa !5
  %82 = load i64, ptr %81, align 8, !tbaa !9
  %83 = icmp slt i64 %82, 0
  br i1 %83, label %84, label %86

84:                                               ; preds = %80
  %85 = load ptr, ptr %21, align 8, !tbaa !5
  store i64 -3, ptr %85, align 8, !tbaa !9
  br label %102

86:                                               ; preds = %80
  %87 = load ptr, ptr %18, align 8, !tbaa !5
  %88 = load i64, ptr %87, align 8, !tbaa !9
  %89 = icmp slt i64 %88, 1
  br i1 %89, label %99, label %90

90:                                               ; preds = %86
  %91 = load i64, ptr %34, align 8, !tbaa !9
  %92 = icmp ne i64 %91, 0
  br i1 %92, label %93, label %101

93:                                               ; preds = %90
  %94 = load ptr, ptr %18, align 8, !tbaa !5
  %95 = load i64, ptr %94, align 8, !tbaa !9
  %96 = load ptr, ptr %14, align 8, !tbaa !5
  %97 = load i64, ptr %96, align 8, !tbaa !9
  %98 = icmp slt i64 %95, %97
  br i1 %98, label %99, label %101

99:                                               ; preds = %93, %86
  %100 = load ptr, ptr %21, align 8, !tbaa !5
  store i64 -7, ptr %100, align 8, !tbaa !9
  br label %101

101:                                              ; preds = %99, %93, %90
  br label %102

102:                                              ; preds = %101, %84
  br label %103

103:                                              ; preds = %102, %78
  br label %104

104:                                              ; preds = %103, %68
  %105 = load ptr, ptr %21, align 8, !tbaa !5
  %106 = load i64, ptr %105, align 8, !tbaa !9
  %107 = icmp ne i64 %106, 0
  br i1 %107, label %108, label %113

108:                                              ; preds = %104
  %109 = load ptr, ptr %21, align 8, !tbaa !5
  %110 = load i64, ptr %109, align 8, !tbaa !9
  %111 = sub nsw i64 0, %110
  store i64 %111, ptr %24, align 8, !tbaa !9
  %112 = call i32 @xerbla_(ptr noundef @.str.4, ptr noundef %24)
  store i32 0, ptr %11, align 4
  store i32 1, ptr %42, align 4
  br label %283

113:                                              ; preds = %104
  %114 = load ptr, ptr %14, align 8, !tbaa !5
  %115 = load i64, ptr %114, align 8, !tbaa !9
  %116 = icmp eq i64 %115, 0
  br i1 %116, label %117, label %118

117:                                              ; preds = %113
  store i32 0, ptr %11, align 4
  store i32 1, ptr %42, align 4
  br label %283

118:                                              ; preds = %113
  %119 = load ptr, ptr %14, align 8, !tbaa !5
  %120 = load i64, ptr %119, align 8, !tbaa !9
  %121 = icmp eq i64 %120, 1
  br i1 %121, label %122, label %145

122:                                              ; preds = %118
  %123 = load ptr, ptr %15, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.doublecomplex, ptr %123, i64 1
  %125 = getelementptr inbounds %struct.doublecomplex, ptr %124, i32 0, i32 0
  %126 = load double, ptr %125, align 8, !tbaa !11
  %127 = load ptr, ptr %16, align 8, !tbaa !5
  %128 = getelementptr inbounds double, ptr %127, i64 1
  store double %126, ptr %128, align 8, !tbaa !14
  %129 = load ptr, ptr %20, align 8, !tbaa !5
  %130 = getelementptr inbounds double, ptr %129, i64 1
  store double 1.000000e+00, ptr %130, align 8, !tbaa !14
  %131 = load i64, ptr %34, align 8, !tbaa !9
  %132 = icmp ne i64 %131, 0
  br i1 %132, label %133, label %144

133:                                              ; preds = %122
  %134 = load i64, ptr %22, align 8, !tbaa !9
  %135 = add nsw i64 %134, 1
  store i64 %135, ptr %24, align 8, !tbaa !9
  %136 = load ptr, ptr %17, align 8, !tbaa !5
  %137 = load i64, ptr %24, align 8, !tbaa !9
  %138 = getelementptr inbounds %struct.doublecomplex, ptr %136, i64 %137
  %139 = getelementptr inbounds %struct.doublecomplex, ptr %138, i32 0, i32 0
  store double 1.000000e+00, ptr %139, align 8, !tbaa !11
  %140 = load ptr, ptr %17, align 8, !tbaa !5
  %141 = load i64, ptr %24, align 8, !tbaa !9
  %142 = getelementptr inbounds %struct.doublecomplex, ptr %140, i64 %141
  %143 = getelementptr inbounds %struct.doublecomplex, ptr %142, i32 0, i32 1
  store double 0.000000e+00, ptr %143, align 8, !tbaa !15
  br label %144

144:                                              ; preds = %133, %122
  store i32 0, ptr %11, align 4
  store i32 1, ptr %42, align 4
  br label %283

145:                                              ; preds = %118
  %146 = call double @dlamch_(ptr noundef @.str.5)
  store double %146, ptr %36, align 8, !tbaa !14
  %147 = call double @dlamch_(ptr noundef @.str.6)
  store double %147, ptr %26, align 8, !tbaa !14
  %148 = load double, ptr %36, align 8, !tbaa !14
  %149 = load double, ptr %26, align 8, !tbaa !14
  %150 = fdiv double %148, %149
  store double %150, ptr %41, align 8, !tbaa !14
  %151 = load double, ptr %41, align 8, !tbaa !14
  %152 = fdiv double 1.000000e+00, %151
  store double %152, ptr %37, align 8, !tbaa !14
  %153 = load double, ptr %41, align 8, !tbaa !14
  %154 = call double @sqrt(double noundef %153) #4
  store double %154, ptr %30, align 8, !tbaa !14
  %155 = load double, ptr %37, align 8, !tbaa !14
  %156 = call double @sqrt(double noundef %155) #4
  store double %156, ptr %31, align 8, !tbaa !14
  %157 = load ptr, ptr %13, align 8, !tbaa !5
  %158 = load ptr, ptr %14, align 8, !tbaa !5
  %159 = load ptr, ptr %15, align 8, !tbaa !5
  %160 = getelementptr inbounds %struct.doublecomplex, ptr %159, i64 1
  %161 = load ptr, ptr %20, align 8, !tbaa !5
  %162 = getelementptr inbounds double, ptr %161, i64 1
  %163 = call double @zlanhp_(ptr noundef @.str.7, ptr noundef %157, ptr noundef %158, ptr noundef %160, ptr noundef %162)
  store double %163, ptr %28, align 8, !tbaa !14
  store i64 0, ptr %35, align 8, !tbaa !9
  %164 = load double, ptr %28, align 8, !tbaa !14
  %165 = fcmp ogt double %164, 0.000000e+00
  br i1 %165, label %166, label %174

166:                                              ; preds = %145
  %167 = load double, ptr %28, align 8, !tbaa !14
  %168 = load double, ptr %30, align 8, !tbaa !14
  %169 = fcmp olt double %167, %168
  br i1 %169, label %170, label %174

170:                                              ; preds = %166
  store i64 1, ptr %35, align 8, !tbaa !9
  %171 = load double, ptr %30, align 8, !tbaa !14
  %172 = load double, ptr %28, align 8, !tbaa !14
  %173 = fdiv double %171, %172
  store double %173, ptr %32, align 8, !tbaa !14
  br label %183

174:                                              ; preds = %166, %145
  %175 = load double, ptr %28, align 8, !tbaa !14
  %176 = load double, ptr %31, align 8, !tbaa !14
  %177 = fcmp ogt double %175, %176
  br i1 %177, label %178, label %182

178:                                              ; preds = %174
  store i64 1, ptr %35, align 8, !tbaa !9
  %179 = load double, ptr %31, align 8, !tbaa !14
  %180 = load double, ptr %28, align 8, !tbaa !14
  %181 = fdiv double %179, %180
  store double %181, ptr %32, align 8, !tbaa !14
  br label %182

182:                                              ; preds = %178, %174
  br label %183

183:                                              ; preds = %182, %170
  %184 = load i64, ptr %35, align 8, !tbaa !9
  %185 = icmp eq i64 %184, 1
  br i1 %185, label %186, label %197

186:                                              ; preds = %183
  %187 = load ptr, ptr %14, align 8, !tbaa !5
  %188 = load i64, ptr %187, align 8, !tbaa !9
  %189 = load ptr, ptr %14, align 8, !tbaa !5
  %190 = load i64, ptr %189, align 8, !tbaa !9
  %191 = add nsw i64 %190, 1
  %192 = mul nsw i64 %188, %191
  %193 = sdiv i64 %192, 2
  store i64 %193, ptr %24, align 8, !tbaa !9
  %194 = load ptr, ptr %15, align 8, !tbaa !5
  %195 = getelementptr inbounds %struct.doublecomplex, ptr %194, i64 1
  %196 = call i32 @f2c_zdscal(ptr noundef %24, ptr noundef %32, ptr noundef %195, ptr noundef @c__1)
  br label %197

197:                                              ; preds = %186, %183
  store i64 1, ptr %27, align 8, !tbaa !9
  store i64 1, ptr %38, align 8, !tbaa !9
  %198 = load ptr, ptr %13, align 8, !tbaa !5
  %199 = load ptr, ptr %14, align 8, !tbaa !5
  %200 = load ptr, ptr %15, align 8, !tbaa !5
  %201 = getelementptr inbounds %struct.doublecomplex, ptr %200, i64 1
  %202 = load ptr, ptr %16, align 8, !tbaa !5
  %203 = getelementptr inbounds double, ptr %202, i64 1
  %204 = load ptr, ptr %20, align 8, !tbaa !5
  %205 = load i64, ptr %27, align 8, !tbaa !9
  %206 = getelementptr inbounds double, ptr %204, i64 %205
  %207 = load ptr, ptr %19, align 8, !tbaa !5
  %208 = load i64, ptr %38, align 8, !tbaa !9
  %209 = getelementptr inbounds %struct.doublecomplex, ptr %207, i64 %208
  %210 = call i32 @zhptrd_(ptr noundef %198, ptr noundef %199, ptr noundef %201, ptr noundef %203, ptr noundef %206, ptr noundef %209, ptr noundef %33)
  %211 = load i64, ptr %34, align 8, !tbaa !9
  %212 = icmp ne i64 %211, 0
  br i1 %212, label %222, label %213

213:                                              ; preds = %197
  %214 = load ptr, ptr %14, align 8, !tbaa !5
  %215 = load ptr, ptr %16, align 8, !tbaa !5
  %216 = getelementptr inbounds double, ptr %215, i64 1
  %217 = load ptr, ptr %20, align 8, !tbaa !5
  %218 = load i64, ptr %27, align 8, !tbaa !9
  %219 = getelementptr inbounds double, ptr %217, i64 %218
  %220 = load ptr, ptr %21, align 8, !tbaa !5
  %221 = call i32 @dsterf_(ptr noundef %214, ptr noundef %216, ptr noundef %219, ptr noundef %220)
  br label %262

222:                                              ; preds = %197
  %223 = load i64, ptr %38, align 8, !tbaa !9
  %224 = load ptr, ptr %14, align 8, !tbaa !5
  %225 = load i64, ptr %224, align 8, !tbaa !9
  %226 = add nsw i64 %223, %225
  store i64 %226, ptr %40, align 8, !tbaa !9
  %227 = load ptr, ptr %13, align 8, !tbaa !5
  %228 = load ptr, ptr %14, align 8, !tbaa !5
  %229 = load ptr, ptr %15, align 8, !tbaa !5
  %230 = getelementptr inbounds %struct.doublecomplex, ptr %229, i64 1
  %231 = load ptr, ptr %19, align 8, !tbaa !5
  %232 = load i64, ptr %38, align 8, !tbaa !9
  %233 = getelementptr inbounds %struct.doublecomplex, ptr %231, i64 %232
  %234 = load ptr, ptr %17, align 8, !tbaa !5
  %235 = load i64, ptr %23, align 8, !tbaa !9
  %236 = getelementptr inbounds %struct.doublecomplex, ptr %234, i64 %235
  %237 = load ptr, ptr %18, align 8, !tbaa !5
  %238 = load ptr, ptr %19, align 8, !tbaa !5
  %239 = load i64, ptr %40, align 8, !tbaa !9
  %240 = getelementptr inbounds %struct.doublecomplex, ptr %238, i64 %239
  %241 = call i32 @zupgtr_(ptr noundef %227, ptr noundef %228, ptr noundef %230, ptr noundef %233, ptr noundef %236, ptr noundef %237, ptr noundef %240, ptr noundef %33)
  %242 = load i64, ptr %27, align 8, !tbaa !9
  %243 = load ptr, ptr %14, align 8, !tbaa !5
  %244 = load i64, ptr %243, align 8, !tbaa !9
  %245 = add nsw i64 %242, %244
  store i64 %245, ptr %39, align 8, !tbaa !9
  %246 = load ptr, ptr %12, align 8, !tbaa !5
  %247 = load ptr, ptr %14, align 8, !tbaa !5
  %248 = load ptr, ptr %16, align 8, !tbaa !5
  %249 = getelementptr inbounds double, ptr %248, i64 1
  %250 = load ptr, ptr %20, align 8, !tbaa !5
  %251 = load i64, ptr %27, align 8, !tbaa !9
  %252 = getelementptr inbounds double, ptr %250, i64 %251
  %253 = load ptr, ptr %17, align 8, !tbaa !5
  %254 = load i64, ptr %23, align 8, !tbaa !9
  %255 = getelementptr inbounds %struct.doublecomplex, ptr %253, i64 %254
  %256 = load ptr, ptr %18, align 8, !tbaa !5
  %257 = load ptr, ptr %20, align 8, !tbaa !5
  %258 = load i64, ptr %39, align 8, !tbaa !9
  %259 = getelementptr inbounds double, ptr %257, i64 %258
  %260 = load ptr, ptr %21, align 8, !tbaa !5
  %261 = call i32 @zsteqr_(ptr noundef %246, ptr noundef %247, ptr noundef %249, ptr noundef %252, ptr noundef %255, ptr noundef %256, ptr noundef %259, ptr noundef %260)
  br label %262

262:                                              ; preds = %222, %213
  %263 = load i64, ptr %35, align 8, !tbaa !9
  %264 = icmp eq i64 %263, 1
  br i1 %264, label %265, label %282

265:                                              ; preds = %262
  %266 = load ptr, ptr %21, align 8, !tbaa !5
  %267 = load i64, ptr %266, align 8, !tbaa !9
  %268 = icmp eq i64 %267, 0
  br i1 %268, label %269, label %272

269:                                              ; preds = %265
  %270 = load ptr, ptr %14, align 8, !tbaa !5
  %271 = load i64, ptr %270, align 8, !tbaa !9
  store i64 %271, ptr %29, align 8, !tbaa !9
  br label %276

272:                                              ; preds = %265
  %273 = load ptr, ptr %21, align 8, !tbaa !5
  %274 = load i64, ptr %273, align 8, !tbaa !9
  %275 = sub nsw i64 %274, 1
  store i64 %275, ptr %29, align 8, !tbaa !9
  br label %276

276:                                              ; preds = %272, %269
  %277 = load double, ptr %32, align 8, !tbaa !14
  %278 = fdiv double 1.000000e+00, %277
  store double %278, ptr %25, align 8, !tbaa !14
  %279 = load ptr, ptr %16, align 8, !tbaa !5
  %280 = getelementptr inbounds double, ptr %279, i64 1
  %281 = call i32 @f2c_dscal(ptr noundef %29, ptr noundef %25, ptr noundef %280, ptr noundef @c__1)
  br label %282

282:                                              ; preds = %276, %262
  store i32 0, ptr %11, align 4
  store i32 1, ptr %42, align 4
  br label %283

283:                                              ; preds = %282, %144, %117, %108
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #4
  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 8, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #4
  %284 = load i32, ptr %11, align 4
  ret i32 %284
}

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

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

declare double @zlanhp_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

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

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

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

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

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

declare i32 @f2c_dscal(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}


; 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 [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 [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [2 x i8], align 1
@c__1 = external hidden global i64, align 8

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @zhpev_(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) local_unnamed_addr #0 {
  %11 = alloca i64, align 8
  %12 = alloca double, align 8
  %13 = alloca i64, align 8
  %14 = alloca double, align 8
  %15 = alloca i64, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #4
  %16 = tail call i64 @lsame_(ptr noundef %0, ptr noundef nonnull @.str) #4
  store i64 0, ptr %9, align 8, !tbaa !5
  %.not = icmp ne i64 %16, 0
  br i1 %.not, label %19, label %17

17:                                               ; preds = %10
  %18 = tail call i64 @lsame_(ptr noundef %0, ptr noundef nonnull @.str.1) #4
  %.not108 = icmp eq i64 %18, 0
  br i1 %.not108, label %.thread.sink.split, label %19

19:                                               ; preds = %17, %10
  %20 = tail call i64 @lsame_(ptr noundef %1, ptr noundef nonnull @.str.2) #4
  %.not109 = icmp eq i64 %20, 0
  br i1 %.not109, label %21, label %23

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

23:                                               ; preds = %21, %19
  %24 = load i64, ptr %2, align 8, !tbaa !5
  %25 = icmp slt i64 %24, 0
  br i1 %25, label %.thread.sink.split, label %26

26:                                               ; preds = %23
  %27 = load i64, ptr %6, align 8, !tbaa !5
  %28 = icmp slt i64 %27, 1
  %29 = icmp ult i64 %27, %24
  %or.cond = and i1 %.not, %29
  %or.cond117 = or i1 %28, %or.cond
  br i1 %or.cond117, label %.thread.sink.split, label %30

30:                                               ; preds = %26
  %.pr = load i64, ptr %9, align 8, !tbaa !5
  %.not111 = icmp eq i64 %.pr, 0
  br i1 %.not111, label %34, label %.thread

.thread.sink.split:                               ; preds = %26, %23, %21, %17
  %.sink = phi i64 [ -1, %17 ], [ -2, %21 ], [ -3, %23 ], [ -7, %26 ]
  store i64 %.sink, ptr %9, align 8, !tbaa !5
  br label %.thread

.thread:                                          ; preds = %.thread.sink.split, %30
  %31 = phi i64 [ %.pr, %30 ], [ %.sink, %.thread.sink.split ]
  %32 = sub nsw i64 0, %31
  store i64 %32, ptr %11, align 8, !tbaa !5
  %33 = call i32 @xerbla_(ptr noundef nonnull @.str.4, ptr noundef nonnull %11) #4
  br label %80

34:                                               ; preds = %30
  switch i64 %24, label %38 [
    i64 0, label %80
    i64 1, label %35
  ]

35:                                               ; preds = %34
  %36 = load double, ptr %3, align 8, !tbaa !9
  store double %36, ptr %4, align 8, !tbaa !12
  store double 1.000000e+00, ptr %8, align 8, !tbaa !12
  br i1 %.not, label %37, label %80

37:                                               ; preds = %35
  store <2 x double> <double 1.000000e+00, double 0.000000e+00>, ptr %5, align 8, !tbaa !12
  br label %80

38:                                               ; preds = %34
  %39 = tail call double @dlamch_(ptr noundef nonnull @.str.5) #4
  %40 = tail call double @dlamch_(ptr noundef nonnull @.str.6) #4
  %41 = fdiv double %39, %40
  %42 = fdiv double 1.000000e+00, %41
  %43 = tail call double @sqrt(double noundef %41) #4
  %44 = tail call double @sqrt(double noundef %42) #4
  %45 = tail call double @zlanhp_(ptr noundef nonnull @.str.7, ptr noundef %1, ptr noundef nonnull %2, ptr noundef %3, ptr noundef %8) #4
  %46 = fcmp ogt double %45, 0.000000e+00
  %47 = fcmp olt double %45, %43
  %or.cond112 = select i1 %46, i1 %47, i1 false
  br i1 %or.cond112, label %50, label %48

48:                                               ; preds = %38
  %49 = fcmp ogt double %45, %44
  br i1 %49, label %50, label %56

50:                                               ; preds = %48, %38
  %.pn = phi double [ %43, %38 ], [ %44, %48 ]
  %storemerge116 = fdiv double %.pn, %45
  store double %storemerge116, ptr %14, align 8, !tbaa !12
  %51 = load i64, ptr %2, align 8, !tbaa !5
  %52 = add nsw i64 %51, 1
  %53 = mul nsw i64 %52, %51
  %54 = sdiv i64 %53, 2
  store i64 %54, ptr %11, align 8, !tbaa !5
  %55 = call i32 @f2c_zdscal(ptr noundef nonnull %11, ptr noundef nonnull %14, ptr noundef %3, ptr noundef nonnull @c__1) #4
  br label %56

56:                                               ; preds = %48, %50
  %57 = phi i1 [ true, %50 ], [ false, %48 ]
  %58 = call i32 @zhptrd_(ptr noundef %1, ptr noundef nonnull %2, ptr noundef %3, ptr noundef %4, ptr noundef %8, ptr noundef %7, ptr noundef nonnull %15) #4
  br i1 %.not, label %61, label %59

59:                                               ; preds = %56
  %60 = call i32 @dsterf_(ptr noundef nonnull %2, ptr noundef %4, ptr noundef %8, ptr noundef nonnull %9) #4
  br label %68

61:                                               ; preds = %56
  %62 = load i64, ptr %2, align 8, !tbaa !5
  %63 = getelementptr %struct.doublecomplex, ptr %7, i64 %62
  %64 = call i32 @zupgtr_(ptr noundef %1, ptr noundef nonnull %2, ptr noundef %3, ptr noundef %7, ptr noundef %5, ptr noundef nonnull %6, ptr noundef %63, ptr noundef nonnull %15) #4
  %65 = load i64, ptr %2, align 8, !tbaa !5
  %66 = getelementptr double, ptr %8, i64 %65
  %67 = call i32 @zsteqr_(ptr noundef %0, ptr noundef nonnull %2, ptr noundef %4, ptr noundef %8, ptr noundef %5, ptr noundef nonnull %6, ptr noundef %66, ptr noundef nonnull %9) #4
  br label %68

68:                                               ; preds = %61, %59
  br i1 %57, label %69, label %80

69:                                               ; preds = %68
  %70 = load i64, ptr %9, align 8, !tbaa !5
  %71 = icmp eq i64 %70, 0
  br i1 %71, label %72, label %74

72:                                               ; preds = %69
  %73 = load i64, ptr %2, align 8, !tbaa !5
  br label %76

74:                                               ; preds = %69
  %75 = add nsw i64 %70, -1
  br label %76

76:                                               ; preds = %74, %72
  %storemerge = phi i64 [ %75, %74 ], [ %73, %72 ]
  store i64 %storemerge, ptr %13, align 8, !tbaa !5
  %77 = load double, ptr %14, align 8, !tbaa !12
  %78 = fdiv double 1.000000e+00, %77
  store double %78, ptr %12, align 8, !tbaa !12
  %79 = call i32 @f2c_dscal(ptr noundef nonnull %13, ptr noundef nonnull %12, ptr noundef %4, ptr noundef nonnull @c__1) #4
  br label %80

80:                                               ; preds = %68, %76, %35, %37, %34, %.thread
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #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 double @dlamch_(ptr noundef) local_unnamed_addr #2

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

declare double @zlanhp_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

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

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

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

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

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

declare i32 @f2c_dscal(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 = !{!11, !11, i64 0}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,PostOrderFunctionAttrsPass,ReassociatePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass