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

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

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

69:                                               ; preds = %11
  %70 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -1, ptr %70, align 4, !tbaa !9
  br label %198

71:                                               ; preds = %11
  %72 = load ptr, ptr %13, align 8, !tbaa !5
  %73 = load i32, ptr %72, align 4, !tbaa !9
  %74 = icmp slt i32 %73, 0
  br i1 %74, label %81, label %75

75:                                               ; preds = %71
  %76 = load ptr, ptr %12, align 8, !tbaa !5
  %77 = load i32, ptr %76, align 4, !tbaa !9
  %78 = load ptr, ptr %13, align 8, !tbaa !5
  %79 = load i32, ptr %78, align 4, !tbaa !9
  %80 = icmp slt i32 %77, %79
  br i1 %80, label %81, label %83

81:                                               ; preds = %75, %71
  %82 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -2, ptr %82, align 4, !tbaa !9
  br label %197

83:                                               ; preds = %75
  %84 = load ptr, ptr %14, align 8, !tbaa !5
  %85 = load i32, ptr %84, align 4, !tbaa !9
  %86 = load ptr, ptr %13, align 8, !tbaa !5
  %87 = load i32, ptr %86, align 4, !tbaa !9
  %88 = icmp sle i32 %85, %87
  br i1 %88, label %89, label %91

89:                                               ; preds = %83
  %90 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -3, ptr %90, align 4, !tbaa !9
  br label %196

91:                                               ; preds = %83
  %92 = load ptr, ptr %15, align 8, !tbaa !5
  %93 = load i32, ptr %92, align 4, !tbaa !9
  %94 = icmp slt i32 %93, 1
  br i1 %94, label %95, label %97

95:                                               ; preds = %91
  %96 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -4, ptr %96, align 4, !tbaa !9
  br label %195

97:                                               ; preds = %91
  %98 = load ptr, ptr %17, align 8, !tbaa !5
  %99 = load i32, ptr %98, align 4, !tbaa !9
  %100 = load ptr, ptr %12, align 8, !tbaa !5
  %101 = load i32, ptr %100, align 4, !tbaa !9
  %102 = icmp sge i32 1, %101
  br i1 %102, label %103, label %104

103:                                              ; preds = %97
  br label %107

104:                                              ; preds = %97
  %105 = load ptr, ptr %12, align 8, !tbaa !5
  %106 = load i32, ptr %105, align 4, !tbaa !9
  br label %107

107:                                              ; preds = %104, %103
  %108 = phi i32 [ 1, %103 ], [ %106, %104 ]
  %109 = icmp slt i32 %99, %108
  br i1 %109, label %110, label %112

110:                                              ; preds = %107
  %111 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -6, ptr %111, align 4, !tbaa !9
  br label %194

112:                                              ; preds = %107
  store i32 1, ptr %27, align 4, !tbaa !9
  %113 = load ptr, ptr %15, align 8, !tbaa !5
  %114 = load i32, ptr %113, align 4, !tbaa !9
  %115 = load ptr, ptr %13, align 8, !tbaa !5
  %116 = load i32, ptr %115, align 4, !tbaa !9
  %117 = icmp sle i32 %114, %116
  br i1 %117, label %118, label %121

118:                                              ; preds = %112
  %119 = load ptr, ptr %15, align 8, !tbaa !5
  %120 = load i32, ptr %119, align 4, !tbaa !9
  br label %124

121:                                              ; preds = %112
  %122 = load ptr, ptr %13, align 8, !tbaa !5
  %123 = load i32, ptr %122, align 4, !tbaa !9
  br label %124

124:                                              ; preds = %121, %118
  %125 = phi i32 [ %120, %118 ], [ %123, %121 ]
  store i32 %125, ptr %28, align 4, !tbaa !9
  %126 = load ptr, ptr %19, align 8, !tbaa !5
  %127 = load i32, ptr %126, align 4, !tbaa !9
  %128 = load i32, ptr %27, align 4, !tbaa !9
  %129 = load i32, ptr %28, align 4, !tbaa !9
  %130 = icmp sge i32 %128, %129
  br i1 %130, label %131, label %133

131:                                              ; preds = %124
  %132 = load i32, ptr %27, align 4, !tbaa !9
  br label %135

133:                                              ; preds = %124
  %134 = load i32, ptr %28, align 4, !tbaa !9
  br label %135

135:                                              ; preds = %133, %131
  %136 = phi i32 [ %132, %131 ], [ %134, %133 ]
  %137 = icmp slt i32 %127, %136
  br i1 %137, label %138, label %140

138:                                              ; preds = %135
  %139 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -8, ptr %139, align 4, !tbaa !9
  br label %193

140:                                              ; preds = %135
  %141 = load ptr, ptr %21, align 8, !tbaa !5
  %142 = load i32, ptr %141, align 4, !tbaa !9
  %143 = icmp slt i32 %142, 2
  br i1 %143, label %144, label %149

144:                                              ; preds = %140
  %145 = load i32, ptr %35, align 4, !tbaa !9
  %146 = icmp ne i32 %145, 0
  br i1 %146, label %149, label %147

147:                                              ; preds = %144
  %148 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -10, ptr %148, align 4, !tbaa !9
  br label %192

149:                                              ; preds = %144, %140
  %150 = load ptr, ptr %15, align 8, !tbaa !5
  %151 = load i32, ptr %150, align 4, !tbaa !9
  %152 = load ptr, ptr %13, align 8, !tbaa !5
  %153 = load i32, ptr %152, align 4, !tbaa !9
  %154 = icmp sle i32 %151, %153
  br i1 %154, label %155, label %158

155:                                              ; preds = %149
  %156 = load ptr, ptr %15, align 8, !tbaa !5
  %157 = load i32, ptr %156, align 4, !tbaa !9
  br label %161

158:                                              ; preds = %149
  %159 = load ptr, ptr %13, align 8, !tbaa !5
  %160 = load i32, ptr %159, align 4, !tbaa !9
  br label %161

161:                                              ; preds = %158, %155
  %162 = phi i32 [ %157, %155 ], [ %160, %158 ]
  store i32 %162, ptr %37, align 4, !tbaa !9
  %163 = load ptr, ptr %12, align 8, !tbaa !5
  %164 = load i32, ptr %163, align 4, !tbaa !9
  store i32 %164, ptr %36, align 4, !tbaa !9
  %165 = load i32, ptr %36, align 4, !tbaa !9
  %166 = load ptr, ptr %13, align 8, !tbaa !5
  %167 = load i32, ptr %166, align 4, !tbaa !9
  %168 = mul nsw i32 %165, %167
  store i32 %168, ptr %33, align 4, !tbaa !9
  %169 = load ptr, ptr %13, align 8, !tbaa !5
  %170 = load i32, ptr %169, align 4, !tbaa !9
  %171 = load i32, ptr %37, align 4, !tbaa !9
  %172 = mul nsw i32 %170, %171
  store i32 %172, ptr %34, align 4, !tbaa !9
  %173 = load i32, ptr %33, align 4, !tbaa !9
  %174 = load i32, ptr %34, align 4, !tbaa !9
  %175 = add nsw i32 %173, %174
  store i32 %175, ptr %30, align 4, !tbaa !9
  %176 = load ptr, ptr %21, align 8, !tbaa !5
  %177 = load i32, ptr %176, align 4, !tbaa !9
  %178 = load i32, ptr %30, align 4, !tbaa !9
  %179 = icmp sge i32 1, %178
  br i1 %179, label %180, label %181

180:                                              ; preds = %161
  br label %183

181:                                              ; preds = %161
  %182 = load i32, ptr %30, align 4, !tbaa !9
  br label %183

183:                                              ; preds = %181, %180
  %184 = phi i32 [ 1, %180 ], [ %182, %181 ]
  %185 = icmp slt i32 %177, %184
  br i1 %185, label %186, label %191

186:                                              ; preds = %183
  %187 = load i32, ptr %35, align 4, !tbaa !9
  %188 = icmp ne i32 %187, 0
  br i1 %188, label %191, label %189

189:                                              ; preds = %186
  %190 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -10, ptr %190, align 4, !tbaa !9
  br label %191

191:                                              ; preds = %189, %186, %183
  br label %192

192:                                              ; preds = %191, %147
  br label %193

193:                                              ; preds = %192, %138
  br label %194

194:                                              ; preds = %193, %110
  br label %195

195:                                              ; preds = %194, %95
  br label %196

196:                                              ; preds = %195, %89
  br label %197

197:                                              ; preds = %196, %81
  br label %198

198:                                              ; preds = %197, %69
  %199 = load ptr, ptr %22, align 8, !tbaa !5
  %200 = load i32, ptr %199, align 4, !tbaa !9
  %201 = icmp ne i32 %200, 0
  br i1 %201, label %202, label %207

202:                                              ; preds = %198
  %203 = load ptr, ptr %22, align 8, !tbaa !5
  %204 = load i32, ptr %203, align 4, !tbaa !9
  %205 = sub nsw i32 0, %204
  store i32 %205, ptr %27, align 4, !tbaa !9
  %206 = call i32 @xerbla_(ptr noundef @.str, ptr noundef %27, i32 noundef 8)
  store i32 1, ptr %38, align 4
  br label %323

207:                                              ; preds = %198
  %208 = load i32, ptr %35, align 4, !tbaa !9
  %209 = icmp ne i32 %208, 0
  br i1 %209, label %210, label %225

210:                                              ; preds = %207
  %211 = load i32, ptr %30, align 4, !tbaa !9
  %212 = sitofp i32 %211 to float
  %213 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 0
  store float %212, ptr %213, align 4, !tbaa !11
  %214 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 1
  store float 0.000000e+00, ptr %214, align 4, !tbaa !14
  %215 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 0
  %216 = load float, ptr %215, align 4, !tbaa !11
  %217 = load ptr, ptr %20, align 8, !tbaa !5
  %218 = getelementptr inbounds %struct.complex, ptr %217, i64 1
  %219 = getelementptr inbounds %struct.complex, ptr %218, i32 0, i32 0
  store float %216, ptr %219, align 4, !tbaa !11
  %220 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 1
  %221 = load float, ptr %220, align 4, !tbaa !14
  %222 = load ptr, ptr %20, align 8, !tbaa !5
  %223 = getelementptr inbounds %struct.complex, ptr %222, i64 1
  %224 = getelementptr inbounds %struct.complex, ptr %223, i32 0, i32 1
  store float %221, ptr %224, align 4, !tbaa !14
  store i32 1, ptr %38, align 4
  br label %323

225:                                              ; preds = %207
  br label %226

226:                                              ; preds = %225
  %227 = load ptr, ptr %12, align 8, !tbaa !5
  %228 = load i32, ptr %227, align 4, !tbaa !9
  %229 = load ptr, ptr %13, align 8, !tbaa !5
  %230 = load i32, ptr %229, align 4, !tbaa !9
  %231 = icmp sle i32 %228, %230
  br i1 %231, label %232, label %235

232:                                              ; preds = %226
  %233 = load ptr, ptr %12, align 8, !tbaa !5
  %234 = load i32, ptr %233, align 4, !tbaa !9
  br label %238

235:                                              ; preds = %226
  %236 = load ptr, ptr %13, align 8, !tbaa !5
  %237 = load i32, ptr %236, align 4, !tbaa !9
  br label %238

238:                                              ; preds = %235, %232
  %239 = phi i32 [ %234, %232 ], [ %237, %235 ]
  %240 = icmp eq i32 %239, 0
  br i1 %240, label %241, label %256

241:                                              ; preds = %238
  %242 = load i32, ptr %30, align 4, !tbaa !9
  %243 = sitofp i32 %242 to float
  %244 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 0
  store float %243, ptr %244, align 4, !tbaa !11
  %245 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 1
  store float 0.000000e+00, ptr %245, align 4, !tbaa !14
  %246 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 0
  %247 = load float, ptr %246, align 4, !tbaa !11
  %248 = load ptr, ptr %20, align 8, !tbaa !5
  %249 = getelementptr inbounds %struct.complex, ptr %248, i64 1
  %250 = getelementptr inbounds %struct.complex, ptr %249, i32 0, i32 0
  store float %247, ptr %250, align 4, !tbaa !11
  %251 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 1
  %252 = load float, ptr %251, align 4, !tbaa !14
  %253 = load ptr, ptr %20, align 8, !tbaa !5
  %254 = getelementptr inbounds %struct.complex, ptr %253, i64 1
  %255 = getelementptr inbounds %struct.complex, ptr %254, i32 0, i32 1
  store float %252, ptr %255, align 4, !tbaa !14
  store i32 1, ptr %38, align 4
  br label %323

256:                                              ; preds = %238
  %257 = load ptr, ptr %12, align 8, !tbaa !5
  %258 = load ptr, ptr %13, align 8, !tbaa !5
  %259 = load ptr, ptr %20, align 8, !tbaa !5
  %260 = getelementptr inbounds %struct.complex, ptr %259, i64 1
  call void @claset_(ptr noundef @.str.1, ptr noundef %257, ptr noundef %258, ptr noundef @c_b2, ptr noundef @c_b1, ptr noundef %260, ptr noundef %36)
  %261 = load ptr, ptr %12, align 8, !tbaa !5
  %262 = load ptr, ptr %13, align 8, !tbaa !5
  %263 = load ptr, ptr %13, align 8, !tbaa !5
  %264 = load ptr, ptr %14, align 8, !tbaa !5
  %265 = load ptr, ptr %16, align 8, !tbaa !5
  %266 = load i32, ptr %24, align 4, !tbaa !9
  %267 = sext i32 %266 to i64
  %268 = getelementptr inbounds %struct.complex, ptr %265, i64 %267
  %269 = load ptr, ptr %17, align 8, !tbaa !5
  %270 = load ptr, ptr %18, align 8, !tbaa !5
  %271 = load i32, ptr %26, align 4, !tbaa !9
  %272 = sext i32 %271 to i64
  %273 = getelementptr inbounds %struct.complex, ptr %270, i64 %272
  %274 = load ptr, ptr %19, align 8, !tbaa !5
  %275 = load ptr, ptr %20, align 8, !tbaa !5
  %276 = getelementptr inbounds %struct.complex, ptr %275, i64 1
  %277 = load ptr, ptr %20, align 8, !tbaa !5
  %278 = load i32, ptr %33, align 4, !tbaa !9
  %279 = add nsw i32 %278, 1
  %280 = sext i32 %279 to i64
  %281 = getelementptr inbounds %struct.complex, ptr %277, i64 %280
  call void @clamtsqr_(ptr noundef @.str.2, ptr noundef @.str.3, ptr noundef %261, ptr noundef %262, ptr noundef %263, ptr noundef %264, ptr noundef %37, ptr noundef %268, ptr noundef %269, ptr noundef %273, ptr noundef %274, ptr noundef %276, ptr noundef %36, ptr noundef %281, ptr noundef %34, ptr noundef %32)
  %282 = load ptr, ptr %13, align 8, !tbaa !5
  %283 = load i32, ptr %282, align 4, !tbaa !9
  store i32 %283, ptr %27, align 4, !tbaa !9
  store i32 1, ptr %31, align 4, !tbaa !9
  br label %284

284:                                              ; preds = %305, %256
  %285 = load i32, ptr %31, align 4, !tbaa !9
  %286 = load i32, ptr %27, align 4, !tbaa !9
  %287 = icmp sle i32 %285, %286
  br i1 %287, label %288, label %308

288:                                              ; preds = %284
  %289 = load ptr, ptr %12, align 8, !tbaa !5
  %290 = load ptr, ptr %20, align 8, !tbaa !5
  %291 = load i32, ptr %31, align 4, !tbaa !9
  %292 = sub nsw i32 %291, 1
  %293 = load i32, ptr %36, align 4, !tbaa !9
  %294 = mul nsw i32 %292, %293
  %295 = add nsw i32 %294, 1
  %296 = sext i32 %295 to i64
  %297 = getelementptr inbounds %struct.complex, ptr %290, i64 %296
  %298 = load ptr, ptr %16, align 8, !tbaa !5
  %299 = load i32, ptr %31, align 4, !tbaa !9
  %300 = load i32, ptr %23, align 4, !tbaa !9
  %301 = mul nsw i32 %299, %300
  %302 = add nsw i32 %301, 1
  %303 = sext i32 %302 to i64
  %304 = getelementptr inbounds %struct.complex, ptr %298, i64 %303
  call void @ccopy_(ptr noundef %289, ptr noundef %297, ptr noundef @c__1, ptr noundef %304, ptr noundef @c__1)
  br label %305

305:                                              ; preds = %288
  %306 = load i32, ptr %31, align 4, !tbaa !9
  %307 = add nsw i32 %306, 1
  store i32 %307, ptr %31, align 4, !tbaa !9
  br label %284, !llvm.loop !15

308:                                              ; preds = %284
  %309 = load i32, ptr %30, align 4, !tbaa !9
  %310 = sitofp i32 %309 to float
  %311 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 0
  store float %310, ptr %311, align 4, !tbaa !11
  %312 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 1
  store float 0.000000e+00, ptr %312, align 4, !tbaa !14
  %313 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 0
  %314 = load float, ptr %313, align 4, !tbaa !11
  %315 = load ptr, ptr %20, align 8, !tbaa !5
  %316 = getelementptr inbounds %struct.complex, ptr %315, i64 1
  %317 = getelementptr inbounds %struct.complex, ptr %316, i32 0, i32 0
  store float %314, ptr %317, align 4, !tbaa !11
  %318 = getelementptr inbounds %struct.complex, ptr %29, i32 0, i32 1
  %319 = load float, ptr %318, align 4, !tbaa !14
  %320 = load ptr, ptr %20, align 8, !tbaa !5
  %321 = getelementptr inbounds %struct.complex, ptr %320, i64 1
  %322 = getelementptr inbounds %struct.complex, ptr %321, i32 0, i32 1
  store float %319, ptr %322, align 4, !tbaa !14
  store i32 1, ptr %38, align 4
  br label %323

323:                                              ; preds = %308, %241, %210, %202
  call void @llvm.lifetime.end.p0(i64 4, ptr %37) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %35) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %32) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #3
  ret void
}

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

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

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

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

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

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

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

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

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


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

; Function Attrs: nounwind uwtable
define dso_local void @cungtsqr_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr nocapture noundef readonly %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8, ptr nocapture noundef readonly %9, ptr nocapture noundef writeonly %10) local_unnamed_addr #0 {
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %13) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %14) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %15) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %16) #4
  %17 = load i32, ptr %5, align 4, !tbaa !5
  %narrow = xor i32 %17, -1
  %18 = sext i32 %narrow to i64
  %19 = getelementptr inbounds %struct.complex, ptr %4, i64 %18
  %20 = getelementptr inbounds i8, ptr %8, i64 -8
  %21 = load i32, ptr %9, align 4, !tbaa !5
  %22 = icmp eq i32 %21, -1
  store i32 0, ptr %10, align 4, !tbaa !5
  %23 = load i32, ptr %0, align 4, !tbaa !5
  %24 = icmp slt i32 %23, 0
  br i1 %24, label %.thread, label %25

25:                                               ; preds = %11
  %26 = load i32, ptr %1, align 4, !tbaa !5
  %or.cond114 = icmp ugt i32 %26, %23
  br i1 %or.cond114, label %.thread, label %27

27:                                               ; preds = %25
  %28 = load i32, ptr %2, align 4, !tbaa !5
  %.not = icmp sgt i32 %28, %26
  br i1 %.not, label %29, label %.thread

29:                                               ; preds = %27
  %30 = load i32, ptr %3, align 4, !tbaa !5
  %31 = icmp slt i32 %30, 1
  br i1 %31, label %.thread, label %32

32:                                               ; preds = %29
  %33 = load i32, ptr %5, align 4, !tbaa !5
  %spec.select = tail call i32 @llvm.umax.i32(i32 %23, i32 1)
  %34 = icmp slt i32 %33, %spec.select
  br i1 %34, label %.thread, label %35

35:                                               ; preds = %32
  %. = tail call i32 @llvm.umin.i32(i32 %30, i32 %26)
  %36 = load i32, ptr %7, align 4, !tbaa !5
  %37 = tail call i32 @llvm.umax.i32(i32 %., i32 1)
  %38 = icmp slt i32 %36, %37
  br i1 %38, label %.thread, label %39

39:                                               ; preds = %35
  %40 = load i32, ptr %9, align 4, !tbaa !5
  %41 = icmp sgt i32 %40, 1
  %or.cond = select i1 %41, i1 true, i1 %22
  br i1 %or.cond, label %42, label %.thread

42:                                               ; preds = %39
  store i32 %., ptr %16, align 4, !tbaa !5
  store i32 %23, ptr %15, align 4, !tbaa !5
  %43 = mul nsw i32 %26, %23
  %44 = mul nsw i32 %., %26
  store i32 %44, ptr %14, align 4, !tbaa !5
  %45 = add nuw nsw i32 %44, %43
  %46 = tail call i32 @llvm.umax.i32(i32 %45, i32 1)
  %47 = icmp sge i32 %40, %46
  %or.cond3 = select i1 %47, i1 true, i1 %22
  br i1 %or.cond3, label %49, label %.thread

.thread:                                          ; preds = %42, %39, %35, %32, %29, %27, %25, %11
  %.sink = phi i32 [ -1, %11 ], [ -2, %25 ], [ -3, %27 ], [ -4, %29 ], [ -6, %32 ], [ -8, %35 ], [ -10, %39 ], [ -10, %42 ]
  %.neg = phi i32 [ 1, %11 ], [ 2, %25 ], [ 3, %27 ], [ 4, %29 ], [ 6, %32 ], [ 8, %35 ], [ 10, %39 ], [ 10, %42 ]
  store i32 %.sink, ptr %10, align 4, !tbaa !5
  store i32 %.neg, ptr %12, align 4, !tbaa !5
  %48 = call i32 @xerbla_(ptr noundef nonnull @.str, ptr noundef nonnull %12, i32 noundef 8) #4
  br label %73

49:                                               ; preds = %42
  br i1 %22, label %50, label %53

50:                                               ; preds = %49
  %51 = uitofp nneg i32 %45 to float
  store float %51, ptr %8, align 4, !tbaa !9
  %52 = getelementptr inbounds i8, ptr %8, i64 4
  store float 0.000000e+00, ptr %52, align 4, !tbaa !12
  br label %73

53:                                               ; preds = %49
  %54 = tail call i32 @llvm.umin.i32(i32 %23, i32 %26)
  %55 = icmp eq i32 %54, 0
  br i1 %55, label %56, label %59

56:                                               ; preds = %53
  %57 = uitofp nneg i32 %45 to float
  store float %57, ptr %8, align 4, !tbaa !9
  %58 = getelementptr inbounds i8, ptr %8, i64 4
  store float 0.000000e+00, ptr %58, align 4, !tbaa !12
  br label %73

59:                                               ; preds = %53
  call void @claset_(ptr noundef nonnull @.str.1, ptr noundef nonnull %0, ptr noundef nonnull %1, ptr noundef nonnull @c_b2, ptr noundef nonnull @c_b1, ptr noundef %8, ptr noundef nonnull %15) #4
  %60 = zext nneg i32 %43 to i64
  %61 = getelementptr %struct.complex, ptr %20, i64 %60
  %62 = getelementptr i8, ptr %61, i64 8
  call void @clamtsqr_(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.3, ptr noundef nonnull %0, ptr noundef nonnull %1, ptr noundef nonnull %1, ptr noundef nonnull %2, ptr noundef nonnull %16, ptr noundef %4, ptr noundef nonnull %5, ptr noundef %6, ptr noundef nonnull %7, ptr noundef %8, ptr noundef nonnull %15, ptr noundef %62, ptr noundef nonnull %14, ptr noundef nonnull %13) #4
  %63 = load i32, ptr %1, align 4, !tbaa !5
  %invariant.gep120 = getelementptr i8, ptr %19, i64 8
  %.not113122 = icmp slt i32 %63, 1
  br i1 %.not113122, label %._crit_edge, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %59
  %64 = sext i32 %17 to i64
  %65 = zext nneg i32 %63 to i64
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 1, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %66 = add nsw i64 %indvars.iv, -1
  %67 = load i32, ptr %15, align 4, !tbaa !5
  %68 = sext i32 %67 to i64
  %69 = mul nsw i64 %66, %68
  %gep = getelementptr %struct.complex, ptr %8, i64 %69
  %70 = mul nsw i64 %indvars.iv, %64
  %gep121 = getelementptr %struct.complex, ptr %invariant.gep120, i64 %70
  call void @ccopy_(ptr noundef nonnull %0, ptr noundef %gep, ptr noundef nonnull @c__1, ptr noundef %gep121, ptr noundef nonnull @c__1) #4
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %.not113.not = icmp ult i64 %indvars.iv, %65
  br i1 %.not113.not, label %.lr.ph, label %._crit_edge, !llvm.loop !13

._crit_edge:                                      ; preds = %.lr.ph, %59
  %71 = sitofp i32 %45 to float
  store float %71, ptr %8, align 4, !tbaa !9
  %72 = getelementptr inbounds i8, ptr %8, i64 4
  store float 0.000000e+00, ptr %72, align 4, !tbaa !12
  br label %73

73:                                               ; preds = %._crit_edge, %56, %50, %.thread
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %16) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %14) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #4
  ret void
}

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

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

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

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

declare void @ccopy_(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 i32 @llvm.umax.i32(i32, i32) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umin.i32(i32, i32) #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 = !{!"int", !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 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}


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