; LLVM IR from VastoLorde95/Competitive-Programming :: Codeforces/250 Division 1/Problem C (C)

; 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"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair.0" = type { i32, i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"struct.std::pair" = type { i64, i64 }

@n = external dso_local global i32, align 4
@x = external dso_local global i32, align 4
@y = external dso_local global i32, align 4
@p = external dso_local global %"class.std::vector", align 8
@dp = external dso_local global [201 x [201 x i64]], align 16
@MOD = external dso_local global i64, align 8
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z4goodSt4pairIxxES0_S0_(i64, i64, i64, i64, i64, i64) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #1 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca %"struct.std::pair.0", align 4
  %4 = alloca i64, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca %"struct.std::pair", align 8
  %14 = alloca %"struct.std::pair", align 8
  %15 = alloca %"struct.std::pair", align 8
  store i32 0, ptr %1, align 4
  %16 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %17

17:                                               ; preds = %25, %0
  %18 = load i32, ptr %2, align 4, !tbaa !5
  %19 = load i32, ptr @n, align 4, !tbaa !5
  %20 = icmp slt i32 %18, %19
  br i1 %20, label %22, label %21

21:                                               ; preds = %17
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  br label %28

22:                                               ; preds = %17
  %23 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef @x, ptr noundef @y)
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #6
  %24 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) @x, ptr noundef nonnull align 4 dereferenceable(4) @y)
  store i64 %24, ptr %3, align 4
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) @p, ptr noundef nonnull align 4 dereferenceable(8) %3)
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #6
  br label %25

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

28:                                               ; preds = %21
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #6
  store i64 0, ptr %4, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  %29 = load i32, ptr @n, align 4, !tbaa !5
  %30 = sub nsw i32 %29, 1
  store i32 %30, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #6
  store i32 0, ptr %6, align 4, !tbaa !5
  br label %31

31:                                               ; preds = %66, %28
  %32 = load i32, ptr %6, 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 %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  br label %69

36:                                               ; preds = %31
  %37 = load i32, ptr %5, align 4, !tbaa !5
  %38 = sext i32 %37 to i64
  %39 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %38) #6
  %40 = getelementptr inbounds %"struct.std::pair.0", ptr %39, i32 0, i32 0
  %41 = load i32, ptr %40, align 4, !tbaa !13
  %42 = sext i32 %41 to i64
  %43 = load i32, ptr %6, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %45 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %44) #6
  %46 = getelementptr inbounds %"struct.std::pair.0", ptr %45, i32 0, i32 1
  %47 = load i32, ptr %46, align 4, !tbaa !15
  %48 = sext i32 %47 to i64
  %49 = mul nsw i64 %42, %48
  %50 = load i32, ptr %5, align 4, !tbaa !5
  %51 = sext i32 %50 to i64
  %52 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %51) #6
  %53 = getelementptr inbounds %"struct.std::pair.0", ptr %52, i32 0, i32 1
  %54 = load i32, ptr %53, align 4, !tbaa !15
  %55 = sext i32 %54 to i64
  %56 = load i32, ptr %6, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %57) #6
  %59 = getelementptr inbounds %"struct.std::pair.0", ptr %58, i32 0, i32 0
  %60 = load i32, ptr %59, align 4, !tbaa !13
  %61 = sext i32 %60 to i64
  %62 = mul nsw i64 %55, %61
  %63 = sub nsw i64 %49, %62
  %64 = load i64, ptr %4, align 8, !tbaa !11
  %65 = add nsw i64 %64, %63
  store i64 %65, ptr %4, align 8, !tbaa !11
  br label %66

66:                                               ; preds = %36
  %67 = load i32, ptr %6, align 4, !tbaa !5
  %68 = add nsw i32 %67, 1
  store i32 %68, ptr %6, align 4, !tbaa !5
  store i32 %67, ptr %5, align 4, !tbaa !5
  br label %31, !llvm.loop !16

69:                                               ; preds = %35
  %70 = load i64, ptr %4, align 8, !tbaa !11
  %71 = icmp slt i64 %70, 0
  br i1 %71, label %72, label %81

72:                                               ; preds = %69
  %73 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) @p) #6
  %74 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %7, i32 0, i32 0
  store ptr %73, ptr %74, align 8
  %75 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) @p) #6
  %76 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  store ptr %75, ptr %76, align 8
  %77 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %7, i32 0, i32 0
  %78 = load ptr, ptr %77, align 8
  %79 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  %80 = load ptr, ptr %79, align 8
  call void @_ZSt7reverseIN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS3_SaIS3_EEEEEvT_S9_(ptr %78, ptr %80)
  br label %81

81:                                               ; preds = %72, %69
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  store i32 1, ptr %9, align 4, !tbaa !5
  br label %82

82:                                               ; preds = %205, %81
  %83 = load i32, ptr %9, align 4, !tbaa !5
  %84 = load i32, ptr @n, align 4, !tbaa !5
  %85 = icmp slt i32 %83, %84
  br i1 %85, label %87, label %86

86:                                               ; preds = %82
  store i32 8, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  br label %208

87:                                               ; preds = %82
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  %88 = load i32, ptr %9, align 4, !tbaa !5
  store i32 %88, ptr %11, align 4, !tbaa !5
  br label %89

89:                                               ; preds = %201, %87
  %90 = load i32, ptr %11, align 4, !tbaa !5
  %91 = load i32, ptr @n, align 4, !tbaa !5
  %92 = icmp slt i32 %90, %91
  br i1 %92, label %94, label %93

93:                                               ; preds = %89
  store i32 11, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  br label %204

94:                                               ; preds = %89
  %95 = load i32, ptr %9, align 4, !tbaa !5
  %96 = icmp eq i32 %95, 1
  br i1 %96, label %97, label %106

97:                                               ; preds = %94
  %98 = load i32, ptr %11, align 4, !tbaa !5
  %99 = load i32, ptr %9, align 4, !tbaa !5
  %100 = sub nsw i32 %98, %99
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %101
  %103 = load i32, ptr %11, align 4, !tbaa !5
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds [201 x i64], ptr %102, i64 0, i64 %104
  store i64 1, ptr %105, align 8, !tbaa !11
  br label %200

106:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  %107 = load i32, ptr %11, align 4, !tbaa !5
  %108 = load i32, ptr %9, align 4, !tbaa !5
  %109 = sub nsw i32 %107, %108
  %110 = add nsw i32 %109, 1
  store i32 %110, ptr %12, align 4, !tbaa !5
  br label %111

111:                                              ; preds = %196, %106
  %112 = load i32, ptr %12, align 4, !tbaa !5
  %113 = load i32, ptr %11, align 4, !tbaa !5
  %114 = icmp slt i32 %112, %113
  br i1 %114, label %116, label %115

115:                                              ; preds = %111
  store i32 14, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  br label %199

116:                                              ; preds = %111
  %117 = load i32, ptr %11, align 4, !tbaa !5
  %118 = load i32, ptr %9, align 4, !tbaa !5
  %119 = sub nsw i32 %117, %118
  %120 = sext i32 %119 to i64
  %121 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %120) #6
  call void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef nonnull align 4 dereferenceable(8) %121)
  %122 = load i32, ptr %11, align 4, !tbaa !5
  %123 = sext i32 %122 to i64
  %124 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %123) #6
  call void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 4 dereferenceable(8) %124)
  %125 = load i32, ptr %12, align 4, !tbaa !5
  %126 = sext i32 %125 to i64
  %127 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %126) #6
  call void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16) %15, ptr noundef nonnull align 4 dereferenceable(8) %127)
  %128 = getelementptr inbounds { i64, i64 }, ptr %13, i32 0, i32 0
  %129 = load i64, ptr %128, align 8
  %130 = getelementptr inbounds { i64, i64 }, ptr %13, i32 0, i32 1
  %131 = load i64, ptr %130, align 8
  %132 = getelementptr inbounds { i64, i64 }, ptr %14, i32 0, i32 0
  %133 = load i64, ptr %132, align 8
  %134 = getelementptr inbounds { i64, i64 }, ptr %14, i32 0, i32 1
  %135 = load i64, ptr %134, align 8
  %136 = getelementptr inbounds { i64, i64 }, ptr %15, i32 0, i32 0
  %137 = load i64, ptr %136, align 8
  %138 = getelementptr inbounds { i64, i64 }, ptr %15, i32 0, i32 1
  %139 = load i64, ptr %138, align 8
  %140 = call noundef zeroext i1 @_Z4goodSt4pairIxxES0_S0_(i64 %129, i64 %131, i64 %133, i64 %135, i64 %137, i64 %139)
  br i1 %140, label %142, label %141

141:                                              ; preds = %116
  br label %196

142:                                              ; preds = %116
  %143 = load i32, ptr %11, align 4, !tbaa !5
  %144 = load i32, ptr %9, align 4, !tbaa !5
  %145 = sub nsw i32 %143, %144
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %146
  %148 = load i32, ptr %12, align 4, !tbaa !5
  %149 = sext i32 %148 to i64
  %150 = getelementptr inbounds [201 x i64], ptr %147, i64 0, i64 %149
  %151 = load i64, ptr %150, align 8, !tbaa !11
  %152 = load i32, ptr %12, align 4, !tbaa !5
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %153
  %155 = load i32, ptr %11, align 4, !tbaa !5
  %156 = sext i32 %155 to i64
  %157 = getelementptr inbounds [201 x i64], ptr %154, i64 0, i64 %156
  %158 = load i64, ptr %157, align 8, !tbaa !11
  %159 = mul nsw i64 %151, %158
  %160 = load i64, ptr @MOD, align 8, !tbaa !11
  %161 = srem i64 %159, %160
  %162 = load i32, ptr %11, align 4, !tbaa !5
  %163 = load i32, ptr %9, align 4, !tbaa !5
  %164 = sub nsw i32 %162, %163
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %165
  %167 = load i32, ptr %11, align 4, !tbaa !5
  %168 = sext i32 %167 to i64
  %169 = getelementptr inbounds [201 x i64], ptr %166, i64 0, i64 %168
  %170 = load i64, ptr %169, align 8, !tbaa !11
  %171 = add nsw i64 %170, %161
  store i64 %171, ptr %169, align 8, !tbaa !11
  %172 = load i32, ptr %11, align 4, !tbaa !5
  %173 = load i32, ptr %9, align 4, !tbaa !5
  %174 = sub nsw i32 %172, %173
  %175 = sext i32 %174 to i64
  %176 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %175
  %177 = load i32, ptr %11, align 4, !tbaa !5
  %178 = sext i32 %177 to i64
  %179 = getelementptr inbounds [201 x i64], ptr %176, i64 0, i64 %178
  %180 = load i64, ptr %179, align 8, !tbaa !11
  %181 = load i64, ptr @MOD, align 8, !tbaa !11
  %182 = icmp sge i64 %180, %181
  br i1 %182, label %183, label %195

183:                                              ; preds = %142
  %184 = load i64, ptr @MOD, align 8, !tbaa !11
  %185 = load i32, ptr %11, align 4, !tbaa !5
  %186 = load i32, ptr %9, align 4, !tbaa !5
  %187 = sub nsw i32 %185, %186
  %188 = sext i32 %187 to i64
  %189 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %188
  %190 = load i32, ptr %11, align 4, !tbaa !5
  %191 = sext i32 %190 to i64
  %192 = getelementptr inbounds [201 x i64], ptr %189, i64 0, i64 %191
  %193 = load i64, ptr %192, align 8, !tbaa !11
  %194 = sub nsw i64 %193, %184
  store i64 %194, ptr %192, align 8, !tbaa !11
  br label %195

195:                                              ; preds = %183, %142
  br label %196

196:                                              ; preds = %195, %141
  %197 = load i32, ptr %12, align 4, !tbaa !5
  %198 = add nsw i32 %197, 1
  store i32 %198, ptr %12, align 4, !tbaa !5
  br label %111, !llvm.loop !17

199:                                              ; preds = %115
  br label %200

200:                                              ; preds = %199, %97
  br label %201

201:                                              ; preds = %200
  %202 = load i32, ptr %11, align 4, !tbaa !5
  %203 = add nsw i32 %202, 1
  store i32 %203, ptr %11, align 4, !tbaa !5
  br label %89, !llvm.loop !18

204:                                              ; preds = %93
  br label %205

205:                                              ; preds = %204
  %206 = load i32, ptr %9, align 4, !tbaa !5
  %207 = add nsw i32 %206, 1
  store i32 %207, ptr %9, align 4, !tbaa !5
  br label %82, !llvm.loop !19

208:                                              ; preds = %86
  %209 = load i32, ptr @n, align 4, !tbaa !5
  %210 = sub nsw i32 %209, 1
  %211 = sext i32 %210 to i64
  %212 = getelementptr inbounds [201 x i64], ptr @dp, i64 0, i64 %211
  %213 = load i64, ptr %212, align 8, !tbaa !11
  %214 = trunc i64 %213 to i32
  %215 = call i32 (ptr, ...) @printf(ptr noundef @.str.3, i32 noundef %214)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #6
  %216 = load i32, ptr %1, align 4
  ret i32 %216
}

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(8)) #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #4

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt7reverseIN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS3_SaIS3_EEEEEvT_S9_(ptr, ptr) #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(8)) unnamed_addr #0 align 2

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

attributes #0 = { 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 #1 = { 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 #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { 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 #6 = { 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, !12, i64 0}
!12 = !{!"long long", !7, i64 0}
!13 = !{!14, !6, i64 0}
!14 = !{!"_ZTSSt4pairIiiE", !6, i64 0, !6, i64 4}
!15 = !{!14, !6, i64 4}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !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"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair.0" = type { i32, i32 }
%"struct.std::pair" = type { i64, i64 }

@n = external dso_local global i32, align 4
@x = external dso_local global i32, align 4
@y = external dso_local global i32, align 4
@p = external dso_local global %"class.std::vector", align 8
@dp = external dso_local local_unnamed_addr global [201 x [201 x i64]], align 16
@MOD = external dso_local local_unnamed_addr global i64, align 8
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z4goodSt4pairIxxES0_S0_(i64, i64, i64, i64, i64, i64) local_unnamed_addr #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #1 {
  %1 = alloca %"struct.std::pair.0", align 8
  %2 = alloca %"struct.std::pair", align 8
  %3 = alloca %"struct.std::pair", align 8
  %4 = alloca %"struct.std::pair", align 8
  %5 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n)
  %6 = load i32, ptr @n, align 4, !tbaa !5
  %7 = icmp sgt i32 %6, 0
  br i1 %7, label %.lr.ph, label %._crit_edge73

._crit_edge:                                      ; preds = %.lr.ph
  %8 = icmp sgt i32 %13, 0
  br i1 %8, label %.lr.ph60.preheader, label %._crit_edge73

.lr.ph60.preheader:                               ; preds = %._crit_edge
  %9 = add nsw i32 %13, -1
  br label %.lr.ph60

.lr.ph:                                           ; preds = %0, %.lr.ph
  %.04655 = phi i32 [ %12, %.lr.ph ], [ 0, %0 ]
  %10 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull @x, ptr noundef nonnull @y)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #6
  %11 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) @x, ptr noundef nonnull align 4 dereferenceable(4) @y)
  store i64 %11, ptr %1, align 8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) @p, ptr noundef nonnull align 4 dereferenceable(8) %1)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #6
  %12 = add nuw nsw i32 %.04655, 1
  %13 = load i32, ptr @n, align 4, !tbaa !5
  %14 = icmp slt i32 %12, %13
  br i1 %14, label %.lr.ph, label %._crit_edge, !llvm.loop !9

._crit_edge61:                                    ; preds = %.lr.ph60
  %15 = icmp slt i64 %34, 0
  br i1 %15, label %39, label %42

.lr.ph60:                                         ; preds = %.lr.ph60.preheader, %.lr.ph60
  %indvars.iv = phi i64 [ 0, %.lr.ph60.preheader ], [ %indvars.iv.next, %.lr.ph60 ]
  %.04857 = phi i32 [ %9, %.lr.ph60.preheader ], [ %38, %.lr.ph60 ]
  %.04956 = phi i64 [ 0, %.lr.ph60.preheader ], [ %34, %.lr.ph60 ]
  %16 = sext i32 %.04857 to i64
  %17 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %16) #6
  %18 = load i32, ptr %17, align 4, !tbaa !11
  %19 = sext i32 %18 to i64
  %20 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %indvars.iv) #6
  %21 = getelementptr inbounds i8, ptr %20, i64 4
  %22 = load i32, ptr %21, align 4, !tbaa !13
  %23 = sext i32 %22 to i64
  %24 = mul nsw i64 %23, %19
  %25 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %16) #6
  %26 = getelementptr inbounds i8, ptr %25, i64 4
  %27 = load i32, ptr %26, align 4, !tbaa !13
  %28 = sext i32 %27 to i64
  %29 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %indvars.iv) #6
  %30 = load i32, ptr %29, align 4, !tbaa !11
  %31 = sext i32 %30 to i64
  %32 = mul nsw i64 %31, %28
  %33 = add i64 %24, %.04956
  %34 = sub i64 %33, %32
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %35 = load i32, ptr @n, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = icmp slt i64 %indvars.iv.next, %36
  %38 = trunc nuw nsw i64 %indvars.iv to i32
  br i1 %37, label %.lr.ph60, label %._crit_edge61, !llvm.loop !14

39:                                               ; preds = %._crit_edge61
  %40 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) @p) #6
  %41 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) @p) #6
  call void @_ZSt7reverseIN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS3_SaIS3_EEEEEvT_S9_(ptr %40, ptr %41)
  %.pre = load i32, ptr @n, align 4, !tbaa !5
  br label %42

42:                                               ; preds = %39, %._crit_edge61
  %43 = phi i32 [ %.pre, %39 ], [ %35, %._crit_edge61 ]
  %44 = icmp sgt i32 %43, 1
  br i1 %44, label %.preheader.lr.ph, label %._crit_edge73

.preheader.lr.ph:                                 ; preds = %42
  %45 = getelementptr inbounds i8, ptr %2, i64 8
  %46 = getelementptr inbounds i8, ptr %3, i64 8
  %47 = getelementptr inbounds i8, ptr %4, i64 8
  br label %.preheader

.preheader:                                       ; preds = %.preheader.lr.ph, %._crit_edge70
  %48 = phi i32 [ %43, %.preheader.lr.ph ], [ %70, %._crit_edge70 ]
  %indvars.iv85 = phi i64 [ 1, %.preheader.lr.ph ], [ %indvars.iv.next86, %._crit_edge70 ]
  %49 = sext i32 %48 to i64
  %50 = icmp slt i64 %indvars.iv85, %49
  br i1 %50, label %.lr.ph69, label %._crit_edge70

.lr.ph69:                                         ; preds = %.preheader
  %51 = icmp eq i64 %indvars.iv85, 1
  br i1 %51, label %.lr.ph69.split.us.preheader, label %.lr.ph69.split

.lr.ph69.split.us.preheader:                      ; preds = %.lr.ph69
  %52 = add nsw i64 %49, -1
  %53 = add nsw i64 %49, -2
  %xtraiter = and i64 %52, 3
  %54 = icmp ult i64 %53, 3
  br i1 %54, label %._crit_edge70.loopexit.unr-lcssa, label %.lr.ph69.split.us.preheader.new

.lr.ph69.split.us.preheader.new:                  ; preds = %.lr.ph69.split.us.preheader
  %unroll_iter = and i64 %52, -4
  br label %.lr.ph69.split.us

.lr.ph69.split.us:                                ; preds = %.lr.ph69.split.us, %.lr.ph69.split.us.preheader.new
  %indvars.iv91 = phi i64 [ 1, %.lr.ph69.split.us.preheader.new ], [ %indvars.iv.next92.3, %.lr.ph69.split.us ]
  %niter = phi i64 [ 0, %.lr.ph69.split.us.preheader.new ], [ %niter.next.3, %.lr.ph69.split.us ]
  %55 = add nsw i64 %indvars.iv91, -1
  %56 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %55, i64 %indvars.iv91
  store i64 1, ptr %56, align 8, !tbaa !15
  %indvars.iv.next92 = add nuw nsw i64 %indvars.iv91, 1
  %57 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %indvars.iv91, i64 %indvars.iv.next92
  store i64 1, ptr %57, align 8, !tbaa !15
  %indvars.iv.next92.1 = add nuw nsw i64 %indvars.iv91, 2
  %58 = add nuw nsw i64 %indvars.iv91, 1
  %59 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %58, i64 %indvars.iv.next92.1
  store i64 1, ptr %59, align 8, !tbaa !15
  %indvars.iv.next92.2 = add nuw nsw i64 %indvars.iv91, 3
  %60 = add nuw nsw i64 %indvars.iv91, 2
  %61 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %60, i64 %indvars.iv.next92.2
  store i64 1, ptr %61, align 8, !tbaa !15
  %indvars.iv.next92.3 = add nuw nsw i64 %indvars.iv91, 4
  %niter.next.3 = add nuw i64 %niter, 4
  %niter.ncmp.3.not = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3.not, label %._crit_edge70.loopexit.unr-lcssa, label %.lr.ph69.split.us, !llvm.loop !17

._crit_edge73:                                    ; preds = %._crit_edge70, %._crit_edge, %0, %42
  %.lcssa = phi i32 [ %43, %42 ], [ %13, %._crit_edge ], [ %6, %0 ], [ %70, %._crit_edge70 ]
  %62 = add nsw i32 %.lcssa, -1
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds [201 x i64], ptr @dp, i64 0, i64 %63
  %65 = load i64, ptr %64, align 8, !tbaa !15
  %66 = trunc i64 %65 to i32
  %67 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i32 noundef %66)
  ret i32 0

._crit_edge70.loopexit75:                         ; preds = %.loopexit
  %.pre96 = sext i32 %102 to i64
  br label %._crit_edge70

._crit_edge70.loopexit.unr-lcssa:                 ; preds = %.lr.ph69.split.us, %.lr.ph69.split.us.preheader
  %indvars.iv91.unr = phi i64 [ 1, %.lr.ph69.split.us.preheader ], [ %indvars.iv.next92.3, %.lr.ph69.split.us ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge70, label %.lr.ph69.split.us.epil

.lr.ph69.split.us.epil:                           ; preds = %._crit_edge70.loopexit.unr-lcssa, %.lr.ph69.split.us.epil
  %indvars.iv91.epil = phi i64 [ %indvars.iv.next92.epil, %.lr.ph69.split.us.epil ], [ %indvars.iv91.unr, %._crit_edge70.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph69.split.us.epil ], [ 0, %._crit_edge70.loopexit.unr-lcssa ]
  %68 = add nsw i64 %indvars.iv91.epil, -1
  %69 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %68, i64 %indvars.iv91.epil
  store i64 1, ptr %69, align 8, !tbaa !15
  %indvars.iv.next92.epil = add nuw nsw i64 %indvars.iv91.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %._crit_edge70, label %.lr.ph69.split.us.epil, !llvm.loop !18

._crit_edge70:                                    ; preds = %._crit_edge70.loopexit.unr-lcssa, %.lr.ph69.split.us.epil, %._crit_edge70.loopexit75, %.preheader
  %.pre-phi = phi i64 [ %.pre96, %._crit_edge70.loopexit75 ], [ %49, %.preheader ], [ %49, %.lr.ph69.split.us.epil ], [ %49, %._crit_edge70.loopexit.unr-lcssa ]
  %70 = phi i32 [ %102, %._crit_edge70.loopexit75 ], [ %48, %.preheader ], [ %48, %.lr.ph69.split.us.epil ], [ %48, %._crit_edge70.loopexit.unr-lcssa ]
  %indvars.iv.next86 = add nuw nsw i64 %indvars.iv85, 1
  %71 = icmp slt i64 %indvars.iv.next86, %.pre-phi
  br i1 %71, label %.preheader, label %._crit_edge73, !llvm.loop !20

.lr.ph69.split:                                   ; preds = %.lr.ph69, %.loopexit
  %72 = phi i32 [ %102, %.loopexit ], [ %48, %.lr.ph69 ]
  %73 = phi i32 [ %103, %.loopexit ], [ %48, %.lr.ph69 ]
  %indvars.iv87 = phi i64 [ %indvars.iv.next88, %.loopexit ], [ %indvars.iv85, %.lr.ph69 ]
  %indvars.iv80 = phi i64 [ %indvars.iv.next81, %.loopexit ], [ 1, %.lr.ph69 ]
  %74 = sub nuw nsw i64 %indvars.iv87, %indvars.iv85
  %75 = add nuw nsw i64 %74, 1
  %76 = icmp ult i64 %75, %indvars.iv87
  br i1 %76, label %.lr.ph66, label %.loopexit

.lr.ph66:                                         ; preds = %.lr.ph69.split
  %77 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %74, i64 %indvars.iv87
  br label %78

78:                                               ; preds = %.lr.ph66, %101
  %indvars.iv82 = phi i64 [ %indvars.iv80, %.lr.ph66 ], [ %indvars.iv.next83, %101 ]
  %79 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %74) #6
  call void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16) %2, ptr noundef nonnull align 4 dereferenceable(8) %79)
  %80 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %indvars.iv87) #6
  call void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 4 dereferenceable(8) %80)
  %81 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @p, i64 noundef %indvars.iv82) #6
  call void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16) %4, ptr noundef nonnull align 4 dereferenceable(8) %81)
  %82 = load i64, ptr %2, align 8
  %83 = load i64, ptr %45, align 8
  %84 = load i64, ptr %3, align 8
  %85 = load i64, ptr %46, align 8
  %86 = load i64, ptr %4, align 8
  %87 = load i64, ptr %47, align 8
  %88 = call noundef zeroext i1 @_Z4goodSt4pairIxxES0_S0_(i64 %82, i64 %83, i64 %84, i64 %85, i64 %86, i64 %87)
  br i1 %88, label %89, label %101

89:                                               ; preds = %78
  %90 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %74, i64 %indvars.iv82
  %91 = load i64, ptr %90, align 8, !tbaa !15
  %92 = getelementptr inbounds [201 x [201 x i64]], ptr @dp, i64 0, i64 %indvars.iv82, i64 %indvars.iv87
  %93 = load i64, ptr %92, align 8, !tbaa !15
  %94 = mul nsw i64 %93, %91
  %95 = load i64, ptr @MOD, align 8, !tbaa !15
  %96 = srem i64 %94, %95
  %97 = load i64, ptr %77, align 8, !tbaa !15
  %98 = add nsw i64 %97, %96
  store i64 %98, ptr %77, align 8, !tbaa !15
  %.not = icmp slt i64 %98, %95
  br i1 %.not, label %101, label %99

99:                                               ; preds = %89
  %100 = sub nsw i64 %98, %95
  store i64 %100, ptr %77, align 8, !tbaa !15
  br label %101

101:                                              ; preds = %89, %99, %78
  %indvars.iv.next83 = add nuw nsw i64 %indvars.iv82, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next83, %indvars.iv87
  br i1 %exitcond.not, label %.loopexit.loopexit, label %78, !llvm.loop !21

.loopexit.loopexit:                               ; preds = %101
  %.pre95 = load i32, ptr @n, align 4, !tbaa !5
  br label %.loopexit

.loopexit:                                        ; preds = %.loopexit.loopexit, %.lr.ph69.split
  %102 = phi i32 [ %.pre95, %.loopexit.loopexit ], [ %72, %.lr.ph69.split ]
  %103 = phi i32 [ %.pre95, %.loopexit.loopexit ], [ %73, %.lr.ph69.split ]
  %indvars.iv.next88 = add nuw nsw i64 %indvars.iv87, 1
  %104 = sext i32 %103 to i64
  %105 = icmp slt i64 %indvars.iv.next88, %104
  %indvars.iv.next81 = add nuw nsw i64 %indvars.iv80, 1
  br i1 %105, label %.lr.ph69.split, label %._crit_edge70.loopexit75, !llvm.loop !17
}

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt7reverseIN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS3_SaIS3_EEEEEvT_S9_(ptr, ptr) local_unnamed_addr #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt4pairIxxEC2IiiTnNSt9enable_ifIXaaclsr6_PCCFPIT_T0_EE18_ConstructiblePairIS3_S4_EEclsr6_PCCFPIS3_S4_EE26_ImplicitlyConvertiblePairIS3_S4_EEEbE4typeELb1EEERKS_IS3_S4_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(8)) unnamed_addr #0 align 2

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

attributes #0 = { 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 #1 = { 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 #2 = { 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 #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { 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 #6 = { 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 = !{!12, !6, i64 4}
!14 = distinct !{!14, !10}
!15 = !{!16, !16, i64 0}
!16 = !{!"long long", !7, i64 0}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.unroll.disable"}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}


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