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

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

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

55:                                               ; preds = %9
  %56 = load ptr, ptr %10, align 8, !tbaa !5
  %57 = call i32 @lsame_(ptr noundef %56, ptr noundef @.str.1)
  %58 = icmp ne i32 %57, 0
  br i1 %58, label %61, label %59

59:                                               ; preds = %55
  %60 = load ptr, ptr %18, align 8, !tbaa !5
  store i32 -1, ptr %60, align 4, !tbaa !9
  br label %91

61:                                               ; preds = %55, %9
  %62 = load ptr, ptr %11, align 8, !tbaa !5
  %63 = load i32, ptr %62, align 4, !tbaa !9
  %64 = icmp slt i32 %63, 0
  br i1 %64, label %65, label %67

65:                                               ; preds = %61
  %66 = load ptr, ptr %18, align 8, !tbaa !5
  store i32 -2, ptr %66, align 4, !tbaa !9
  br label %90

67:                                               ; preds = %61
  %68 = load ptr, ptr %13, align 8, !tbaa !5
  %69 = load i32, ptr %68, align 4, !tbaa !9
  %70 = load ptr, ptr %11, align 8, !tbaa !5
  %71 = load i32, ptr %70, align 4, !tbaa !9
  %72 = icmp sge i32 1, %71
  br i1 %72, label %73, label %74

73:                                               ; preds = %67
  br label %77

74:                                               ; preds = %67
  %75 = load ptr, ptr %11, align 8, !tbaa !5
  %76 = load i32, ptr %75, align 4, !tbaa !9
  br label %77

77:                                               ; preds = %74, %73
  %78 = phi i32 [ 1, %73 ], [ %76, %74 ]
  %79 = icmp slt i32 %69, %78
  br i1 %79, label %80, label %82

80:                                               ; preds = %77
  %81 = load ptr, ptr %18, align 8, !tbaa !5
  store i32 -4, ptr %81, align 4, !tbaa !9
  br label %89

82:                                               ; preds = %77
  %83 = load ptr, ptr %14, align 8, !tbaa !5
  %84 = load float, ptr %83, align 4, !tbaa !11
  %85 = fcmp olt float %84, 0.000000e+00
  br i1 %85, label %86, label %88

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

88:                                               ; preds = %86, %82
  br label %89

89:                                               ; preds = %88, %80
  br label %90

90:                                               ; preds = %89, %65
  br label %91

91:                                               ; preds = %90, %59
  %92 = load ptr, ptr %18, align 8, !tbaa !5
  %93 = load i32, ptr %92, align 4, !tbaa !9
  %94 = icmp ne i32 %93, 0
  br i1 %94, label %95, label %100

95:                                               ; preds = %91
  %96 = load ptr, ptr %18, align 8, !tbaa !5
  %97 = load i32, ptr %96, align 4, !tbaa !9
  %98 = sub nsw i32 0, %97
  store i32 %98, ptr %21, align 4, !tbaa !9
  %99 = call i32 @xerbla_(ptr noundef @.str.2, ptr noundef %21, i32 noundef 6)
  store i32 1, ptr %34, align 4
  br label %255

100:                                              ; preds = %91
  %101 = load ptr, ptr %15, align 8, !tbaa !5
  store float 0.000000e+00, ptr %101, align 4, !tbaa !11
  %102 = load ptr, ptr %11, align 8, !tbaa !5
  %103 = load i32, ptr %102, align 4, !tbaa !9
  %104 = icmp eq i32 %103, 0
  br i1 %104, label %105, label %107

105:                                              ; preds = %100
  %106 = load ptr, ptr %15, align 8, !tbaa !5
  store float 1.000000e+00, ptr %106, align 4, !tbaa !11
  store i32 1, ptr %34, align 4
  br label %255

107:                                              ; preds = %100
  %108 = load ptr, ptr %14, align 8, !tbaa !5
  %109 = load float, ptr %108, align 4, !tbaa !11
  %110 = fcmp oeq float %109, 0.000000e+00
  br i1 %110, label %111, label %112

111:                                              ; preds = %107
  store i32 1, ptr %34, align 4
  br label %255

112:                                              ; preds = %107
  br label %113

113:                                              ; preds = %112
  %114 = call float @slamch_(ptr noundef @.str.3)
  store float %114, ptr %33, align 4, !tbaa !11
  store i32 0, ptr %24, align 4, !tbaa !9
  %115 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  store i8 78, ptr %115, align 1, !tbaa !13
  br label %116

116:                                              ; preds = %242, %113
  %117 = load ptr, ptr %11, align 8, !tbaa !5
  %118 = load ptr, ptr %16, align 8, !tbaa !5
  %119 = load ptr, ptr %11, align 8, !tbaa !5
  %120 = load i32, ptr %119, align 4, !tbaa !9
  %121 = add nsw i32 %120, 1
  %122 = sext i32 %121 to i64
  %123 = getelementptr inbounds %struct.complex, ptr %118, i64 %122
  %124 = load ptr, ptr %16, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.complex, ptr %124, i64 1
  %126 = getelementptr inbounds [3 x i32], ptr %26, i64 0, i64 0
  call void @clacn2_(ptr noundef %117, ptr noundef %123, ptr noundef %125, ptr noundef %31, ptr noundef %24, ptr noundef %126)
  %127 = load i32, ptr %24, align 4, !tbaa !9
  %128 = icmp ne i32 %127, 0
  br i1 %128, label %129, label %243

129:                                              ; preds = %116
  %130 = load i32, ptr %27, align 4, !tbaa !9
  %131 = icmp ne i32 %130, 0
  br i1 %131, label %132, label %158

132:                                              ; preds = %129
  %133 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  %134 = load ptr, ptr %11, align 8, !tbaa !5
  %135 = load ptr, ptr %12, align 8, !tbaa !5
  %136 = load i32, ptr %20, align 4, !tbaa !9
  %137 = sext i32 %136 to i64
  %138 = getelementptr inbounds %struct.complex, ptr %135, i64 %137
  %139 = load ptr, ptr %13, align 8, !tbaa !5
  %140 = load ptr, ptr %16, align 8, !tbaa !5
  %141 = getelementptr inbounds %struct.complex, ptr %140, i64 1
  %142 = load ptr, ptr %17, align 8, !tbaa !5
  %143 = getelementptr inbounds float, ptr %142, i64 1
  %144 = load ptr, ptr %18, align 8, !tbaa !5
  call void @clatrs_(ptr noundef @.str.4, ptr noundef @.str.5, ptr noundef @.str.6, ptr noundef %133, ptr noundef %134, ptr noundef %138, ptr noundef %139, ptr noundef %141, ptr noundef %29, ptr noundef %143, ptr noundef %144)
  %145 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  store i8 89, ptr %145, align 1, !tbaa !13
  %146 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  %147 = load ptr, ptr %11, align 8, !tbaa !5
  %148 = load ptr, ptr %12, align 8, !tbaa !5
  %149 = load i32, ptr %20, align 4, !tbaa !9
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds %struct.complex, ptr %148, i64 %150
  %152 = load ptr, ptr %13, align 8, !tbaa !5
  %153 = load ptr, ptr %16, align 8, !tbaa !5
  %154 = getelementptr inbounds %struct.complex, ptr %153, i64 1
  %155 = load ptr, ptr %17, align 8, !tbaa !5
  %156 = getelementptr inbounds float, ptr %155, i64 1
  %157 = load ptr, ptr %18, align 8, !tbaa !5
  call void @clatrs_(ptr noundef @.str.4, ptr noundef @.str.7, ptr noundef @.str.6, ptr noundef %146, ptr noundef %147, ptr noundef %151, ptr noundef %152, ptr noundef %154, ptr noundef %30, ptr noundef %156, ptr noundef %157)
  br label %184

158:                                              ; preds = %129
  %159 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  %160 = load ptr, ptr %11, align 8, !tbaa !5
  %161 = load ptr, ptr %12, align 8, !tbaa !5
  %162 = load i32, ptr %20, align 4, !tbaa !9
  %163 = sext i32 %162 to i64
  %164 = getelementptr inbounds %struct.complex, ptr %161, i64 %163
  %165 = load ptr, ptr %13, align 8, !tbaa !5
  %166 = load ptr, ptr %16, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.complex, ptr %166, i64 1
  %168 = load ptr, ptr %17, align 8, !tbaa !5
  %169 = getelementptr inbounds float, ptr %168, i64 1
  %170 = load ptr, ptr %18, align 8, !tbaa !5
  call void @clatrs_(ptr noundef @.str.8, ptr noundef @.str.7, ptr noundef @.str.6, ptr noundef %159, ptr noundef %160, ptr noundef %164, ptr noundef %165, ptr noundef %167, ptr noundef %29, ptr noundef %169, ptr noundef %170)
  %171 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  store i8 89, ptr %171, align 1, !tbaa !13
  %172 = getelementptr inbounds [1 x i8], ptr %32, i64 0, i64 0
  %173 = load ptr, ptr %11, align 8, !tbaa !5
  %174 = load ptr, ptr %12, align 8, !tbaa !5
  %175 = load i32, ptr %20, align 4, !tbaa !9
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds %struct.complex, ptr %174, i64 %176
  %178 = load ptr, ptr %13, align 8, !tbaa !5
  %179 = load ptr, ptr %16, align 8, !tbaa !5
  %180 = getelementptr inbounds %struct.complex, ptr %179, i64 1
  %181 = load ptr, ptr %17, align 8, !tbaa !5
  %182 = getelementptr inbounds float, ptr %181, i64 1
  %183 = load ptr, ptr %18, align 8, !tbaa !5
  call void @clatrs_(ptr noundef @.str.8, ptr noundef @.str.5, ptr noundef @.str.6, ptr noundef %172, ptr noundef %173, ptr noundef %177, ptr noundef %178, ptr noundef %180, ptr noundef %30, ptr noundef %182, ptr noundef %183)
  br label %184

184:                                              ; preds = %158, %132
  %185 = load float, ptr %29, align 4, !tbaa !11
  %186 = load float, ptr %30, align 4, !tbaa !11
  %187 = fmul float %185, %186
  store float %187, ptr %25, align 4, !tbaa !11
  %188 = load float, ptr %25, align 4, !tbaa !11
  %189 = fcmp une float %188, 1.000000e+00
  br i1 %189, label %190, label %242

190:                                              ; preds = %184
  %191 = load ptr, ptr %11, align 8, !tbaa !5
  %192 = load ptr, ptr %16, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.complex, ptr %192, i64 1
  %194 = call i32 @icamax_(ptr noundef %191, ptr noundef %193, ptr noundef @c__1)
  store i32 %194, ptr %28, align 4, !tbaa !9
  %195 = load i32, ptr %28, align 4, !tbaa !9
  store i32 %195, ptr %21, align 4, !tbaa !9
  %196 = load float, ptr %25, align 4, !tbaa !11
  %197 = load ptr, ptr %16, align 8, !tbaa !5
  %198 = load i32, ptr %21, align 4, !tbaa !9
  %199 = sext i32 %198 to i64
  %200 = getelementptr inbounds %struct.complex, ptr %197, i64 %199
  %201 = getelementptr inbounds %struct.complex, ptr %200, i32 0, i32 0
  %202 = load float, ptr %201, align 4, !tbaa !14
  store float %202, ptr %22, align 4, !tbaa !11
  %203 = load float, ptr %22, align 4, !tbaa !11
  %204 = fcmp oge float %203, 0.000000e+00
  br i1 %204, label %205, label %207

205:                                              ; preds = %190
  %206 = load float, ptr %22, align 4, !tbaa !11
  br label %210

207:                                              ; preds = %190
  %208 = load float, ptr %22, align 4, !tbaa !11
  %209 = fneg float %208
  br label %210

210:                                              ; preds = %207, %205
  %211 = phi float [ %206, %205 ], [ %209, %207 ]
  %212 = load ptr, ptr %16, align 8, !tbaa !5
  %213 = load i32, ptr %28, align 4, !tbaa !9
  %214 = sext i32 %213 to i64
  %215 = getelementptr inbounds %struct.complex, ptr %212, i64 %214
  %216 = call <2 x float> @Cf(ptr noundef %215)
  store <2 x float> %216, ptr %35, align 4
  %217 = getelementptr inbounds { float, float }, ptr %35, i32 0, i32 0
  %218 = load float, ptr %217, align 4
  %219 = getelementptr inbounds { float, float }, ptr %35, i32 0, i32 1
  %220 = load float, ptr %219, align 4
  store float %220, ptr %23, align 4, !tbaa !11
  %221 = load float, ptr %23, align 4, !tbaa !11
  %222 = fcmp oge float %221, 0.000000e+00
  br i1 %222, label %223, label %225

223:                                              ; preds = %210
  %224 = load float, ptr %23, align 4, !tbaa !11
  br label %228

225:                                              ; preds = %210
  %226 = load float, ptr %23, align 4, !tbaa !11
  %227 = fneg float %226
  br label %228

228:                                              ; preds = %225, %223
  %229 = phi float [ %224, %223 ], [ %227, %225 ]
  %230 = fadd float %211, %229
  %231 = load float, ptr %33, align 4, !tbaa !11
  %232 = fmul float %230, %231
  %233 = fcmp olt float %196, %232
  br i1 %233, label %237, label %234

234:                                              ; preds = %228
  %235 = load float, ptr %25, align 4, !tbaa !11
  %236 = fcmp oeq float %235, 0.000000e+00
  br i1 %236, label %237, label %238

237:                                              ; preds = %234, %228
  br label %254

238:                                              ; preds = %234
  %239 = load ptr, ptr %11, align 8, !tbaa !5
  %240 = load ptr, ptr %16, align 8, !tbaa !5
  %241 = getelementptr inbounds %struct.complex, ptr %240, i64 1
  call void @csrscl_(ptr noundef %239, ptr noundef %25, ptr noundef %241, ptr noundef @c__1)
  br label %242

242:                                              ; preds = %238, %184
  br label %116

243:                                              ; preds = %116
  %244 = load float, ptr %31, align 4, !tbaa !11
  %245 = fcmp une float %244, 0.000000e+00
  br i1 %245, label %246, label %253

246:                                              ; preds = %243
  %247 = load float, ptr %31, align 4, !tbaa !11
  %248 = fdiv float 1.000000e+00, %247
  %249 = load ptr, ptr %14, align 8, !tbaa !5
  %250 = load float, ptr %249, align 4, !tbaa !11
  %251 = fdiv float %248, %250
  %252 = load ptr, ptr %15, align 8, !tbaa !5
  store float %251, ptr %252, align 4, !tbaa !11
  br label %253

253:                                              ; preds = %246, %243
  br label %254

254:                                              ; preds = %253, %237
  store i32 1, ptr %34, align 4
  br label %255

255:                                              ; preds = %254, %111, %105, %95
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %32) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #4
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #4
  ret void
}

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

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

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

declare float @slamch_(ptr noundef) #2

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

declare void @clatrs_(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 @icamax_(ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden <2 x float> @Cf(ptr noundef) #3

declare void @csrscl_(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"="64" "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 = { inlinehint nounwind uwtable "min-legal-vector-width"="64" "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 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = !{!7, !7, i64 0}
!14 = !{!15, !12, i64 0}
!15 = !{!"", !12, i64 0, !12, i64 4}


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

; Function Attrs: nounwind uwtable
define dso_local void @cpocon_(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr nocapture noundef readonly %4, ptr nocapture noundef writeonly %5, ptr noundef %6, ptr noundef %7, ptr noundef %8) local_unnamed_addr #0 {
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca float, align 4
  %13 = alloca [3 x i32], align 4
  %14 = alloca float, align 4
  %15 = alloca float, align 4
  %16 = alloca float, align 4
  %17 = alloca [1 x i8], align 1
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #5
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %13) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %14) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %15) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %16) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %17) #5
  %18 = getelementptr inbounds i8, ptr %6, i64 -8
  store i32 0, ptr %8, align 4, !tbaa !5
  %19 = tail call i32 @lsame_(ptr noundef %0, ptr noundef nonnull @.str) #5
  %.not = icmp eq i32 %19, 0
  br i1 %.not, label %20, label %22

20:                                               ; preds = %9
  %21 = tail call i32 @lsame_(ptr noundef %0, ptr noundef nonnull @.str.1) #5
  %.not77 = icmp eq i32 %21, 0
  br i1 %.not77, label %.thread.sink.split, label %22

22:                                               ; preds = %20, %9
  %23 = load i32, ptr %1, align 4, !tbaa !5
  %24 = icmp slt i32 %23, 0
  br i1 %24, label %.thread.sink.split, label %25

25:                                               ; preds = %22
  %26 = load i32, ptr %3, align 4, !tbaa !5
  %spec.select = tail call i32 @llvm.umax.i32(i32 %23, i32 1)
  %27 = icmp slt i32 %26, %spec.select
  br i1 %27, label %.thread.sink.split, label %28

28:                                               ; preds = %25
  %29 = load float, ptr %4, align 4, !tbaa !9
  %30 = fcmp olt float %29, 0.000000e+00
  br i1 %30, label %.thread.sink.split, label %31

31:                                               ; preds = %28
  %.pr = load i32, ptr %8, align 4, !tbaa !5
  %.not78 = icmp eq i32 %.pr, 0
  br i1 %.not78, label %35, label %.thread

.thread.sink.split:                               ; preds = %28, %25, %22, %20
  %.sink = phi i32 [ -1, %20 ], [ -2, %22 ], [ -4, %25 ], [ -5, %28 ]
  store i32 %.sink, ptr %8, align 4, !tbaa !5
  br label %.thread

.thread:                                          ; preds = %.thread.sink.split, %31
  %32 = phi i32 [ %.pr, %31 ], [ %.sink, %.thread.sink.split ]
  %33 = sub nsw i32 0, %32
  store i32 %33, ptr %10, align 4, !tbaa !5
  %34 = call i32 @xerbla_(ptr noundef nonnull @.str.2, ptr noundef nonnull %10, i32 noundef 6) #5
  br label %.loopexit

35:                                               ; preds = %31
  store float 0.000000e+00, ptr %5, align 4, !tbaa !9
  %36 = icmp eq i32 %23, 0
  br i1 %36, label %37, label %38

37:                                               ; preds = %35
  store float 1.000000e+00, ptr %5, align 4, !tbaa !9
  br label %.loopexit

38:                                               ; preds = %35
  %39 = load float, ptr %4, align 4, !tbaa !9
  %40 = fcmp oeq float %39, 0.000000e+00
  br i1 %40, label %.loopexit, label %41

41:                                               ; preds = %38
  %42 = tail call float @slamch_(ptr noundef nonnull @.str.3) #5
  store i32 0, ptr %11, align 4, !tbaa !5
  store i8 78, ptr %17, align 1, !tbaa !11
  %43 = load i32, ptr %1, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %gep81 = getelementptr %struct.complex, ptr %6, i64 %44
  call void @clacn2_(ptr noundef nonnull %1, ptr noundef %gep81, ptr noundef %6, ptr noundef nonnull %16, ptr noundef nonnull %11, ptr noundef nonnull %13) #5
  %45 = load i32, ptr %11, align 4, !tbaa !5
  %.not7982 = icmp eq i32 %45, 0
  br i1 %.not7982, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %41, %72
  br i1 %.not, label %47, label %46

46:                                               ; preds = %.lr.ph
  call void @clatrs_(ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.6, ptr noundef nonnull %17, ptr noundef nonnull %1, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %6, ptr noundef nonnull %14, ptr noundef %7, ptr noundef nonnull %8) #5
  store i8 89, ptr %17, align 1, !tbaa !11
  call void @clatrs_(ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.7, ptr noundef nonnull @.str.6, ptr noundef nonnull %17, ptr noundef nonnull %1, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %6, ptr noundef nonnull %15, ptr noundef %7, ptr noundef nonnull %8) #5
  br label %48

47:                                               ; preds = %.lr.ph
  call void @clatrs_(ptr noundef nonnull @.str.8, ptr noundef nonnull @.str.7, ptr noundef nonnull @.str.6, ptr noundef nonnull %17, ptr noundef nonnull %1, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %6, ptr noundef nonnull %14, ptr noundef %7, ptr noundef nonnull %8) #5
  store i8 89, ptr %17, align 1, !tbaa !11
  call void @clatrs_(ptr noundef nonnull @.str.8, ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.6, ptr noundef nonnull %17, ptr noundef nonnull %1, ptr noundef %2, ptr noundef nonnull %3, ptr noundef %6, ptr noundef nonnull %15, ptr noundef %7, ptr noundef nonnull %8) #5
  br label %48

48:                                               ; preds = %47, %46
  %49 = load float, ptr %14, align 4, !tbaa !9
  %50 = load float, ptr %15, align 4, !tbaa !9
  %51 = fmul float %49, %50
  store float %51, ptr %12, align 4, !tbaa !9
  %52 = fcmp une float %51, 1.000000e+00
  br i1 %52, label %53, label %72

53:                                               ; preds = %48
  %54 = call i32 @icamax_(ptr noundef nonnull %1, ptr noundef %6, ptr noundef nonnull @c__1) #5
  %55 = load float, ptr %12, align 4, !tbaa !9
  %56 = sext i32 %54 to i64
  %57 = getelementptr inbounds %struct.complex, ptr %18, i64 %56
  %58 = load float, ptr %57, align 4, !tbaa !12
  %59 = fcmp oge float %58, 0.000000e+00
  %60 = fneg float %58
  %61 = select i1 %59, float %58, float %60
  %62 = call <2 x float> @Cf(ptr noundef nonnull %57)
  %.sroa.0.4.vec.extract = extractelement <2 x float> %62, i64 1
  %63 = fcmp oge float %.sroa.0.4.vec.extract, 0.000000e+00
  %64 = fneg float %.sroa.0.4.vec.extract
  %65 = select i1 %63, float %.sroa.0.4.vec.extract, float %64
  %66 = fadd float %61, %65
  %67 = fmul float %42, %66
  %68 = fcmp olt float %55, %67
  %69 = load float, ptr %12, align 4
  %70 = fcmp oeq float %69, 0.000000e+00
  %or.cond = select i1 %68, i1 true, i1 %70
  br i1 %or.cond, label %.loopexit, label %71

71:                                               ; preds = %53
  call void @csrscl_(ptr noundef nonnull %1, ptr noundef nonnull %12, ptr noundef nonnull %6, ptr noundef nonnull @c__1) #5
  br label %72

72:                                               ; preds = %71, %48
  %73 = load i32, ptr %1, align 4, !tbaa !5
  %74 = sext i32 %73 to i64
  %gep = getelementptr %struct.complex, ptr %6, i64 %74
  call void @clacn2_(ptr noundef nonnull %1, ptr noundef %gep, ptr noundef %6, ptr noundef nonnull %16, ptr noundef nonnull %11, ptr noundef nonnull %13) #5
  %75 = load i32, ptr %11, align 4, !tbaa !5
  %.not79 = icmp eq i32 %75, 0
  br i1 %.not79, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %72, %41
  %76 = load float, ptr %16, align 4, !tbaa !9
  %77 = fcmp une float %76, 0.000000e+00
  br i1 %77, label %78, label %.loopexit

78:                                               ; preds = %._crit_edge
  %79 = fdiv float 1.000000e+00, %76
  %80 = load float, ptr %4, align 4, !tbaa !9
  %81 = fdiv float %79, %80
  store float %81, ptr %5, align 4, !tbaa !9
  br label %.loopexit

.loopexit:                                        ; preds = %53, %78, %._crit_edge, %38, %37, %.thread
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %16) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %13) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  ret void
}

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

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

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

declare float @slamch_(ptr noundef) local_unnamed_addr #2

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

declare void @clatrs_(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 @icamax_(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden <2 x float> @Cf(ptr noundef) local_unnamed_addr #3

declare void @csrscl_(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) #4

attributes #0 = { nounwind uwtable "min-legal-vector-width"="64" "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 = { inlinehint nounwind uwtable "min-legal-vector-width"="64" "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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { 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, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !10, i64 0}
!13 = !{!"", !10, i64 0, !10, i64 4}


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