; LLVM IR from eyangch/competitive-programming :: Codeforces/1748 (e)

; 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::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%struct.mint = type { i64 }
%"class.std::stack" = type { %"class.std::deque" }
%"class.std::deque" = type { %"class.std::_Deque_base" }
%"class.std::_Deque_base" = type { %"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl" }
%"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl" = type { %"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl_data" }
%"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator", %"struct.std::_Deque_iterator" }
%"struct.std::_Deque_iterator" = type { ptr, ptr, ptr, ptr }
%"struct.std::pair" = type { i64, i64 }

@T = external dso_local global i64, align 8
@N = external dso_local global i64, align 8
@M = external dso_local global i64, align 8
@A = external dso_local global [200002 x i64], align 16
@au = external dso_local global %"class.std::vector", align 8
@pau = external dso_local global %"class.std::vector", align 8
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

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

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

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #3 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca %struct.mint, align 8
  %5 = alloca %"class.std::stack", align 8
  %6 = alloca %"struct.std::pair", align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i64, align 8
  %11 = alloca i32, align 4
  %12 = alloca %"struct.std::pair", align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  %17 = alloca %struct.mint, align 8
  %18 = alloca i64, align 8
  %19 = alloca %struct.mint, align 8
  %20 = alloca %struct.mint, align 8
  %21 = alloca %struct.mint, align 8
  %22 = alloca i64, align 8
  %23 = alloca %struct.mint, align 8
  %24 = alloca %"struct.std::pair", align 8
  store i32 0, ptr %1, align 4
  %25 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %26 = getelementptr i8, ptr %25, i64 -24
  %27 = load i64, ptr %26, align 8
  %28 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %27
  %29 = call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %28, ptr noundef null)
  %30 = call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  %31 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) @T)
  br label %32

32:                                               ; preds = %241, %0
  %33 = load i64, ptr @T, align 8, !tbaa !8
  %34 = add nsw i64 %33, -1
  store i64 %34, ptr @T, align 8, !tbaa !8
  %35 = icmp ne i64 %33, 0
  br i1 %35, label %36, label %247

36:                                               ; preds = %32
  %37 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) @N)
  %38 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %37, ptr noundef nonnull align 8 dereferenceable(8) @M)
  call void @_Z4initRSt6vectorIS_I4mintSaIS0_EESaIS2_EE(ptr noundef nonnull align 8 dereferenceable(24) @au)
  call void @_Z4initRSt6vectorIS_I4mintSaIS0_EESaIS2_EE(ptr noundef nonnull align 8 dereferenceable(24) @pau)
  %39 = load i64, ptr @M, align 8, !tbaa !8
  %40 = add nsw i64 %39, 1
  store i64 %40, ptr @A, align 16, !tbaa !8
  %41 = load i64, ptr @M, align 8, !tbaa !8
  %42 = add nsw i64 %41, 1
  %43 = load i64, ptr @N, align 8, !tbaa !8
  %44 = add nsw i64 %43, 1
  %45 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %44
  store i64 %42, ptr %45, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #8
  store i64 1, ptr %2, align 8, !tbaa !8
  br label %46

46:                                               ; preds = %55, %36
  %47 = load i64, ptr %2, align 8, !tbaa !8
  %48 = load i64, ptr @N, align 8, !tbaa !8
  %49 = icmp sle i64 %47, %48
  br i1 %49, label %51, label %50

50:                                               ; preds = %46
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #8
  br label %58

51:                                               ; preds = %46
  %52 = load i64, ptr %2, align 8, !tbaa !8
  %53 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %52
  %54 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %53)
  br label %55

55:                                               ; preds = %51
  %56 = load i64, ptr %2, align 8, !tbaa !8
  %57 = add nsw i64 %56, 1
  store i64 %57, ptr %2, align 8, !tbaa !8
  br label %46, !llvm.loop !11

58:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #8
  store i64 0, ptr %3, align 8, !tbaa !8
  br label %59

59:                                               ; preds = %68, %58
  %60 = load i64, ptr %3, align 8, !tbaa !8
  %61 = load i64, ptr @M, align 8, !tbaa !8
  %62 = icmp sle i64 %60, %61
  br i1 %62, label %64, label %63

63:                                               ; preds = %59
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #8
  br label %71

64:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #8
  call void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %4, i64 noundef 1)
  %65 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef 0) #8
  %66 = load i64, ptr %3, align 8, !tbaa !8
  %67 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %65, i64 noundef %66) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %67, ptr align 8 %4, i64 8, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #8
  br label %68

68:                                               ; preds = %64
  %69 = load i64, ptr %3, align 8, !tbaa !8
  %70 = add nsw i64 %69, 1
  store i64 %70, ptr %3, align 8, !tbaa !8
  br label %59, !llvm.loop !14

71:                                               ; preds = %63
  call void @llvm.lifetime.start.p0(i64 80, ptr %5) #8
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEEC2IS4_vEEv(ptr noundef nonnull align 8 dereferenceable(80) %5)
  call void @llvm.lifetime.start.p0(i64 16, ptr %6) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  store i32 0, ptr %7, align 4, !tbaa !15
  invoke void @_ZNSt4pairIxxEC2IRxiTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull align 8 dereferenceable(8) @A, ptr noundef nonnull align 4 dereferenceable(4) %7)
          to label %72 unwind label %80

72:                                               ; preds = %71
  invoke void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE4pushEOS1_(ptr noundef nonnull align 8 dereferenceable(80) %5, ptr noundef nonnull align 8 dereferenceable(16) %6)
          to label %73 unwind label %80

73:                                               ; preds = %72
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %6) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #8
  store i64 1, ptr %10, align 8, !tbaa !8
  br label %74

74:                                               ; preds = %224, %73
  %75 = load i64, ptr %10, align 8, !tbaa !8
  %76 = load i64, ptr @N, align 8, !tbaa !8
  %77 = add nsw i64 %76, 1
  %78 = icmp sle i64 %75, %77
  br i1 %78, label %84, label %79

79:                                               ; preds = %74
  store i32 10, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #8
  br label %232

80:                                               ; preds = %72, %71
  %81 = landingpad { ptr, i32 }
          cleanup
  %82 = extractvalue { ptr, i32 } %81, 0
  store ptr %82, ptr %8, align 8
  %83 = extractvalue { ptr, i32 } %81, 1
  store i32 %83, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %6) #8
  br label %246

84:                                               ; preds = %74
  br label %85

85:                                               ; preds = %198, %84
  br label %86

86:                                               ; preds = %85
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #8
  %87 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %5)
          to label %88 unwind label %110

88:                                               ; preds = %86
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %12, ptr align 8 %87, i64 16, i1 false)
  %89 = getelementptr inbounds %"struct.std::pair", ptr %12, i32 0, i32 0
  %90 = load i64, ptr %89, align 8, !tbaa !17
  %91 = load i64, ptr %10, align 8, !tbaa !8
  %92 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %91
  %93 = load i64, ptr %92, align 8, !tbaa !8
  %94 = icmp slt i64 %90, %93
  br i1 %94, label %95, label %194

95:                                               ; preds = %88
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #8
  %96 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %5)
          to label %97 unwind label %114

97:                                               ; preds = %95
  %98 = getelementptr inbounds %"struct.std::pair", ptr %96, i32 0, i32 1
  %99 = load i64, ptr %98, align 8, !tbaa !19
  store i64 %99, ptr %13, align 8, !tbaa !8
  invoke void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3popEv(ptr noundef nonnull align 8 dereferenceable(80) %5)
          to label %100 unwind label %114

100:                                              ; preds = %97
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  %101 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %5)
          to label %102 unwind label %118

102:                                              ; preds = %100
  %103 = getelementptr inbounds %"struct.std::pair", ptr %101, i32 0, i32 1
  %104 = load i64, ptr %103, align 8, !tbaa !19
  store i64 %104, ptr %14, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #8
  store i64 0, ptr %15, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #8
  store i64 1, ptr %16, align 8, !tbaa !8
  br label %105

105:                                              ; preds = %139, %102
  %106 = load i64, ptr %16, align 8, !tbaa !8
  %107 = load i64, ptr @M, align 8, !tbaa !8
  %108 = icmp sle i64 %106, %107
  br i1 %108, label %122, label %109

109:                                              ; preds = %105
  store i32 15, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  br label %146

110:                                              ; preds = %86
  %111 = landingpad { ptr, i32 }
          cleanup
  %112 = extractvalue { ptr, i32 } %111, 0
  store ptr %112, ptr %8, align 8
  %113 = extractvalue { ptr, i32 } %111, 1
  store i32 %113, ptr %9, align 4
  br label %199

114:                                              ; preds = %97, %95
  %115 = landingpad { ptr, i32 }
          cleanup
  %116 = extractvalue { ptr, i32 } %115, 0
  store ptr %116, ptr %8, align 8
  %117 = extractvalue { ptr, i32 } %115, 1
  store i32 %117, ptr %9, align 4
  br label %193

118:                                              ; preds = %100
  %119 = landingpad { ptr, i32 }
          cleanup
  %120 = extractvalue { ptr, i32 } %119, 0
  store ptr %120, ptr %8, align 8
  %121 = extractvalue { ptr, i32 } %119, 1
  store i32 %121, ptr %9, align 4
  br label %192

122:                                              ; preds = %105
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #8
  %123 = load i64, ptr %14, align 8, !tbaa !8
  %124 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %123) #8
  %125 = load i64, ptr %16, align 8, !tbaa !8
  %126 = sub nsw i64 %125, 1
  %127 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %124, i64 noundef %126) #8
  %128 = load i64, ptr %13, align 8, !tbaa !8
  %129 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %128) #8
  %130 = load i64, ptr %16, align 8, !tbaa !8
  %131 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %129, i64 noundef %130) #8
  %132 = invoke i64 @_ZmlRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8) %127, ptr noundef nonnull align 8 dereferenceable(8) %131)
          to label %133 unwind label %142

133:                                              ; preds = %122
  %134 = getelementptr inbounds %struct.mint, ptr %17, i32 0, i32 0
  store i64 %132, ptr %134, align 8
  %135 = load i64, ptr %14, align 8, !tbaa !8
  %136 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @au, i64 noundef %135) #8
  %137 = load i64, ptr %16, align 8, !tbaa !8
  %138 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %136, i64 noundef %137) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %138, ptr align 8 %17, i64 8, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  br label %139

139:                                              ; preds = %133
  %140 = load i64, ptr %16, align 8, !tbaa !8
  %141 = add nsw i64 %140, 1
  store i64 %141, ptr %16, align 8, !tbaa !8
  br label %105, !llvm.loop !20

142:                                              ; preds = %122
  %143 = landingpad { ptr, i32 }
          cleanup
  %144 = extractvalue { ptr, i32 } %143, 0
  store ptr %144, ptr %8, align 8
  %145 = extractvalue { ptr, i32 } %143, 1
  store i32 %145, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  br label %191

146:                                              ; preds = %109
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #8
  store i64 1, ptr %18, align 8, !tbaa !8
  br label %147

147:                                              ; preds = %175, %146
  %148 = load i64, ptr %18, align 8, !tbaa !8
  %149 = load i64, ptr @M, align 8, !tbaa !8
  %150 = icmp sle i64 %148, %149
  br i1 %150, label %152, label %151

151:                                              ; preds = %147
  store i32 18, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  br label %182

152:                                              ; preds = %147
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #8
  %153 = load i64, ptr %18, align 8, !tbaa !8
  %154 = icmp eq i64 %153, 1
  br i1 %154, label %155, label %157

155:                                              ; preds = %152
  invoke void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %20, i64 noundef 0)
          to label %156 unwind label %178

156:                                              ; preds = %155
  br label %163

157:                                              ; preds = %152
  %158 = load i64, ptr %14, align 8, !tbaa !8
  %159 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %158) #8
  %160 = load i64, ptr %18, align 8, !tbaa !8
  %161 = sub nsw i64 %160, 1
  %162 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %159, i64 noundef %161) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %20, ptr align 8 %162, i64 8, i1 false), !tbaa.struct !13
  br label %163

163:                                              ; preds = %157, %156
  %164 = load i64, ptr %14, align 8, !tbaa !8
  %165 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @au, i64 noundef %164) #8
  %166 = load i64, ptr %18, align 8, !tbaa !8
  %167 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %165, i64 noundef %166) #8
  %168 = invoke i64 @_ZplRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8) %20, ptr noundef nonnull align 8 dereferenceable(8) %167)
          to label %169 unwind label %178

169:                                              ; preds = %163
  %170 = getelementptr inbounds %struct.mint, ptr %19, i32 0, i32 0
  store i64 %168, ptr %170, align 8
  %171 = load i64, ptr %14, align 8, !tbaa !8
  %172 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %171) #8
  %173 = load i64, ptr %18, align 8, !tbaa !8
  %174 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %172, i64 noundef %173) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %174, ptr align 8 %19, i64 8, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  br label %175

175:                                              ; preds = %169
  %176 = load i64, ptr %18, align 8, !tbaa !8
  %177 = add nsw i64 %176, 1
  store i64 %177, ptr %18, align 8, !tbaa !8
  br label %147, !llvm.loop !21

178:                                              ; preds = %163, %155
  %179 = landingpad { ptr, i32 }
          cleanup
  %180 = extractvalue { ptr, i32 } %179, 0
  store ptr %180, ptr %8, align 8
  %181 = extractvalue { ptr, i32 } %179, 1
  store i32 %181, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  br label %191

182:                                              ; preds = %151
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #8
  invoke void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %21, i64 noundef 0)
          to label %183 unwind label %187

183:                                              ; preds = %182
  %184 = load i64, ptr %14, align 8, !tbaa !8
  %185 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %184) #8
  %186 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %185, i64 noundef 0) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %186, ptr align 8 %21, i64 8, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  br label %195

187:                                              ; preds = %182
  %188 = landingpad { ptr, i32 }
          cleanup
  %189 = extractvalue { ptr, i32 } %188, 0
  store ptr %189, ptr %8, align 8
  %190 = extractvalue { ptr, i32 } %188, 1
  store i32 %190, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #8
  br label %191

191:                                              ; preds = %187, %178, %142
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  br label %192

192:                                              ; preds = %191, %118
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  br label %193

193:                                              ; preds = %192, %114
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  br label %199

194:                                              ; preds = %88
  store i32 14, ptr %11, align 4
  br label %196

195:                                              ; preds = %183
  store i32 0, ptr %11, align 4
  br label %196

196:                                              ; preds = %195, %194
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #8
  %197 = load i32, ptr %11, align 4
  switch i32 %197, label %254 [
    i32 0, label %198
    i32 14, label %200
  ]

198:                                              ; preds = %196
  br label %85, !llvm.loop !22

199:                                              ; preds = %193, %110
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #8
  br label %231

200:                                              ; preds = %196
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #8
  store i64 0, ptr %22, align 8, !tbaa !8
  br label %201

201:                                              ; preds = %212, %200
  %202 = load i64, ptr %22, align 8, !tbaa !8
  %203 = load i64, ptr @M, align 8, !tbaa !8
  %204 = icmp sle i64 %202, %203
  br i1 %204, label %206, label %205

205:                                              ; preds = %201
  store i32 21, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  br label %219

206:                                              ; preds = %201
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #8
  invoke void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %23, i64 noundef 1)
          to label %207 unwind label %215

207:                                              ; preds = %206
  %208 = load i64, ptr %10, align 8, !tbaa !8
  %209 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %208) #8
  %210 = load i64, ptr %22, align 8, !tbaa !8
  %211 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %209, i64 noundef %210) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %211, ptr align 8 %23, i64 8, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #8
  br label %212

212:                                              ; preds = %207
  %213 = load i64, ptr %22, align 8, !tbaa !8
  %214 = add nsw i64 %213, 1
  store i64 %214, ptr %22, align 8, !tbaa !8
  br label %201, !llvm.loop !23

215:                                              ; preds = %206
  %216 = landingpad { ptr, i32 }
          cleanup
  %217 = extractvalue { ptr, i32 } %216, 0
  store ptr %217, ptr %8, align 8
  %218 = extractvalue { ptr, i32 } %216, 1
  store i32 %218, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  br label %231

219:                                              ; preds = %205
  call void @llvm.lifetime.start.p0(i64 16, ptr %24) #8
  %220 = load i64, ptr %10, align 8, !tbaa !8
  %221 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %220
  invoke void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %24, ptr noundef nonnull align 8 dereferenceable(8) %221, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %222 unwind label %227

222:                                              ; preds = %219
  invoke void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE4pushEOS1_(ptr noundef nonnull align 8 dereferenceable(80) %5, ptr noundef nonnull align 8 dereferenceable(16) %24)
          to label %223 unwind label %227

223:                                              ; preds = %222
  call void @llvm.lifetime.end.p0(i64 16, ptr %24) #8
  br label %224

224:                                              ; preds = %223
  %225 = load i64, ptr %10, align 8, !tbaa !8
  %226 = add nsw i64 %225, 1
  store i64 %226, ptr %10, align 8, !tbaa !8
  br label %74, !llvm.loop !24

227:                                              ; preds = %222, %219
  %228 = landingpad { ptr, i32 }
          cleanup
  %229 = extractvalue { ptr, i32 } %228, 0
  store ptr %229, ptr %8, align 8
  %230 = extractvalue { ptr, i32 } %228, 1
  store i32 %230, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %24) #8
  br label %231

231:                                              ; preds = %227, %215, %199
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #8
  br label %246

232:                                              ; preds = %79
  %233 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef 0) #8
  %234 = load i64, ptr @M, align 8, !tbaa !8
  %235 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %233, i64 noundef %234) #8
  %236 = getelementptr inbounds %struct.mint, ptr %235, i32 0, i32 0
  %237 = load i64, ptr %236, align 8, !tbaa !25
  %238 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %237)
          to label %239 unwind label %242

239:                                              ; preds = %232
  %240 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8) %238, i8 noundef signext 10)
          to label %241 unwind label %242

241:                                              ; preds = %239
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %5) #8
  call void @llvm.lifetime.end.p0(i64 80, ptr %5) #8
  br label %32, !llvm.loop !27

242:                                              ; preds = %239, %232
  %243 = landingpad { ptr, i32 }
          cleanup
  %244 = extractvalue { ptr, i32 } %243, 0
  store ptr %244, ptr %8, align 8
  %245 = extractvalue { ptr, i32 } %243, 1
  store i32 %245, ptr %9, align 4
  br label %246

246:                                              ; preds = %242, %231, %80
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %5) #8
  call void @llvm.lifetime.end.p0(i64 80, ptr %5) #8
  br label %249

247:                                              ; preds = %32
  %248 = load i32, ptr %1, align 4
  ret i32 %248

249:                                              ; preds = %246
  %250 = load ptr, ptr %8, align 8
  %251 = load i32, ptr %9, align 4
  %252 = insertvalue { ptr, i32 } poison, ptr %250, 0
  %253 = insertvalue { ptr, i32 } %252, i32 %251, 1
  resume { ptr, i32 } %253

254:                                              ; preds = %196
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264), ptr noundef) #2 align 2

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) #4

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #0 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #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) #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEEC2IS4_vEEv(ptr noundef nonnull align 8 dereferenceable(80)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE4pushEOS1_(ptr noundef nonnull align 8 dereferenceable(80), ptr noundef nonnull align 8 dereferenceable(16)) #0 align 2

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZmlRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #0

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZplRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #0

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8), i8 noundef signext) #6

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef) #0 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(80)) unnamed_addr #7 align 2

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { "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 nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { 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 #8 = { 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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"long long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{i64 0, i64 8, !8}
!14 = distinct !{!14, !12}
!15 = !{!16, !16, i64 0}
!16 = !{!"int", !10, i64 0}
!17 = !{!18, !9, i64 0}
!18 = !{!"_ZTSSt4pairIxxE", !9, i64 0, !9, i64 8}
!19 = !{!18, !9, i64 8}
!20 = distinct !{!20, !12}
!21 = distinct !{!21, !12}
!22 = distinct !{!22, !12}
!23 = distinct !{!23, !12}
!24 = distinct !{!24, !12}
!25 = !{!26, !9, i64 0}
!26 = !{!"_ZTS4mint", !9, i64 0}
!27 = distinct !{!27, !12}


; 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::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<mint>, std::allocator<std::vector<mint>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%struct.mint = type { i64 }
%"class.std::stack" = type { %"class.std::deque" }
%"class.std::deque" = type { %"class.std::_Deque_base" }
%"class.std::_Deque_base" = type { %"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl" }
%"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl" = type { %"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl_data" }
%"struct.std::_Deque_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator", %"struct.std::_Deque_iterator" }
%"struct.std::_Deque_iterator" = type { ptr, ptr, ptr, ptr }
%"struct.std::pair" = type { i64, i64 }

@T = external dso_local global i64, align 8
@N = external dso_local global i64, align 8
@M = external dso_local global i64, align 8
@A = external dso_local global [200002 x i64], align 16
@au = external dso_local global %"class.std::vector", align 8
@pau = external dso_local global %"class.std::vector", align 8
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

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

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

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #3 personality ptr @__gxx_personality_v0 {
  %1 = alloca %struct.mint, align 8
  %2 = alloca %"class.std::stack", align 8
  %3 = alloca %"struct.std::pair", align 8
  %4 = alloca i32, align 4
  %5 = alloca i64, align 8
  %6 = alloca %struct.mint, align 8
  %7 = alloca %struct.mint, align 8
  %8 = alloca %struct.mint, align 8
  %9 = alloca %"struct.std::pair", align 8
  %10 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %11 = getelementptr i8, ptr %10, i64 -24
  %12 = load i64, ptr %11, align 8
  %13 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %12
  %14 = tail call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %13, ptr noundef null)
  %15 = tail call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  %16 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) @T)
  %17 = load i64, ptr @T, align 8, !tbaa !8
  %18 = add nsw i64 %17, -1
  store i64 %18, ptr @T, align 8, !tbaa !8
  %.not72 = icmp eq i64 %17, 0
  br i1 %.not72, label %._crit_edge75, label %.lr.ph74

.lr.ph74:                                         ; preds = %0, %118
  %19 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) @N)
  %20 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %19, ptr noundef nonnull align 8 dereferenceable(8) @M)
  call void @_Z4initRSt6vectorIS_I4mintSaIS0_EESaIS2_EE(ptr noundef nonnull align 8 dereferenceable(24) @au)
  call void @_Z4initRSt6vectorIS_I4mintSaIS0_EESaIS2_EE(ptr noundef nonnull align 8 dereferenceable(24) @pau)
  %21 = load i64, ptr @M, align 8, !tbaa !8
  %22 = add nsw i64 %21, 1
  store i64 %22, ptr @A, align 16, !tbaa !8
  %23 = load i64, ptr @N, align 8, !tbaa !8
  %24 = add nsw i64 %23, 1
  %25 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %24
  store i64 %22, ptr %25, align 8, !tbaa !8
  %.not4152 = icmp slt i64 %23, 1
  br i1 %.not4152, label %.preheader51, label %.lr.ph

.preheader51.loopexit:                            ; preds = %.lr.ph
  %.pre = load i64, ptr @M, align 8, !tbaa !8
  br label %.preheader51

.preheader51:                                     ; preds = %.preheader51.loopexit, %.lr.ph74
  %26 = phi i64 [ %.pre, %.preheader51.loopexit ], [ %21, %.lr.ph74 ]
  %.not4254 = icmp slt i64 %26, 0
  br i1 %.not4254, label %._crit_edge, label %.lr.ph56

.lr.ph:                                           ; preds = %.lr.ph74, %.lr.ph
  %.03253 = phi i64 [ %29, %.lr.ph ], [ 1, %.lr.ph74 ]
  %27 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %.03253
  %28 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %27)
  %29 = add nuw nsw i64 %.03253, 1
  %30 = load i64, ptr @N, align 8, !tbaa !8
  %.not41.not = icmp slt i64 %.03253, %30
  br i1 %.not41.not, label %.lr.ph, label %.preheader51.loopexit, !llvm.loop !11

._crit_edge:                                      ; preds = %.lr.ph56, %.preheader51
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %2) #7
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEEC2IS4_vEEv(ptr noundef nonnull align 8 dereferenceable(80) %2)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #7
  store i32 0, ptr %4, align 4, !tbaa !13
  call void @_ZNSt4pairIxxEC2IRxiTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(8) @A, ptr noundef nonnull align 4 dereferenceable(4) %4)
  invoke void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE4pushEOS1_(ptr noundef nonnull align 8 dereferenceable(80) %2, ptr noundef nonnull align 8 dereferenceable(16) %3)
          to label %36 unwind label %48

.lr.ph56:                                         ; preds = %.preheader51, %.lr.ph56
  %.03455 = phi i64 [ %34, %.lr.ph56 ], [ 0, %.preheader51 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #7
  call void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %1, i64 noundef 1)
  %31 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef 0) #7
  %32 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %31, i64 noundef %.03455) #7
  %33 = load i64, ptr %1, align 8, !tbaa !8
  store i64 %33, ptr %32, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #7
  %34 = add nuw nsw i64 %.03455, 1
  %35 = load i64, ptr @M, align 8, !tbaa !8
  %.not42.not = icmp slt i64 %.03455, %35
  br i1 %.not42.not, label %.lr.ph56, label %._crit_edge, !llvm.loop !15

36:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #7
  store i64 1, ptr %5, align 8, !tbaa !8
  %37 = load i64, ptr @N, align 8, !tbaa !8
  %.not4370 = icmp slt i64 %37, 0
  br i1 %.not4370, label %._crit_edge71, label %.preheader50

.preheader50:                                     ; preds = %36, %109
  %38 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %2)
  %.sroa.022.0.copyload65 = load i64, ptr %38, align 8
  %39 = load i64, ptr %5, align 8, !tbaa !8
  %40 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %39
  %41 = load i64, ptr %40, align 8, !tbaa !8
  %42 = icmp slt i64 %.sroa.022.0.copyload65, %41
  br i1 %42, label %.lr.ph66, label %.critedge.preheader

._crit_edge71:                                    ; preds = %109, %36
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #7
  %43 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef 0) #7
  %44 = load i64, ptr @M, align 8, !tbaa !8
  %45 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %43, i64 noundef %44) #7
  %46 = load i64, ptr %45, align 8, !tbaa !16
  %47 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %46)
          to label %116 unwind label %121

48:                                               ; preds = %._crit_edge
  %49 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #7
  br label %123

.critedge.preheader:                              ; preds = %._crit_edge64, %.preheader50
  %50 = phi i64 [ %39, %.preheader50 ], [ %84, %._crit_edge64 ]
  %51 = load i64, ptr @M, align 8, !tbaa !8
  %.not4667 = icmp slt i64 %51, 0
  br i1 %.not4667, label %.critedge._crit_edge, label %.critedge

.lr.ph66:                                         ; preds = %.preheader50, %._crit_edge64
  %52 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %2)
  %53 = getelementptr inbounds i8, ptr %52, i64 8
  %54 = load i64, ptr %53, align 8, !tbaa !18
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3popEv(ptr noundef nonnull align 8 dereferenceable(80) %2)
  %55 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %2)
  %56 = getelementptr inbounds i8, ptr %55, i64 8
  %57 = load i64, ptr %56, align 8, !tbaa !18
  %58 = load i64, ptr @M, align 8, !tbaa !8
  %.not4457 = icmp slt i64 %58, 1
  br i1 %.not4457, label %._crit_edge64, label %.lr.ph60

.preheader:                                       ; preds = %73
  %.not4561 = icmp slt i64 %77, 1
  br i1 %.not4561, label %._crit_edge64, label %59

59:                                               ; preds = %.preheader
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #7
  call void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %6, i64 noundef 0)
  %60 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @au, i64 noundef %57) #7
  %61 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef 1) #7
  %62 = invoke i64 @_ZplRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %61)
          to label %63 unwind label %.loopexit.split-lp

63:                                               ; preds = %59
  %64 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %57) #7
  %65 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %64, i64 noundef 1) #7
  store i64 %62, ptr %65, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  %66 = load i64, ptr @M, align 8, !tbaa !8
  %.not45.not.peel = icmp sgt i64 %66, 1
  br i1 %.not45.not.peel, label %.lr.ph63.peel.next, label %._crit_edge64

.lr.ph60:                                         ; preds = %.lr.ph66, %73
  %.03558 = phi i64 [ %76, %73 ], [ 1, %.lr.ph66 ]
  %67 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %57) #7
  %68 = add nsw i64 %.03558, -1
  %69 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %67, i64 noundef %68) #7
  %70 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %54) #7
  %71 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %70, i64 noundef %.03558) #7
  %72 = invoke i64 @_ZmlRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8) %69, ptr noundef nonnull align 8 dereferenceable(8) %71)
          to label %73 unwind label %78

73:                                               ; preds = %.lr.ph60
  %74 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @au, i64 noundef %57) #7
  %75 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %74, i64 noundef %.03558) #7
  store i64 %72, ptr %75, align 8, !tbaa !8
  %76 = add nuw nsw i64 %.03558, 1
  %77 = load i64, ptr @M, align 8, !tbaa !8
  %.not44.not = icmp slt i64 %.03558, %77
  br i1 %.not44.not, label %.lr.ph60, label %.preheader, !llvm.loop !20

78:                                               ; preds = %.lr.ph60
  %79 = landingpad { ptr, i32 }
          cleanup
  br label %115

._crit_edge64:                                    ; preds = %95, %.lr.ph66, %63, %.preheader
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  call void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %7, i64 noundef 0)
  %80 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %57) #7
  %81 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %80, i64 noundef 0) #7
  %82 = load i64, ptr %7, align 8, !tbaa !8
  store i64 %82, ptr %81, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  %83 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE3topEv(ptr noundef nonnull align 8 dereferenceable(80) %2)
  %.sroa.022.0.copyload = load i64, ptr %83, align 8
  %84 = load i64, ptr %5, align 8, !tbaa !8
  %85 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %84
  %86 = load i64, ptr %85, align 8, !tbaa !8
  %87 = icmp slt i64 %.sroa.022.0.copyload, %86
  br i1 %87, label %.lr.ph66, label %.critedge.preheader

.lr.ph63.peel.next:                               ; preds = %63, %95
  %.03362 = phi i64 [ %98, %95 ], [ 2, %63 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #7
  %88 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %57) #7
  %89 = add nsw i64 %.03362, -1
  %90 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %88, i64 noundef %89) #7
  %91 = load i64, ptr %90, align 8, !tbaa !8
  store i64 %91, ptr %6, align 8, !tbaa !8
  %92 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @au, i64 noundef %57) #7
  %93 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %92, i64 noundef %.03362) #7
  %94 = invoke i64 @_ZplRK4mintS1_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %93)
          to label %95 unwind label %.loopexit

95:                                               ; preds = %.lr.ph63.peel.next
  %96 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %57) #7
  %97 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %96, i64 noundef %.03362) #7
  store i64 %94, ptr %97, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  %98 = add nuw nsw i64 %.03362, 1
  %99 = load i64, ptr @M, align 8, !tbaa !8
  %.not45.not = icmp slt i64 %.03362, %99
  br i1 %.not45.not, label %.lr.ph63.peel.next, label %._crit_edge64, !llvm.loop !21

.loopexit:                                        ; preds = %.lr.ph63.peel.next
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %100

.loopexit.split-lp:                               ; preds = %59
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %100

100:                                              ; preds = %.loopexit.split-lp, %.loopexit
  %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  br label %115

.critedge._crit_edge.loopexit:                    ; preds = %.critedge
  %.pre78 = load i64, ptr %5, align 8, !tbaa !8
  br label %.critedge._crit_edge

.critedge._crit_edge:                             ; preds = %.critedge._crit_edge.loopexit, %.critedge.preheader
  %101 = phi i64 [ %.pre78, %.critedge._crit_edge.loopexit ], [ %50, %.critedge.preheader ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #7
  %102 = getelementptr inbounds [200002 x i64], ptr @A, i64 0, i64 %101
  call void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(8) %102, ptr noundef nonnull align 8 dereferenceable(8) %5)
  invoke void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE4pushEOS1_(ptr noundef nonnull align 8 dereferenceable(80) %2, ptr noundef nonnull align 8 dereferenceable(16) %9)
          to label %109 unwind label %113

.critedge:                                        ; preds = %.critedge.preheader, %.critedge
  %.068 = phi i64 [ %107, %.critedge ], [ 0, %.critedge.preheader ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  call void @_ZN4mintC2Ex(ptr noundef nonnull align 8 dereferenceable(8) %8, i64 noundef 1)
  %103 = load i64, ptr %5, align 8, !tbaa !8
  %104 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_I4mintSaIS0_EESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @pau, i64 noundef %103) #7
  %105 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorI4mintSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %104, i64 noundef %.068) #7
  %106 = load i64, ptr %8, align 8, !tbaa !8
  store i64 %106, ptr %105, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  %107 = add nuw nsw i64 %.068, 1
  %108 = load i64, ptr @M, align 8, !tbaa !8
  %.not46.not = icmp slt i64 %.068, %108
  br i1 %.not46.not, label %.critedge, label %.critedge._crit_edge.loopexit, !llvm.loop !23

109:                                              ; preds = %.critedge._crit_edge
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #7
  %110 = load i64, ptr %5, align 8, !tbaa !8
  %111 = add nsw i64 %110, 1
  store i64 %111, ptr %5, align 8, !tbaa !8
  %112 = load i64, ptr @N, align 8, !tbaa !8
  %.not43 = icmp sgt i64 %110, %112
  br i1 %.not43, label %._crit_edge71, label %.preheader50, !llvm.loop !24

113:                                              ; preds = %.critedge._crit_edge
  %114 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #7
  br label %115

115:                                              ; preds = %78, %100, %113
  %.pn.pn = phi { ptr, i32 } [ %114, %113 ], [ %79, %78 ], [ %lpad.phi, %100 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #7
  br label %123

116:                                              ; preds = %._crit_edge71
  %117 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8) %47, i8 noundef signext 10)
          to label %118 unwind label %121

118:                                              ; preds = %116
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %2) #7
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %2) #7
  %119 = load i64, ptr @T, align 8, !tbaa !8
  %120 = add nsw i64 %119, -1
  store i64 %120, ptr @T, align 8, !tbaa !8
  %.not = icmp eq i64 %119, 0
  br i1 %.not, label %._crit_edge75, label %.lr.ph74, !llvm.loop !25

121:                                              ; preds = %116, %._crit_edge71
  %122 = landingpad { ptr, i32 }
          cleanup
  br label %123

123:                                              ; preds = %121, %115, %48
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %115 ], [ %122, %121 ], [ %49, %48 ]
  call void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %2) #7
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %2) #7
  resume { ptr, i32 } %.pn.pn.pn

._crit_edge75:                                    ; preds = %118, %0
  ret i32 0
}

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

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #0 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEEC2IS4_vEEv(ptr noundef nonnull align 8 dereferenceable(80)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEE4pushEOS1_(ptr noundef nonnull align 8 dereferenceable(80), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #0 align 2

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8), i8 noundef signext) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef) local_unnamed_addr #0 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZNSt5stackISt4pairIxxESt5dequeIS1_SaIS1_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(80)) unnamed_addr #6 align 2

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

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"long long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !14, i64 0}
!14 = !{!"int", !10, i64 0}
!15 = distinct !{!15, !12}
!16 = !{!17, !9, i64 0}
!17 = !{!"_ZTS4mint", !9, i64 0}
!18 = !{!19, !9, i64 8}
!19 = !{!"_ZTSSt4pairIxxE", !9, i64 0, !9, i64 8}
!20 = distinct !{!20, !12}
!21 = distinct !{!21, !12, !22}
!22 = !{!"llvm.loop.peeled.count", i32 1}
!23 = distinct !{!23, !12}
!24 = distinct !{!24, !12}
!25 = distinct !{!25, !12}


; Effective O3 passes: ConstraintEliminationPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopFullUnrollPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,SCCPPass,SROAPass,SimplifyCFGPass,TailCallElimPass