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

; 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.complex = type { float, float }

@.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
@c__1 = external hidden global i64, align 8
@.str.4 = external hidden unnamed_addr constant [7 x i8], align 1
@c_n1 = external hidden global i64, align 8
@.str.5 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [9 x i8], align 1
@c_b1 = external hidden global %struct.complex, align 4

; Function Attrs: nounwind uwtable
define dso_local i32 @chegv_(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, ptr noundef %11, ptr noundef %12) #0 {
  %14 = alloca i32, align 4
  %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 ptr, align 8
  %24 = alloca ptr, align 8
  %25 = alloca ptr, align 8
  %26 = alloca ptr, align 8
  %27 = alloca ptr, align 8
  %28 = alloca i64, align 8
  %29 = alloca i64, align 8
  %30 = alloca i64, align 8
  %31 = alloca i64, align 8
  %32 = alloca i64, align 8
  %33 = alloca i64, align 8
  %34 = alloca i64, align 8
  %35 = alloca i64, align 8
  %36 = alloca [1 x i8], align 1
  %37 = alloca i64, align 8
  %38 = alloca i64, align 8
  %39 = alloca i64, align 8
  %40 = alloca i64, align 8
  %41 = alloca i32, align 4
  store ptr %0, ptr %15, align 8, !tbaa !5
  store ptr %1, ptr %16, align 8, !tbaa !5
  store ptr %2, ptr %17, align 8, !tbaa !5
  store ptr %3, ptr %18, align 8, !tbaa !5
  store ptr %4, ptr %19, align 8, !tbaa !5
  store ptr %5, ptr %20, align 8, !tbaa !5
  store ptr %6, ptr %21, align 8, !tbaa !5
  store ptr %7, ptr %22, align 8, !tbaa !5
  store ptr %8, ptr %23, align 8, !tbaa !5
  store ptr %9, ptr %24, align 8, !tbaa !5
  store ptr %10, ptr %25, align 8, !tbaa !5
  store ptr %11, ptr %26, align 8, !tbaa !5
  store ptr %12, ptr %27, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %36) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %39) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #3
  %42 = load ptr, ptr %20, align 8, !tbaa !5
  %43 = load i64, ptr %42, align 8, !tbaa !9
  store i64 %43, ptr %28, align 8, !tbaa !9
  %44 = load i64, ptr %28, align 8, !tbaa !9
  %45 = add nsw i64 1, %44
  store i64 %45, ptr %29, align 8, !tbaa !9
  %46 = load i64, ptr %29, align 8, !tbaa !9
  %47 = load ptr, ptr %19, align 8, !tbaa !5
  %48 = sub i64 0, %46
  %49 = getelementptr inbounds %struct.complex, ptr %47, i64 %48
  store ptr %49, ptr %19, align 8, !tbaa !5
  %50 = load ptr, ptr %22, align 8, !tbaa !5
  %51 = load i64, ptr %50, align 8, !tbaa !9
  store i64 %51, ptr %30, align 8, !tbaa !9
  %52 = load i64, ptr %30, align 8, !tbaa !9
  %53 = add nsw i64 1, %52
  store i64 %53, ptr %31, align 8, !tbaa !9
  %54 = load i64, ptr %31, align 8, !tbaa !9
  %55 = load ptr, ptr %21, align 8, !tbaa !5
  %56 = sub i64 0, %54
  %57 = getelementptr inbounds %struct.complex, ptr %55, i64 %56
  store ptr %57, ptr %21, align 8, !tbaa !5
  %58 = load ptr, ptr %23, align 8, !tbaa !5
  %59 = getelementptr inbounds float, ptr %58, i32 -1
  store ptr %59, ptr %23, align 8, !tbaa !5
  %60 = load ptr, ptr %24, align 8, !tbaa !5
  %61 = getelementptr inbounds %struct.complex, ptr %60, i32 -1
  store ptr %61, ptr %24, align 8, !tbaa !5
  %62 = load ptr, ptr %26, align 8, !tbaa !5
  %63 = getelementptr inbounds float, ptr %62, i32 -1
  store ptr %63, ptr %26, align 8, !tbaa !5
  %64 = load ptr, ptr %16, align 8, !tbaa !5
  %65 = call i64 @lsame_(ptr noundef %64, ptr noundef @.str)
  store i64 %65, ptr %38, align 8, !tbaa !9
  %66 = load ptr, ptr %17, align 8, !tbaa !5
  %67 = call i64 @lsame_(ptr noundef %66, ptr noundef @.str.1)
  store i64 %67, ptr %37, align 8, !tbaa !9
  %68 = load ptr, ptr %25, align 8, !tbaa !5
  %69 = load i64, ptr %68, align 8, !tbaa !9
  %70 = icmp eq i64 %69, -1
  %71 = zext i1 %70 to i32
  %72 = sext i32 %71 to i64
  store i64 %72, ptr %40, align 8, !tbaa !9
  %73 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 0, ptr %73, align 8, !tbaa !9
  %74 = load ptr, ptr %15, align 8, !tbaa !5
  %75 = load i64, ptr %74, align 8, !tbaa !9
  %76 = icmp slt i64 %75, 1
  br i1 %76, label %81, label %77

77:                                               ; preds = %13
  %78 = load ptr, ptr %15, align 8, !tbaa !5
  %79 = load i64, ptr %78, align 8, !tbaa !9
  %80 = icmp sgt i64 %79, 3
  br i1 %80, label %81, label %83

81:                                               ; preds = %77, %13
  %82 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -1, ptr %82, align 8, !tbaa !9
  br label %142

83:                                               ; preds = %77
  %84 = load i64, ptr %38, align 8, !tbaa !9
  %85 = icmp ne i64 %84, 0
  br i1 %85, label %92, label %86

86:                                               ; preds = %83
  %87 = load ptr, ptr %16, align 8, !tbaa !5
  %88 = call i64 @lsame_(ptr noundef %87, ptr noundef @.str.2)
  %89 = icmp ne i64 %88, 0
  br i1 %89, label %92, label %90

90:                                               ; preds = %86
  %91 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -2, ptr %91, align 8, !tbaa !9
  br label %141

92:                                               ; preds = %86, %83
  %93 = load i64, ptr %37, align 8, !tbaa !9
  %94 = icmp ne i64 %93, 0
  br i1 %94, label %101, label %95

95:                                               ; preds = %92
  %96 = load ptr, ptr %17, align 8, !tbaa !5
  %97 = call i64 @lsame_(ptr noundef %96, ptr noundef @.str.3)
  %98 = icmp ne i64 %97, 0
  br i1 %98, label %101, label %99

99:                                               ; preds = %95
  %100 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -3, ptr %100, align 8, !tbaa !9
  br label %140

101:                                              ; preds = %95, %92
  %102 = load ptr, ptr %18, align 8, !tbaa !5
  %103 = load i64, ptr %102, align 8, !tbaa !9
  %104 = icmp slt i64 %103, 0
  br i1 %104, label %105, label %107

105:                                              ; preds = %101
  %106 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -4, ptr %106, align 8, !tbaa !9
  br label %139

107:                                              ; preds = %101
  %108 = load ptr, ptr %20, align 8, !tbaa !5
  %109 = load i64, ptr %108, align 8, !tbaa !9
  %110 = load ptr, ptr %18, align 8, !tbaa !5
  %111 = load i64, ptr %110, align 8, !tbaa !9
  %112 = icmp sge i64 1, %111
  br i1 %112, label %113, label %114

113:                                              ; preds = %107
  br label %117

114:                                              ; preds = %107
  %115 = load ptr, ptr %18, align 8, !tbaa !5
  %116 = load i64, ptr %115, align 8, !tbaa !9
  br label %117

117:                                              ; preds = %114, %113
  %118 = phi i64 [ 1, %113 ], [ %116, %114 ]
  %119 = icmp slt i64 %109, %118
  br i1 %119, label %120, label %122

120:                                              ; preds = %117
  %121 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -6, ptr %121, align 8, !tbaa !9
  br label %138

122:                                              ; preds = %117
  %123 = load ptr, ptr %22, align 8, !tbaa !5
  %124 = load i64, ptr %123, align 8, !tbaa !9
  %125 = load ptr, ptr %18, align 8, !tbaa !5
  %126 = load i64, ptr %125, align 8, !tbaa !9
  %127 = icmp sge i64 1, %126
  br i1 %127, label %128, label %129

128:                                              ; preds = %122
  br label %132

129:                                              ; preds = %122
  %130 = load ptr, ptr %18, align 8, !tbaa !5
  %131 = load i64, ptr %130, align 8, !tbaa !9
  br label %132

132:                                              ; preds = %129, %128
  %133 = phi i64 [ 1, %128 ], [ %131, %129 ]
  %134 = icmp slt i64 %124, %133
  br i1 %134, label %135, label %137

135:                                              ; preds = %132
  %136 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -8, ptr %136, align 8, !tbaa !9
  br label %137

137:                                              ; preds = %135, %132
  br label %138

138:                                              ; preds = %137, %120
  br label %139

139:                                              ; preds = %138, %105
  br label %140

140:                                              ; preds = %139, %99
  br label %141

141:                                              ; preds = %140, %90
  br label %142

142:                                              ; preds = %141, %81
  %143 = load ptr, ptr %27, align 8, !tbaa !5
  %144 = load i64, ptr %143, align 8, !tbaa !9
  %145 = icmp eq i64 %144, 0
  br i1 %145, label %146, label %194

146:                                              ; preds = %142
  %147 = load ptr, ptr %17, align 8, !tbaa !5
  %148 = load ptr, ptr %18, align 8, !tbaa !5
  %149 = call i64 @ilaenv_(ptr noundef @c__1, ptr noundef @.str.4, ptr noundef %147, ptr noundef %148, ptr noundef @c_n1, ptr noundef @c_n1, ptr noundef @c_n1)
  store i64 %149, ptr %34, align 8, !tbaa !9
  store i64 1, ptr %32, align 8, !tbaa !9
  %150 = load i64, ptr %34, align 8, !tbaa !9
  %151 = add nsw i64 %150, 1
  %152 = load ptr, ptr %18, align 8, !tbaa !5
  %153 = load i64, ptr %152, align 8, !tbaa !9
  %154 = mul nsw i64 %151, %153
  store i64 %154, ptr %33, align 8, !tbaa !9
  %155 = load i64, ptr %32, align 8, !tbaa !9
  %156 = load i64, ptr %33, align 8, !tbaa !9
  %157 = icmp sge i64 %155, %156
  br i1 %157, label %158, label %160

158:                                              ; preds = %146
  %159 = load i64, ptr %32, align 8, !tbaa !9
  br label %162

160:                                              ; preds = %146
  %161 = load i64, ptr %33, align 8, !tbaa !9
  br label %162

162:                                              ; preds = %160, %158
  %163 = phi i64 [ %159, %158 ], [ %161, %160 ]
  store i64 %163, ptr %39, align 8, !tbaa !9
  %164 = load i64, ptr %39, align 8, !tbaa !9
  %165 = sitofp i64 %164 to float
  %166 = load ptr, ptr %24, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.complex, ptr %166, i64 1
  %168 = getelementptr inbounds %struct.complex, ptr %167, i32 0, i32 0
  store float %165, ptr %168, align 4, !tbaa !11
  %169 = load ptr, ptr %24, align 8, !tbaa !5
  %170 = getelementptr inbounds %struct.complex, ptr %169, i64 1
  %171 = getelementptr inbounds %struct.complex, ptr %170, i32 0, i32 1
  store float 0.000000e+00, ptr %171, align 4, !tbaa !14
  store i64 1, ptr %32, align 8, !tbaa !9
  %172 = load ptr, ptr %18, align 8, !tbaa !5
  %173 = load i64, ptr %172, align 8, !tbaa !9
  %174 = shl i64 %173, 1
  %175 = sub nsw i64 %174, 1
  store i64 %175, ptr %33, align 8, !tbaa !9
  %176 = load ptr, ptr %25, align 8, !tbaa !5
  %177 = load i64, ptr %176, align 8, !tbaa !9
  %178 = load i64, ptr %32, align 8, !tbaa !9
  %179 = load i64, ptr %33, align 8, !tbaa !9
  %180 = icmp sge i64 %178, %179
  br i1 %180, label %181, label %183

181:                                              ; preds = %162
  %182 = load i64, ptr %32, align 8, !tbaa !9
  br label %185

183:                                              ; preds = %162
  %184 = load i64, ptr %33, align 8, !tbaa !9
  br label %185

185:                                              ; preds = %183, %181
  %186 = phi i64 [ %182, %181 ], [ %184, %183 ]
  %187 = icmp slt i64 %177, %186
  br i1 %187, label %188, label %193

188:                                              ; preds = %185
  %189 = load i64, ptr %40, align 8, !tbaa !9
  %190 = icmp ne i64 %189, 0
  br i1 %190, label %193, label %191

191:                                              ; preds = %188
  %192 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 -11, ptr %192, align 8, !tbaa !9
  br label %193

193:                                              ; preds = %191, %188, %185
  br label %194

194:                                              ; preds = %193, %142
  %195 = load ptr, ptr %27, align 8, !tbaa !5
  %196 = load i64, ptr %195, align 8, !tbaa !9
  %197 = icmp ne i64 %196, 0
  br i1 %197, label %198, label %203

198:                                              ; preds = %194
  %199 = load ptr, ptr %27, align 8, !tbaa !5
  %200 = load i64, ptr %199, align 8, !tbaa !9
  %201 = sub nsw i64 0, %200
  store i64 %201, ptr %32, align 8, !tbaa !9
  %202 = call i32 @xerbla_(ptr noundef @.str.5, ptr noundef %32)
  store i32 0, ptr %14, align 4
  store i32 1, ptr %41, align 4
  br label %337

203:                                              ; preds = %194
  %204 = load i64, ptr %40, align 8, !tbaa !9
  %205 = icmp ne i64 %204, 0
  br i1 %205, label %206, label %207

206:                                              ; preds = %203
  store i32 0, ptr %14, align 4
  store i32 1, ptr %41, align 4
  br label %337

207:                                              ; preds = %203
  br label %208

208:                                              ; preds = %207
  %209 = load ptr, ptr %18, align 8, !tbaa !5
  %210 = load i64, ptr %209, align 8, !tbaa !9
  %211 = icmp eq i64 %210, 0
  br i1 %211, label %212, label %213

212:                                              ; preds = %208
  store i32 0, ptr %14, align 4
  store i32 1, ptr %41, align 4
  br label %337

213:                                              ; preds = %208
  %214 = load ptr, ptr %17, align 8, !tbaa !5
  %215 = load ptr, ptr %18, align 8, !tbaa !5
  %216 = load ptr, ptr %21, align 8, !tbaa !5
  %217 = load i64, ptr %31, align 8, !tbaa !9
  %218 = getelementptr inbounds %struct.complex, ptr %216, i64 %217
  %219 = load ptr, ptr %22, align 8, !tbaa !5
  %220 = load ptr, ptr %27, align 8, !tbaa !5
  %221 = call i32 @cpotrf_(ptr noundef %214, ptr noundef %215, ptr noundef %218, ptr noundef %219, ptr noundef %220)
  %222 = load ptr, ptr %27, align 8, !tbaa !5
  %223 = load i64, ptr %222, align 8, !tbaa !9
  %224 = icmp ne i64 %223, 0
  br i1 %224, label %225, label %232

225:                                              ; preds = %213
  %226 = load ptr, ptr %18, align 8, !tbaa !5
  %227 = load i64, ptr %226, align 8, !tbaa !9
  %228 = load ptr, ptr %27, align 8, !tbaa !5
  %229 = load i64, ptr %228, align 8, !tbaa !9
  %230 = add nsw i64 %227, %229
  %231 = load ptr, ptr %27, align 8, !tbaa !5
  store i64 %230, ptr %231, align 8, !tbaa !9
  store i32 0, ptr %14, align 4
  store i32 1, ptr %41, align 4
  br label %337

232:                                              ; preds = %213
  %233 = load ptr, ptr %15, align 8, !tbaa !5
  %234 = load ptr, ptr %17, align 8, !tbaa !5
  %235 = load ptr, ptr %18, align 8, !tbaa !5
  %236 = load ptr, ptr %19, align 8, !tbaa !5
  %237 = load i64, ptr %29, align 8, !tbaa !9
  %238 = getelementptr inbounds %struct.complex, ptr %236, i64 %237
  %239 = load ptr, ptr %20, align 8, !tbaa !5
  %240 = load ptr, ptr %21, align 8, !tbaa !5
  %241 = load i64, ptr %31, align 8, !tbaa !9
  %242 = getelementptr inbounds %struct.complex, ptr %240, i64 %241
  %243 = load ptr, ptr %22, align 8, !tbaa !5
  %244 = load ptr, ptr %27, align 8, !tbaa !5
  %245 = call i32 @chegst_(ptr noundef %233, ptr noundef %234, ptr noundef %235, ptr noundef %238, ptr noundef %239, ptr noundef %242, ptr noundef %243, ptr noundef %244)
  %246 = load ptr, ptr %16, align 8, !tbaa !5
  %247 = load ptr, ptr %17, align 8, !tbaa !5
  %248 = load ptr, ptr %18, align 8, !tbaa !5
  %249 = load ptr, ptr %19, align 8, !tbaa !5
  %250 = load i64, ptr %29, align 8, !tbaa !9
  %251 = getelementptr inbounds %struct.complex, ptr %249, i64 %250
  %252 = load ptr, ptr %20, align 8, !tbaa !5
  %253 = load ptr, ptr %23, align 8, !tbaa !5
  %254 = getelementptr inbounds float, ptr %253, i64 1
  %255 = load ptr, ptr %24, align 8, !tbaa !5
  %256 = getelementptr inbounds %struct.complex, ptr %255, i64 1
  %257 = load ptr, ptr %25, align 8, !tbaa !5
  %258 = load ptr, ptr %26, align 8, !tbaa !5
  %259 = getelementptr inbounds float, ptr %258, i64 1
  %260 = load ptr, ptr %27, align 8, !tbaa !5
  %261 = call i32 @cheev_(ptr noundef %246, ptr noundef %247, ptr noundef %248, ptr noundef %251, ptr noundef %252, ptr noundef %254, ptr noundef %256, ptr noundef %257, ptr noundef %259, ptr noundef %260)
  %262 = load i64, ptr %38, align 8, !tbaa !9
  %263 = icmp ne i64 %262, 0
  br i1 %263, label %264, label %328

264:                                              ; preds = %232
  %265 = load ptr, ptr %18, align 8, !tbaa !5
  %266 = load i64, ptr %265, align 8, !tbaa !9
  store i64 %266, ptr %35, align 8, !tbaa !9
  %267 = load ptr, ptr %27, align 8, !tbaa !5
  %268 = load i64, ptr %267, align 8, !tbaa !9
  %269 = icmp sgt i64 %268, 0
  br i1 %269, label %270, label %274

270:                                              ; preds = %264
  %271 = load ptr, ptr %27, align 8, !tbaa !5
  %272 = load i64, ptr %271, align 8, !tbaa !9
  %273 = sub nsw i64 %272, 1
  store i64 %273, ptr %35, align 8, !tbaa !9
  br label %274

274:                                              ; preds = %270, %264
  %275 = load ptr, ptr %15, align 8, !tbaa !5
  %276 = load i64, ptr %275, align 8, !tbaa !9
  %277 = icmp eq i64 %276, 1
  br i1 %277, label %282, label %278

278:                                              ; preds = %274
  %279 = load ptr, ptr %15, align 8, !tbaa !5
  %280 = load i64, ptr %279, align 8, !tbaa !9
  %281 = icmp eq i64 %280, 2
  br i1 %281, label %282, label %302

282:                                              ; preds = %278, %274
  %283 = load i64, ptr %37, align 8, !tbaa !9
  %284 = icmp ne i64 %283, 0
  br i1 %284, label %285, label %287

285:                                              ; preds = %282
  %286 = getelementptr inbounds [1 x i8], ptr %36, i64 0, i64 0
  store i8 78, ptr %286, align 1, !tbaa !15
  br label %289

287:                                              ; preds = %282
  %288 = getelementptr inbounds [1 x i8], ptr %36, i64 0, i64 0
  store i8 67, ptr %288, align 1, !tbaa !15
  br label %289

289:                                              ; preds = %287, %285
  %290 = load ptr, ptr %17, align 8, !tbaa !5
  %291 = getelementptr inbounds [1 x i8], ptr %36, i64 0, i64 0
  %292 = load ptr, ptr %18, align 8, !tbaa !5
  %293 = load ptr, ptr %21, align 8, !tbaa !5
  %294 = load i64, ptr %31, align 8, !tbaa !9
  %295 = getelementptr inbounds %struct.complex, ptr %293, i64 %294
  %296 = load ptr, ptr %22, align 8, !tbaa !5
  %297 = load ptr, ptr %19, align 8, !tbaa !5
  %298 = load i64, ptr %29, align 8, !tbaa !9
  %299 = getelementptr inbounds %struct.complex, ptr %297, i64 %298
  %300 = load ptr, ptr %20, align 8, !tbaa !5
  %301 = call i32 @f2c_ctrsm(ptr noundef @.str.6, ptr noundef %290, ptr noundef %291, ptr noundef @.str.7, ptr noundef %292, ptr noundef %35, ptr noundef @c_b1, ptr noundef %295, ptr noundef %296, ptr noundef %299, ptr noundef %300)
  br label %327

302:                                              ; preds = %278
  %303 = load ptr, ptr %15, align 8, !tbaa !5
  %304 = load i64, ptr %303, align 8, !tbaa !9
  %305 = icmp eq i64 %304, 3
  br i1 %305, label %306, label %326

306:                                              ; preds = %302
  %307 = load i64, ptr %37, align 8, !tbaa !9
  %308 = icmp ne i64 %307, 0
  br i1 %308, label %309, label %311

309:                                              ; preds = %306
  %310 = getelementptr inbounds [1 x i8], ptr %36, i64 0, i64 0
  store i8 67, ptr %310, align 1, !tbaa !15
  br label %313

311:                                              ; preds = %306
  %312 = getelementptr inbounds [1 x i8], ptr %36, i64 0, i64 0
  store i8 78, ptr %312, align 1, !tbaa !15
  br label %313

313:                                              ; preds = %311, %309
  %314 = load ptr, ptr %17, align 8, !tbaa !5
  %315 = getelementptr inbounds [1 x i8], ptr %36, i64 0, i64 0
  %316 = load ptr, ptr %18, align 8, !tbaa !5
  %317 = load ptr, ptr %21, align 8, !tbaa !5
  %318 = load i64, ptr %31, align 8, !tbaa !9
  %319 = getelementptr inbounds %struct.complex, ptr %317, i64 %318
  %320 = load ptr, ptr %22, align 8, !tbaa !5
  %321 = load ptr, ptr %19, align 8, !tbaa !5
  %322 = load i64, ptr %29, align 8, !tbaa !9
  %323 = getelementptr inbounds %struct.complex, ptr %321, i64 %322
  %324 = load ptr, ptr %20, align 8, !tbaa !5
  %325 = call i32 @f2c_ctrmm(ptr noundef @.str.6, ptr noundef %314, ptr noundef %315, ptr noundef @.str.7, ptr noundef %316, ptr noundef %35, ptr noundef @c_b1, ptr noundef %319, ptr noundef %320, ptr noundef %323, ptr noundef %324)
  br label %326

326:                                              ; preds = %313, %302
  br label %327

327:                                              ; preds = %326, %289
  br label %328

328:                                              ; preds = %327, %232
  %329 = load i64, ptr %39, align 8, !tbaa !9
  %330 = sitofp i64 %329 to float
  %331 = load ptr, ptr %24, align 8, !tbaa !5
  %332 = getelementptr inbounds %struct.complex, ptr %331, i64 1
  %333 = getelementptr inbounds %struct.complex, ptr %332, i32 0, i32 0
  store float %330, ptr %333, align 4, !tbaa !11
  %334 = load ptr, ptr %24, align 8, !tbaa !5
  %335 = getelementptr inbounds %struct.complex, ptr %334, i64 1
  %336 = getelementptr inbounds %struct.complex, ptr %335, i32 0, i32 1
  store float 0.000000e+00, ptr %336, align 4, !tbaa !14
  store i32 0, ptr %14, align 4
  store i32 1, ptr %41, align 4
  br label %337

337:                                              ; preds = %328, %225, %212, %206, %198
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %36) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #3
  %338 = load i32, ptr %14, align 4
  ret i32 %338
}

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

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

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

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

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

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

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

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

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

!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 4}
!13 = !{!"float", !7, i64 0}
!14 = !{!12, !13, i64 4}
!15 = !{!7, !7, i64 0}


; 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.complex = type { float, float }

@.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
@c__1 = external hidden global i64, align 8
@.str.4 = external hidden unnamed_addr constant [7 x i8], align 1
@c_n1 = external hidden global i64, align 8
@.str.5 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [9 x i8], align 1
@c_b1 = external hidden global %struct.complex, align 4

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @chegv_(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, ptr noundef %11, ptr noundef %12) local_unnamed_addr #0 {
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca [1 x i8], align 1
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %16) #4
  %17 = tail call i64 @lsame_(ptr noundef %1, ptr noundef nonnull @.str) #4
  %18 = tail call i64 @lsame_(ptr noundef %2, ptr noundef nonnull @.str.1) #4
  %19 = load i64, ptr %10, align 8, !tbaa !5
  %20 = icmp eq i64 %19, -1
  store i64 0, ptr %12, align 8, !tbaa !5
  %21 = load i64, ptr %0, align 8, !tbaa !5
  %22 = add i64 %21, -4
  %or.cond130 = icmp ult i64 %22, -3
  br i1 %or.cond130, label %.thread137.sink.split, label %23

23:                                               ; preds = %13
  %.not = icmp eq i64 %17, 0
  br i1 %.not, label %24, label %26

24:                                               ; preds = %23
  %25 = tail call i64 @lsame_(ptr noundef %1, ptr noundef nonnull @.str.2) #4
  %.not121 = icmp eq i64 %25, 0
  br i1 %.not121, label %.thread137.sink.split, label %26

26:                                               ; preds = %24, %23
  %.not122 = icmp eq i64 %18, 0
  br i1 %.not122, label %27, label %29

27:                                               ; preds = %26
  %28 = tail call i64 @lsame_(ptr noundef %2, ptr noundef nonnull @.str.3) #4
  %.not123 = icmp eq i64 %28, 0
  br i1 %.not123, label %.thread137.sink.split, label %29

29:                                               ; preds = %27, %26
  %30 = load i64, ptr %3, align 8, !tbaa !5
  %31 = icmp slt i64 %30, 0
  br i1 %31, label %.thread137.sink.split, label %32

32:                                               ; preds = %29
  %33 = load i64, ptr %5, align 8, !tbaa !5
  %spec.select = tail call i64 @llvm.umax.i64(i64 %30, i64 1)
  %34 = icmp slt i64 %33, %spec.select
  br i1 %34, label %.thread137.sink.split, label %35

35:                                               ; preds = %32
  %36 = load i64, ptr %7, align 8, !tbaa !5
  %37 = icmp slt i64 %36, %spec.select
  br i1 %37, label %.thread137.sink.split, label %38

38:                                               ; preds = %35
  %.pr = load i64, ptr %12, align 8, !tbaa !5
  %39 = icmp eq i64 %.pr, 0
  br i1 %39, label %40, label %.thread137

40:                                               ; preds = %38
  %41 = tail call i64 @ilaenv_(ptr noundef nonnull @c__1, ptr noundef nonnull @.str.4, ptr noundef %2, ptr noundef nonnull %3, ptr noundef nonnull @c_n1, ptr noundef nonnull @c_n1, ptr noundef nonnull @c_n1) #4
  %42 = add nsw i64 %41, 1
  %43 = load i64, ptr %3, align 8, !tbaa !5
  %44 = mul nsw i64 %43, %42
  %45 = tail call i64 @llvm.smax.i64(i64 %44, i64 1)
  %46 = uitofp nneg i64 %45 to float
  store float %46, ptr %9, align 4, !tbaa !9
  %47 = getelementptr inbounds i8, ptr %9, i64 4
  store float 0.000000e+00, ptr %47, align 4, !tbaa !12
  %48 = shl i64 %43, 1
  %49 = add nsw i64 %48, -1
  %50 = load i64, ptr %10, align 8, !tbaa !5
  %51 = icmp slt i64 %48, 3
  %52 = select i1 %51, i64 1, i64 %49
  %53 = icmp sge i64 %50, %52
  %or.cond = select i1 %53, i1 true, i1 %20
  br i1 %or.cond, label %.thread, label %.thread137.sink.split

.thread:                                          ; preds = %40
  %.pr134.pr = load i64, ptr %12, align 8, !tbaa !5
  %.not124 = icmp eq i64 %.pr134.pr, 0
  br i1 %.not124, label %57, label %.thread137

.thread137.sink.split:                            ; preds = %40, %35, %32, %29, %27, %24, %13
  %.sink = phi i64 [ -1, %13 ], [ -2, %24 ], [ -3, %27 ], [ -4, %29 ], [ -6, %32 ], [ -8, %35 ], [ -11, %40 ]
  store i64 %.sink, ptr %12, align 8, !tbaa !5
  br label %.thread137

.thread137:                                       ; preds = %.thread137.sink.split, %38, %.thread
  %54 = phi i64 [ %.pr134.pr, %.thread ], [ %.pr, %38 ], [ %.sink, %.thread137.sink.split ]
  %55 = sub nsw i64 0, %54
  store i64 %55, ptr %14, align 8, !tbaa !5
  %56 = call i32 @xerbla_(ptr noundef nonnull @.str.5, ptr noundef nonnull %14) #4
  br label %81

57:                                               ; preds = %.thread
  %58 = icmp eq i64 %43, 0
  %or.cond143 = or i1 %20, %58
  br i1 %or.cond143, label %81, label %59

59:                                               ; preds = %57
  %60 = tail call i32 @cpotrf_(ptr noundef %2, ptr noundef nonnull %3, ptr noundef %6, ptr noundef nonnull %7, ptr noundef nonnull %12) #4
  %61 = load i64, ptr %12, align 8, !tbaa !5
  %.not125 = icmp eq i64 %61, 0
  br i1 %.not125, label %65, label %62

62:                                               ; preds = %59
  %63 = load i64, ptr %3, align 8, !tbaa !5
  %64 = add nsw i64 %63, %61
  store i64 %64, ptr %12, align 8, !tbaa !5
  br label %81

65:                                               ; preds = %59
  %66 = tail call i32 @chegst_(ptr noundef nonnull %0, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %4, ptr noundef nonnull %5, ptr noundef %6, ptr noundef nonnull %7, ptr noundef nonnull %12) #4
  %67 = tail call i32 @cheev_(ptr noundef %1, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %4, ptr noundef nonnull %5, ptr noundef %8, ptr noundef nonnull %9, ptr noundef nonnull %10, ptr noundef %11, ptr noundef nonnull %12) #4
  br i1 %.not, label %80, label %68

68:                                               ; preds = %65
  %69 = load i64, ptr %3, align 8, !tbaa !5
  store i64 %69, ptr %15, align 8, !tbaa !5
  %70 = load i64, ptr %12, align 8, !tbaa !5
  %71 = icmp sgt i64 %70, 0
  br i1 %71, label %72, label %74

72:                                               ; preds = %68
  %73 = add nsw i64 %70, -1
  store i64 %73, ptr %15, align 8, !tbaa !5
  br label %74

74:                                               ; preds = %72, %68
  %75 = load i64, ptr %0, align 8, !tbaa !5
  switch i64 %75, label %80 [
    i64 1, label %76
    i64 2, label %76
    i64 3, label %78
  ]

76:                                               ; preds = %74, %74
  %. = select i1 %.not122, i8 67, i8 78
  store i8 %., ptr %16, align 1, !tbaa !13
  %77 = call i32 @f2c_ctrsm(ptr noundef nonnull @.str.6, ptr noundef %2, ptr noundef nonnull %16, ptr noundef nonnull @.str.7, ptr noundef nonnull %3, ptr noundef nonnull %15, ptr noundef nonnull @c_b1, ptr noundef %6, ptr noundef nonnull %7, ptr noundef %4, ptr noundef nonnull %5) #4
  br label %80

78:                                               ; preds = %74
  %.132 = select i1 %.not122, i8 78, i8 67
  store i8 %.132, ptr %16, align 1, !tbaa !13
  %79 = call i32 @f2c_ctrmm(ptr noundef nonnull @.str.6, ptr noundef %2, ptr noundef nonnull %16, ptr noundef nonnull @.str.7, ptr noundef nonnull %3, ptr noundef nonnull %15, ptr noundef nonnull @c_b1, ptr noundef %6, ptr noundef nonnull %7, ptr noundef %4, ptr noundef nonnull %5) #4
  br label %80

80:                                               ; preds = %74, %76, %78, %65
  store float %46, ptr %9, align 4, !tbaa !9
  store float 0.000000e+00, ptr %47, align 4, !tbaa !12
  br label %81

81:                                               ; preds = %57, %80, %62, %.thread137
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #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 i64 @ilaenv_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

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

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

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

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

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

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.smax.i64(i64, i64) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.umax.i64(i64, i64) #3

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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 4}
!11 = !{!"float", !7, i64 0}
!12 = !{!10, !11, i64 4}
!13 = !{!7, !7, i64 0}


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