; LLVM IR from tangjz/acm-icpc :: lydsy (4624)

; 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 { x86_fp80, x86_fp80 }

@X1 = external dso_local global [524288 x %struct.complex], align 16
@X2 = external dso_local global [524288 x %struct.complex], align 16
@Y1 = external dso_local global [524288 x %struct.complex], align 16
@Y2 = external dso_local global [524288 x %struct.complex], align 16
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@tt = external dso_local global i32, align 4
@p = external dso_local global i32, align 4
@q = external dso_local global i32, align 4
@slen = external dso_local global i32, align 4
@tlen = external dso_local global i32, align 4
@len = external dso_local global i32, align 4
@s = external dso_local global [251001 x i8], align 16
@t = external dso_local global [251001 x i8], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [23 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3FFTP7complexii(ptr noundef, i32 noundef, i32 noundef) #0

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32), x86_fp80 noundef, x86_fp80 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZmlRK7complexS1_(ptr dead_on_unwind noalias writable sret(%struct.complex) align 16, ptr noundef nonnull align 16 dereferenceable(32), ptr noundef nonnull align 16 dereferenceable(32)) #0

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #4 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca %struct.complex, align 16
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca %struct.complex, align 16
  %11 = alloca i32, align 4
  %12 = alloca %struct.complex, align 16
  %13 = alloca i32, align 4
  %14 = alloca %struct.complex, align 16
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca %struct.complex, align 16
  %18 = alloca i32, align 4
  %19 = alloca %struct.complex, align 16
  %20 = alloca i32, align 4
  %21 = alloca %struct.complex, align 16
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %27 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n, ptr noundef @m)
  %28 = load i32, ptr @n, align 4, !tbaa !5
  %29 = load i32, ptr @m, align 4, !tbaa !5
  %30 = mul nsw i32 %28, %29
  store i32 %30, ptr @slen, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #7
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %31

31:                                               ; preds = %43, %0
  %32 = load i32, ptr %2, align 4, !tbaa !5
  %33 = load i32, ptr @n, align 4, !tbaa !5
  %34 = icmp slt i32 %32, %33
  br i1 %34, label %36, label %35

35:                                               ; preds = %31
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #7
  br label %46

36:                                               ; preds = %31
  %37 = load i32, ptr %2, align 4, !tbaa !5
  %38 = load i32, ptr @m, align 4, !tbaa !5
  %39 = mul nsw i32 %37, %38
  %40 = sext i32 %39 to i64
  %41 = getelementptr inbounds i8, ptr @s, i64 %40
  %42 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.5, ptr noundef %41)
  br label %43

43:                                               ; preds = %36
  %44 = load i32, ptr %2, align 4, !tbaa !5
  %45 = add nsw i32 %44, 1
  store i32 %45, ptr %2, align 4, !tbaa !5
  br label %31, !llvm.loop !9

46:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #7
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %47

47:                                               ; preds = %69, %46
  %48 = load i32, ptr %3, align 4, !tbaa !5
  %49 = load i32, ptr @slen, align 4, !tbaa !5
  %50 = icmp slt i32 %48, %49
  br i1 %50, label %52, label %51

51:                                               ; preds = %47
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #7
  br label %72

52:                                               ; preds = %47
  call void @llvm.lifetime.start.p0(i64 32, ptr %4) #7
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %4, x86_fp80 noundef 0xK3FFF8000000000000000, x86_fp80 noundef 0xK00000000000000000000)
  %53 = load i32, ptr %3, align 4, !tbaa !5
  %54 = sext i32 %53 to i64
  %55 = getelementptr inbounds [251001 x i8], ptr @s, i64 0, i64 %54
  %56 = load i8, ptr %55, align 1, !tbaa !11
  %57 = sext i8 %56 to i32
  %58 = icmp eq i32 %57, 71
  br i1 %58, label %59, label %63

59:                                               ; preds = %52
  %60 = load i32, ptr %3, align 4, !tbaa !5
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [524288 x %struct.complex], ptr @X1, i64 0, i64 %61
  br label %67

63:                                               ; preds = %52
  %64 = load i32, ptr %3, align 4, !tbaa !5
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [524288 x %struct.complex], ptr @X2, i64 0, i64 %65
  br label %67

67:                                               ; preds = %63, %59
  %68 = phi ptr [ %62, %59 ], [ %66, %63 ]
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %68, ptr align 16 %4, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %4) #7
  br label %69

69:                                               ; preds = %67
  %70 = load i32, ptr %3, align 4, !tbaa !5
  %71 = add nsw i32 %70, 1
  store i32 %71, ptr %3, align 4, !tbaa !5
  br label %47, !llvm.loop !15

72:                                               ; preds = %51
  store i32 1, ptr @len, align 4, !tbaa !5
  br label %73

73:                                               ; preds = %79, %72
  %74 = load i32, ptr @len, align 4, !tbaa !5
  %75 = load i32, ptr @slen, align 4, !tbaa !5
  %76 = shl i32 %75, 1
  %77 = icmp slt i32 %74, %76
  br i1 %77, label %78, label %82

78:                                               ; preds = %73
  br label %79

79:                                               ; preds = %78
  %80 = load i32, ptr @len, align 4, !tbaa !5
  %81 = shl i32 %80, 1
  store i32 %81, ptr @len, align 4, !tbaa !5
  br label %73, !llvm.loop !16

82:                                               ; preds = %73
  %83 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef @X1, i32 noundef %83, i32 noundef 1)
  %84 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef @X2, i32 noundef %84, i32 noundef 1)
  %85 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.6, ptr noundef @tt)
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #7
  store i32 1, ptr %5, align 4, !tbaa !5
  br label %86

86:                                               ; preds = %344, %82
  %87 = load i32, ptr %5, align 4, !tbaa !5
  %88 = load i32, ptr @tt, align 4, !tbaa !5
  %89 = icmp sle i32 %87, %88
  br i1 %89, label %91, label %90

90:                                               ; preds = %86
  store i32 11, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #7
  br label %347

91:                                               ; preds = %86
  %92 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @p, ptr noundef @q)
  %93 = load i32, ptr @p, align 4, !tbaa !5
  %94 = sub nsw i32 %93, 1
  %95 = load i32, ptr @m, align 4, !tbaa !5
  %96 = mul nsw i32 %94, %95
  %97 = load i32, ptr @q, align 4, !tbaa !5
  %98 = add nsw i32 %96, %97
  store i32 %98, ptr @tlen, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #7
  store i32 0, ptr %7, align 4, !tbaa !5
  br label %99

99:                                               ; preds = %111, %91
  %100 = load i32, ptr %7, align 4, !tbaa !5
  %101 = load i32, ptr @p, align 4, !tbaa !5
  %102 = icmp slt i32 %100, %101
  br i1 %102, label %104, label %103

103:                                              ; preds = %99
  store i32 14, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #7
  br label %114

104:                                              ; preds = %99
  %105 = load i32, ptr %7, align 4, !tbaa !5
  %106 = load i32, ptr @m, align 4, !tbaa !5
  %107 = mul nsw i32 %105, %106
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds i8, ptr @t, i64 %108
  %110 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.5, ptr noundef %109)
  br label %111

111:                                              ; preds = %104
  %112 = load i32, ptr %7, align 4, !tbaa !5
  %113 = add nsw i32 %112, 1
  store i32 %113, ptr %7, align 4, !tbaa !5
  br label %99, !llvm.loop !17

114:                                              ; preds = %103
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #7
  store i32 0, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #7
  store i32 0, ptr %9, align 4, !tbaa !5
  br label %115

115:                                              ; preds = %148, %114
  %116 = load i32, ptr %8, align 4, !tbaa !5
  %117 = load i32, ptr @tlen, align 4, !tbaa !5
  %118 = icmp slt i32 %116, %117
  br i1 %118, label %120, label %119

119:                                              ; preds = %115
  store i32 17, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #7
  br label %150

120:                                              ; preds = %115
  call void @llvm.lifetime.start.p0(i64 32, ptr %10) #7
  %121 = load i32, ptr %9, align 4, !tbaa !5
  %122 = load i32, ptr @q, align 4, !tbaa !5
  %123 = icmp slt i32 %121, %122
  br i1 %123, label %124, label %131

124:                                              ; preds = %120
  %125 = load i32, ptr %8, align 4, !tbaa !5
  %126 = sext i32 %125 to i64
  %127 = getelementptr inbounds [251001 x i8], ptr @t, i64 0, i64 %126
  %128 = load i8, ptr %127, align 1, !tbaa !11
  %129 = sext i8 %128 to i32
  %130 = icmp eq i32 %129, 71
  br label %131

131:                                              ; preds = %124, %120
  %132 = phi i1 [ false, %120 ], [ %130, %124 ]
  %133 = uitofp i1 %132 to x86_fp80
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %10, x86_fp80 noundef %133, x86_fp80 noundef 0xK00000000000000000000)
  %134 = load i32, ptr %8, align 4, !tbaa !5
  %135 = sext i32 %134 to i64
  %136 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %135
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %136, ptr align 16 %10, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %10) #7
  br label %137

137:                                              ; preds = %131
  %138 = load i32, ptr %8, align 4, !tbaa !5
  %139 = add nsw i32 %138, 1
  store i32 %139, ptr %8, align 4, !tbaa !5
  %140 = load i32, ptr %9, align 4, !tbaa !5
  %141 = add nsw i32 %140, 1
  %142 = load i32, ptr @m, align 4, !tbaa !5
  %143 = icmp slt i32 %141, %142
  br i1 %143, label %144, label %147

144:                                              ; preds = %137
  %145 = load i32, ptr %9, align 4, !tbaa !5
  %146 = add nsw i32 %145, 1
  br label %148

147:                                              ; preds = %137
  br label %148

148:                                              ; preds = %147, %144
  %149 = phi i32 [ %146, %144 ], [ 0, %147 ]
  store i32 %149, ptr %9, align 4, !tbaa !5
  br label %115, !llvm.loop !18

150:                                              ; preds = %119
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #7
  %151 = load i32, ptr @tlen, align 4, !tbaa !5
  store i32 %151, ptr %11, align 4, !tbaa !5
  br label %152

152:                                              ; preds = %161, %150
  %153 = load i32, ptr %11, align 4, !tbaa !5
  %154 = load i32, ptr @len, align 4, !tbaa !5
  %155 = icmp slt i32 %153, %154
  br i1 %155, label %157, label %156

156:                                              ; preds = %152
  store i32 20, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #7
  br label %164

157:                                              ; preds = %152
  call void @llvm.lifetime.start.p0(i64 32, ptr %12) #7
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %12, x86_fp80 noundef 0xK00000000000000000000, x86_fp80 noundef 0xK00000000000000000000)
  %158 = load i32, ptr %11, align 4, !tbaa !5
  %159 = sext i32 %158 to i64
  %160 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %159
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %160, ptr align 16 %12, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #7
  br label %161

161:                                              ; preds = %157
  %162 = load i32, ptr %11, align 4, !tbaa !5
  %163 = add nsw i32 %162, 1
  store i32 %163, ptr %11, align 4, !tbaa !5
  br label %152, !llvm.loop !19

164:                                              ; preds = %156
  %165 = load i32, ptr @tlen, align 4, !tbaa !5
  %166 = sext i32 %165 to i64
  %167 = getelementptr inbounds %struct.complex, ptr @Y1, i64 %166
  call void @_ZSt7reverseIP7complexEvT_S2_(ptr noundef @Y1, ptr noundef %167)
  %168 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef @Y1, i32 noundef %168, i32 noundef 1)
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %169

169:                                              ; preds = %184, %164
  %170 = load i32, ptr %13, align 4, !tbaa !5
  %171 = load i32, ptr @len, align 4, !tbaa !5
  %172 = icmp slt i32 %170, %171
  br i1 %172, label %174, label %173

173:                                              ; preds = %169
  store i32 23, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %187

174:                                              ; preds = %169
  call void @llvm.lifetime.start.p0(i64 32, ptr %14) #7
  %175 = load i32, ptr %13, align 4, !tbaa !5
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds [524288 x %struct.complex], ptr @X1, i64 0, i64 %176
  %178 = load i32, ptr %13, align 4, !tbaa !5
  %179 = sext i32 %178 to i64
  %180 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %179
  call void @_ZmlRK7complexS1_(ptr dead_on_unwind writable sret(%struct.complex) align 16 %14, ptr noundef nonnull align 16 dereferenceable(32) %177, ptr noundef nonnull align 16 dereferenceable(32) %180)
  %181 = load i32, ptr %13, align 4, !tbaa !5
  %182 = sext i32 %181 to i64
  %183 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %182
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %183, ptr align 16 %14, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %14) #7
  br label %184

184:                                              ; preds = %174
  %185 = load i32, ptr %13, align 4, !tbaa !5
  %186 = add nsw i32 %185, 1
  store i32 %186, ptr %13, align 4, !tbaa !5
  br label %169, !llvm.loop !20

187:                                              ; preds = %173
  %188 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef @Y1, i32 noundef %188, i32 noundef -1)
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #7
  store i32 0, ptr %15, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #7
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %189

189:                                              ; preds = %222, %187
  %190 = load i32, ptr %15, align 4, !tbaa !5
  %191 = load i32, ptr @tlen, align 4, !tbaa !5
  %192 = icmp slt i32 %190, %191
  br i1 %192, label %194, label %193

193:                                              ; preds = %189
  store i32 26, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #7
  br label %224

194:                                              ; preds = %189
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #7
  %195 = load i32, ptr %16, align 4, !tbaa !5
  %196 = load i32, ptr @q, align 4, !tbaa !5
  %197 = icmp slt i32 %195, %196
  br i1 %197, label %198, label %205

198:                                              ; preds = %194
  %199 = load i32, ptr %15, align 4, !tbaa !5
  %200 = sext i32 %199 to i64
  %201 = getelementptr inbounds [251001 x i8], ptr @t, i64 0, i64 %200
  %202 = load i8, ptr %201, align 1, !tbaa !11
  %203 = sext i8 %202 to i32
  %204 = icmp eq i32 %203, 76
  br label %205

205:                                              ; preds = %198, %194
  %206 = phi i1 [ false, %194 ], [ %204, %198 ]
  %207 = uitofp i1 %206 to x86_fp80
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %17, x86_fp80 noundef %207, x86_fp80 noundef 0xK00000000000000000000)
  %208 = load i32, ptr %15, align 4, !tbaa !5
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %209
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %210, ptr align 16 %17, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #7
  br label %211

211:                                              ; preds = %205
  %212 = load i32, ptr %15, align 4, !tbaa !5
  %213 = add nsw i32 %212, 1
  store i32 %213, ptr %15, align 4, !tbaa !5
  %214 = load i32, ptr %16, align 4, !tbaa !5
  %215 = add nsw i32 %214, 1
  %216 = load i32, ptr @m, align 4, !tbaa !5
  %217 = icmp slt i32 %215, %216
  br i1 %217, label %218, label %221

218:                                              ; preds = %211
  %219 = load i32, ptr %16, align 4, !tbaa !5
  %220 = add nsw i32 %219, 1
  br label %222

221:                                              ; preds = %211
  br label %222

222:                                              ; preds = %221, %218
  %223 = phi i32 [ %220, %218 ], [ 0, %221 ]
  store i32 %223, ptr %16, align 4, !tbaa !5
  br label %189, !llvm.loop !21

224:                                              ; preds = %193
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #7
  %225 = load i32, ptr @tlen, align 4, !tbaa !5
  store i32 %225, ptr %18, align 4, !tbaa !5
  br label %226

226:                                              ; preds = %235, %224
  %227 = load i32, ptr %18, align 4, !tbaa !5
  %228 = load i32, ptr @len, align 4, !tbaa !5
  %229 = icmp slt i32 %227, %228
  br i1 %229, label %231, label %230

230:                                              ; preds = %226
  store i32 29, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #7
  br label %238

231:                                              ; preds = %226
  call void @llvm.lifetime.start.p0(i64 32, ptr %19) #7
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %19, x86_fp80 noundef 0xK00000000000000000000, x86_fp80 noundef 0xK00000000000000000000)
  %232 = load i32, ptr %18, align 4, !tbaa !5
  %233 = sext i32 %232 to i64
  %234 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %233
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %234, ptr align 16 %19, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %19) #7
  br label %235

235:                                              ; preds = %231
  %236 = load i32, ptr %18, align 4, !tbaa !5
  %237 = add nsw i32 %236, 1
  store i32 %237, ptr %18, align 4, !tbaa !5
  br label %226, !llvm.loop !22

238:                                              ; preds = %230
  %239 = load i32, ptr @tlen, align 4, !tbaa !5
  %240 = sext i32 %239 to i64
  %241 = getelementptr inbounds %struct.complex, ptr @Y2, i64 %240
  call void @_ZSt7reverseIP7complexEvT_S2_(ptr noundef @Y2, ptr noundef %241)
  %242 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef @Y2, i32 noundef %242, i32 noundef 1)
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #7
  store i32 0, ptr %20, align 4, !tbaa !5
  br label %243

243:                                              ; preds = %258, %238
  %244 = load i32, ptr %20, align 4, !tbaa !5
  %245 = load i32, ptr @len, align 4, !tbaa !5
  %246 = icmp slt i32 %244, %245
  br i1 %246, label %248, label %247

247:                                              ; preds = %243
  store i32 32, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #7
  br label %261

248:                                              ; preds = %243
  call void @llvm.lifetime.start.p0(i64 32, ptr %21) #7
  %249 = load i32, ptr %20, align 4, !tbaa !5
  %250 = sext i32 %249 to i64
  %251 = getelementptr inbounds [524288 x %struct.complex], ptr @X2, i64 0, i64 %250
  %252 = load i32, ptr %20, align 4, !tbaa !5
  %253 = sext i32 %252 to i64
  %254 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %253
  call void @_ZmlRK7complexS1_(ptr dead_on_unwind writable sret(%struct.complex) align 16 %21, ptr noundef nonnull align 16 dereferenceable(32) %251, ptr noundef nonnull align 16 dereferenceable(32) %254)
  %255 = load i32, ptr %20, align 4, !tbaa !5
  %256 = sext i32 %255 to i64
  %257 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %256
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %257, ptr align 16 %21, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr %21) #7
  br label %258

258:                                              ; preds = %248
  %259 = load i32, ptr %20, align 4, !tbaa !5
  %260 = add nsw i32 %259, 1
  store i32 %260, ptr %20, align 4, !tbaa !5
  br label %243, !llvm.loop !23

261:                                              ; preds = %247
  %262 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef @Y2, i32 noundef %262, i32 noundef -1)
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #7
  store i32 -1, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #7
  %263 = load i32, ptr @tlen, align 4, !tbaa !5
  %264 = sub nsw i32 %263, 1
  store i32 %264, ptr %25, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #7
  store i32 0, ptr %26, align 4, !tbaa !5
  br label %265

265:                                              ; preds = %327, %261
  %266 = load i32, ptr %25, align 4, !tbaa !5
  %267 = load i32, ptr @slen, align 4, !tbaa !5
  %268 = icmp slt i32 %266, %267
  br i1 %268, label %270, label %269

269:                                              ; preds = %265
  store i32 35, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #7
  br label %329

270:                                              ; preds = %265
  %271 = load i32, ptr %26, align 4, !tbaa !5
  %272 = load i32, ptr @q, align 4, !tbaa !5
  %273 = add nsw i32 %271, %272
  %274 = load i32, ptr @m, align 4, !tbaa !5
  %275 = icmp sle i32 %273, %274
  br i1 %275, label %276, label %315

276:                                              ; preds = %270
  %277 = load i32, ptr %22, align 4, !tbaa !5
  %278 = load i32, ptr %25, align 4, !tbaa !5
  %279 = sext i32 %278 to i64
  %280 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %279
  %281 = getelementptr inbounds %struct.complex, ptr %280, i32 0, i32 0
  %282 = load x86_fp80, ptr %281, align 16, !tbaa !24
  %283 = fadd x86_fp80 %282, 0xK3FFE8000000000000000
  %284 = fptosi x86_fp80 %283 to i32
  %285 = load i32, ptr %25, align 4, !tbaa !5
  %286 = sext i32 %285 to i64
  %287 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %286
  %288 = getelementptr inbounds %struct.complex, ptr %287, i32 0, i32 0
  %289 = load x86_fp80, ptr %288, align 16, !tbaa !24
  %290 = fadd x86_fp80 %289, 0xK3FFE8000000000000000
  %291 = fptosi x86_fp80 %290 to i32
  %292 = add nsw i32 %284, %291
  %293 = icmp slt i32 %277, %292
  br i1 %293, label %294, label %315

294:                                              ; preds = %276
  %295 = load i32, ptr %25, align 4, !tbaa !5
  %296 = load i32, ptr @tlen, align 4, !tbaa !5
  %297 = sub nsw i32 %295, %296
  %298 = add nsw i32 %297, 1
  store i32 %298, ptr %23, align 4, !tbaa !5
  %299 = load i32, ptr %25, align 4, !tbaa !5
  %300 = sext i32 %299 to i64
  %301 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %300
  %302 = getelementptr inbounds %struct.complex, ptr %301, i32 0, i32 0
  %303 = load x86_fp80, ptr %302, align 16, !tbaa !24
  %304 = fadd x86_fp80 %303, 0xK3FFE8000000000000000
  %305 = fptosi x86_fp80 %304 to i32
  store i32 %305, ptr %24, align 4, !tbaa !5
  %306 = load i32, ptr %24, align 4, !tbaa !5
  %307 = load i32, ptr %25, align 4, !tbaa !5
  %308 = sext i32 %307 to i64
  %309 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %308
  %310 = getelementptr inbounds %struct.complex, ptr %309, i32 0, i32 0
  %311 = load x86_fp80, ptr %310, align 16, !tbaa !24
  %312 = fadd x86_fp80 %311, 0xK3FFE8000000000000000
  %313 = fptosi x86_fp80 %312 to i32
  %314 = add nsw i32 %306, %313
  store i32 %314, ptr %22, align 4, !tbaa !5
  br label %315

315:                                              ; preds = %294, %276, %270
  br label %316

316:                                              ; preds = %315
  %317 = load i32, ptr %25, align 4, !tbaa !5
  %318 = add nsw i32 %317, 1
  store i32 %318, ptr %25, align 4, !tbaa !5
  %319 = load i32, ptr %26, align 4, !tbaa !5
  %320 = add nsw i32 %319, 1
  %321 = load i32, ptr @m, align 4, !tbaa !5
  %322 = icmp slt i32 %320, %321
  br i1 %322, label %323, label %326

323:                                              ; preds = %316
  %324 = load i32, ptr %26, align 4, !tbaa !5
  %325 = add nsw i32 %324, 1
  br label %327

326:                                              ; preds = %316
  br label %327

327:                                              ; preds = %326, %323
  %328 = phi i32 [ %325, %323 ], [ 0, %326 ]
  store i32 %328, ptr %26, align 4, !tbaa !5
  br label %265, !llvm.loop !26

329:                                              ; preds = %269
  %330 = load i32, ptr %5, align 4, !tbaa !5
  %331 = load i32, ptr %23, align 4, !tbaa !5
  %332 = load i32, ptr @m, align 4, !tbaa !5
  %333 = sdiv i32 %331, %332
  %334 = add nsw i32 %333, 1
  %335 = load i32, ptr %23, align 4, !tbaa !5
  %336 = load i32, ptr @m, align 4, !tbaa !5
  %337 = srem i32 %335, %336
  %338 = add nsw i32 %337, 1
  %339 = load i32, ptr %24, align 4, !tbaa !5
  %340 = load i32, ptr %22, align 4, !tbaa !5
  %341 = load i32, ptr %24, align 4, !tbaa !5
  %342 = sub nsw i32 %340, %341
  %343 = call i32 (ptr, ...) @printf(ptr noundef @.str.7, i32 noundef %330, i32 noundef %334, i32 noundef %338, i32 noundef %339, i32 noundef %342)
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #7
  br label %344

344:                                              ; preds = %329
  %345 = load i32, ptr %5, align 4, !tbaa !5
  %346 = add nsw i32 %345, 1
  store i32 %346, ptr %5, align 4, !tbaa !5
  br label %86, !llvm.loop !27

347:                                              ; preds = %90
  ret i32 0
}

declare i32 @__isoc99_scanf(ptr noundef, ...) #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt7reverseIP7complexEvT_S2_(ptr noundef, ptr noundef) #6

declare i32 @printf(ptr noundef, ...) #5

attributes #0 = { mustprogress 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 = { mustprogress 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 #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress norecurse 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 #5 = { "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 #6 = { inlinehint mustprogress 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 #7 = { 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++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!7, !7, i64 0}
!12 = !{i64 0, i64 16, !13, i64 16, i64 16, !13}
!13 = !{!14, !14, i64 0}
!14 = !{!"long double", !7, i64 0}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10}
!23 = distinct !{!23, !10}
!24 = !{!25, !14, i64 0}
!25 = !{!"_ZTS7complex", !14, i64 0, !14, i64 16}
!26 = distinct !{!26, !10}
!27 = distinct !{!27, !10}


; 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 { x86_fp80, x86_fp80 }

@X1 = external dso_local global [524288 x %struct.complex], align 16
@X2 = external dso_local global [524288 x %struct.complex], align 16
@Y1 = external dso_local global [524288 x %struct.complex], align 16
@Y2 = external dso_local global [524288 x %struct.complex], align 16
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@tt = external dso_local global i32, align 4
@p = external dso_local global i32, align 4
@q = external dso_local global i32, align 4
@slen = external dso_local local_unnamed_addr global i32, align 4
@tlen = external dso_local local_unnamed_addr global i32, align 4
@len = external dso_local local_unnamed_addr global i32, align 4
@s = external dso_local global [251001 x i8], align 16
@t = external dso_local global [251001 x i8], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [23 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3FFTP7complexii(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32), x86_fp80 noundef, x86_fp80 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZmlRK7complexS1_(ptr dead_on_unwind noalias writable sret(%struct.complex) align 16, ptr noundef nonnull align 16 dereferenceable(32), ptr noundef nonnull align 16 dereferenceable(32)) local_unnamed_addr #0

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #4 {
  %1 = alloca %struct.complex, align 16
  %2 = alloca %struct.complex, align 16
  %3 = alloca %struct.complex, align 16
  %4 = alloca %struct.complex, align 16
  %5 = alloca %struct.complex, align 16
  %6 = alloca %struct.complex, align 16
  %7 = alloca %struct.complex, align 16
  %8 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n, ptr noundef nonnull @m)
  %9 = load i32, ptr @n, align 4, !tbaa !5
  %10 = load i32, ptr @m, align 4, !tbaa !5
  %11 = mul nsw i32 %10, %9
  store i32 %11, ptr @slen, align 4, !tbaa !5
  %12 = icmp sgt i32 %9, 0
  br i1 %12, label %.lr.ph, label %.preheader91

.preheader91.loopexit:                            ; preds = %.lr.ph
  %.pre = load i32, ptr @slen, align 4, !tbaa !5
  br label %.preheader91

.preheader91:                                     ; preds = %.preheader91.loopexit, %0
  %13 = phi i32 [ %.pre, %.preheader91.loopexit ], [ %11, %0 ]
  %14 = icmp sgt i32 %13, 0
  br i1 %14, label %.lr.ph98, label %.preheader90

.lr.ph:                                           ; preds = %0, %.lr.ph
  %.07996 = phi i32 [ %20, %.lr.ph ], [ 0, %0 ]
  %15 = load i32, ptr @m, align 4, !tbaa !5
  %16 = mul nsw i32 %15, %.07996
  %17 = sext i32 %16 to i64
  %18 = getelementptr inbounds i8, ptr @s, i64 %17
  %19 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.5, ptr noundef nonnull %18)
  %20 = add nuw nsw i32 %.07996, 1
  %21 = load i32, ptr @n, align 4, !tbaa !5
  %22 = icmp slt i32 %20, %21
  br i1 %22, label %.lr.ph, label %.preheader91.loopexit, !llvm.loop !9

.preheader90:                                     ; preds = %.lr.ph98, %.preheader91
  %.lcssa95 = phi i32 [ %13, %.preheader91 ], [ %30, %.lr.ph98 ]
  %23 = shl i32 %.lcssa95, 1
  br label %33

.lr.ph98:                                         ; preds = %.preheader91, %.lr.ph98
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph98 ], [ 0, %.preheader91 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %1) #7
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %1, x86_fp80 noundef 0xK3FFF8000000000000000, x86_fp80 noundef 0xK00000000000000000000)
  %24 = getelementptr inbounds [251001 x i8], ptr @s, i64 0, i64 %indvars.iv
  %25 = load i8, ptr %24, align 1, !tbaa !11
  %26 = icmp eq i8 %25, 71
  %27 = getelementptr inbounds [524288 x %struct.complex], ptr @X1, i64 0, i64 %indvars.iv
  %28 = getelementptr inbounds [524288 x %struct.complex], ptr @X2, i64 0, i64 %indvars.iv
  %29 = select i1 %26, ptr %27, ptr %28
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %29, ptr noundef nonnull align 16 dereferenceable(32) %1, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %1) #7
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %30 = load i32, ptr @slen, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = icmp slt i64 %indvars.iv.next, %31
  br i1 %32, label %.lr.ph98, label %.preheader90, !llvm.loop !15

33:                                               ; preds = %33, %.preheader90
  %storemerge = phi i32 [ %35, %33 ], [ 1, %.preheader90 ]
  %34 = icmp slt i32 %storemerge, %23
  %35 = shl i32 %storemerge, 1
  br i1 %34, label %33, label %36, !llvm.loop !16

36:                                               ; preds = %33
  store i32 %storemerge, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef nonnull @X1, i32 noundef %storemerge, i32 noundef 1)
  %37 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef nonnull @X2, i32 noundef %37, i32 noundef 1)
  %38 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.6, ptr noundef nonnull @tt)
  %39 = load i32, ptr @tt, align 4, !tbaa !5
  %.not137 = icmp slt i32 %39, 1
  br i1 %.not137, label %._crit_edge143, label %.lr.ph142

._crit_edge143:                                   ; preds = %._crit_edge133, %36
  ret i32 0

.lr.ph142:                                        ; preds = %36, %._crit_edge133
  %.062140 = phi i32 [ %.1.lcssa, %._crit_edge133 ], [ undef, %36 ]
  %.063139 = phi i32 [ %.164.lcssa, %._crit_edge133 ], [ undef, %36 ]
  %.077138 = phi i32 [ %141, %._crit_edge133 ], [ 1, %36 ]
  %40 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @p, ptr noundef nonnull @q)
  %41 = load i32, ptr @p, align 4, !tbaa !5
  %42 = add nsw i32 %41, -1
  %43 = load i32, ptr @m, align 4, !tbaa !5
  %44 = mul nsw i32 %42, %43
  %45 = load i32, ptr @q, align 4, !tbaa !5
  %46 = add nsw i32 %44, %45
  store i32 %46, ptr @tlen, align 4, !tbaa !5
  %47 = icmp sgt i32 %41, 0
  br i1 %47, label %.lr.ph101, label %.preheader89

.preheader89.loopexit:                            ; preds = %.lr.ph101
  %.pre172 = load i32, ptr @tlen, align 4, !tbaa !5
  br label %.preheader89

.preheader89:                                     ; preds = %.preheader89.loopexit, %.lr.ph142
  %48 = phi i32 [ %.pre172, %.preheader89.loopexit ], [ %46, %.lr.ph142 ]
  %49 = icmp sgt i32 %48, 0
  br i1 %49, label %.lr.ph104, label %.preheader88

.lr.ph101:                                        ; preds = %.lr.ph142, %.lr.ph101
  %.076100 = phi i32 [ %55, %.lr.ph101 ], [ 0, %.lr.ph142 ]
  %50 = load i32, ptr @m, align 4, !tbaa !5
  %51 = mul nsw i32 %50, %.076100
  %52 = sext i32 %51 to i64
  %53 = getelementptr inbounds i8, ptr @t, i64 %52
  %54 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.5, ptr noundef nonnull %53)
  %55 = add nuw nsw i32 %.076100, 1
  %56 = load i32, ptr @p, align 4, !tbaa !5
  %57 = icmp slt i32 %55, %56
  br i1 %57, label %.lr.ph101, label %.preheader89.loopexit, !llvm.loop !17

.preheader88:                                     ; preds = %67, %.preheader89
  %.lcssa = phi i32 [ %48, %.preheader89 ], [ %75, %67 ]
  %58 = load i32, ptr @len, align 4, !tbaa !5
  %59 = icmp slt i32 %.lcssa, %58
  br i1 %59, label %.lr.ph107.preheader, label %._crit_edge

.lr.ph107.preheader:                              ; preds = %.preheader88
  %60 = sext i32 %.lcssa to i64
  br label %.lr.ph107

.lr.ph104:                                        ; preds = %.preheader89, %67
  %indvars.iv151 = phi i64 [ %indvars.iv.next152, %67 ], [ 0, %.preheader89 ]
  %.074103 = phi i32 [ %74, %67 ], [ 0, %.preheader89 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %2) #7
  %61 = load i32, ptr @q, align 4, !tbaa !5
  %62 = icmp slt i32 %.074103, %61
  br i1 %62, label %63, label %67

63:                                               ; preds = %.lr.ph104
  %64 = getelementptr inbounds [251001 x i8], ptr @t, i64 0, i64 %indvars.iv151
  %65 = load i8, ptr %64, align 1, !tbaa !11
  %66 = icmp eq i8 %65, 71
  br label %67

67:                                               ; preds = %63, %.lr.ph104
  %68 = phi i1 [ false, %.lr.ph104 ], [ %66, %63 ]
  %69 = uitofp i1 %68 to x86_fp80
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %2, x86_fp80 noundef %69, x86_fp80 noundef 0xK00000000000000000000)
  %70 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %indvars.iv151
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %70, ptr noundef nonnull align 16 dereferenceable(32) %2, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %2) #7
  %indvars.iv.next152 = add nuw nsw i64 %indvars.iv151, 1
  %71 = add nsw i32 %.074103, 1
  %72 = load i32, ptr @m, align 4, !tbaa !5
  %73 = icmp slt i32 %71, %72
  %74 = select i1 %73, i32 %71, i32 0
  %75 = load i32, ptr @tlen, align 4, !tbaa !5
  %76 = sext i32 %75 to i64
  %77 = icmp slt i64 %indvars.iv.next152, %76
  br i1 %77, label %.lr.ph104, label %.preheader88, !llvm.loop !18

._crit_edge.loopexit:                             ; preds = %.lr.ph107
  %.pre173 = load i32, ptr @tlen, align 4, !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit, %.preheader88
  %78 = phi i32 [ %.pre173, %._crit_edge.loopexit ], [ %.lcssa, %.preheader88 ]
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds %struct.complex, ptr @Y1, i64 %79
  call void @_ZSt7reverseIP7complexEvT_S2_(ptr noundef nonnull @Y1, ptr noundef nonnull %80)
  %81 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef nonnull @Y1, i32 noundef %81, i32 noundef 1)
  %82 = load i32, ptr @len, align 4, !tbaa !5
  %83 = icmp sgt i32 %82, 0
  br i1 %83, label %.lr.ph110, label %._crit_edge111

.lr.ph107:                                        ; preds = %.lr.ph107.preheader, %.lr.ph107
  %indvars.iv154 = phi i64 [ %60, %.lr.ph107.preheader ], [ %indvars.iv.next155, %.lr.ph107 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %3) #7
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %3, x86_fp80 noundef 0xK00000000000000000000, x86_fp80 noundef 0xK00000000000000000000)
  %84 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %indvars.iv154
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %84, ptr noundef nonnull align 16 dereferenceable(32) %3, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #7
  %indvars.iv.next155 = add nsw i64 %indvars.iv154, 1
  %85 = load i32, ptr @len, align 4, !tbaa !5
  %86 = sext i32 %85 to i64
  %87 = icmp slt i64 %indvars.iv.next155, %86
  br i1 %87, label %.lr.ph107, label %._crit_edge.loopexit, !llvm.loop !19

._crit_edge111:                                   ; preds = %.lr.ph110, %._crit_edge
  %.lcssa92 = phi i32 [ %82, %._crit_edge ], [ %92, %.lr.ph110 ]
  call void @_Z3FFTP7complexii(ptr noundef nonnull @Y1, i32 noundef %.lcssa92, i32 noundef -1)
  %88 = load i32, ptr @tlen, align 4, !tbaa !5
  %89 = icmp sgt i32 %88, 0
  br i1 %89, label %.lr.ph116, label %.preheader

.lr.ph110:                                        ; preds = %._crit_edge, %.lr.ph110
  %indvars.iv157 = phi i64 [ %indvars.iv.next158, %.lr.ph110 ], [ 0, %._crit_edge ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #7
  %90 = getelementptr inbounds [524288 x %struct.complex], ptr @X1, i64 0, i64 %indvars.iv157
  %91 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %indvars.iv157
  call void @_ZmlRK7complexS1_(ptr dead_on_unwind nonnull writable sret(%struct.complex) align 16 %4, ptr noundef nonnull align 16 dereferenceable(32) %90, ptr noundef nonnull align 16 dereferenceable(32) %91)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %91, ptr noundef nonnull align 16 dereferenceable(32) %4, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #7
  %indvars.iv.next158 = add nuw nsw i64 %indvars.iv157, 1
  %92 = load i32, ptr @len, align 4, !tbaa !5
  %93 = sext i32 %92 to i64
  %94 = icmp slt i64 %indvars.iv.next158, %93
  br i1 %94, label %.lr.ph110, label %._crit_edge111, !llvm.loop !20

.preheader:                                       ; preds = %104, %._crit_edge111
  %.lcssa93 = phi i32 [ %88, %._crit_edge111 ], [ %112, %104 ]
  %95 = load i32, ptr @len, align 4, !tbaa !5
  %96 = icmp slt i32 %.lcssa93, %95
  br i1 %96, label %.lr.ph119.preheader, label %._crit_edge120

.lr.ph119.preheader:                              ; preds = %.preheader
  %97 = sext i32 %.lcssa93 to i64
  br label %.lr.ph119

.lr.ph116:                                        ; preds = %._crit_edge111, %104
  %indvars.iv160 = phi i64 [ %indvars.iv.next161, %104 ], [ 0, %._crit_edge111 ]
  %.070114 = phi i32 [ %111, %104 ], [ 0, %._crit_edge111 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #7
  %98 = load i32, ptr @q, align 4, !tbaa !5
  %99 = icmp slt i32 %.070114, %98
  br i1 %99, label %100, label %104

100:                                              ; preds = %.lr.ph116
  %101 = getelementptr inbounds [251001 x i8], ptr @t, i64 0, i64 %indvars.iv160
  %102 = load i8, ptr %101, align 1, !tbaa !11
  %103 = icmp eq i8 %102, 76
  br label %104

104:                                              ; preds = %100, %.lr.ph116
  %105 = phi i1 [ false, %.lr.ph116 ], [ %103, %100 ]
  %106 = uitofp i1 %105 to x86_fp80
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %5, x86_fp80 noundef %106, x86_fp80 noundef 0xK00000000000000000000)
  %107 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %indvars.iv160
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %107, ptr noundef nonnull align 16 dereferenceable(32) %5, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  %indvars.iv.next161 = add nuw nsw i64 %indvars.iv160, 1
  %108 = add nsw i32 %.070114, 1
  %109 = load i32, ptr @m, align 4, !tbaa !5
  %110 = icmp slt i32 %108, %109
  %111 = select i1 %110, i32 %108, i32 0
  %112 = load i32, ptr @tlen, align 4, !tbaa !5
  %113 = sext i32 %112 to i64
  %114 = icmp slt i64 %indvars.iv.next161, %113
  br i1 %114, label %.lr.ph116, label %.preheader, !llvm.loop !21

._crit_edge120.loopexit:                          ; preds = %.lr.ph119
  %.pre174 = load i32, ptr @tlen, align 4, !tbaa !5
  br label %._crit_edge120

._crit_edge120:                                   ; preds = %._crit_edge120.loopexit, %.preheader
  %115 = phi i32 [ %.pre174, %._crit_edge120.loopexit ], [ %.lcssa93, %.preheader ]
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds %struct.complex, ptr @Y2, i64 %116
  call void @_ZSt7reverseIP7complexEvT_S2_(ptr noundef nonnull @Y2, ptr noundef nonnull %117)
  %118 = load i32, ptr @len, align 4, !tbaa !5
  call void @_Z3FFTP7complexii(ptr noundef nonnull @Y2, i32 noundef %118, i32 noundef 1)
  %119 = load i32, ptr @len, align 4, !tbaa !5
  %120 = icmp sgt i32 %119, 0
  br i1 %120, label %.lr.ph123, label %._crit_edge124

.lr.ph119:                                        ; preds = %.lr.ph119.preheader, %.lr.ph119
  %indvars.iv163 = phi i64 [ %97, %.lr.ph119.preheader ], [ %indvars.iv.next164, %.lr.ph119 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #7
  call void @_ZN7complexC2Eee(ptr noundef nonnull align 16 dereferenceable(32) %6, x86_fp80 noundef 0xK00000000000000000000, x86_fp80 noundef 0xK00000000000000000000)
  %121 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %indvars.iv163
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %121, ptr noundef nonnull align 16 dereferenceable(32) %6, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  %indvars.iv.next164 = add nsw i64 %indvars.iv163, 1
  %122 = load i32, ptr @len, align 4, !tbaa !5
  %123 = sext i32 %122 to i64
  %124 = icmp slt i64 %indvars.iv.next164, %123
  br i1 %124, label %.lr.ph119, label %._crit_edge120.loopexit, !llvm.loop !22

._crit_edge124:                                   ; preds = %.lr.ph123, %._crit_edge120
  %.lcssa94 = phi i32 [ %119, %._crit_edge120 ], [ %132, %.lr.ph123 ]
  call void @_Z3FFTP7complexii(ptr noundef nonnull @Y2, i32 noundef %.lcssa94, i32 noundef -1)
  %125 = load i32, ptr @tlen, align 4, !tbaa !5
  %126 = load i32, ptr @slen, align 4, !tbaa !5
  %.not144 = icmp sgt i32 %125, %126
  %.pre175 = load i32, ptr @m, align 4, !tbaa !5
  br i1 %.not144, label %._crit_edge133, label %.lr.ph132

.lr.ph132:                                        ; preds = %._crit_edge124
  %127 = add i32 %125, -1
  %128 = load i32, ptr @q, align 4, !tbaa !5
  %129 = sext i32 %127 to i64
  br label %143

.lr.ph123:                                        ; preds = %._crit_edge120, %.lr.ph123
  %indvars.iv166 = phi i64 [ %indvars.iv.next167, %.lr.ph123 ], [ 0, %._crit_edge120 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %7) #7
  %130 = getelementptr inbounds [524288 x %struct.complex], ptr @X2, i64 0, i64 %indvars.iv166
  %131 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %indvars.iv166
  call void @_ZmlRK7complexS1_(ptr dead_on_unwind nonnull writable sret(%struct.complex) align 16 %7, ptr noundef nonnull align 16 dereferenceable(32) %130, ptr noundef nonnull align 16 dereferenceable(32) %131)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(32) %131, ptr noundef nonnull align 16 dereferenceable(32) %7, i64 32, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #7
  %indvars.iv.next167 = add nuw nsw i64 %indvars.iv166, 1
  %132 = load i32, ptr @len, align 4, !tbaa !5
  %133 = sext i32 %132 to i64
  %134 = icmp slt i64 %indvars.iv.next167, %133
  br i1 %134, label %.lr.ph123, label %._crit_edge124, !llvm.loop !23

._crit_edge133:                                   ; preds = %159, %._crit_edge124
  %.066.lcssa = phi i32 [ -1, %._crit_edge124 ], [ %.167, %159 ]
  %.164.lcssa = phi i32 [ %.063139, %._crit_edge124 ], [ %.265, %159 ]
  %.1.lcssa = phi i32 [ %.062140, %._crit_edge124 ], [ %.2, %159 ]
  %135 = sdiv i32 %.164.lcssa, %.pre175
  %136 = add nsw i32 %135, 1
  %137 = srem i32 %.164.lcssa, %.pre175
  %138 = add nsw i32 %137, 1
  %139 = sub nsw i32 %.066.lcssa, %.1.lcssa
  %140 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.7, i32 noundef %.077138, i32 noundef %136, i32 noundef %138, i32 noundef %.1.lcssa, i32 noundef %139)
  %141 = add nuw nsw i32 %.077138, 1
  %142 = load i32, ptr @tt, align 4, !tbaa !5
  %.not.not = icmp slt i32 %.077138, %142
  br i1 %.not.not, label %.lr.ph142, label %._crit_edge143, !llvm.loop !24

143:                                              ; preds = %.lr.ph132, %159
  %indvars.iv169 = phi i64 [ %129, %.lr.ph132 ], [ %indvars.iv.next170, %159 ]
  %.0130 = phi i32 [ 0, %.lr.ph132 ], [ %162, %159 ]
  %.1128 = phi i32 [ %.062140, %.lr.ph132 ], [ %.2, %159 ]
  %.164127 = phi i32 [ %.063139, %.lr.ph132 ], [ %.265, %159 ]
  %.066126 = phi i32 [ -1, %.lr.ph132 ], [ %.167, %159 ]
  %144 = add nsw i32 %128, %.0130
  %.not87 = icmp sgt i32 %144, %.pre175
  br i1 %.not87, label %159, label %145

145:                                              ; preds = %143
  %146 = getelementptr inbounds [524288 x %struct.complex], ptr @Y1, i64 0, i64 %indvars.iv169
  %147 = load x86_fp80, ptr %146, align 16, !tbaa !25
  %148 = fadd x86_fp80 %147, 0xK3FFE8000000000000000
  %149 = fptosi x86_fp80 %148 to i32
  %150 = getelementptr inbounds [524288 x %struct.complex], ptr @Y2, i64 0, i64 %indvars.iv169
  %151 = load x86_fp80, ptr %150, align 16, !tbaa !25
  %152 = fadd x86_fp80 %151, 0xK3FFE8000000000000000
  %153 = fptosi x86_fp80 %152 to i32
  %154 = add nsw i32 %153, %149
  %155 = icmp slt i32 %.066126, %154
  br i1 %155, label %156, label %159

156:                                              ; preds = %145
  %157 = trunc nsw i64 %indvars.iv169 to i32
  %reass.sub = sub i32 %157, %125
  %158 = add i32 %reass.sub, 1
  br label %159

159:                                              ; preds = %143, %145, %156
  %.167 = phi i32 [ %154, %156 ], [ %.066126, %145 ], [ %.066126, %143 ]
  %.265 = phi i32 [ %158, %156 ], [ %.164127, %145 ], [ %.164127, %143 ]
  %.2 = phi i32 [ %149, %156 ], [ %.1128, %145 ], [ %.1128, %143 ]
  %indvars.iv.next170 = add nsw i64 %indvars.iv169, 1
  %160 = add nsw i32 %.0130, 1
  %161 = icmp slt i32 %160, %.pre175
  %162 = select i1 %161, i32 %160, i32 0
  %lftr.wideiv = trunc i64 %indvars.iv.next170 to i32
  %exitcond.not = icmp eq i32 %126, %lftr.wideiv
  br i1 %exitcond.not, label %._crit_edge133, label %143, !llvm.loop !27
}

; Function Attrs: nofree nounwind
declare noundef i32 @__isoc99_scanf(ptr nocapture noundef readonly, ...) local_unnamed_addr #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt7reverseIP7complexEvT_S2_(ptr noundef, ptr noundef) local_unnamed_addr #6

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #5

attributes #0 = { mustprogress 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 = { mustprogress 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 #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress norecurse 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 #5 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { inlinehint mustprogress 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 #7 = { 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++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!7, !7, i64 0}
!12 = !{i64 0, i64 16, !13, i64 16, i64 16, !13}
!13 = !{!14, !14, i64 0}
!14 = !{!"long double", !7, i64 0}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10}
!23 = distinct !{!23, !10}
!24 = distinct !{!24, !10}
!25 = !{!26, !14, i64 0}
!26 = !{!"_ZTS7complex", !14, i64 0, !14, i64 16}
!27 = distinct !{!27, !10}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass