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

; 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
@h = external dso_local global [2000001 x i32], align 16
@dsu = external dso_local global [2000001 x i32], align 16
@m = external dso_local global i32, align 4
@ans = external dso_local global i32, align 4
@buf = external dso_local global [2000001 x i8], align 16
@e = external dso_local global [2000001 x %"struct.std::pair"], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_Z8dsu_findi(i32 noundef) #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 {
  %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
  %10 = alloca %"struct.std::pair", align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %14 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @buf)
  %15 = call i64 @strlen(ptr noundef @buf) #9
  %16 = trunc i64 %15 to i32
  store i32 %16, ptr @n, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #10
  %17 = load i32, ptr @n, align 4, !tbaa !5
  %18 = sub nsw i32 %17, 1
  store i32 %18, ptr %2, align 4, !tbaa !5
  br label %19

19:                                               ; preds = %37, %0
  %20 = load i32, ptr %2, align 4, !tbaa !5
  %21 = icmp sge i32 %20, 0
  br i1 %21, label %23, label %22

22:                                               ; preds = %19
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #10
  br label %40

23:                                               ; preds = %19
  %24 = load i32, ptr %2, align 4, !tbaa !5
  %25 = sext i32 %24 to i64
  %26 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %25
  %27 = load i8, ptr %26, align 1, !tbaa !9
  %28 = load i32, ptr %2, align 4, !tbaa !5
  %29 = shl i32 %28, 1
  %30 = sext i32 %29 to i64
  %31 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %30
  store i8 %27, ptr %31, align 1, !tbaa !9
  %32 = load i32, ptr %2, align 4, !tbaa !5
  %33 = shl i32 %32, 1
  %34 = or i32 %33, 1
  %35 = sext i32 %34 to i64
  %36 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %35
  store i8 35, ptr %36, align 1, !tbaa !9
  br label %37

37:                                               ; preds = %23
  %38 = load i32, ptr %2, align 4, !tbaa !5
  %39 = add nsw i32 %38, -1
  store i32 %39, ptr %2, align 4, !tbaa !5
  br label %19, !llvm.loop !10

40:                                               ; preds = %22
  %41 = load i32, ptr @n, align 4, !tbaa !5
  %42 = shl i32 %41, 1
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %43
  store i8 0, ptr %44, align 1, !tbaa !9
  %45 = load i32, ptr @n, align 4, !tbaa !5
  %46 = shl i32 %45, 1
  store i32 %46, ptr @n, align 4, !tbaa !5
  %47 = load i32, ptr @n, align 4, !tbaa !5
  %48 = sext i32 %47 to i64
  %49 = mul i64 %48, 4
  call void @llvm.memset.p0.i64(ptr align 16 @dsu, i8 -1, i64 %49, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #10
  store i32 0, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #10
  store i32 0, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #10
  store i32 0, ptr %5, align 4, !tbaa !5
  br label %50

50:                                               ; preds = %145, %40
  %51 = load i32, ptr %3, align 4, !tbaa !5
  %52 = load i32, ptr @n, align 4, !tbaa !5
  %53 = icmp slt i32 %51, %52
  br i1 %53, label %55, label %54

54:                                               ; preds = %50
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #10
  br label %148

55:                                               ; preds = %50
  %56 = load i32, ptr %3, align 4, !tbaa !5
  %57 = load i32, ptr %4, align 4, !tbaa !5
  %58 = icmp slt i32 %56, %57
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #10
  br i1 %58, label %59, label %71

59:                                               ; preds = %55
  %60 = load i32, ptr %4, align 4, !tbaa !5
  %61 = load i32, ptr %3, align 4, !tbaa !5
  %62 = sub nsw i32 %60, %61
  store i32 %62, ptr %6, align 4, !tbaa !5
  %63 = load i32, ptr %5, align 4, !tbaa !5
  %64 = shl i32 %63, 1
  %65 = load i32, ptr %3, align 4, !tbaa !5
  %66 = sub nsw i32 %64, %65
  %67 = sext i32 %66 to i64
  %68 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %67
  %69 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %6, ptr noundef nonnull align 4 dereferenceable(4) %68)
  %70 = load i32, ptr %69, align 4, !tbaa !5
  br label %72

71:                                               ; preds = %55
  br label %72

72:                                               ; preds = %71, %59
  %73 = phi i32 [ %70, %59 ], [ 1, %71 ]
  %74 = load i32, ptr %3, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %75
  store i32 %73, ptr %76, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #10
  br label %77

77:                                               ; preds = %121, %72
  %78 = load i32, ptr %3, align 4, !tbaa !5
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %79
  %81 = load i32, ptr %80, align 4, !tbaa !5
  %82 = load i32, ptr %3, align 4, !tbaa !5
  %83 = icmp sle i32 %81, %82
  br i1 %83, label %84, label %106

84:                                               ; preds = %77
  %85 = load i32, ptr %3, align 4, !tbaa !5
  %86 = load i32, ptr %3, align 4, !tbaa !5
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %87
  %89 = load i32, ptr %88, align 4, !tbaa !5
  %90 = sub nsw i32 %85, %89
  %91 = sext i32 %90 to i64
  %92 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %91
  %93 = load i8, ptr %92, align 1, !tbaa !9
  %94 = sext i8 %93 to i32
  %95 = load i32, ptr %3, align 4, !tbaa !5
  %96 = load i32, ptr %3, align 4, !tbaa !5
  %97 = sext i32 %96 to i64
  %98 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %97
  %99 = load i32, ptr %98, align 4, !tbaa !5
  %100 = add nsw i32 %95, %99
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %101
  %103 = load i8, ptr %102, align 1, !tbaa !9
  %104 = sext i8 %103 to i32
  %105 = icmp eq i32 %94, %104
  br label %106

106:                                              ; preds = %84, %77
  %107 = phi i1 [ false, %77 ], [ %105, %84 ]
  br i1 %107, label %108, label %127

108:                                              ; preds = %106
  %109 = load i32, ptr %3, align 4, !tbaa !5
  %110 = load i32, ptr %3, align 4, !tbaa !5
  %111 = sext i32 %110 to i64
  %112 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %111
  %113 = load i32, ptr %112, align 4, !tbaa !5
  %114 = sub nsw i32 %109, %113
  %115 = load i32, ptr %3, align 4, !tbaa !5
  %116 = load i32, ptr %3, align 4, !tbaa !5
  %117 = sext i32 %116 to i64
  %118 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %117
  %119 = load i32, ptr %118, align 4, !tbaa !5
  %120 = add nsw i32 %115, %119
  call void @_Z9dsu_mergeii(i32 noundef %114, i32 noundef %120)
  br label %121

121:                                              ; preds = %108
  %122 = load i32, ptr %3, align 4, !tbaa !5
  %123 = sext i32 %122 to i64
  %124 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %123
  %125 = load i32, ptr %124, align 4, !tbaa !5
  %126 = add nsw i32 %125, 1
  store i32 %126, ptr %124, align 4, !tbaa !5
  br label %77, !llvm.loop !12

127:                                              ; preds = %106
  %128 = load i32, ptr %4, align 4, !tbaa !5
  %129 = load i32, ptr %3, align 4, !tbaa !5
  %130 = load i32, ptr %3, align 4, !tbaa !5
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %131
  %133 = load i32, ptr %132, align 4, !tbaa !5
  %134 = add nsw i32 %129, %133
  %135 = icmp slt i32 %128, %134
  br i1 %135, label %136, label %144

136:                                              ; preds = %127
  %137 = load i32, ptr %3, align 4, !tbaa !5
  %138 = load i32, ptr %3, align 4, !tbaa !5
  %139 = sext i32 %138 to i64
  %140 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %139
  %141 = load i32, ptr %140, align 4, !tbaa !5
  %142 = add nsw i32 %137, %141
  store i32 %142, ptr %4, align 4, !tbaa !5
  %143 = load i32, ptr %3, align 4, !tbaa !5
  store i32 %143, ptr %5, align 4, !tbaa !5
  br label %144

144:                                              ; preds = %136, %127
  br label %145

145:                                              ; preds = %144
  %146 = load i32, ptr %3, align 4, !tbaa !5
  %147 = add nsw i32 %146, 1
  store i32 %147, ptr %3, align 4, !tbaa !5
  br label %50, !llvm.loop !13

148:                                              ; preds = %54
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #10
  store i32 0, ptr %7, align 4, !tbaa !5
  br label %149

149:                                              ; preds = %198, %148
  %150 = load i32, ptr %7, align 4, !tbaa !5
  %151 = load i32, ptr @n, align 4, !tbaa !5
  %152 = icmp slt i32 %150, %151
  br i1 %152, label %154, label %153

153:                                              ; preds = %149
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #10
  br label %201

154:                                              ; preds = %149
  %155 = load i32, ptr %7, align 4, !tbaa !5
  %156 = load i32, ptr %7, align 4, !tbaa !5
  %157 = sext i32 %156 to i64
  %158 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %157
  %159 = load i32, ptr %158, align 4, !tbaa !5
  %160 = sub nsw i32 %155, %159
  %161 = icmp sge i32 %160, 0
  br i1 %161, label %162, label %197

162:                                              ; preds = %154
  %163 = load i32, ptr %7, align 4, !tbaa !5
  %164 = load i32, ptr %7, align 4, !tbaa !5
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %165
  %167 = load i32, ptr %166, align 4, !tbaa !5
  %168 = add nsw i32 %163, %167
  %169 = load i32, ptr @n, align 4, !tbaa !5
  %170 = icmp slt i32 %168, %169
  br i1 %170, label %171, label %197

171:                                              ; preds = %162
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #10
  %172 = load i32, ptr %7, align 4, !tbaa !5
  %173 = load i32, ptr %7, align 4, !tbaa !5
  %174 = sext i32 %173 to i64
  %175 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %174
  %176 = load i32, ptr %175, align 4, !tbaa !5
  %177 = sub nsw i32 %172, %176
  %178 = call noundef i32 @_Z8dsu_findi(i32 noundef %177)
  store i32 %178, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #10
  %179 = load i32, ptr %7, align 4, !tbaa !5
  %180 = load i32, ptr %7, align 4, !tbaa !5
  %181 = sext i32 %180 to i64
  %182 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %181
  %183 = load i32, ptr %182, align 4, !tbaa !5
  %184 = add nsw i32 %179, %183
  %185 = call noundef i32 @_Z8dsu_findi(i32 noundef %184)
  store i32 %185, ptr %9, align 4, !tbaa !5
  %186 = load i32, ptr %8, align 4, !tbaa !5
  %187 = load i32, ptr %9, align 4, !tbaa !5
  %188 = icmp slt i32 %186, %187
  br i1 %188, label %189, label %190

189:                                              ; preds = %171
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %8, ptr noundef nonnull align 4 dereferenceable(4) %9) #10
  br label %190

190:                                              ; preds = %189, %171
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #10
  %191 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %8, ptr noundef nonnull align 4 dereferenceable(4) %9)
  store i64 %191, ptr %10, align 4
  %192 = load i32, ptr @m, align 4, !tbaa !5
  %193 = add nsw i32 %192, 1
  store i32 %193, ptr @m, align 4, !tbaa !5
  %194 = sext i32 %192 to i64
  %195 = getelementptr inbounds [2000001 x %"struct.std::pair"], ptr @e, i64 0, i64 %194
  %196 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt4pairIiiEaSEOS0_(ptr noundef nonnull align 4 dereferenceable(8) %195, ptr noundef nonnull align 4 dereferenceable(8) %10) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #10
  br label %197

197:                                              ; preds = %190, %162, %154
  br label %198

198:                                              ; preds = %197
  %199 = load i32, ptr %7, align 4, !tbaa !5
  %200 = add nsw i32 %199, 1
  store i32 %200, ptr %7, align 4, !tbaa !5
  br label %149, !llvm.loop !14

201:                                              ; preds = %153
  %202 = load i32, ptr @m, align 4, !tbaa !5
  %203 = sext i32 %202 to i64
  %204 = getelementptr inbounds %"struct.std::pair", ptr @e, i64 %203
  call void @_ZSt4sortIPSt4pairIiiEEvT_S3_(ptr noundef @e, ptr noundef %204)
  %205 = load i32, ptr @m, align 4, !tbaa !5
  %206 = sext i32 %205 to i64
  %207 = getelementptr inbounds %"struct.std::pair", ptr @e, i64 %206
  %208 = call noundef ptr @_ZSt6uniqueIPSt4pairIiiEET_S3_S3_(ptr noundef @e, ptr noundef %207)
  %209 = ptrtoint ptr %208 to i64
  %210 = sub i64 %209, ptrtoint (ptr @e to i64)
  %211 = sdiv exact i64 %210, 8
  %212 = trunc i64 %211 to i32
  store i32 %212, ptr @m, align 4, !tbaa !5
  store i32 1, ptr @ans, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #10
  store i32 0, ptr %11, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #10
  store i32 0, ptr %12, align 4, !tbaa !5
  br label %213

213:                                              ; preds = %253, %201
  %214 = load i32, ptr %11, align 4, !tbaa !5
  %215 = load i32, ptr @n, align 4, !tbaa !5
  %216 = icmp slt i32 %214, %215
  br i1 %216, label %218, label %217

217:                                              ; preds = %213
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #10
  br label %256

218:                                              ; preds = %213
  %219 = load i32, ptr %11, align 4, !tbaa !5
  %220 = call noundef i32 @_Z8dsu_findi(i32 noundef %219)
  %221 = load i32, ptr %11, align 4, !tbaa !5
  %222 = icmp eq i32 %220, %221
  br i1 %222, label %223, label %252

223:                                              ; preds = %218
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #10
  store i32 26, ptr %13, align 4, !tbaa !5
  br label %224

224:                                              ; preds = %239, %223
  %225 = load i32, ptr %12, align 4, !tbaa !5
  %226 = load i32, ptr @m, align 4, !tbaa !5
  %227 = icmp slt i32 %225, %226
  br i1 %227, label %228, label %236

228:                                              ; preds = %224
  %229 = load i32, ptr %12, align 4, !tbaa !5
  %230 = sext i32 %229 to i64
  %231 = getelementptr inbounds [2000001 x %"struct.std::pair"], ptr @e, i64 0, i64 %230
  %232 = getelementptr inbounds %"struct.std::pair", ptr %231, i32 0, i32 0
  %233 = load i32, ptr %232, align 8, !tbaa !15
  %234 = load i32, ptr %11, align 4, !tbaa !5
  %235 = icmp eq i32 %233, %234
  br label %236

236:                                              ; preds = %228, %224
  %237 = phi i1 [ false, %224 ], [ %235, %228 ]
  br i1 %237, label %238, label %244

238:                                              ; preds = %236
  br label %239

239:                                              ; preds = %238
  %240 = load i32, ptr %12, align 4, !tbaa !5
  %241 = add nsw i32 %240, 1
  store i32 %241, ptr %12, align 4, !tbaa !5
  %242 = load i32, ptr %13, align 4, !tbaa !5
  %243 = add nsw i32 %242, -1
  store i32 %243, ptr %13, align 4, !tbaa !5
  br label %224, !llvm.loop !17

244:                                              ; preds = %236
  %245 = load i32, ptr @ans, align 4, !tbaa !5
  %246 = sext i32 %245 to i64
  %247 = load i32, ptr %13, align 4, !tbaa !5
  %248 = sext i32 %247 to i64
  %249 = mul nsw i64 %246, %248
  %250 = srem i64 %249, 1000000007
  %251 = trunc i64 %250 to i32
  store i32 %251, ptr @ans, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #10
  br label %252

252:                                              ; preds = %244, %218
  br label %253

253:                                              ; preds = %252
  %254 = load i32, ptr %11, align 4, !tbaa !5
  %255 = add nsw i32 %254, 2
  store i32 %255, ptr %11, align 4, !tbaa !5
  br label %213, !llvm.loop !18

256:                                              ; preds = %217
  %257 = load i32, ptr @ans, align 4, !tbaa !5
  %258 = call i32 (ptr, ...) @printf(ptr noundef @.str.1, i32 noundef %257)
  ret i32 0
}

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

; Function Attrs: nounwind willreturn memory(read)
declare i64 @strlen(ptr noundef) #4

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #1

; 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)) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt4pairIiiEaSEOS0_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(8)) #7 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZSt6uniqueIPSt4pairIiiEET_S3_S3_(ptr noundef, ptr noundef) #8

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

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


; 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 local_unnamed_addr global i32, align 4
@h = external dso_local global [2000001 x i32], align 16
@dsu = external dso_local local_unnamed_addr global [2000001 x i32], align 16
@m = external dso_local local_unnamed_addr global i32, align 4
@ans = external dso_local local_unnamed_addr global i32, align 4
@buf = external dso_local global [2000001 x i8], align 16
@e = external dso_local global [2000001 x %"struct.std::pair"], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_Z8dsu_findi(i32 noundef) local_unnamed_addr #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca %"struct.std::pair", align 8
  %5 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @buf)
  %6 = tail call i64 @strlen(ptr noundef nonnull dereferenceable(1) @buf) #10
  %7 = trunc i64 %6 to i32
  %8 = icmp sgt i32 %7, 0
  br i1 %8, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %0
  %9 = and i64 %6, 2147483647
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %0
  %10 = shl i32 %7, 1
  %11 = sext i32 %10 to i64
  %12 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %11
  store i8 0, ptr %12, align 2, !tbaa !5
  store i32 %10, ptr @n, align 4, !tbaa !8
  %13 = shl nsw i64 %11, 2
  tail call void @llvm.memset.p0.i64(ptr nonnull align 16 @dsu, i8 -1, i64 %13, i1 false)
  %14 = icmp sgt i32 %10, 0
  br i1 %14, label %.lr.ph79, label %._crit_edge82

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ %9, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %indvars.iv.next = add nsw i64 %indvars.iv, -1
  %15 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %indvars.iv.next
  %16 = load i8, ptr %15, align 1, !tbaa !5
  %sext = shl i64 %indvars.iv.next, 33
  %17 = ashr exact i64 %sext, 32
  %18 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %17
  store i8 %16, ptr %18, align 2, !tbaa !5
  %indvars.iv.next.tr = trunc i64 %indvars.iv.next to i32
  %19 = shl i32 %indvars.iv.next.tr, 1
  %20 = or disjoint i32 %19, 1
  %21 = sext i32 %20 to i64
  %22 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %21
  store i8 35, ptr %22, align 1, !tbaa !5
  %23 = icmp ugt i64 %indvars.iv, 1
  br i1 %23, label %.lr.ph, label %._crit_edge, !llvm.loop !10

.preheader68:                                     ; preds = %.critedge
  %24 = icmp sgt i32 %56, 0
  br i1 %24, label %.lr.ph81, label %._crit_edge82

.lr.ph79:                                         ; preds = %._crit_edge, %.critedge
  %indvars.iv98 = phi i64 [ %indvars.iv.next99, %.critedge ], [ 0, %._crit_edge ]
  %.05677 = phi i32 [ %spec.select66, %.critedge ], [ 0, %._crit_edge ]
  %.05876 = phi i32 [ %spec.select, %.critedge ], [ 0, %._crit_edge ]
  %25 = sext i32 %.05876 to i64
  %26 = icmp slt i64 %indvars.iv98, %25
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #11
  br i1 %26, label %27, label %36

27:                                               ; preds = %.lr.ph79
  %28 = trunc nuw nsw i64 %indvars.iv98 to i32
  %29 = sub nsw i32 %.05876, %28
  store i32 %29, ptr %1, align 4, !tbaa !8
  %30 = shl i32 %.05677, 1
  %31 = sub nsw i32 %30, %28
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %32
  %34 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %1, ptr noundef nonnull align 4 dereferenceable(4) %33)
  %35 = load i32, ptr %34, align 4, !tbaa !8
  br label %36

36:                                               ; preds = %.lr.ph79, %27
  %37 = phi i32 [ %35, %27 ], [ 1, %.lr.ph79 ]
  %38 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %indvars.iv98
  store i32 %37, ptr %38, align 4, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #11
  %39 = sext i32 %37 to i64
  %.not6570 = icmp slt i64 %indvars.iv98, %39
  %.pre108 = trunc nuw nsw i64 %indvars.iv98 to i32
  br i1 %.not6570, label %.critedge, label %.lr.ph72

.lr.ph72:                                         ; preds = %36, %50
  %40 = phi i32 [ %52, %50 ], [ %37, %36 ]
  %41 = sub nsw i32 %.pre108, %40
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %42
  %44 = load i8, ptr %43, align 1, !tbaa !5
  %45 = add nsw i32 %40, %.pre108
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds [2000001 x i8], ptr @buf, i64 0, i64 %46
  %48 = load i8, ptr %47, align 1, !tbaa !5
  %49 = icmp eq i8 %44, %48
  br i1 %49, label %50, label %.critedge

50:                                               ; preds = %.lr.ph72
  call void @_Z9dsu_mergeii(i32 noundef %41, i32 noundef %45)
  %51 = load i32, ptr %38, align 4, !tbaa !8
  %52 = add nsw i32 %51, 1
  store i32 %52, ptr %38, align 4, !tbaa !8
  %53 = sext i32 %51 to i64
  %.not65.not = icmp sgt i64 %indvars.iv98, %53
  br i1 %.not65.not, label %.lr.ph72, label %.critedge, !llvm.loop !12

.critedge:                                        ; preds = %.lr.ph72, %50, %36
  %.lcssa = phi i32 [ %37, %36 ], [ %52, %50 ], [ %40, %.lr.ph72 ]
  %54 = add nsw i32 %.lcssa, %.pre108
  %55 = icmp slt i32 %.05876, %54
  %spec.select = call i32 @llvm.smax.i32(i32 %.05876, i32 %54)
  %spec.select66 = select i1 %55, i32 %.pre108, i32 %.05677
  %indvars.iv.next99 = add nuw nsw i64 %indvars.iv98, 1
  %56 = load i32, ptr @n, align 4, !tbaa !8
  %57 = sext i32 %56 to i64
  %58 = icmp slt i64 %indvars.iv.next99, %57
  br i1 %58, label %.lr.ph79, label %.preheader68, !llvm.loop !13

._crit_edge82:                                    ; preds = %95, %._crit_edge, %.preheader68
  %59 = load i32, ptr @m, align 4, !tbaa !8
  %60 = sext i32 %59 to i64
  %61 = getelementptr inbounds %"struct.std::pair", ptr @e, i64 %60
  call void @_ZSt4sortIPSt4pairIiiEEvT_S3_(ptr noundef nonnull @e, ptr noundef nonnull %61)
  %62 = load i32, ptr @m, align 4, !tbaa !8
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds %"struct.std::pair", ptr @e, i64 %63
  %65 = call noundef ptr @_ZSt6uniqueIPSt4pairIiiEET_S3_S3_(ptr noundef nonnull @e, ptr noundef nonnull %64)
  %66 = ptrtoint ptr %65 to i64
  %67 = sub i64 %66, ptrtoint (ptr @e to i64)
  %68 = lshr exact i64 %67, 3
  %69 = trunc i64 %68 to i32
  store i32 %69, ptr @m, align 4, !tbaa !8
  store i32 1, ptr @ans, align 4, !tbaa !8
  %70 = load i32, ptr @n, align 4, !tbaa !8
  %71 = icmp sgt i32 %70, 0
  br i1 %71, label %.lr.ph95, label %._crit_edge96

.lr.ph81:                                         ; preds = %.preheader68, %95
  %72 = phi i32 [ %96, %95 ], [ %56, %.preheader68 ]
  %indvars.iv101 = phi i64 [ %indvars.iv.next102, %95 ], [ 0, %.preheader68 ]
  %73 = getelementptr inbounds [2000001 x i32], ptr @h, i64 0, i64 %indvars.iv101
  %74 = load i32, ptr %73, align 4, !tbaa !8
  %75 = sext i32 %74 to i64
  %.not = icmp sge i64 %indvars.iv101, %75
  %76 = trunc nuw nsw i64 %indvars.iv101 to i32
  %77 = add nsw i32 %74, %76
  %78 = icmp slt i32 %77, %72
  %or.cond = select i1 %.not, i1 %78, i1 false
  br i1 %or.cond, label %79, label %95

79:                                               ; preds = %.lr.ph81
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #11
  %80 = sub nsw i32 %76, %74
  %81 = call noundef i32 @_Z8dsu_findi(i32 noundef %80)
  store i32 %81, ptr %2, align 4, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #11
  %82 = load i32, ptr %73, align 4, !tbaa !8
  %83 = add nsw i32 %82, %76
  %84 = call noundef i32 @_Z8dsu_findi(i32 noundef %83)
  store i32 %84, ptr %3, align 4, !tbaa !8
  %85 = load i32, ptr %2, align 4, !tbaa !8
  %86 = icmp slt i32 %85, %84
  br i1 %86, label %87, label %88

87:                                               ; preds = %79
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %2, ptr noundef nonnull align 4 dereferenceable(4) %3) #11
  br label %88

88:                                               ; preds = %87, %79
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #11
  %89 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %2, ptr noundef nonnull align 4 dereferenceable(4) %3)
  store i64 %89, ptr %4, align 8
  %90 = load i32, ptr @m, align 4, !tbaa !8
  %91 = add nsw i32 %90, 1
  store i32 %91, ptr @m, align 4, !tbaa !8
  %92 = sext i32 %90 to i64
  %93 = getelementptr inbounds [2000001 x %"struct.std::pair"], ptr @e, i64 0, i64 %92
  %94 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt4pairIiiEaSEOS0_(ptr noundef nonnull align 4 dereferenceable(8) %93, ptr noundef nonnull align 4 dereferenceable(8) %4) #11
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #11
  %.pre = load i32, ptr @n, align 4, !tbaa !8
  br label %95

95:                                               ; preds = %.lr.ph81, %88
  %96 = phi i32 [ %72, %.lr.ph81 ], [ %.pre, %88 ]
  %indvars.iv.next102 = add nuw nsw i64 %indvars.iv101, 1
  %97 = sext i32 %96 to i64
  %98 = icmp slt i64 %indvars.iv.next102, %97
  br i1 %98, label %.lr.ph81, label %._crit_edge82, !llvm.loop !14

._crit_edge96.loopexit:                           ; preds = %121
  %.pre107 = load i32, ptr @ans, align 4, !tbaa !8
  br label %._crit_edge96

._crit_edge96:                                    ; preds = %._crit_edge96.loopexit, %._crit_edge82
  %99 = phi i32 [ %.pre107, %._crit_edge96.loopexit ], [ 1, %._crit_edge82 ]
  %100 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef %99)
  ret i32 0

.lr.ph95:                                         ; preds = %._crit_edge82, %121
  %.05393 = phi i32 [ %.2, %121 ], [ 0, %._crit_edge82 ]
  %.05491 = phi i32 [ %122, %121 ], [ 0, %._crit_edge82 ]
  %101 = call noundef i32 @_Z8dsu_findi(i32 noundef %.05491)
  %102 = icmp eq i32 %101, %.05491
  br i1 %102, label %.preheader, label %121

.preheader:                                       ; preds = %.lr.ph95
  %103 = load i32, ptr @m, align 4, !tbaa !8
  %104 = icmp slt i32 %.05393, %103
  br i1 %104, label %.lr.ph85.preheader, label %.critedge2

.lr.ph85.preheader:                               ; preds = %.preheader
  %105 = sext i32 %.05393 to i64
  %106 = sext i32 %103 to i64
  %107 = add i32 %.05393, 26
  %108 = sub i32 %107, %103
  br label %.lr.ph85

.lr.ph85:                                         ; preds = %.lr.ph85.preheader, %112
  %indvars.iv104 = phi i64 [ %105, %.lr.ph85.preheader ], [ %indvars.iv.next105, %112 ]
  %.084 = phi i32 [ 26, %.lr.ph85.preheader ], [ %113, %112 ]
  %109 = getelementptr inbounds [2000001 x %"struct.std::pair"], ptr @e, i64 0, i64 %indvars.iv104
  %110 = load i32, ptr %109, align 8, !tbaa !15
  %111 = icmp eq i32 %110, %.05491
  br i1 %111, label %112, label %.critedge2.loopexit.split.loop.exit111

112:                                              ; preds = %.lr.ph85
  %indvars.iv.next105 = add nsw i64 %indvars.iv104, 1
  %113 = add nsw i32 %.084, -1
  %exitcond.not = icmp eq i64 %indvars.iv.next105, %106
  br i1 %exitcond.not, label %.critedge2, label %.lr.ph85, !llvm.loop !17

.critedge2.loopexit.split.loop.exit111:           ; preds = %.lr.ph85
  %114 = trunc nsw i64 %indvars.iv104 to i32
  br label %.critedge2

.critedge2:                                       ; preds = %112, %.critedge2.loopexit.split.loop.exit111, %.preheader
  %.1.lcssa = phi i32 [ %.05393, %.preheader ], [ %114, %.critedge2.loopexit.split.loop.exit111 ], [ %103, %112 ]
  %.0.lcssa = phi i32 [ 26, %.preheader ], [ %.084, %.critedge2.loopexit.split.loop.exit111 ], [ %108, %112 ]
  %115 = load i32, ptr @ans, align 4, !tbaa !8
  %116 = sext i32 %115 to i64
  %117 = sext i32 %.0.lcssa to i64
  %118 = mul nsw i64 %116, %117
  %119 = srem i64 %118, 1000000007
  %120 = trunc nsw i64 %119 to i32
  store i32 %120, ptr @ans, align 4, !tbaa !8
  br label %121

121:                                              ; preds = %.lr.ph95, %.critedge2
  %.2 = phi i32 [ %.1.lcssa, %.critedge2 ], [ %.05393, %.lr.ph95 ]
  %122 = add nuw nsw i32 %.05491, 2
  %123 = load i32, ptr @n, align 4, !tbaa !8
  %124 = icmp slt i32 %122, %123
  br i1 %124, label %.lr.ph95, label %._crit_edge96.loopexit, !llvm.loop !18
}

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare i64 @strlen(ptr nocapture noundef) local_unnamed_addr #4

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1

; 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 #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt4pairIiiEaSEOS0_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #7 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZSt6uniqueIPSt4pairIiiEET_S3_S3_(ptr noundef, ptr noundef) local_unnamed_addr #8

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

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

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 = { inlinehint 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 #2 = { 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 #3 = { 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 #4 = { mustprogress nofree nounwind willreturn memory(argmem: read) "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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { 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 #8 = { 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 #9 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #10 = { nounwind willreturn memory(read) }
attributes #11 = { 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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"int", !6, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}
!13 = distinct !{!13, !11}
!14 = distinct !{!14, !11}
!15 = !{!16, !9, i64 0}
!16 = !{!"_ZTSSt4pairIiiE", !9, i64 0, !9, i64 4}
!17 = distinct !{!17, !11}
!18 = distinct !{!18, !11}


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