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

; 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 [7 x i8], align 1
@c__1 = external hidden global i32, align 4
@c_n1 = external hidden global i32, align 4

; Function Attrs: nounwind uwtable
define dso_local void @cgttrs_(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 i32, align 4
  %30 = alloca i32, align 4
  %31 = alloca i32, align 4
  %32 = alloca i32, align 4
  %33 = 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 4, 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
  %34 = load ptr, ptr %15, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.complex, ptr %34, i32 -1
  store ptr %35, ptr %15, align 8, !tbaa !5
  %36 = load ptr, ptr %16, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.complex, ptr %36, i32 -1
  store ptr %37, ptr %16, align 8, !tbaa !5
  %38 = load ptr, ptr %17, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.complex, ptr %38, i32 -1
  store ptr %39, ptr %17, align 8, !tbaa !5
  %40 = load ptr, ptr %18, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.complex, ptr %40, i32 -1
  store ptr %41, ptr %18, align 8, !tbaa !5
  %42 = load ptr, ptr %19, align 8, !tbaa !5
  %43 = getelementptr inbounds i32, ptr %42, i32 -1
  store ptr %43, ptr %19, align 8, !tbaa !5
  %44 = load ptr, ptr %21, align 8, !tbaa !5
  %45 = load i32, ptr %44, align 4, !tbaa !9
  store i32 %45, ptr %23, align 4, !tbaa !9
  %46 = load i32, ptr %23, align 4, !tbaa !9
  %47 = mul nsw i32 %46, 1
  %48 = add nsw i32 1, %47
  store i32 %48, ptr %24, align 4, !tbaa !9
  %49 = load i32, ptr %24, align 4, !tbaa !9
  %50 = load ptr, ptr %20, align 8, !tbaa !5
  %51 = sext i32 %49 to i64
  %52 = sub i64 0, %51
  %53 = getelementptr inbounds %struct.complex, ptr %50, i64 %52
  store ptr %53, ptr %20, align 8, !tbaa !5
  %54 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 0, ptr %54, align 4, !tbaa !9
  %55 = load ptr, ptr %12, align 8, !tbaa !5
  %56 = load i8, ptr %55, align 1, !tbaa !11
  %57 = zext i8 %56 to i32
  %58 = icmp eq i32 %57, 78
  br i1 %58, label %64, label %59

59:                                               ; preds = %11
  %60 = load ptr, ptr %12, align 8, !tbaa !5
  %61 = load i8, ptr %60, align 1, !tbaa !11
  %62 = zext i8 %61 to i32
  %63 = icmp eq i32 %62, 110
  br label %64

64:                                               ; preds = %59, %11
  %65 = phi i1 [ true, %11 ], [ %63, %59 ]
  %66 = zext i1 %65 to i32
  store i32 %66, ptr %32, align 4, !tbaa !9
  %67 = load i32, ptr %32, align 4, !tbaa !9
  %68 = icmp ne i32 %67, 0
  br i1 %68, label %91, label %69

69:                                               ; preds = %64
  %70 = load ptr, ptr %12, align 8, !tbaa !5
  %71 = load i8, ptr %70, align 1, !tbaa !11
  %72 = zext i8 %71 to i32
  %73 = icmp eq i32 %72, 84
  br i1 %73, label %91, label %74

74:                                               ; preds = %69
  %75 = load ptr, ptr %12, align 8, !tbaa !5
  %76 = load i8, ptr %75, align 1, !tbaa !11
  %77 = zext i8 %76 to i32
  %78 = icmp eq i32 %77, 116
  br i1 %78, label %91, label %79

79:                                               ; preds = %74
  %80 = load ptr, ptr %12, align 8, !tbaa !5
  %81 = load i8, ptr %80, align 1, !tbaa !11
  %82 = zext i8 %81 to i32
  %83 = icmp eq i32 %82, 67
  br i1 %83, label %91, label %84

84:                                               ; preds = %79
  %85 = load ptr, ptr %12, align 8, !tbaa !5
  %86 = load i8, ptr %85, align 1, !tbaa !11
  %87 = zext i8 %86 to i32
  %88 = icmp eq i32 %87, 99
  br i1 %88, label %91, label %89

89:                                               ; preds = %84
  %90 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -1, ptr %90, align 4, !tbaa !9
  br label %121

91:                                               ; preds = %84, %79, %74, %69, %64
  %92 = load ptr, ptr %13, align 8, !tbaa !5
  %93 = load i32, ptr %92, align 4, !tbaa !9
  %94 = icmp slt i32 %93, 0
  br i1 %94, label %95, label %97

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

97:                                               ; preds = %91
  %98 = load ptr, ptr %14, align 8, !tbaa !5
  %99 = load i32, ptr %98, align 4, !tbaa !9
  %100 = icmp slt i32 %99, 0
  br i1 %100, label %101, label %103

101:                                              ; preds = %97
  %102 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -3, ptr %102, align 4, !tbaa !9
  br label %119

103:                                              ; preds = %97
  %104 = load ptr, ptr %21, align 8, !tbaa !5
  %105 = load i32, ptr %104, align 4, !tbaa !9
  %106 = load ptr, ptr %13, align 8, !tbaa !5
  %107 = load i32, ptr %106, align 4, !tbaa !9
  %108 = icmp sge i32 %107, 1
  br i1 %108, label %109, label %112

109:                                              ; preds = %103
  %110 = load ptr, ptr %13, align 8, !tbaa !5
  %111 = load i32, ptr %110, align 4, !tbaa !9
  br label %113

112:                                              ; preds = %103
  br label %113

113:                                              ; preds = %112, %109
  %114 = phi i32 [ %111, %109 ], [ 1, %112 ]
  %115 = icmp slt i32 %105, %114
  br i1 %115, label %116, label %118

116:                                              ; preds = %113
  %117 = load ptr, ptr %22, align 8, !tbaa !5
  store i32 -10, ptr %117, align 4, !tbaa !9
  br label %118

118:                                              ; preds = %116, %113
  br label %119

119:                                              ; preds = %118, %101
  br label %120

120:                                              ; preds = %119, %95
  br label %121

121:                                              ; preds = %120, %89
  %122 = load ptr, ptr %22, align 8, !tbaa !5
  %123 = load i32, ptr %122, align 4, !tbaa !9
  %124 = icmp ne i32 %123, 0
  br i1 %124, label %125, label %130

125:                                              ; preds = %121
  %126 = load ptr, ptr %22, align 8, !tbaa !5
  %127 = load i32, ptr %126, align 4, !tbaa !9
  %128 = sub nsw i32 0, %127
  store i32 %128, ptr %25, align 4, !tbaa !9
  %129 = call i32 @xerbla_(ptr noundef @.str, ptr noundef %25, i32 noundef 6)
  store i32 1, ptr %33, align 4
  br label %258

130:                                              ; preds = %121
  %131 = load ptr, ptr %13, align 8, !tbaa !5
  %132 = load i32, ptr %131, align 4, !tbaa !9
  %133 = icmp eq i32 %132, 0
  br i1 %133, label %138, label %134

134:                                              ; preds = %130
  %135 = load ptr, ptr %14, align 8, !tbaa !5
  %136 = load i32, ptr %135, align 4, !tbaa !9
  %137 = icmp eq i32 %136, 0
  br i1 %137, label %138, label %139

138:                                              ; preds = %134, %130
  store i32 1, ptr %33, align 4
  br label %258

139:                                              ; preds = %134
  %140 = load i32, ptr %32, align 4, !tbaa !9
  %141 = icmp ne i32 %140, 0
  br i1 %141, label %142, label %143

142:                                              ; preds = %139
  store i32 0, ptr %31, align 4, !tbaa !9
  br label %156

143:                                              ; preds = %139
  %144 = load ptr, ptr %12, align 8, !tbaa !5
  %145 = load i8, ptr %144, align 1, !tbaa !11
  %146 = zext i8 %145 to i32
  %147 = icmp eq i32 %146, 84
  br i1 %147, label %153, label %148

148:                                              ; preds = %143
  %149 = load ptr, ptr %12, align 8, !tbaa !5
  %150 = load i8, ptr %149, align 1, !tbaa !11
  %151 = zext i8 %150 to i32
  %152 = icmp eq i32 %151, 116
  br i1 %152, label %153, label %154

153:                                              ; preds = %148, %143
  store i32 1, ptr %31, align 4, !tbaa !9
  br label %155

154:                                              ; preds = %148
  store i32 2, ptr %31, align 4, !tbaa !9
  br label %155

155:                                              ; preds = %154, %153
  br label %156

156:                                              ; preds = %155, %142
  %157 = load ptr, ptr %14, align 8, !tbaa !5
  %158 = load i32, ptr %157, align 4, !tbaa !9
  %159 = icmp eq i32 %158, 1
  br i1 %159, label %160, label %161

160:                                              ; preds = %156
  store i32 1, ptr %30, align 4, !tbaa !9
  br label %175

161:                                              ; preds = %156
  store i32 1, ptr %25, align 4, !tbaa !9
  %162 = load ptr, ptr %12, align 8, !tbaa !5
  %163 = load ptr, ptr %13, align 8, !tbaa !5
  %164 = load ptr, ptr %14, align 8, !tbaa !5
  %165 = call i32 @ilaenv_(ptr noundef @c__1, ptr noundef @.str, ptr noundef %162, ptr noundef %163, ptr noundef %164, ptr noundef @c_n1, ptr noundef @c_n1, i32 noundef 6, i32 noundef 1)
  store i32 %165, ptr %26, align 4, !tbaa !9
  %166 = load i32, ptr %25, align 4, !tbaa !9
  %167 = load i32, ptr %26, align 4, !tbaa !9
  %168 = icmp sge i32 %166, %167
  br i1 %168, label %169, label %171

169:                                              ; preds = %161
  %170 = load i32, ptr %25, align 4, !tbaa !9
  br label %173

171:                                              ; preds = %161
  %172 = load i32, ptr %26, align 4, !tbaa !9
  br label %173

173:                                              ; preds = %171, %169
  %174 = phi i32 [ %170, %169 ], [ %172, %171 ]
  store i32 %174, ptr %30, align 4, !tbaa !9
  br label %175

175:                                              ; preds = %173, %160
  %176 = load i32, ptr %30, align 4, !tbaa !9
  %177 = load ptr, ptr %14, align 8, !tbaa !5
  %178 = load i32, ptr %177, align 4, !tbaa !9
  %179 = icmp sge i32 %176, %178
  br i1 %179, label %180, label %198

180:                                              ; preds = %175
  %181 = load ptr, ptr %13, align 8, !tbaa !5
  %182 = load ptr, ptr %14, align 8, !tbaa !5
  %183 = load ptr, ptr %15, align 8, !tbaa !5
  %184 = getelementptr inbounds %struct.complex, ptr %183, i64 1
  %185 = load ptr, ptr %16, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct.complex, ptr %185, i64 1
  %187 = load ptr, ptr %17, align 8, !tbaa !5
  %188 = getelementptr inbounds %struct.complex, ptr %187, i64 1
  %189 = load ptr, ptr %18, align 8, !tbaa !5
  %190 = getelementptr inbounds %struct.complex, ptr %189, i64 1
  %191 = load ptr, ptr %19, align 8, !tbaa !5
  %192 = getelementptr inbounds i32, ptr %191, i64 1
  %193 = load ptr, ptr %20, align 8, !tbaa !5
  %194 = load i32, ptr %24, align 4, !tbaa !9
  %195 = sext i32 %194 to i64
  %196 = getelementptr inbounds %struct.complex, ptr %193, i64 %195
  %197 = load ptr, ptr %21, align 8, !tbaa !5
  call void @cgtts2_(ptr noundef %31, ptr noundef %181, ptr noundef %182, ptr noundef %184, ptr noundef %186, ptr noundef %188, ptr noundef %190, ptr noundef %192, ptr noundef %196, ptr noundef %197)
  br label %257

198:                                              ; preds = %175
  %199 = load ptr, ptr %14, align 8, !tbaa !5
  %200 = load i32, ptr %199, align 4, !tbaa !9
  store i32 %200, ptr %25, align 4, !tbaa !9
  %201 = load i32, ptr %30, align 4, !tbaa !9
  store i32 %201, ptr %26, align 4, !tbaa !9
  store i32 1, ptr %28, align 4, !tbaa !9
  br label %202

202:                                              ; preds = %252, %198
  %203 = load i32, ptr %26, align 4, !tbaa !9
  %204 = icmp slt i32 %203, 0
  br i1 %204, label %205, label %210

205:                                              ; preds = %202
  %206 = load i32, ptr %28, align 4, !tbaa !9
  %207 = load i32, ptr %25, align 4, !tbaa !9
  %208 = icmp sge i32 %206, %207
  %209 = zext i1 %208 to i32
  br label %215

210:                                              ; preds = %202
  %211 = load i32, ptr %28, align 4, !tbaa !9
  %212 = load i32, ptr %25, align 4, !tbaa !9
  %213 = icmp sle i32 %211, %212
  %214 = zext i1 %213 to i32
  br label %215

215:                                              ; preds = %210, %205
  %216 = phi i32 [ %209, %205 ], [ %214, %210 ]
  %217 = icmp ne i32 %216, 0
  br i1 %217, label %218, label %256

218:                                              ; preds = %215
  %219 = load ptr, ptr %14, align 8, !tbaa !5
  %220 = load i32, ptr %219, align 4, !tbaa !9
  %221 = load i32, ptr %28, align 4, !tbaa !9
  %222 = sub nsw i32 %220, %221
  %223 = add nsw i32 %222, 1
  store i32 %223, ptr %27, align 4, !tbaa !9
  %224 = load i32, ptr %27, align 4, !tbaa !9
  %225 = load i32, ptr %30, align 4, !tbaa !9
  %226 = icmp sle i32 %224, %225
  br i1 %226, label %227, label %229

227:                                              ; preds = %218
  %228 = load i32, ptr %27, align 4, !tbaa !9
  br label %231

229:                                              ; preds = %218
  %230 = load i32, ptr %30, align 4, !tbaa !9
  br label %231

231:                                              ; preds = %229, %227
  %232 = phi i32 [ %228, %227 ], [ %230, %229 ]
  store i32 %232, ptr %29, align 4, !tbaa !9
  %233 = load ptr, ptr %13, align 8, !tbaa !5
  %234 = load ptr, ptr %15, align 8, !tbaa !5
  %235 = getelementptr inbounds %struct.complex, ptr %234, i64 1
  %236 = load ptr, ptr %16, align 8, !tbaa !5
  %237 = getelementptr inbounds %struct.complex, ptr %236, i64 1
  %238 = load ptr, ptr %17, align 8, !tbaa !5
  %239 = getelementptr inbounds %struct.complex, ptr %238, i64 1
  %240 = load ptr, ptr %18, align 8, !tbaa !5
  %241 = getelementptr inbounds %struct.complex, ptr %240, i64 1
  %242 = load ptr, ptr %19, align 8, !tbaa !5
  %243 = getelementptr inbounds i32, ptr %242, i64 1
  %244 = load ptr, ptr %20, align 8, !tbaa !5
  %245 = load i32, ptr %28, align 4, !tbaa !9
  %246 = load i32, ptr %23, align 4, !tbaa !9
  %247 = mul nsw i32 %245, %246
  %248 = add nsw i32 %247, 1
  %249 = sext i32 %248 to i64
  %250 = getelementptr inbounds %struct.complex, ptr %244, i64 %249
  %251 = load ptr, ptr %21, align 8, !tbaa !5
  call void @cgtts2_(ptr noundef %31, ptr noundef %233, ptr noundef %29, ptr noundef %235, ptr noundef %237, ptr noundef %239, ptr noundef %241, ptr noundef %243, ptr noundef %250, ptr noundef %251)
  br label %252

252:                                              ; preds = %231
  %253 = load i32, ptr %26, align 4, !tbaa !9
  %254 = load i32, ptr %28, align 4, !tbaa !9
  %255 = add nsw i32 %254, %253
  store i32 %255, ptr %28, align 4, !tbaa !9
  br label %202, !llvm.loop !12

256:                                              ; preds = %215
  br label %257

257:                                              ; preds = %256, %180
  store i32 1, ptr %33, align 4
  br label %258

258:                                              ; preds = %257, %138, %125
  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 4, 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 i32 @ilaenv_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef) #2

declare void @cgtts2_(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 = !{!"int", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"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 [7 x i8], align 1
@c__1 = external hidden global i32, align 4
@c_n1 = external hidden global i32, align 4

; Function Attrs: nounwind uwtable
define dso_local void @cgttrs_(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 nocapture noundef writeonly %10) local_unnamed_addr #0 {
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = 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
  %15 = load i32, ptr %9, align 4, !tbaa !5
  %narrow = xor i32 %15, -1
  %16 = sext i32 %narrow to i64
  %17 = getelementptr inbounds %struct.complex, ptr %8, i64 %16
  store i32 0, ptr %10, align 4, !tbaa !5
  %18 = load i8, ptr %0, align 1, !tbaa !9
  switch i8 %18, label %.thread [
    i8 110, label %19
    i8 78, label %19
    i8 84, label %19
    i8 116, label %19
    i8 67, label %19
    i8 99, label %19
  ]

19:                                               ; preds = %11, %11, %11, %11, %11, %11
  %20 = load i32, ptr %1, align 4, !tbaa !5
  %21 = icmp slt i32 %20, 0
  br i1 %21, label %.thread, label %22

22:                                               ; preds = %19
  %23 = load i32, ptr %2, align 4, !tbaa !5
  %24 = icmp slt i32 %23, 0
  br i1 %24, label %.thread, label %25

25:                                               ; preds = %22
  %26 = load i32, ptr %9, align 4, !tbaa !5
  %spec.select84 = tail call i32 @llvm.umax.i32(i32 %20, i32 1)
  %27 = icmp slt i32 %26, %spec.select84
  br i1 %27, label %.thread, label %29

.thread:                                          ; preds = %25, %22, %19, %11
  %.sink = phi i32 [ -1, %11 ], [ -2, %19 ], [ -3, %22 ], [ -10, %25 ]
  %.neg = phi i32 [ 1, %11 ], [ 2, %19 ], [ 3, %22 ], [ 10, %25 ]
  store i32 %.sink, ptr %10, align 4, !tbaa !5
  store i32 %.neg, ptr %12, align 4, !tbaa !5
  %28 = call i32 @xerbla_(ptr noundef nonnull @.str, ptr noundef nonnull %12, i32 noundef 6) #4
  br label %.loopexit

29:                                               ; preds = %25
  %30 = icmp eq i32 %20, 0
  %31 = icmp eq i32 %23, 0
  %or.cond = or i1 %30, %31
  br i1 %or.cond, label %.loopexit, label %32

32:                                               ; preds = %29
  switch i8 %18, label %35 [
    i8 110, label %33
    i8 78, label %33
    i8 84, label %34
    i8 116, label %34
  ]

33:                                               ; preds = %32, %32
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %36

34:                                               ; preds = %32, %32
  store i32 1, ptr %14, align 4, !tbaa !5
  br label %36

35:                                               ; preds = %32
  store i32 2, ptr %14, align 4, !tbaa !5
  br label %36

36:                                               ; preds = %34, %35, %33
  %37 = icmp eq i32 %23, 1
  br i1 %37, label %.thread89, label %38

38:                                               ; preds = %36
  %39 = tail call i32 @ilaenv_(ptr noundef nonnull @c__1, ptr noundef nonnull @.str, ptr noundef nonnull %0, ptr noundef nonnull %1, ptr noundef nonnull %2, ptr noundef nonnull @c_n1, ptr noundef nonnull @c_n1, i32 noundef 6, i32 noundef 1) #4
  %40 = tail call i32 @llvm.smax.i32(i32 %39, i32 1)
  %.pre = load i32, ptr %2, align 4, !tbaa !5
  %.not82 = icmp slt i32 %40, %.pre
  br i1 %.not82, label %.lr.ph.preheader, label %.thread89

.thread89:                                        ; preds = %36, %38
  call void @cgtts2_(ptr noundef nonnull %14, ptr noundef nonnull %1, ptr noundef nonnull %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8, ptr noundef nonnull %9) #4
  br label %.loopexit

.lr.ph.preheader:                                 ; preds = %38
  %invariant.gep = getelementptr i8, ptr %17, i64 8
  %41 = zext nneg i32 %40 to i64
  %42 = sext i32 %15 to i64
  %43 = zext nneg i32 %.pre 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 ]
  %44 = load i32, ptr %2, align 4, !tbaa !5
  %45 = trunc nuw nsw i64 %indvars.iv to i32
  %reass.sub = sub i32 %44, %45
  %46 = add i32 %reass.sub, 1
  %47 = call i32 @llvm.smin.i32(i32 %46, i32 %40)
  store i32 %47, ptr %13, align 4, !tbaa !5
  %48 = mul nsw i64 %indvars.iv, %42
  %gep = getelementptr %struct.complex, ptr %invariant.gep, i64 %48
  call void @cgtts2_(ptr noundef nonnull %14, ptr noundef nonnull %1, ptr noundef nonnull %13, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %gep, ptr noundef nonnull %9) #4
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, %41
  %.not = icmp ugt i64 %indvars.iv.next, %43
  br i1 %.not, label %.loopexit, label %.lr.ph, !llvm.loop !10

.loopexit:                                        ; preds = %.lr.ph, %.thread89, %29, %.thread
  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 i32 @ilaenv_(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #2

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umax.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 = !{!7, !7, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}


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