; LLVM IR from DionysiosB/CodeForces :: 0500-0599 (524A-PerhapsYouKnowThesePeople)

; 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::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<long, std::pair<const long, std::map<long, long>>, std::_Select1st<std::pair<const long, std::map<long, long>>>, std::less<long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<long, std::pair<const long, std::map<long, long>>, std::_Select1st<std::pair<const long, std::map<long, long>>>, std::less<long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::_Rb_tree_iterator" = type { ptr }
%"class.std::map.0" = type { %"class.std::_Rb_tree.1" }
%"class.std::_Rb_tree.1" = type { %"struct.std::_Rb_tree<long, std::pair<const long, long>, std::_Select1st<std::pair<const long, long>>, std::less<long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<long, std::pair<const long, long>, std::_Select1st<std::pair<const long, long>>, std::less<long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_iterator.5" = type { ptr }
%"struct.std::pair" = type { i64, %"class.std::map.0" }
%"struct.std::pair.6" = type { i64, i64 }

@.str = external hidden unnamed_addr constant [8 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca %"class.std::map", align 8
  %5 = alloca i64, align 8
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %12 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca %"class.std::map.0", align 8
  %16 = alloca i64, align 8
  %17 = alloca ptr, align 8
  %18 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %19 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %20 = alloca ptr, align 8
  %21 = alloca i64, align 8
  %22 = alloca ptr, align 8
  %23 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %24 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %25 = alloca ptr, align 8
  %26 = alloca ptr, align 8
  %27 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %28 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %29 = alloca ptr, align 8
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #5
  %30 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2, ptr noundef %3)
  call void @llvm.lifetime.start.p0(i64 48, ptr %4) #5
  call void @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  store i64 0, ptr %5, align 8, !tbaa !5
  br label %31

31:                                               ; preds = %47, %0
  %32 = load i64, ptr %5, align 8, !tbaa !5
  %33 = load i64, ptr %2, align 8, !tbaa !5
  %34 = icmp slt i64 %32, %33
  br i1 %34, label %36, label %35

35:                                               ; preds = %31
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  br label %54

36:                                               ; preds = %31
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %37 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %6, ptr noundef %7)
          to label %38 unwind label %50

38:                                               ; preds = %36
  %39 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 8 dereferenceable(8) %7)
          to label %40 unwind label %50

40:                                               ; preds = %38
  %41 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %39, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %42 unwind label %50

42:                                               ; preds = %40
  store i64 1, ptr %41, align 8, !tbaa !5
  %43 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %44 unwind label %50

44:                                               ; preds = %42
  %45 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %43, ptr noundef nonnull align 8 dereferenceable(8) %7)
          to label %46 unwind label %50

46:                                               ; preds = %44
  store i64 1, ptr %45, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  br label %47

47:                                               ; preds = %46
  %48 = load i64, ptr %5, align 8, !tbaa !5
  %49 = add nsw i64 %48, 1
  store i64 %49, ptr %5, align 8, !tbaa !5
  br label %31, !llvm.loop !9

50:                                               ; preds = %44, %42, %40, %38, %36
  %51 = landingpad { ptr, i32 }
          cleanup
  %52 = extractvalue { ptr, i32 } %51, 0
  store ptr %52, ptr %8, align 8
  %53 = extractvalue { ptr, i32 } %51, 1
  store i32 %53, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  br label %195

54:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  store ptr %4, ptr %10, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %55 = load ptr, ptr %10, align 8, !tbaa !11
  %56 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %55) #5
  %57 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %11, i32 0, i32 0
  store ptr %56, ptr %57, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %58 = load ptr, ptr %10, align 8, !tbaa !11
  %59 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %58) #5
  %60 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %12, i32 0, i32 0
  store ptr %59, ptr %60, align 8
  br label %61

61:                                               ; preds = %189, %54
  %62 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEESB_(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %12) #5
  br i1 %62, label %64, label %63

63:                                               ; preds = %61
  store i32 5, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  br label %193

64:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %65 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %11) #5
  store ptr %65, ptr %14, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 48, ptr %15) #5
  call void @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  %66 = load ptr, ptr %14, align 8, !tbaa !11
  %67 = getelementptr inbounds %"struct.std::pair", ptr %66, i32 0, i32 0
  %68 = load i64, ptr %67, align 8, !tbaa !13
  %69 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, i64 noundef %68)
          to label %70 unwind label %83

70:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  %71 = load ptr, ptr %14, align 8, !tbaa !11
  %72 = getelementptr inbounds %"struct.std::pair", ptr %71, i32 0, i32 1
  %73 = call noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %72) #5
  store i64 %73, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  store ptr %4, ptr %17, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  %74 = load ptr, ptr %17, align 8, !tbaa !11
  %75 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %74) #5
  %76 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %18, i32 0, i32 0
  store ptr %75, ptr %76, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  %77 = load ptr, ptr %17, align 8, !tbaa !11
  %78 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %77) #5
  %79 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %19, i32 0, i32 0
  store ptr %78, ptr %79, align 8
  br label %80

80:                                               ; preds = %153, %70
  %81 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEESB_(ptr noundef nonnull align 8 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(8) %19) #5
  br i1 %81, label %87, label %82

82:                                               ; preds = %80
  store i32 7, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  br label %156

83:                                               ; preds = %64
  %84 = landingpad { ptr, i32 }
          cleanup
  %85 = extractvalue { ptr, i32 } %84, 0
  store ptr %85, ptr %8, align 8
  %86 = extractvalue { ptr, i32 } %84, 1
  store i32 %86, ptr %9, align 4
  br label %192

87:                                               ; preds = %80
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  %88 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %18) #5
  store ptr %88, ptr %20, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  store i64 0, ptr %21, align 8, !tbaa !5
  %89 = load ptr, ptr %14, align 8, !tbaa !11
  %90 = getelementptr inbounds %"struct.std::pair", ptr %89, i32 0, i32 1
  %91 = load ptr, ptr %20, align 8, !tbaa !11
  %92 = getelementptr inbounds %"struct.std::pair", ptr %91, i32 0, i32 0
  %93 = invoke noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE5countERS3_(ptr noundef nonnull align 8 dereferenceable(48) %90, ptr noundef nonnull align 8 dereferenceable(8) %92)
          to label %94 unwind label %116

94:                                               ; preds = %87
  %95 = icmp eq i64 %93, 0
  br i1 %95, label %96, label %152

96:                                               ; preds = %94
  %97 = load ptr, ptr %14, align 8, !tbaa !11
  %98 = getelementptr inbounds %"struct.std::pair", ptr %97, i32 0, i32 0
  %99 = load i64, ptr %98, align 8, !tbaa !13
  %100 = load ptr, ptr %20, align 8, !tbaa !11
  %101 = getelementptr inbounds %"struct.std::pair", ptr %100, i32 0, i32 0
  %102 = load i64, ptr %101, align 8, !tbaa !13
  %103 = icmp ne i64 %99, %102
  br i1 %103, label %104, label %152

104:                                              ; preds = %96
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  %105 = load ptr, ptr %14, align 8, !tbaa !11
  %106 = getelementptr inbounds %"struct.std::pair", ptr %105, i32 0, i32 1
  store ptr %106, ptr %22, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  %107 = load ptr, ptr %22, align 8, !tbaa !11
  %108 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %107) #5
  %109 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.5", ptr %23, i32 0, i32 0
  store ptr %108, ptr %109, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #5
  %110 = load ptr, ptr %22, align 8, !tbaa !11
  %111 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %110) #5
  %112 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.5", ptr %24, i32 0, i32 0
  store ptr %111, ptr %112, align 8
  br label %113

113:                                              ; preds = %137, %104
  %114 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKllEES5_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %24) #5
  br i1 %114, label %120, label %115

115:                                              ; preds = %113
  store i32 9, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  br label %139

116:                                              ; preds = %146, %87
  %117 = landingpad { ptr, i32 }
          cleanup
  %118 = extractvalue { ptr, i32 } %117, 0
  store ptr %118, ptr %8, align 8
  %119 = extractvalue { ptr, i32 } %117, 1
  store i32 %119, ptr %9, align 4
  br label %155

120:                                              ; preds = %113
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #5
  %121 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKllEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #5
  store ptr %121, ptr %25, align 8, !tbaa !11
  %122 = load ptr, ptr %20, align 8, !tbaa !11
  %123 = getelementptr inbounds %"struct.std::pair", ptr %122, i32 0, i32 1
  %124 = load ptr, ptr %25, align 8, !tbaa !11
  %125 = getelementptr inbounds %"struct.std::pair.6", ptr %124, i32 0, i32 0
  %126 = invoke noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE5countERS3_(ptr noundef nonnull align 8 dereferenceable(48) %123, ptr noundef nonnull align 8 dereferenceable(8) %125)
          to label %127 unwind label %132

127:                                              ; preds = %120
  %128 = icmp ugt i64 %126, 0
  br i1 %128, label %129, label %136

129:                                              ; preds = %127
  %130 = load i64, ptr %21, align 8, !tbaa !5
  %131 = add nsw i64 %130, 1
  store i64 %131, ptr %21, align 8, !tbaa !5
  br label %136

132:                                              ; preds = %120
  %133 = landingpad { ptr, i32 }
          cleanup
  %134 = extractvalue { ptr, i32 } %133, 0
  store ptr %134, ptr %8, align 8
  %135 = extractvalue { ptr, i32 } %133, 1
  store i32 %135, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  br label %155

136:                                              ; preds = %129, %127
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  br label %137

137:                                              ; preds = %136
  %138 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKllEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #5
  br label %113

139:                                              ; preds = %115
  %140 = load i64, ptr %21, align 8, !tbaa !5
  %141 = mul nsw i64 100, %140
  %142 = load i64, ptr %16, align 8, !tbaa !5
  %143 = sdiv i64 %141, %142
  %144 = load i64, ptr %3, align 8, !tbaa !5
  %145 = icmp sge i64 %143, %144
  br i1 %145, label %146, label %151

146:                                              ; preds = %139
  %147 = load ptr, ptr %20, align 8, !tbaa !11
  %148 = getelementptr inbounds %"struct.std::pair", ptr %147, i32 0, i32 0
  %149 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %15, ptr noundef nonnull align 8 dereferenceable(8) %148)
          to label %150 unwind label %116

150:                                              ; preds = %146
  store i64 1, ptr %149, align 8, !tbaa !5
  br label %151

151:                                              ; preds = %150, %139
  br label %152

152:                                              ; preds = %151, %96, %94
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  br label %153

153:                                              ; preds = %152
  %154 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %18) #5
  br label %80

155:                                              ; preds = %132, %116
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  br label %191

156:                                              ; preds = %82
  %157 = call noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  %158 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %157)
          to label %159 unwind label %169

159:                                              ; preds = %156
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #5
  store ptr %15, ptr %26, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #5
  %160 = load ptr, ptr %26, align 8, !tbaa !11
  %161 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %160) #5
  %162 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.5", ptr %27, i32 0, i32 0
  store ptr %161, ptr %162, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #5
  %163 = load ptr, ptr %26, align 8, !tbaa !11
  %164 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %163) #5
  %165 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.5", ptr %28, i32 0, i32 0
  store ptr %164, ptr %165, align 8
  br label %166

166:                                              ; preds = %180, %159
  %167 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKllEES5_(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull align 8 dereferenceable(8) %28) #5
  br i1 %167, label %173, label %168

168:                                              ; preds = %166
  store i32 11, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #5
  br label %186

169:                                              ; preds = %186, %156
  %170 = landingpad { ptr, i32 }
          cleanup
  %171 = extractvalue { ptr, i32 } %170, 0
  store ptr %171, ptr %8, align 8
  %172 = extractvalue { ptr, i32 } %170, 1
  store i32 %172, ptr %9, align 4
  br label %191

173:                                              ; preds = %166
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #5
  %174 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKllEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %27) #5
  store ptr %174, ptr %29, align 8, !tbaa !11
  %175 = load ptr, ptr %29, align 8, !tbaa !11
  %176 = getelementptr inbounds %"struct.std::pair.6", ptr %175, i32 0, i32 0
  %177 = load i64, ptr %176, align 8, !tbaa !23
  %178 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.3, i64 noundef %177)
          to label %179 unwind label %182

179:                                              ; preds = %173
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #5
  br label %180

180:                                              ; preds = %179
  %181 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKllEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %27) #5
  br label %166

182:                                              ; preds = %173
  %183 = landingpad { ptr, i32 }
          cleanup
  %184 = extractvalue { ptr, i32 } %183, 0
  store ptr %184, ptr %8, align 8
  %185 = extractvalue { ptr, i32 } %183, 1
  store i32 %185, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #5
  br label %191

186:                                              ; preds = %168
  %187 = invoke i32 @puts(ptr noundef @.str.4)
          to label %188 unwind label %169

188:                                              ; preds = %186
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %189

189:                                              ; preds = %188
  %190 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %11) #5
  br label %61

191:                                              ; preds = %182, %169, %155
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  br label %192

192:                                              ; preds = %191, %83
  call void @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  br label %195

193:                                              ; preds = %63
  store i32 0, ptr %1, align 4
  store i32 1, ptr %13, align 4
  call void @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  %194 = load i32, ptr %1, align 4
  ret i32 %194

195:                                              ; preds = %192, %50
  call void @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  br label %196

196:                                              ; preds = %195
  %197 = load ptr, ptr %8, align 8
  %198 = load i32, ptr %9, align 4
  %199 = insertvalue { ptr, i32 } poison, ptr %197, 0
  %200 = insertvalue { ptr, i32 } %199, i32 %198, 1
  resume { ptr, i32 } %200
}

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

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

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) #4 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 nounwind uwtable
declare dso_local ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48)) #3 align 2

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

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

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

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

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

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

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

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

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

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

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

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

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

declare i32 @puts(ptr noundef) #2

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

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

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


; 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::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<long, std::pair<const long, std::map<long, long>>, std::_Select1st<std::pair<const long, std::map<long, long>>>, std::less<long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<long, std::pair<const long, std::map<long, long>>, std::_Select1st<std::pair<const long, std::map<long, long>>>, std::less<long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::_Rb_tree_iterator" = type { ptr }
%"class.std::map.0" = type { %"class.std::_Rb_tree.1" }
%"class.std::_Rb_tree.1" = type { %"struct.std::_Rb_tree<long, std::pair<const long, long>, std::_Select1st<std::pair<const long, long>>, std::less<long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<long, std::pair<const long, long>, std::_Select1st<std::pair<const long, long>>, std::less<long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_iterator.5" = type { ptr }

@.str = external hidden unnamed_addr constant [8 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i64, align 8
  %2 = alloca i64, align 8
  %3 = alloca %"class.std::map", align 8
  %4 = alloca i64, align 8
  %5 = alloca i64, align 8
  %6 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %7 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %8 = alloca %"class.std::map.0", align 8
  %9 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %10 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %11 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %12 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %13 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  %14 = alloca %"struct.std::_Rb_tree_iterator.5", align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #5
  %15 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1, ptr noundef nonnull %2)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %3) #5
  call void @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  %16 = load i64, ptr %1, align 8, !tbaa !5
  %17 = icmp sgt i64 %16, 0
  br i1 %17, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %29, %0
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  %18 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  store ptr %18, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #5
  %19 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  store ptr %19, ptr %7, align 8
  %20 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEESB_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  br i1 %20, label %.lr.ph49, label %._crit_edge50

.lr.ph:                                           ; preds = %0, %29
  %.037 = phi i64 [ %30, %29 ], [ 0, %0 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %21 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %4, ptr noundef nonnull %5)
  %22 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 8 dereferenceable(8) %5)
          to label %23 unwind label %33

23:                                               ; preds = %.lr.ph
  %24 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 8 dereferenceable(8) %4)
          to label %25 unwind label %33

25:                                               ; preds = %23
  store i64 1, ptr %24, align 8, !tbaa !5
  %26 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 8 dereferenceable(8) %4)
          to label %27 unwind label %33

27:                                               ; preds = %25
  %28 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %26, ptr noundef nonnull align 8 dereferenceable(8) %5)
          to label %29 unwind label %33

29:                                               ; preds = %27
  store i64 1, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  %30 = add nuw nsw i64 %.037, 1
  %31 = load i64, ptr %1, align 8, !tbaa !5
  %32 = icmp slt i64 %30, %31
  br i1 %32, label %.lr.ph, label %._crit_edge, !llvm.loop !9

33:                                               ; preds = %27, %25, %23, %.lr.ph
  %34 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  br label %89

._crit_edge50:                                    ; preds = %._crit_edge47, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #5
  ret i32 0

.lr.ph49:                                         ; preds = %._crit_edge, %._crit_edge47
  %35 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %8) #5
  call void @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  %36 = load i64, ptr %35, align 8, !tbaa !11
  %37 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i64 noundef %36)
  %38 = getelementptr inbounds i8, ptr %35, i64 8
  %39 = call noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %38) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  %40 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  store ptr %40, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #5
  %41 = call ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  store ptr %41, ptr %10, align 8
  %42 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEESB_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  br i1 %42, label %.lr.ph43, label %._crit_edge44

._crit_edge44:                                    ; preds = %77, %.lr.ph49
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  %43 = call noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  %44 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %43)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #5
  %45 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  store ptr %45, ptr %13, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #5
  %46 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  store ptr %46, ptr %14, align 8
  %47 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKllEES5_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  br i1 %47, label %.lr.ph46, label %._crit_edge47

.lr.ph43:                                         ; preds = %.lr.ph49, %77
  %48 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %49 = invoke noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE5countERS3_(ptr noundef nonnull align 8 dereferenceable(48) %38, ptr noundef nonnull align 8 dereferenceable(8) %48)
          to label %50 unwind label %63

50:                                               ; preds = %.lr.ph43
  %51 = icmp eq i64 %49, 0
  br i1 %51, label %52, label %77

52:                                               ; preds = %50
  %53 = load i64, ptr %35, align 8, !tbaa !11
  %54 = load i64, ptr %48, align 8, !tbaa !11
  %.not = icmp eq i64 %53, %54
  br i1 %.not, label %77, label %55

55:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #5
  %56 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %38) #5
  store ptr %56, ptr %11, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #5
  %57 = call ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %38) #5
  store ptr %57, ptr %12, align 8
  %58 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKllEES5_(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %12) #5
  br i1 %58, label %.lr.ph40, label %._crit_edge41

.lr.ph40:                                         ; preds = %55
  %59 = getelementptr inbounds i8, ptr %48, i64 8
  br label %65

._crit_edge41:                                    ; preds = %68, %55
  %.029.lcssa = phi i64 [ 0, %55 ], [ %spec.select, %68 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #5
  %60 = mul nsw i64 %.029.lcssa, 100
  %61 = sdiv i64 %60, %39
  %62 = load i64, ptr %2, align 8, !tbaa !5
  %.not31 = icmp slt i64 %61, %62
  br i1 %.not31, label %77, label %74

63:                                               ; preds = %74, %.lr.ph43
  %64 = landingpad { ptr, i32 }
          cleanup
  br label %80

65:                                               ; preds = %.lr.ph40, %68
  %.02938 = phi i64 [ 0, %.lr.ph40 ], [ %spec.select, %68 ]
  %66 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKllEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %11) #5
  %67 = invoke noundef i64 @_ZNKSt3mapIllSt4lessIlESaISt4pairIKllEEE5countERS3_(ptr noundef nonnull align 8 dereferenceable(48) %59, ptr noundef nonnull align 8 dereferenceable(8) %66)
          to label %68 unwind label %72

68:                                               ; preds = %65
  %.not33 = icmp ne i64 %67, 0
  %69 = zext i1 %.not33 to i64
  %spec.select = add nuw nsw i64 %.02938, %69
  %70 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKllEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %11) #5
  %71 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKllEES5_(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %12) #5
  br i1 %71, label %65, label %._crit_edge41

72:                                               ; preds = %65
  %73 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #5
  br label %80

74:                                               ; preds = %._crit_edge41
  %75 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) %8, ptr noundef nonnull align 8 dereferenceable(8) %48)
          to label %76 unwind label %63

76:                                               ; preds = %74
  store i64 1, ptr %75, align 8, !tbaa !5
  br label %77

77:                                               ; preds = %._crit_edge41, %76, %52, %50
  %78 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %79 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEESB_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  br i1 %79, label %.lr.ph43, label %._crit_edge44

80:                                               ; preds = %72, %63
  %.pn = phi { ptr, i32 } [ %73, %72 ], [ %64, %63 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  call void @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  br label %89

._crit_edge47:                                    ; preds = %.lr.ph46, %._crit_edge44
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  %81 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.4)
  call void @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %8) #5
  %82 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  %83 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKlSt3mapIllSt4lessIlESaIS0_IS1_lEEEEESB_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  br i1 %83, label %.lr.ph49, label %._crit_edge50

.lr.ph46:                                         ; preds = %._crit_edge44, %.lr.ph46
  %84 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKllEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #5
  %85 = load i64, ptr %84, align 8, !tbaa !22
  %86 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i64 noundef %85)
  %87 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKllEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #5
  %88 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKllEES5_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  br i1 %88, label %.lr.ph46, label %._crit_edge47

89:                                               ; preds = %80, %33
  %.pn34 = phi { ptr, i32 } [ %34, %33 ], [ %.pn, %80 ]
  call void @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #5
  resume { ptr, i32 } %.pn34
}

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

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

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt3mapIllSt4lessIlESaISt4pairIKllEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4 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 nounwind uwtable
declare dso_local ptr @_ZNSt3mapIlS_IllSt4lessIlESaISt4pairIKllEEES1_SaIS2_IS3_S6_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #3 align 2

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass