; LLVM IR from sunkafei/xcpc-algorithm-templates :: 算法/数据结构 (可修改优先队列)

; 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.ModifiablePriorityQueue = type { [420000 x i32], [420000 x i32], [420000 x i32], i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"struct.std::pair" = type { i32, i32 }

@__dso_handle = external hidden global i8
@_ZZ4mainE1d = external hidden global [210000 x i32], align 16
@_ZZ4mainE1G = external hidden global [210000 x %"class.std::vector"], align 16
@_ZGVZ4mainE1G = external hidden global i64, align 8
@.str = external hidden unnamed_addr constant [9 x i8], align 1
@_ZZ4mainE1Q = external hidden global %struct.ModifiablePriorityQueue, align 4
@_ZGVZ4mainE1Q = external hidden global i64, align 8
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: nounwind
declare i32 @__cxa_atexit(ptr, ptr, ptr) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #1 personality ptr @__gxx_personality_v0 {
  %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 ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca ptr, align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca %"struct.std::pair", align 4
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %21 = load atomic i8, ptr @_ZGVZ4mainE1G acquire, align 8
  %22 = icmp eq i8 %21, 0
  br i1 %22, label %23, label %33, !prof !5

23:                                               ; preds = %0
  %24 = call i32 @__cxa_guard_acquire(ptr @_ZGVZ4mainE1G) #0
  %25 = icmp ne i32 %24, 0
  br i1 %25, label %26, label %33

26:                                               ; preds = %23
  br label %27

27:                                               ; preds = %27, %26
  %28 = phi ptr [ @_ZZ4mainE1G, %26 ], [ %29, %27 ]
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %28) #0
  %29 = getelementptr inbounds %"class.std::vector", ptr %28, i64 1
  %30 = icmp eq ptr %29, getelementptr inbounds (%"class.std::vector", ptr @_ZZ4mainE1G, i64 210000)
  br i1 %30, label %31, label %27

31:                                               ; preds = %27
  %32 = call i32 @__cxa_atexit(ptr @__cxx_global_array_dtor, ptr null, ptr @__dso_handle) #0
  call void @__cxa_guard_release(ptr @_ZGVZ4mainE1G) #0
  br label %33

33:                                               ; preds = %31, %23, %0
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #0
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #0
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #0
  %34 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2, ptr noundef %3, ptr noundef %4)
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #0
  store i32 0, ptr %5, align 4, !tbaa !6
  br label %35

35:                                               ; preds = %46, %33
  %36 = load i32, ptr %5, align 4, !tbaa !6
  %37 = load i32, ptr %3, align 4, !tbaa !6
  %38 = icmp slt i32 %36, %37
  br i1 %38, label %40, label %39

39:                                               ; preds = %35
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #0
  br label %49

40:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #0
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #0
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #0
  %41 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %6, ptr noundef %7, ptr noundef %8)
  %42 = load i32, ptr %6, align 4, !tbaa !6
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [210000 x %"class.std::vector"], ptr @_ZZ4mainE1G, i64 0, i64 %43
  %45 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE12emplace_backIJRiS5_EEERS1_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %44, ptr noundef nonnull align 4 dereferenceable(4) %7, ptr noundef nonnull align 4 dereferenceable(4) %8)
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #0
  br label %46

46:                                               ; preds = %40
  %47 = load i32, ptr %5, align 4, !tbaa !6
  %48 = add nsw i32 %47, 1
  store i32 %48, ptr %5, align 4, !tbaa !6
  br label %35, !llvm.loop !10

49:                                               ; preds = %39
  %50 = load atomic i8, ptr @_ZGVZ4mainE1Q acquire, align 8
  %51 = icmp eq i8 %50, 0
  br i1 %51, label %52, label %57, !prof !5

52:                                               ; preds = %49
  %53 = call i32 @__cxa_guard_acquire(ptr @_ZGVZ4mainE1Q) #0
  %54 = icmp ne i32 %53, 0
  br i1 %54, label %55, label %57

55:                                               ; preds = %52
  invoke void @_ZN23ModifiablePriorityQueueIiLi210000EEC2Ev(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
          to label %56 unwind label %79

56:                                               ; preds = %55
  call void @__cxa_guard_release(ptr @_ZGVZ4mainE1Q) #0
  br label %57

57:                                               ; preds = %56, %52, %49
  call void @llvm.memset.p0.i64(ptr align 16 @_ZZ4mainE1d, i8 63, i64 840000, i1 false)
  %58 = load i32, ptr %4, align 4, !tbaa !6
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %59
  store i32 0, ptr %60, align 4, !tbaa !6
  %61 = load i32, ptr %4, align 4, !tbaa !6
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #0
  store i32 0, ptr %11, align 4, !tbaa !6
  call void @_ZN23ModifiablePriorityQueueIiLi210000EE4pushEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q, i32 noundef %61, ptr noundef nonnull align 4 dereferenceable(4) %11)
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #0
  br label %62

62:                                               ; preds = %123, %57
  %63 = call noundef zeroext i1 @_ZNK23ModifiablePriorityQueueIiLi210000EE5emptyEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  %64 = xor i1 %63, true
  br i1 %64, label %65, label %124

65:                                               ; preds = %62
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #0
  %66 = call noundef i32 @_ZNK23ModifiablePriorityQueueIiLi210000EE3topEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  store i32 %66, ptr %12, align 4, !tbaa !6
  call void @_ZN23ModifiablePriorityQueueIiLi210000EE3popEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #0
  %67 = load i32, ptr %12, align 4, !tbaa !6
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds [210000 x %"class.std::vector"], ptr @_ZZ4mainE1G, i64 0, i64 %68
  store ptr %69, ptr %13, align 8, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #0
  %70 = load ptr, ptr %13, align 8, !tbaa !12
  %71 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %70) #0
  %72 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  store ptr %71, ptr %72, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #0
  %73 = load ptr, ptr %13, align 8, !tbaa !12
  %74 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %73) #0
  %75 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  store ptr %74, ptr %75, align 8
  br label %76

76:                                               ; preds = %121, %65
  %77 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %15) #0
  br i1 %77, label %83, label %78

78:                                               ; preds = %76
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #0
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #0
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #0
  br label %123

79:                                               ; preds = %55
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %9, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %10, align 4
  call void @__cxa_guard_abort(ptr @_ZGVZ4mainE1Q) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #0
  br label %150

83:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #0
  %84 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %16, ptr align 4 %84, i64 8, i1 false)
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #0
  %85 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3getILm0EiiEONSt13tuple_elementIXT_ESt4pairIT0_T1_EE4typeEOS4_(ptr noundef nonnull align 4 dereferenceable(8) %16) #0
  store ptr %85, ptr %17, align 8, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #0
  %86 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3getILm1EiiEONSt13tuple_elementIXT_ESt4pairIT0_T1_EE4typeEOS4_(ptr noundef nonnull align 4 dereferenceable(8) %16) #0
  store ptr %86, ptr %18, align 8, !tbaa !12
  %87 = load ptr, ptr %17, align 8, !tbaa !12
  %88 = load i32, ptr %87, align 4, !tbaa !6
  %89 = sext i32 %88 to i64
  %90 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %89
  %91 = load i32, ptr %90, align 4, !tbaa !6
  %92 = load i32, ptr %12, align 4, !tbaa !6
  %93 = sext i32 %92 to i64
  %94 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %93
  %95 = load i32, ptr %94, align 4, !tbaa !6
  %96 = load ptr, ptr %18, align 8, !tbaa !12
  %97 = load i32, ptr %96, align 4, !tbaa !6
  %98 = add nsw i32 %95, %97
  %99 = icmp sgt i32 %91, %98
  br i1 %99, label %100, label %120

100:                                              ; preds = %83
  %101 = load i32, ptr %12, align 4, !tbaa !6
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %102
  %104 = load i32, ptr %103, align 4, !tbaa !6
  %105 = load ptr, ptr %18, align 8, !tbaa !12
  %106 = load i32, ptr %105, align 4, !tbaa !6
  %107 = add nsw i32 %104, %106
  %108 = load ptr, ptr %17, align 8, !tbaa !12
  %109 = load i32, ptr %108, align 4, !tbaa !6
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %110
  store i32 %107, ptr %111, align 4, !tbaa !6
  %112 = load ptr, ptr %17, align 8, !tbaa !12
  %113 = load i32, ptr %112, align 4, !tbaa !6
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #0
  %114 = load ptr, ptr %17, align 8, !tbaa !12
  %115 = load i32, ptr %114, align 4, !tbaa !6
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %116
  %118 = load i32, ptr %117, align 4, !tbaa !6
  %119 = sub nsw i32 0, %118
  store i32 %119, ptr %19, align 4, !tbaa !6
  call void @_ZN23ModifiablePriorityQueueIiLi210000EE6modifyEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q, i32 noundef %113, ptr noundef nonnull align 4 dereferenceable(4) %19)
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #0
  br label %120

120:                                              ; preds = %100, %83
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #0
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #0
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #0
  br label %121

121:                                              ; preds = %120
  %122 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #0
  br label %76

123:                                              ; preds = %78
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #0
  br label %62, !llvm.loop !14

124:                                              ; preds = %62
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #0
  store i32 1, ptr %20, align 4, !tbaa !6
  br label %125

125:                                              ; preds = %145, %124
  %126 = load i32, ptr %20, align 4, !tbaa !6
  %127 = load i32, ptr %2, align 4, !tbaa !6
  %128 = icmp sle i32 %126, %127
  br i1 %128, label %130, label %129

129:                                              ; preds = %125
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #0
  br label %148

130:                                              ; preds = %125
  %131 = load i32, ptr %20, align 4, !tbaa !6
  %132 = sext i32 %131 to i64
  %133 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %132
  %134 = load i32, ptr %133, align 4, !tbaa !6
  %135 = icmp eq i32 %134, 1061109567
  br i1 %135, label %136, label %137

136:                                              ; preds = %130
  br label %142

137:                                              ; preds = %130
  %138 = load i32, ptr %20, align 4, !tbaa !6
  %139 = sext i32 %138 to i64
  %140 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %139
  %141 = load i32, ptr %140, align 4, !tbaa !6
  br label %142

142:                                              ; preds = %137, %136
  %143 = phi i32 [ 2147483647, %136 ], [ %141, %137 ]
  %144 = call i32 (ptr, ...) @printf(ptr noundef @.str.1, i32 noundef %143)
  br label %145

145:                                              ; preds = %142
  %146 = load i32, ptr %20, align 4, !tbaa !6
  %147 = add nsw i32 %146, 1
  store i32 %147, ptr %20, align 4, !tbaa !6
  br label %125, !llvm.loop !15

148:                                              ; preds = %129
  %149 = call i32 (ptr, ...) @printf(ptr noundef @.str.2)
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #0
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #0
  ret i32 0

150:                                              ; preds = %79
  %151 = load ptr, ptr %9, align 8
  %152 = load i32, ptr %10, align 4
  %153 = insertvalue { ptr, i32 } poison, ptr %151, 0
  %154 = insertvalue { ptr, i32 } %153, i32 %152, 1
  resume { ptr, i32 } %154
}

; Function Attrs: nounwind
declare i32 @__cxa_guard_acquire(ptr) #0

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

; Function Attrs: uwtable
declare hidden void @__cxx_global_array_dtor(ptr noundef) #3 section ".text.startup"

; Function Attrs: nounwind
declare void @__cxa_guard_release(ptr) #0

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EEC2Ev(ptr noundef nonnull align 4 dereferenceable(5040004)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nounwind
declare void @__cxa_guard_abort(ptr) #0

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EE4pushEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004), i32 noundef, ptr noundef nonnull align 4 dereferenceable(4)) #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK23ModifiablePriorityQueueIiLi210000EE5emptyEv(ptr noundef nonnull align 4 dereferenceable(5040004)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK23ModifiablePriorityQueueIiLi210000EE3topEv(ptr noundef nonnull align 4 dereferenceable(5040004)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EE3popEv(ptr noundef nonnull align 4 dereferenceable(5040004)) #6 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #8

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EE6modifyEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004), i32 noundef, ptr noundef nonnull align 4 dereferenceable(4)) #6 align 2

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

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

attributes #0 = { nounwind }
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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 nosync nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #8 = { 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 #9 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }

!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 = !{!"branch_weights", i32 1, i32 1048575}
!6 = !{!7, !7, i64 0}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = !{!13, !13, i64 0}
!13 = !{!"any pointer", !8, i64 0}
!14 = distinct !{!14, !11}
!15 = distinct !{!15, !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"

%"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.ModifiablePriorityQueue = type { [420000 x i32], [420000 x i32], [420000 x i32], i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"struct.std::pair" = type { i32, i32 }

@__dso_handle = external hidden global i8
@_ZZ4mainE1d = external hidden local_unnamed_addr global [210000 x i32], align 16
@_ZZ4mainE1G = external hidden global [210000 x %"class.std::vector"], align 16
@_ZGVZ4mainE1G = external hidden global i64, align 8
@.str = external hidden unnamed_addr constant [9 x i8], align 1
@_ZZ4mainE1Q = external hidden global %struct.ModifiablePriorityQueue, align 4
@_ZGVZ4mainE1Q = external hidden global i64, align 8
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: nofree nounwind
declare i32 @__cxa_atexit(ptr, ptr, ptr) local_unnamed_addr #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #1 personality ptr @__gxx_personality_v0 {
  %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 %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca %"struct.std::pair", align 8
  %11 = alloca i32, align 4
  %12 = load atomic i8, ptr @_ZGVZ4mainE1G acquire, align 8
  %13 = icmp eq i8 %12, 0
  br i1 %13, label %14, label %19, !prof !5

14:                                               ; preds = %0
  %15 = tail call i32 @__cxa_guard_acquire(ptr nonnull @_ZGVZ4mainE1G) #9
  %.not = icmp eq i32 %15, 0
  br i1 %.not, label %19, label %.preheader22

.preheader22:                                     ; preds = %14, %.preheader22
  %.idx = phi i64 [ %.add, %.preheader22 ], [ 0, %14 ]
  %.ptr = getelementptr inbounds i8, ptr @_ZZ4mainE1G, i64 %.idx
  tail call void @_ZNSt6vectorISt4pairIiiESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %.ptr) #9
  %.add = add nuw nsw i64 %.idx, 24
  %16 = icmp eq i64 %.add, 5040000
  br i1 %16, label %17, label %.preheader22

17:                                               ; preds = %.preheader22
  %18 = tail call i32 @__cxa_atexit(ptr nonnull @__cxx_global_array_dtor, ptr null, ptr nonnull @__dso_handle) #9
  tail call void @__cxa_guard_release(ptr nonnull @_ZGVZ4mainE1G) #9
  br label %19

19:                                               ; preds = %17, %14, %0
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #9
  %20 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1, ptr noundef nonnull %2, ptr noundef nonnull %3)
  %21 = load i32, ptr %2, align 4, !tbaa !6
  %22 = icmp sgt i32 %21, 0
  br i1 %22, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph, %19
  %23 = load atomic i8, ptr @_ZGVZ4mainE1Q acquire, align 8
  %24 = icmp eq i8 %23, 0
  br i1 %24, label %33, label %36, !prof !5

.lr.ph:                                           ; preds = %19, %.lr.ph
  %.01623 = phi i32 [ %30, %.lr.ph ], [ 0, %19 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #9
  %25 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %4, ptr noundef nonnull %5, ptr noundef nonnull %6)
  %26 = load i32, ptr %4, align 4, !tbaa !6
  %27 = sext i32 %26 to i64
  %28 = getelementptr inbounds [210000 x %"class.std::vector"], ptr @_ZZ4mainE1G, i64 0, i64 %27
  %29 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE12emplace_backIJRiS5_EEERS1_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %28, ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #9
  %30 = add nuw nsw i32 %.01623, 1
  %31 = load i32, ptr %2, align 4, !tbaa !6
  %32 = icmp slt i32 %30, %31
  br i1 %32, label %.lr.ph, label %._crit_edge, !llvm.loop !10

33:                                               ; preds = %._crit_edge
  %34 = call i32 @__cxa_guard_acquire(ptr nonnull @_ZGVZ4mainE1Q) #9
  %.not20 = icmp eq i32 %34, 0
  br i1 %.not20, label %36, label %35

35:                                               ; preds = %33
  call void @_ZN23ModifiablePriorityQueueIiLi210000EEC2Ev(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  call void @__cxa_guard_release(ptr nonnull @_ZGVZ4mainE1Q) #9
  br label %36

36:                                               ; preds = %35, %33, %._crit_edge
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(840000) @_ZZ4mainE1d, i8 63, i64 840000, i1 false)
  %37 = load i32, ptr %3, align 4, !tbaa !6
  %38 = sext i32 %37 to i64
  %39 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %38
  store i32 0, ptr %39, align 4, !tbaa !6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #9
  store i32 0, ptr %7, align 4, !tbaa !6
  call void @_ZN23ModifiablePriorityQueueIiLi210000EE4pushEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q, i32 noundef %37, ptr noundef nonnull align 4 dereferenceable(4) %7)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #9
  %40 = call noundef zeroext i1 @_ZNK23ModifiablePriorityQueueIiLi210000EE5emptyEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  br i1 %40, label %.preheader, label %.lr.ph28

.preheader:                                       ; preds = %._crit_edge26, %36
  %41 = load i32, ptr %1, align 4, !tbaa !6
  %.not2129 = icmp slt i32 %41, 1
  br i1 %.not2129, label %._crit_edge32, label %.lr.ph31

.lr.ph28:                                         ; preds = %36, %._crit_edge26
  %42 = call noundef i32 @_ZNK23ModifiablePriorityQueueIiLi210000EE3topEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  call void @_ZN23ModifiablePriorityQueueIiLi210000EE3popEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [210000 x %"class.std::vector"], ptr @_ZZ4mainE1G, i64 0, i64 %43
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #9
  %45 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %44) #9
  store ptr %45, ptr %8, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #9
  %46 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %44) #9
  store ptr %46, ptr %9, align 8
  %47 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #9
  br i1 %47, label %.lr.ph25, label %._crit_edge26

.lr.ph25:                                         ; preds = %.lr.ph28
  %48 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %43
  br label %50

._crit_edge26:                                    ; preds = %69, %.lr.ph28
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #9
  %49 = call noundef zeroext i1 @_ZNK23ModifiablePriorityQueueIiLi210000EE5emptyEv(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q)
  br i1 %49, label %.preheader, label %.lr.ph28, !llvm.loop !12

50:                                               ; preds = %.lr.ph25, %69
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #9
  %51 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #9
  %52 = load i64, ptr %51, align 4
  store i64 %52, ptr %10, align 8
  %53 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3getILm0EiiEONSt13tuple_elementIXT_ESt4pairIT0_T1_EE4typeEOS4_(ptr noundef nonnull align 4 dereferenceable(8) %10) #9
  %54 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3getILm1EiiEONSt13tuple_elementIXT_ESt4pairIT0_T1_EE4typeEOS4_(ptr noundef nonnull align 4 dereferenceable(8) %10) #9
  %55 = load i32, ptr %53, align 4, !tbaa !6
  %56 = sext i32 %55 to i64
  %57 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %56
  %58 = load i32, ptr %57, align 4, !tbaa !6
  %59 = load i32, ptr %48, align 4, !tbaa !6
  %60 = load i32, ptr %54, align 4, !tbaa !6
  %61 = add nsw i32 %60, %59
  %62 = icmp sgt i32 %58, %61
  br i1 %62, label %63, label %69

63:                                               ; preds = %50
  store i32 %61, ptr %57, align 4, !tbaa !6
  %64 = load i32, ptr %53, align 4, !tbaa !6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #9
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %65
  %67 = load i32, ptr %66, align 4, !tbaa !6
  %68 = sub nsw i32 0, %67
  store i32 %68, ptr %11, align 4, !tbaa !6
  call void @_ZN23ModifiablePriorityQueueIiLi210000EE6modifyEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004) @_ZZ4mainE1Q, i32 noundef %64, ptr noundef nonnull align 4 dereferenceable(4) %11)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #9
  br label %69

69:                                               ; preds = %63, %50
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #9
  %70 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #9
  %71 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #9
  br i1 %71, label %50, label %._crit_edge26

._crit_edge32:                                    ; preds = %.lr.ph31, %.preheader
  %72 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #9
  ret i32 0

.lr.ph31:                                         ; preds = %.preheader, %.lr.ph31
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph31 ], [ 1, %.preheader ]
  %73 = getelementptr inbounds [210000 x i32], ptr @_ZZ4mainE1d, i64 0, i64 %indvars.iv
  %74 = load i32, ptr %73, align 4, !tbaa !6
  %75 = icmp eq i32 %74, 1061109567
  %spec.select = select i1 %75, i32 2147483647, i32 %74
  %76 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef %spec.select)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %77 = load i32, ptr %1, align 4, !tbaa !6
  %78 = sext i32 %77 to i64
  %.not21.not = icmp slt i64 %indvars.iv, %78
  br i1 %.not21.not, label %.lr.ph31, label %._crit_edge32, !llvm.loop !13
}

; Function Attrs: nofree nounwind
declare i32 @__cxa_guard_acquire(ptr) local_unnamed_addr #0

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

; Function Attrs: uwtable
declare hidden void @__cxx_global_array_dtor(ptr noundef) #3 section ".text.startup"

; Function Attrs: nofree nounwind
declare void @__cxa_guard_release(ptr) local_unnamed_addr #0

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EEC2Ev(ptr noundef nonnull align 4 dereferenceable(5040004)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EE4pushEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004), i32 noundef, ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK23ModifiablePriorityQueueIiLi210000EE5emptyEv(ptr noundef nonnull align 4 dereferenceable(5040004)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK23ModifiablePriorityQueueIiLi210000EE3topEv(ptr noundef nonnull align 4 dereferenceable(5040004)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EE3popEv(ptr noundef nonnull align 4 dereferenceable(5040004)) local_unnamed_addr #6 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #8

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN23ModifiablePriorityQueueIiLi210000EE6modifyEiRKi(ptr noundef nonnull align 4 dereferenceable(5040004), i32 noundef, ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #6 align 2

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

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

attributes #0 = { nofree nounwind }
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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #8 = { 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 #9 = { 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 = !{!"branch_weights", i32 1, i32 1048575}
!6 = !{!7, !7, i64 0}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}
!13 = distinct !{!13, !11}


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