; LLVM IR from tangjz/acm-icpc :: TDL_training/2016-04-17 (H - Bouquet - tjz)

; 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.std::pair" = type { i32, i32 }

@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@f = external dso_local global [2 x [50001 x i32]], align 16
@a = external dso_local global [1001 x %"struct.std::pair"], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %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
  store i32 0, ptr %1, align 4
  %10 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n, ptr noundef @m)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  store i32 1, ptr %2, align 4, !tbaa !5
  br label %11

11:                                               ; preds = %26, %0
  %12 = load i32, ptr %2, align 4, !tbaa !5
  %13 = load i32, ptr @n, align 4, !tbaa !5
  %14 = icmp sle i32 %12, %13
  br i1 %14, label %16, label %15

15:                                               ; preds = %11
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  br label %29

16:                                               ; preds = %11
  %17 = load i32, ptr %2, align 4, !tbaa !5
  %18 = sext i32 %17 to i64
  %19 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %18
  %20 = getelementptr inbounds %"struct.std::pair", ptr %19, i32 0, i32 0
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = sext i32 %21 to i64
  %23 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %22
  %24 = getelementptr inbounds %"struct.std::pair", ptr %23, i32 0, i32 1
  %25 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %20, ptr noundef %24)
  br label %26

26:                                               ; preds = %16
  %27 = load i32, ptr %2, align 4, !tbaa !5
  %28 = add nsw i32 %27, 1
  store i32 %28, ptr %2, align 4, !tbaa !5
  br label %11, !llvm.loop !9

29:                                               ; preds = %15
  %30 = load i32, ptr @n, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = getelementptr inbounds %"struct.std::pair", ptr @a, i64 %31
  %33 = getelementptr inbounds %"struct.std::pair", ptr %32, i64 1
  call void @_ZSt4sortIPSt4pairIiiEEvT_S3_(ptr noundef getelementptr inbounds (%"struct.std::pair", ptr @a, i64 1), ptr noundef %33)
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  store i32 1, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  store i32 0, ptr %4, align 4, !tbaa !5
  %34 = load i32, ptr %4, align 4, !tbaa !5
  %35 = sext i32 %34 to i64
  %36 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %35
  %37 = getelementptr inbounds [50001 x i32], ptr %36, i64 0, i64 0
  %38 = load i32, ptr @m, align 4, !tbaa !5
  %39 = add nsw i32 %38, 1
  %40 = sext i32 %39 to i64
  %41 = mul i64 %40, 4
  call void @llvm.memset.p0.i64(ptr align 4 %37, i8 -1, i64 %41, i1 false)
  %42 = load i32, ptr %4, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %43
  %45 = getelementptr inbounds [50001 x i32], ptr %44, i64 0, i64 0
  store i32 0, ptr %45, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 1, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  br label %46

46:                                               ; preds = %253, %29
  %47 = load i32, ptr %5, align 4, !tbaa !5
  %48 = load i32, ptr @n, align 4, !tbaa !5
  %49 = icmp sle i32 %47, %48
  br i1 %49, label %51, label %50

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

51:                                               ; preds = %46
  %52 = load i32, ptr %3, align 4, !tbaa !5
  %53 = xor i32 %52, 1
  store i32 %53, ptr %3, align 4, !tbaa !5
  %54 = load i32, ptr %4, align 4, !tbaa !5
  %55 = xor i32 %54, 1
  store i32 %55, ptr %4, align 4, !tbaa !5
  %56 = load i32, ptr %4, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %57
  %59 = getelementptr inbounds [50001 x i32], ptr %58, i64 0, i64 0
  %60 = load i32, ptr @m, align 4, !tbaa !5
  %61 = add nsw i32 %60, 1
  %62 = sext i32 %61 to i64
  %63 = mul i64 %62, 4
  call void @llvm.memset.p0.i64(ptr align 4 %59, i8 -1, i64 %63, i1 false)
  %64 = load i32, ptr %5, align 4, !tbaa !5
  %65 = add nsw i32 %64, 1
  store i32 %65, ptr %6, align 4, !tbaa !5
  br label %66

66:                                               ; preds = %85, %51
  %67 = load i32, ptr %6, align 4, !tbaa !5
  %68 = load i32, ptr @n, align 4, !tbaa !5
  %69 = icmp sle i32 %67, %68
  br i1 %69, label %70, label %82

70:                                               ; preds = %66
  %71 = load i32, ptr %5, align 4, !tbaa !5
  %72 = sext i32 %71 to i64
  %73 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %72
  %74 = getelementptr inbounds %"struct.std::pair", ptr %73, i32 0, i32 0
  %75 = load i32, ptr %74, align 8, !tbaa !11
  %76 = load i32, ptr %6, align 4, !tbaa !5
  %77 = sext i32 %76 to i64
  %78 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %77
  %79 = getelementptr inbounds %"struct.std::pair", ptr %78, i32 0, i32 0
  %80 = load i32, ptr %79, align 8, !tbaa !11
  %81 = icmp eq i32 %75, %80
  br label %82

82:                                               ; preds = %70, %66
  %83 = phi i1 [ false, %66 ], [ %81, %70 ]
  br i1 %83, label %84, label %88

84:                                               ; preds = %82
  br label %85

85:                                               ; preds = %84
  %86 = load i32, ptr %6, align 4, !tbaa !5
  %87 = add nsw i32 %86, 1
  store i32 %87, ptr %6, align 4, !tbaa !5
  br label %66, !llvm.loop !13

88:                                               ; preds = %82
  br label %89

89:                                               ; preds = %210, %88
  %90 = load i32, ptr %5, align 4, !tbaa !5
  %91 = load i32, ptr %6, align 4, !tbaa !5
  %92 = icmp slt i32 %90, %91
  br i1 %92, label %93, label %213

93:                                               ; preds = %89
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  %94 = load i32, ptr @m, align 4, !tbaa !5
  store i32 %94, ptr %8, align 4, !tbaa !5
  br label %95

95:                                               ; preds = %206, %93
  %96 = load i32, ptr %8, align 4, !tbaa !5
  %97 = load i32, ptr %5, align 4, !tbaa !5
  %98 = sext i32 %97 to i64
  %99 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %98
  %100 = getelementptr inbounds %"struct.std::pair", ptr %99, i32 0, i32 1
  %101 = load i32, ptr %100, align 4, !tbaa !14
  %102 = icmp sge i32 %96, %101
  br i1 %102, label %104, label %103

103:                                              ; preds = %95
  store i32 13, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  br label %209

104:                                              ; preds = %95
  %105 = load i32, ptr %3, align 4, !tbaa !5
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %106
  %108 = load i32, ptr %8, align 4, !tbaa !5
  %109 = load i32, ptr %5, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %110
  %112 = getelementptr inbounds %"struct.std::pair", ptr %111, i32 0, i32 1
  %113 = load i32, ptr %112, align 4, !tbaa !14
  %114 = sub nsw i32 %108, %113
  %115 = sext i32 %114 to i64
  %116 = getelementptr inbounds [50001 x i32], ptr %107, i64 0, i64 %115
  %117 = load i32, ptr %116, align 4, !tbaa !5
  %118 = icmp ne i32 %117, -1
  br i1 %118, label %119, label %163

119:                                              ; preds = %104
  %120 = load i32, ptr %4, align 4, !tbaa !5
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %121
  %123 = load i32, ptr %8, align 4, !tbaa !5
  %124 = sext i32 %123 to i64
  %125 = getelementptr inbounds [50001 x i32], ptr %122, i64 0, i64 %124
  %126 = load i32, ptr %125, align 4, !tbaa !5
  %127 = load i32, ptr %3, align 4, !tbaa !5
  %128 = sext i32 %127 to i64
  %129 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %128
  %130 = load i32, ptr %8, align 4, !tbaa !5
  %131 = load i32, ptr %5, align 4, !tbaa !5
  %132 = sext i32 %131 to i64
  %133 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %132
  %134 = getelementptr inbounds %"struct.std::pair", ptr %133, i32 0, i32 1
  %135 = load i32, ptr %134, align 4, !tbaa !14
  %136 = sub nsw i32 %130, %135
  %137 = sext i32 %136 to i64
  %138 = getelementptr inbounds [50001 x i32], ptr %129, i64 0, i64 %137
  %139 = load i32, ptr %138, align 4, !tbaa !5
  %140 = add nsw i32 %139, 1
  %141 = icmp slt i32 %126, %140
  br i1 %141, label %142, label %163

142:                                              ; preds = %119
  %143 = load i32, ptr %3, align 4, !tbaa !5
  %144 = sext i32 %143 to i64
  %145 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %144
  %146 = load i32, ptr %8, align 4, !tbaa !5
  %147 = load i32, ptr %5, align 4, !tbaa !5
  %148 = sext i32 %147 to i64
  %149 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %148
  %150 = getelementptr inbounds %"struct.std::pair", ptr %149, i32 0, i32 1
  %151 = load i32, ptr %150, align 4, !tbaa !14
  %152 = sub nsw i32 %146, %151
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds [50001 x i32], ptr %145, i64 0, i64 %153
  %155 = load i32, ptr %154, align 4, !tbaa !5
  %156 = add nsw i32 %155, 1
  %157 = load i32, ptr %4, align 4, !tbaa !5
  %158 = sext i32 %157 to i64
  %159 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %158
  %160 = load i32, ptr %8, align 4, !tbaa !5
  %161 = sext i32 %160 to i64
  %162 = getelementptr inbounds [50001 x i32], ptr %159, i64 0, i64 %161
  store i32 %156, ptr %162, align 4, !tbaa !5
  br label %163

163:                                              ; preds = %142, %119, %104
  %164 = load i32, ptr %4, align 4, !tbaa !5
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %165
  %167 = load i32, ptr %8, align 4, !tbaa !5
  %168 = sext i32 %167 to i64
  %169 = getelementptr inbounds [50001 x i32], ptr %166, i64 0, i64 %168
  %170 = load i32, ptr %169, align 4, !tbaa !5
  %171 = load i32, ptr %4, align 4, !tbaa !5
  %172 = sext i32 %171 to i64
  %173 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %172
  %174 = load i32, ptr %8, align 4, !tbaa !5
  %175 = load i32, ptr %5, align 4, !tbaa !5
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %176
  %178 = getelementptr inbounds %"struct.std::pair", ptr %177, i32 0, i32 1
  %179 = load i32, ptr %178, align 4, !tbaa !14
  %180 = sub nsw i32 %174, %179
  %181 = sext i32 %180 to i64
  %182 = getelementptr inbounds [50001 x i32], ptr %173, i64 0, i64 %181
  %183 = load i32, ptr %182, align 4, !tbaa !5
  %184 = icmp slt i32 %170, %183
  br i1 %184, label %185, label %205

185:                                              ; preds = %163
  %186 = load i32, ptr %4, align 4, !tbaa !5
  %187 = sext i32 %186 to i64
  %188 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %187
  %189 = load i32, ptr %8, align 4, !tbaa !5
  %190 = load i32, ptr %5, align 4, !tbaa !5
  %191 = sext i32 %190 to i64
  %192 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %191
  %193 = getelementptr inbounds %"struct.std::pair", ptr %192, i32 0, i32 1
  %194 = load i32, ptr %193, align 4, !tbaa !14
  %195 = sub nsw i32 %189, %194
  %196 = sext i32 %195 to i64
  %197 = getelementptr inbounds [50001 x i32], ptr %188, i64 0, i64 %196
  %198 = load i32, ptr %197, align 4, !tbaa !5
  %199 = load i32, ptr %4, align 4, !tbaa !5
  %200 = sext i32 %199 to i64
  %201 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %200
  %202 = load i32, ptr %8, align 4, !tbaa !5
  %203 = sext i32 %202 to i64
  %204 = getelementptr inbounds [50001 x i32], ptr %201, i64 0, i64 %203
  store i32 %198, ptr %204, align 4, !tbaa !5
  br label %205

205:                                              ; preds = %185, %163
  br label %206

206:                                              ; preds = %205
  %207 = load i32, ptr %8, align 4, !tbaa !5
  %208 = add nsw i32 %207, -1
  store i32 %208, ptr %8, align 4, !tbaa !5
  br label %95, !llvm.loop !15

209:                                              ; preds = %103
  br label %210

210:                                              ; preds = %209
  %211 = load i32, ptr %5, align 4, !tbaa !5
  %212 = add nsw i32 %211, 1
  store i32 %212, ptr %5, align 4, !tbaa !5
  br label %89, !llvm.loop !16

213:                                              ; preds = %89
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !5
  br label %214

214:                                              ; preds = %250, %213
  %215 = load i32, ptr %9, align 4, !tbaa !5
  %216 = load i32, ptr @m, align 4, !tbaa !5
  %217 = icmp sle i32 %215, %216
  br i1 %217, label %219, label %218

218:                                              ; preds = %214
  store i32 16, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %253

219:                                              ; preds = %214
  %220 = load i32, ptr %4, align 4, !tbaa !5
  %221 = sext i32 %220 to i64
  %222 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %221
  %223 = load i32, ptr %9, align 4, !tbaa !5
  %224 = sext i32 %223 to i64
  %225 = getelementptr inbounds [50001 x i32], ptr %222, i64 0, i64 %224
  %226 = load i32, ptr %225, align 4, !tbaa !5
  %227 = load i32, ptr %3, align 4, !tbaa !5
  %228 = sext i32 %227 to i64
  %229 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %228
  %230 = load i32, ptr %9, align 4, !tbaa !5
  %231 = sext i32 %230 to i64
  %232 = getelementptr inbounds [50001 x i32], ptr %229, i64 0, i64 %231
  %233 = load i32, ptr %232, align 4, !tbaa !5
  %234 = icmp slt i32 %226, %233
  br i1 %234, label %235, label %249

235:                                              ; preds = %219
  %236 = load i32, ptr %3, align 4, !tbaa !5
  %237 = sext i32 %236 to i64
  %238 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %237
  %239 = load i32, ptr %9, align 4, !tbaa !5
  %240 = sext i32 %239 to i64
  %241 = getelementptr inbounds [50001 x i32], ptr %238, i64 0, i64 %240
  %242 = load i32, ptr %241, align 4, !tbaa !5
  %243 = load i32, ptr %4, align 4, !tbaa !5
  %244 = sext i32 %243 to i64
  %245 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %244
  %246 = load i32, ptr %9, align 4, !tbaa !5
  %247 = sext i32 %246 to i64
  %248 = getelementptr inbounds [50001 x i32], ptr %245, i64 0, i64 %247
  store i32 %242, ptr %248, align 4, !tbaa !5
  br label %249

249:                                              ; preds = %235, %219
  br label %250

250:                                              ; preds = %249
  %251 = load i32, ptr %9, align 4, !tbaa !5
  %252 = add nsw i32 %251, 1
  store i32 %252, ptr %9, align 4, !tbaa !5
  br label %214, !llvm.loop !17

253:                                              ; preds = %218
  br label %46, !llvm.loop !18

254:                                              ; preds = %50
  %255 = load i32, ptr %4, align 4, !tbaa !5
  %256 = sext i32 %255 to i64
  %257 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %256
  %258 = load i32, ptr @m, align 4, !tbaa !5
  %259 = sext i32 %258 to i64
  %260 = getelementptr inbounds [50001 x i32], ptr %257, i64 0, i64 %259
  %261 = load i32, ptr %260, align 4, !tbaa !5
  %262 = icmp eq i32 %261, -1
  br i1 %262, label %263, label %265

263:                                              ; preds = %254
  %264 = call i32 @puts(ptr noundef @.str.1)
  br label %274

265:                                              ; preds = %254
  %266 = load i32, ptr %4, align 4, !tbaa !5
  %267 = sext i32 %266 to i64
  %268 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %267
  %269 = load i32, ptr @m, align 4, !tbaa !5
  %270 = sext i32 %269 to i64
  %271 = getelementptr inbounds [50001 x i32], ptr %268, i64 0, i64 %270
  %272 = load i32, ptr %271, align 4, !tbaa !5
  %273 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, i32 noundef %272)
  br label %274

274:                                              ; preds = %265, %263
  store i32 0, ptr %1, align 4
  store i32 1, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  %275 = load i32, ptr %1, align 4
  ret i32 %275
}

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

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

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

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #4

declare i32 @puts(ptr noundef) #1

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

attributes #0 = { 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 #1 = { "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 #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #4 = { nocallback nofree nounwind willreturn memory(argmem: write) }
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++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !6, i64 0}
!12 = !{!"_ZTSSt4pairIiiE", !6, i64 0, !6, i64 4}
!13 = distinct !{!13, !10}
!14 = !{!12, !6, i64 4}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !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.std::pair" = type { i32, i32 }

@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@f = external dso_local local_unnamed_addr global [2 x [50001 x i32]], align 16
@a = external dso_local global [1001 x %"struct.std::pair"], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n, ptr noundef nonnull @m)
  %2 = load i32, ptr @n, align 4, !tbaa !5
  %.not78 = icmp slt i32 %2, 1
  br i1 %.not78, label %.._crit_edge_crit_edge, label %.lr.ph

.._crit_edge_crit_edge:                           ; preds = %0
  %.pre117 = sext i32 %2 to i64
  br label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph, %.._crit_edge_crit_edge
  %.pre-phi = phi i64 [ %.pre117, %.._crit_edge_crit_edge ], [ %17, %.lr.ph ]
  %3 = getelementptr inbounds %"struct.std::pair", ptr @a, i64 %.pre-phi
  %4 = getelementptr inbounds i8, ptr %3, i64 8
  tail call void @_ZSt4sortIPSt4pairIiiEEvT_S3_(ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 8), ptr noundef nonnull %4)
  %5 = load i32, ptr @m, align 4, !tbaa !5
  %6 = add i32 %5, 1
  %7 = sext i32 %6 to i64
  %8 = shl nsw i64 %7, 2
  tail call void @llvm.memset.p0.i64(ptr nonnull align 16 @f, i8 -1, i64 %8, i1 false)
  store i32 0, ptr @f, align 16, !tbaa !5
  %9 = load i32, ptr @n, align 4, !tbaa !5
  %.not7090 = icmp slt i32 %9, 1
  br i1 %.not7090, label %._crit_edge.._crit_edge96_crit_edge, label %.lr.ph95

._crit_edge.._crit_edge96_crit_edge:              ; preds = %._crit_edge
  %.pre118 = sext i32 %5 to i64
  br label %._crit_edge96

.lr.ph95:                                         ; preds = %._crit_edge
  %.not7387 = icmp slt i32 %5, 0
  %10 = sext i32 %5 to i64
  %wide.trip.count115 = zext i32 %6 to i64
  %11 = shl nuw nsw i64 %wide.trip.count115, 2
  %scevgep125 = getelementptr i8, ptr @f, i64 %11
  %scevgep128 = getelementptr i8, ptr @f, i64 %11
  %min.iters.check = icmp ult i32 %6, 8
  %n.vec = and i64 %wide.trip.count115, 4294967288
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count115
  %xtraiter = and i64 %wide.trip.count115, 1
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  %12 = add nsw i64 %wide.trip.count115, -1
  br label %22

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 1, %0 ]
  %13 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %indvars.iv
  %14 = getelementptr inbounds i8, ptr %13, i64 4
  %15 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %13, ptr noundef nonnull %14)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %16 = load i32, ptr @n, align 4, !tbaa !5
  %17 = sext i32 %16 to i64
  %.not.not = icmp slt i64 %indvars.iv, %17
  br i1 %.not.not, label %.lr.ph, label %._crit_edge, !llvm.loop !9

.loopexit:                                        ; preds = %scalar.ph.prol.loopexit, %113, %middle.block, %.preheader77
  %.not70 = icmp sgt i32 %.1.lcssa, %9
  br i1 %.not70, label %._crit_edge96.loopexit, label %22, !llvm.loop !11

._crit_edge96.loopexit:                           ; preds = %.loopexit
  %18 = zext nneg i32 %24 to i64
  br label %._crit_edge96

._crit_edge96:                                    ; preds = %._crit_edge.._crit_edge96_crit_edge, %._crit_edge96.loopexit
  %.pre-phi119 = phi i64 [ %.pre118, %._crit_edge.._crit_edge96_crit_edge ], [ %10, %._crit_edge96.loopexit ]
  %.060.lcssa = phi i64 [ 0, %._crit_edge.._crit_edge96_crit_edge ], [ %18, %._crit_edge96.loopexit ]
  %19 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %.060.lcssa, i64 %.pre-phi119
  %20 = load i32, ptr %19, align 4, !tbaa !5
  %21 = icmp eq i32 %20, -1
  br i1 %21, label %114, label %116

22:                                               ; preds = %.lr.ph95, %.loopexit
  %.05993 = phi i32 [ 1, %.lr.ph95 ], [ %.1.lcssa, %.loopexit ]
  %.06092 = phi i32 [ 0, %.lr.ph95 ], [ %24, %.loopexit ]
  %.06191 = phi i32 [ 1, %.lr.ph95 ], [ %23, %.loopexit ]
  %23 = xor i32 %.06191, 1
  %24 = xor i32 %.06092, 1
  %25 = zext i32 %24 to i64
  %26 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25
  tail call void @llvm.memset.p0.i64(ptr nonnull align 4 %26, i8 -1, i64 %8, i1 false)
  %27 = sext i32 %.05993 to i64
  %28 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %27
  %smax = tail call i32 @llvm.smax.i32(i32 %.05993, i32 %9)
  %wide.trip.count = zext nneg i32 %smax to i64
  br label %29

29:                                               ; preds = %30, %22
  %indvars.iv102 = phi i64 [ %indvars.iv.next103, %30 ], [ %27, %22 ]
  %exitcond.not = icmp eq i64 %indvars.iv102, %wide.trip.count
  br i1 %exitcond.not, label %.critedge, label %30

30:                                               ; preds = %29
  %indvars.iv.next103 = add nsw i64 %indvars.iv102, 1
  %31 = load i32, ptr %28, align 8, !tbaa !12
  %32 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %indvars.iv.next103
  %33 = load i32, ptr %32, align 8, !tbaa !12
  %34 = icmp eq i32 %31, %33
  br i1 %34, label %29, label %.critedge.split.loop.exit121, !llvm.loop !14

.critedge.split.loop.exit121:                     ; preds = %30
  %35 = trunc nsw i64 %indvars.iv102 to i32
  br label %.critedge

.critedge:                                        ; preds = %29, %.critedge.split.loop.exit121
  %.058.in.lcssa = phi i32 [ %35, %.critedge.split.loop.exit121 ], [ %smax, %29 ]
  %.not7284 = icmp sgt i32 %.05993, %.058.in.lcssa
  br i1 %.not7284, label %.preheader77, label %.preheader.lr.ph

.preheader.lr.ph:                                 ; preds = %.critedge
  %36 = zext nneg i32 %23 to i64
  %37 = add i32 %.058.in.lcssa, 1
  br label %.preheader

.preheader77:                                     ; preds = %._crit_edge83, %.critedge
  %.1.lcssa = phi i32 [ %.05993, %.critedge ], [ %37, %._crit_edge83 ]
  br i1 %.not7387, label %.loopexit, label %.lr.ph89

.lr.ph89:                                         ; preds = %.preheader77
  %38 = zext nneg i32 %23 to i64
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.memcheck

scalar.ph.preheader:                              ; preds = %middle.block, %vector.memcheck, %.lr.ph89
  %indvars.iv112.ph = phi i64 [ 0, %vector.memcheck ], [ 0, %.lr.ph89 ], [ %n.vec, %middle.block ]
  br i1 %lcmp.mod.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol

scalar.ph.prol:                                   ; preds = %scalar.ph.preheader
  %39 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %indvars.iv112.ph
  %40 = load i32, ptr %39, align 4, !tbaa !5
  %41 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %38, i64 %indvars.iv112.ph
  %42 = load i32, ptr %41, align 4, !tbaa !5
  %43 = icmp slt i32 %40, %42
  br i1 %43, label %44, label %scalar.ph.prol.loopexit.unr-lcssa

44:                                               ; preds = %scalar.ph.prol
  store i32 %42, ptr %39, align 4, !tbaa !5
  br label %scalar.ph.prol.loopexit.unr-lcssa

scalar.ph.prol.loopexit.unr-lcssa:                ; preds = %44, %scalar.ph.prol
  %indvars.iv.next113.prol = or disjoint i64 %indvars.iv112.ph, 1
  br label %scalar.ph.prol.loopexit

scalar.ph.prol.loopexit:                          ; preds = %scalar.ph.prol.loopexit.unr-lcssa, %scalar.ph.preheader
  %indvars.iv112.unr = phi i64 [ %indvars.iv112.ph, %scalar.ph.preheader ], [ %indvars.iv.next113.prol, %scalar.ph.prol.loopexit.unr-lcssa ]
  %45 = icmp eq i64 %indvars.iv112.ph, %12
  br i1 %45, label %.loopexit, label %scalar.ph

vector.memcheck:                                  ; preds = %.lr.ph89
  %46 = mul nuw nsw i64 %25, 200004
  %scevgep = getelementptr i8, ptr @f, i64 %46
  %scevgep126 = getelementptr i8, ptr %scevgep125, i64 %46
  %47 = mul nuw nsw i64 %38, 200004
  %scevgep127 = getelementptr i8, ptr @f, i64 %47
  %scevgep129 = getelementptr i8, ptr %scevgep128, i64 %47
  %bound0 = icmp ult ptr %scevgep, %scevgep129
  %bound1 = icmp ult ptr %scevgep127, %scevgep126
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %scalar.ph.preheader, label %vector.body

vector.body:                                      ; preds = %vector.memcheck, %pred.store.continue146
  %index = phi i64 [ %index.next, %pred.store.continue146 ], [ 0, %vector.memcheck ]
  %48 = or disjoint i64 %index, 4
  %49 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %index
  %50 = getelementptr inbounds i8, ptr %49, i64 16
  %wide.load = load <4 x i32>, ptr %49, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  %wide.load130 = load <4 x i32>, ptr %50, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  %51 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %38, i64 %index
  %52 = getelementptr inbounds i8, ptr %51, i64 16
  %wide.load131 = load <4 x i32>, ptr %51, align 4, !tbaa !5, !alias.scope !18
  %wide.load132 = load <4 x i32>, ptr %52, align 4, !tbaa !5, !alias.scope !18
  %53 = icmp slt <4 x i32> %wide.load, %wide.load131
  %54 = icmp slt <4 x i32> %wide.load130, %wide.load132
  %55 = extractelement <4 x i1> %53, i64 0
  br i1 %55, label %pred.store.if, label %pred.store.continue

pred.store.if:                                    ; preds = %vector.body
  %56 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %index
  %57 = extractelement <4 x i32> %wide.load131, i64 0
  store i32 %57, ptr %56, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue

pred.store.continue:                              ; preds = %pred.store.if, %vector.body
  %58 = extractelement <4 x i1> %53, i64 1
  br i1 %58, label %pred.store.if133, label %pred.store.continue134

pred.store.if133:                                 ; preds = %pred.store.continue
  %59 = or disjoint i64 %index, 1
  %60 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %59
  %61 = extractelement <4 x i32> %wide.load131, i64 1
  store i32 %61, ptr %60, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue134

pred.store.continue134:                           ; preds = %pred.store.if133, %pred.store.continue
  %62 = extractelement <4 x i1> %53, i64 2
  br i1 %62, label %pred.store.if135, label %pred.store.continue136

pred.store.if135:                                 ; preds = %pred.store.continue134
  %63 = or disjoint i64 %index, 2
  %64 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %63
  %65 = extractelement <4 x i32> %wide.load131, i64 2
  store i32 %65, ptr %64, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue136

pred.store.continue136:                           ; preds = %pred.store.if135, %pred.store.continue134
  %66 = extractelement <4 x i1> %53, i64 3
  br i1 %66, label %pred.store.if137, label %pred.store.continue138

pred.store.if137:                                 ; preds = %pred.store.continue136
  %67 = or disjoint i64 %index, 3
  %68 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %67
  %69 = extractelement <4 x i32> %wide.load131, i64 3
  store i32 %69, ptr %68, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue138

pred.store.continue138:                           ; preds = %pred.store.if137, %pred.store.continue136
  %70 = extractelement <4 x i1> %54, i64 0
  br i1 %70, label %pred.store.if139, label %pred.store.continue140

pred.store.if139:                                 ; preds = %pred.store.continue138
  %71 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %48
  %72 = extractelement <4 x i32> %wide.load132, i64 0
  store i32 %72, ptr %71, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue140

pred.store.continue140:                           ; preds = %pred.store.if139, %pred.store.continue138
  %73 = extractelement <4 x i1> %54, i64 1
  br i1 %73, label %pred.store.if141, label %pred.store.continue142

pred.store.if141:                                 ; preds = %pred.store.continue140
  %74 = or disjoint i64 %index, 5
  %75 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %74
  %76 = extractelement <4 x i32> %wide.load132, i64 1
  store i32 %76, ptr %75, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue142

pred.store.continue142:                           ; preds = %pred.store.if141, %pred.store.continue140
  %77 = extractelement <4 x i1> %54, i64 2
  br i1 %77, label %pred.store.if143, label %pred.store.continue144

pred.store.if143:                                 ; preds = %pred.store.continue142
  %78 = or disjoint i64 %index, 6
  %79 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %78
  %80 = extractelement <4 x i32> %wide.load132, i64 2
  store i32 %80, ptr %79, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue144

pred.store.continue144:                           ; preds = %pred.store.if143, %pred.store.continue142
  %81 = extractelement <4 x i1> %54, i64 3
  br i1 %81, label %pred.store.if145, label %pred.store.continue146

pred.store.if145:                                 ; preds = %pred.store.continue144
  %82 = or disjoint i64 %index, 7
  %83 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %82
  %84 = extractelement <4 x i32> %wide.load132, i64 3
  store i32 %84, ptr %83, align 4, !tbaa !5, !alias.scope !15, !noalias !18
  br label %pred.store.continue146

pred.store.continue146:                           ; preds = %pred.store.if145, %pred.store.continue144
  %index.next = add nuw i64 %index, 8
  %85 = icmp eq i64 %index.next, %n.vec
  br i1 %85, label %middle.block, label %vector.body, !llvm.loop !20

middle.block:                                     ; preds = %pred.store.continue146
  br i1 %cmp.n, label %.loopexit, label %scalar.ph.preheader

.preheader:                                       ; preds = %.preheader.lr.ph, %._crit_edge83
  %indvars.iv108 = phi i64 [ %27, %.preheader.lr.ph ], [ %indvars.iv.next109, %._crit_edge83 ]
  %86 = getelementptr inbounds [1001 x %"struct.std::pair"], ptr @a, i64 0, i64 %indvars.iv108, i32 1
  %87 = load i32, ptr %86, align 4, !tbaa !23
  %.not7480 = icmp slt i32 %5, %87
  br i1 %.not7480, label %._crit_edge83, label %.lr.ph82.preheader

.lr.ph82.preheader:                               ; preds = %.preheader
  %88 = sext i32 %87 to i64
  br label %.lr.ph82

._crit_edge83:                                    ; preds = %100, %.preheader
  %indvars.iv.next109 = add nsw i64 %indvars.iv108, 1
  %lftr.wideiv = trunc i64 %indvars.iv.next109 to i32
  %exitcond111.not = icmp eq i32 %37, %lftr.wideiv
  br i1 %exitcond111.not, label %.preheader77, label %.preheader, !llvm.loop !24

.lr.ph82:                                         ; preds = %.lr.ph82.preheader, %100
  %indvars.iv105 = phi i64 [ %10, %.lr.ph82.preheader ], [ %indvars.iv.next106, %100 ]
  %89 = sub nsw i64 %indvars.iv105, %88
  %90 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %36, i64 %89
  %91 = load i32, ptr %90, align 4, !tbaa !5
  %.not75 = icmp eq i32 %91, -1
  %.phi.trans.insert = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %indvars.iv105
  %.pre = load i32, ptr %.phi.trans.insert, align 4, !tbaa !5
  %.not76 = icmp sgt i32 %.pre, %91
  %or.cond = select i1 %.not75, i1 true, i1 %.not76
  br i1 %or.cond, label %.lr.ph82._crit_edge, label %92

92:                                               ; preds = %.lr.ph82
  %93 = add nuw nsw i32 %91, 1
  store i32 %93, ptr %.phi.trans.insert, align 4, !tbaa !5
  br label %.lr.ph82._crit_edge

.lr.ph82._crit_edge:                              ; preds = %.lr.ph82, %92
  %94 = phi i32 [ %93, %92 ], [ %.pre, %.lr.ph82 ]
  %95 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %89
  %96 = load i32, ptr %95, align 4, !tbaa !5
  %97 = icmp slt i32 %94, %96
  br i1 %97, label %98, label %100

98:                                               ; preds = %.lr.ph82._crit_edge
  %99 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %indvars.iv105
  store i32 %96, ptr %99, align 4, !tbaa !5
  br label %100

100:                                              ; preds = %.lr.ph82._crit_edge, %98
  %indvars.iv.next106 = add nsw i64 %indvars.iv105, -1
  %.not74.not = icmp sgt i64 %indvars.iv105, %88
  br i1 %.not74.not, label %.lr.ph82, label %._crit_edge83, !llvm.loop !25

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %113
  %indvars.iv112 = phi i64 [ %indvars.iv.next113.1, %113 ], [ %indvars.iv112.unr, %scalar.ph.prol.loopexit ]
  %101 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %indvars.iv112
  %102 = load i32, ptr %101, align 4, !tbaa !5
  %103 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %38, i64 %indvars.iv112
  %104 = load i32, ptr %103, align 4, !tbaa !5
  %105 = icmp slt i32 %102, %104
  br i1 %105, label %106, label %scalar.ph.1

106:                                              ; preds = %scalar.ph
  store i32 %104, ptr %101, align 4, !tbaa !5
  br label %scalar.ph.1

scalar.ph.1:                                      ; preds = %scalar.ph, %106
  %indvars.iv.next113 = add nuw nsw i64 %indvars.iv112, 1
  %107 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %25, i64 %indvars.iv.next113
  %108 = load i32, ptr %107, align 4, !tbaa !5
  %109 = getelementptr inbounds [2 x [50001 x i32]], ptr @f, i64 0, i64 %38, i64 %indvars.iv.next113
  %110 = load i32, ptr %109, align 4, !tbaa !5
  %111 = icmp slt i32 %108, %110
  br i1 %111, label %112, label %113

112:                                              ; preds = %scalar.ph.1
  store i32 %110, ptr %107, align 4, !tbaa !5
  br label %113

113:                                              ; preds = %112, %scalar.ph.1
  %indvars.iv.next113.1 = add nuw nsw i64 %indvars.iv112, 2
  %exitcond116.not.1 = icmp eq i64 %indvars.iv.next113.1, %wide.trip.count115
  br i1 %exitcond116.not.1, label %.loopexit, label %scalar.ph, !llvm.loop !26

114:                                              ; preds = %._crit_edge96
  %115 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.1)
  br label %118

116:                                              ; preds = %._crit_edge96
  %117 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i32 noundef %20)
  br label %118

118:                                              ; preds = %116, %114
  ret i32 0
}

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

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

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

; Function Attrs: nofree nounwind
declare noundef i32 @puts(ptr nocapture noundef readonly) local_unnamed_addr #1

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

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

attributes #0 = { 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 #1 = { 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 #2 = { 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 #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }

!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 = distinct !{!11, !10}
!12 = !{!13, !6, i64 0}
!13 = !{!"_ZTSSt4pairIiiE", !6, i64 0, !6, i64 4}
!14 = distinct !{!14, !10}
!15 = !{!16}
!16 = distinct !{!16, !17}
!17 = distinct !{!17, !"LVerDomain"}
!18 = !{!19}
!19 = distinct !{!19, !17}
!20 = distinct !{!20, !10, !21, !22}
!21 = !{!"llvm.loop.isvectorized", i32 1}
!22 = !{!"llvm.loop.unroll.runtime.disable"}
!23 = !{!13, !6, i64 4}
!24 = distinct !{!24, !10}
!25 = distinct !{!25, !10}
!26 = distinct !{!26, !10, !21}


; Effective O3 passes: BDCEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,SROAPass,SimplifyCFGPass,TailCallElimPass