; LLVM IR from upupming/algorithm :: BasicLevel_C++/1058. 选择题(20)  (main)

; 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::set<char>, std::allocator<std::set<char>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.2" = type { i8 }
%"struct.std::pair" = type <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<char, char, std::_Identity<char>, std::less<char>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<char, char, std::_Identity<char>, std::less<char>>::_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 }

@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [4 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 i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca %"class.std::vector", align 8
  %7 = alloca %"class.std::allocator", align 1
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca %"class.std::vector.0", align 8
  %11 = alloca %"class.std::allocator.2", align 1
  %12 = alloca %"class.std::vector.0", align 8
  %13 = alloca %"class.std::allocator.2", align 1
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i8, align 1
  %18 = alloca %"struct.std::pair", align 8
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca %"class.std::set", align 8
  %23 = alloca i8, align 1
  %24 = alloca i32, align 4
  %25 = alloca %"struct.std::pair", align 8
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  %29 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2, ptr noundef %3)
  call void @llvm.lifetime.start.p0(i64 24, ptr %6) #6
  %30 = load i32, ptr %3, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %7) #6
  call void @_ZNSaISt3setIcSt4lessIcESaIcEEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  invoke void @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %31, ptr noundef nonnull align 1 dereferenceable(1) %7)
          to label %32 unwind label %44

32:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorISt3setIcSt4lessIcESaIcEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %7) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %10) #6
  %33 = load i32, ptr %3, align 4, !tbaa !5
  %34 = sext i32 %33 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %11) #6
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %34, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %35 unwind label %48

35:                                               ; preds = %32
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #6
  %36 = load i32, ptr %3, align 4, !tbaa !5
  %37 = sext i32 %36 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %13) #6
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %13) #6
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %37, ptr noundef nonnull align 1 dereferenceable(1) %13)
          to label %38 unwind label %52

38:                                               ; preds = %35
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %13) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #6
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %39

39:                                               ; preds = %91, %38
  %40 = load i32, ptr %14, align 4, !tbaa !5
  %41 = load i32, ptr %3, align 4, !tbaa !5
  %42 = icmp slt i32 %40, %41
  br i1 %42, label %56, label %43

43:                                               ; preds = %39
  store i32 2, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  br label %95

44:                                               ; preds = %0
  %45 = landingpad { ptr, i32 }
          cleanup
  %46 = extractvalue { ptr, i32 } %45, 0
  store ptr %46, ptr %8, align 8
  %47 = extractvalue { ptr, i32 } %45, 1
  store i32 %47, ptr %9, align 4
  call void @_ZNSt15__new_allocatorISt3setIcSt4lessIcESaIcEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %7) #6
  br label %254

48:                                               ; preds = %32
  %49 = landingpad { ptr, i32 }
          cleanup
  %50 = extractvalue { ptr, i32 } %49, 0
  store ptr %50, ptr %8, align 8
  %51 = extractvalue { ptr, i32 } %49, 1
  store i32 %51, ptr %9, align 4
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #6
  br label %253

52:                                               ; preds = %35
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %8, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %9, align 4
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %13) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #6
  br label %252

56:                                               ; preds = %39
  %57 = load i32, ptr %14, align 4, !tbaa !5
  %58 = sext i32 %57 to i64
  %59 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %58) #6
  %60 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %59, ptr noundef %4, ptr noundef %5)
          to label %61 unwind label %67

61:                                               ; preds = %56
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %62

62:                                               ; preds = %83, %61
  %63 = load i32, ptr %16, align 4, !tbaa !5
  %64 = load i32, ptr %5, align 4, !tbaa !5
  %65 = icmp slt i32 %63, %64
  br i1 %65, label %71, label %66

66:                                               ; preds = %62
  store i32 5, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  br label %90

67:                                               ; preds = %56
  %68 = landingpad { ptr, i32 }
          cleanup
  %69 = extractvalue { ptr, i32 } %68, 0
  store ptr %69, ptr %8, align 8
  %70 = extractvalue { ptr, i32 } %68, 1
  store i32 %70, ptr %9, align 4
  br label %94

71:                                               ; preds = %62
  call void @llvm.lifetime.start.p0(i64 1, ptr %17) #6
  %72 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef %17)
          to label %73 unwind label %86

73:                                               ; preds = %71
  %74 = load i32, ptr %14, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %75) #6
  %77 = invoke { ptr, i8 } @_ZNSt3setIcSt4lessIcESaIcEE6insertERKc(ptr noundef nonnull align 8 dereferenceable(48) %76, ptr noundef nonnull align 1 dereferenceable(1) %17)
          to label %78 unwind label %86

78:                                               ; preds = %73
  %79 = getelementptr inbounds { ptr, i8 }, ptr %18, i32 0, i32 0
  %80 = extractvalue { ptr, i8 } %77, 0
  store ptr %80, ptr %79, align 8
  %81 = getelementptr inbounds { ptr, i8 }, ptr %18, i32 0, i32 1
  %82 = extractvalue { ptr, i8 } %77, 1
  store i8 %82, ptr %81, align 8
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #6
  br label %83

83:                                               ; preds = %78
  %84 = load i32, ptr %16, align 4, !tbaa !5
  %85 = add nsw i32 %84, 1
  store i32 %85, ptr %16, align 4, !tbaa !5
  br label %62, !llvm.loop !9

86:                                               ; preds = %73, %71
  %87 = landingpad { ptr, i32 }
          cleanup
  %88 = extractvalue { ptr, i32 } %87, 0
  store ptr %88, ptr %8, align 8
  %89 = extractvalue { ptr, i32 } %87, 1
  store i32 %89, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  br label %94

90:                                               ; preds = %66
  br label %91

91:                                               ; preds = %90
  %92 = load i32, ptr %14, align 4, !tbaa !5
  %93 = add nsw i32 %92, 1
  store i32 %93, ptr %14, align 4, !tbaa !5
  br label %39, !llvm.loop !11

94:                                               ; preds = %86, %67
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  br label %251

95:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #6
  store i32 0, ptr %19, align 4, !tbaa !5
  br label %96

96:                                               ; preds = %182, %95
  %97 = load i32, ptr %19, align 4, !tbaa !5
  %98 = load i32, ptr %2, align 4, !tbaa !5
  %99 = icmp slt i32 %97, %98
  br i1 %99, label %101, label %100

100:                                              ; preds = %96
  store i32 8, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  br label %186

101:                                              ; preds = %96
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #6
  store i32 0, ptr %20, align 4, !tbaa !5
  %102 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.3)
          to label %103 unwind label %109

103:                                              ; preds = %101
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #6
  store i32 0, ptr %21, align 4, !tbaa !5
  br label %104

104:                                              ; preds = %173, %103
  %105 = load i32, ptr %21, align 4, !tbaa !5
  %106 = load i32, ptr %3, align 4, !tbaa !5
  %107 = icmp slt i32 %105, %106
  br i1 %107, label %113, label %108

108:                                              ; preds = %104
  store i32 11, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #6
  br label %178

109:                                              ; preds = %178, %101
  %110 = landingpad { ptr, i32 }
          cleanup
  %111 = extractvalue { ptr, i32 } %110, 0
  store ptr %111, ptr %8, align 8
  %112 = extractvalue { ptr, i32 } %110, 1
  store i32 %112, ptr %9, align 4
  br label %185

113:                                              ; preds = %104
  %114 = load i32, ptr %21, align 4, !tbaa !5
  %115 = icmp ne i32 %114, 0
  br i1 %115, label %116, label %123

116:                                              ; preds = %113
  %117 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.4)
          to label %118 unwind label %119

118:                                              ; preds = %116
  br label %123

119:                                              ; preds = %123, %116
  %120 = landingpad { ptr, i32 }
          cleanup
  %121 = extractvalue { ptr, i32 } %120, 0
  store ptr %121, ptr %8, align 8
  %122 = extractvalue { ptr, i32 } %120, 1
  store i32 %122, ptr %9, align 4
  br label %177

123:                                              ; preds = %118, %113
  %124 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.5, ptr noundef %5)
          to label %125 unwind label %119

125:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 48, ptr %22) #6
  call void @_ZNSt3setIcSt4lessIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %23) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #6
  store i32 0, ptr %24, align 4, !tbaa !5
  br label %126

126:                                              ; preds = %140, %125
  %127 = load i32, ptr %24, align 4, !tbaa !5
  %128 = load i32, ptr %5, align 4, !tbaa !5
  %129 = icmp slt i32 %127, %128
  br i1 %129, label %131, label %130

130:                                              ; preds = %126
  store i32 14, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #6
  br label %147

131:                                              ; preds = %126
  %132 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef %23)
          to label %133 unwind label %143

133:                                              ; preds = %131
  %134 = invoke { ptr, i8 } @_ZNSt3setIcSt4lessIcESaIcEE6insertERKc(ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 1 dereferenceable(1) %23)
          to label %135 unwind label %143

135:                                              ; preds = %133
  %136 = getelementptr inbounds { ptr, i8 }, ptr %25, i32 0, i32 0
  %137 = extractvalue { ptr, i8 } %134, 0
  store ptr %137, ptr %136, align 8
  %138 = getelementptr inbounds { ptr, i8 }, ptr %25, i32 0, i32 1
  %139 = extractvalue { ptr, i8 } %134, 1
  store i8 %139, ptr %138, align 8
  br label %140

140:                                              ; preds = %135
  %141 = load i32, ptr %24, align 4, !tbaa !5
  %142 = add nsw i32 %141, 1
  store i32 %142, ptr %24, align 4, !tbaa !5
  br label %126, !llvm.loop !12

143:                                              ; preds = %133, %131
  %144 = landingpad { ptr, i32 }
          cleanup
  %145 = extractvalue { ptr, i32 } %144, 0
  store ptr %145, ptr %8, align 8
  %146 = extractvalue { ptr, i32 } %144, 1
  store i32 %146, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #6
  br label %176

147:                                              ; preds = %130
  %148 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.6)
          to label %149 unwind label %162

149:                                              ; preds = %147
  %150 = load i32, ptr %21, align 4, !tbaa !5
  %151 = sext i32 %150 to i64
  %152 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %151) #6
  %153 = invoke noundef zeroext i1 @_ZSteqIcSt4lessIcESaIcEEbRKSt3setIT_T0_T1_ES9_(ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 8 dereferenceable(48) %152)
          to label %154 unwind label %162

154:                                              ; preds = %149
  br i1 %153, label %155, label %166

155:                                              ; preds = %154
  %156 = load i32, ptr %21, align 4, !tbaa !5
  %157 = sext i32 %156 to i64
  %158 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %157) #6
  %159 = load i32, ptr %158, align 4, !tbaa !5
  %160 = load i32, ptr %20, align 4, !tbaa !5
  %161 = add nsw i32 %160, %159
  store i32 %161, ptr %20, align 4, !tbaa !5
  br label %172

162:                                              ; preds = %149, %147
  %163 = landingpad { ptr, i32 }
          cleanup
  %164 = extractvalue { ptr, i32 } %163, 0
  store ptr %164, ptr %8, align 8
  %165 = extractvalue { ptr, i32 } %163, 1
  store i32 %165, ptr %9, align 4
  br label %176

166:                                              ; preds = %154
  %167 = load i32, ptr %21, align 4, !tbaa !5
  %168 = sext i32 %167 to i64
  %169 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %168) #6
  %170 = load i32, ptr %169, align 4, !tbaa !5
  %171 = add nsw i32 %170, 1
  store i32 %171, ptr %169, align 4, !tbaa !5
  br label %172

172:                                              ; preds = %166, %155
  call void @llvm.lifetime.end.p0(i64 1, ptr %23) #6
  call void @_ZNSt3setIcSt4lessIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr %22) #6
  br label %173

173:                                              ; preds = %172
  %174 = load i32, ptr %21, align 4, !tbaa !5
  %175 = add nsw i32 %174, 1
  store i32 %175, ptr %21, align 4, !tbaa !5
  br label %104, !llvm.loop !13

176:                                              ; preds = %162, %143
  call void @llvm.lifetime.end.p0(i64 1, ptr %23) #6
  call void @_ZNSt3setIcSt4lessIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr %22) #6
  br label %177

177:                                              ; preds = %176, %119
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #6
  br label %185

178:                                              ; preds = %108
  %179 = load i32, ptr %20, align 4, !tbaa !5
  %180 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.7, i32 noundef %179)
          to label %181 unwind label %109

181:                                              ; preds = %178
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  br label %182

182:                                              ; preds = %181
  %183 = load i32, ptr %19, align 4, !tbaa !5
  %184 = add nsw i32 %183, 1
  store i32 %184, ptr %19, align 4, !tbaa !5
  br label %96, !llvm.loop !14

185:                                              ; preds = %177, %109
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  br label %251

186:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #6
  store i32 0, ptr %26, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #6
  store i32 0, ptr %27, align 4, !tbaa !5
  br label %187

187:                                              ; preds = %205, %186
  %188 = load i32, ptr %27, align 4, !tbaa !5
  %189 = load i32, ptr %3, align 4, !tbaa !5
  %190 = icmp slt i32 %188, %189
  br i1 %190, label %192, label %191

191:                                              ; preds = %187
  store i32 17, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #6
  br label %208

192:                                              ; preds = %187
  %193 = load i32, ptr %27, align 4, !tbaa !5
  %194 = sext i32 %193 to i64
  %195 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %194) #6
  %196 = load i32, ptr %195, align 4, !tbaa !5
  %197 = load i32, ptr %26, align 4, !tbaa !5
  %198 = icmp sgt i32 %196, %197
  br i1 %198, label %199, label %204

199:                                              ; preds = %192
  %200 = load i32, ptr %27, align 4, !tbaa !5
  %201 = sext i32 %200 to i64
  %202 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %201) #6
  %203 = load i32, ptr %202, align 4, !tbaa !5
  store i32 %203, ptr %26, align 4, !tbaa !5
  br label %204

204:                                              ; preds = %199, %192
  br label %205

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

208:                                              ; preds = %191
  %209 = load i32, ptr %26, align 4, !tbaa !5
  %210 = icmp eq i32 %209, 0
  br i1 %210, label %211, label %218

211:                                              ; preds = %208
  %212 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.8)
          to label %213 unwind label %214

213:                                              ; preds = %211
  br label %248

214:                                              ; preds = %218, %211
  %215 = landingpad { ptr, i32 }
          cleanup
  %216 = extractvalue { ptr, i32 } %215, 0
  store ptr %216, ptr %8, align 8
  %217 = extractvalue { ptr, i32 } %215, 1
  store i32 %217, ptr %9, align 4
  br label %250

218:                                              ; preds = %208
  %219 = load i32, ptr %26, align 4, !tbaa !5
  %220 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.9, i32 noundef %219)
          to label %221 unwind label %214

221:                                              ; preds = %218
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #6
  store i32 0, ptr %28, align 4, !tbaa !5
  br label %222

222:                                              ; preds = %244, %221
  %223 = load i32, ptr %28, align 4, !tbaa !5
  %224 = load i32, ptr %3, align 4, !tbaa !5
  %225 = icmp slt i32 %223, %224
  br i1 %225, label %227, label %226

226:                                              ; preds = %222
  store i32 20, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #6
  br label %247

227:                                              ; preds = %222
  %228 = load i32, ptr %28, align 4, !tbaa !5
  %229 = sext i32 %228 to i64
  %230 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %229) #6
  %231 = load i32, ptr %230, align 4, !tbaa !5
  %232 = load i32, ptr %26, align 4, !tbaa !5
  %233 = icmp eq i32 %231, %232
  br i1 %233, label %234, label %243

234:                                              ; preds = %227
  %235 = load i32, ptr %28, align 4, !tbaa !5
  %236 = add nsw i32 %235, 1
  %237 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.10, i32 noundef %236)
          to label %238 unwind label %239

238:                                              ; preds = %234
  br label %243

239:                                              ; preds = %234
  %240 = landingpad { ptr, i32 }
          cleanup
  %241 = extractvalue { ptr, i32 } %240, 0
  store ptr %241, ptr %8, align 8
  %242 = extractvalue { ptr, i32 } %240, 1
  store i32 %242, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #6
  br label %250

243:                                              ; preds = %238, %227
  br label %244

244:                                              ; preds = %243
  %245 = load i32, ptr %28, align 4, !tbaa !5
  %246 = add nsw i32 %245, 1
  store i32 %246, ptr %28, align 4, !tbaa !5
  br label %222, !llvm.loop !16

247:                                              ; preds = %226
  br label %248

248:                                              ; preds = %247, %213
  store i32 0, ptr %1, align 4
  store i32 1, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #6
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #6
  call void @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  %249 = load i32, ptr %1, align 4
  ret i32 %249

250:                                              ; preds = %239, %214
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #6
  br label %251

251:                                              ; preds = %250, %185, %94
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  br label %252

252:                                              ; preds = %251, %52
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #6
  br label %253

253:                                              ; preds = %252, %48
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #6
  call void @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  br label %254

254:                                              ; preds = %253, %44
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  br label %255

255:                                              ; preds = %254
  %256 = load ptr, ptr %8, align 8
  %257 = load i32, ptr %9, align 4
  %258 = insertvalue { ptr, i32 } poison, ptr %256, 0
  %259 = insertvalue { ptr, i32 } %258, i32 %257, 1
  resume { ptr, i32 } %259
}

; 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 @_ZNSaISt3setIcSt4lessIcESaIcEEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setIcSt4lessIcESaIcEE6insertERKc(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 1 dereferenceable(1)) #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3setIcSt4lessIcESaIcEED2Ev(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 void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) 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 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<char>, std::allocator<std::set<char>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.2" = type { i8 }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<char, char, std::_Identity<char>, std::less<char>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<char, char, std::_Identity<char>, std::less<char>>::_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 }

@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [4 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 i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca %"class.std::vector", align 8
  %6 = alloca %"class.std::allocator", align 1
  %7 = alloca %"class.std::vector.0", align 8
  %8 = alloca %"class.std::allocator.2", align 1
  %9 = alloca %"class.std::vector.0", align 8
  %10 = alloca %"class.std::allocator.2", align 1
  %11 = alloca i8, align 1
  %12 = alloca %"class.std::set", align 8
  %13 = alloca i8, align 1
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #6
  %14 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1, ptr noundef nonnull %2)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #6
  %15 = load i32, ptr %2, align 4, !tbaa !5
  %16 = sext i32 %15 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %6) #6
  call void @_ZNSaISt3setIcSt4lessIcESaIcEEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #6
  invoke void @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %16, ptr noundef nonnull align 1 dereferenceable(1) %6)
          to label %17 unwind label %29

17:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorISt3setIcSt4lessIcESaIcEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %6) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #6
  %18 = load i32, ptr %2, align 4, !tbaa !5
  %19 = sext i32 %18 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %8) #6
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #6
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %19, ptr noundef nonnull align 1 dereferenceable(1) %8)
          to label %20 unwind label %31

20:                                               ; preds = %17
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #6
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = sext i32 %21 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %10) #6
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #6
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %22, ptr noundef nonnull align 1 dereferenceable(1) %10)
          to label %23 unwind label %33

23:                                               ; preds = %20
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #6
  %24 = load i32, ptr %2, align 4, !tbaa !5
  %25 = icmp sgt i32 %24, 0
  br i1 %25, label %.lr.ph62, label %.preheader56

.preheader56:                                     ; preds = %._crit_edge, %23
  %26 = phi i32 [ %24, %23 ], [ %39, %._crit_edge ]
  %27 = load i32, ptr %1, align 4, !tbaa !5
  %28 = icmp sgt i32 %27, 0
  br i1 %28, label %.lr.ph73, label %.preheader

29:                                               ; preds = %0
  %30 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorISt3setIcSt4lessIcESaIcEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %6) #6
  br label %122

31:                                               ; preds = %17
  %32 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #6
  br label %121

33:                                               ; preds = %20
  %34 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #6
  br label %120

.lr.ph62:                                         ; preds = %23, %._crit_edge
  %indvars.iv = phi i64 [ %indvars.iv.next, %._crit_edge ], [ 0, %23 ]
  %35 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv) #6
  %36 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %35, ptr noundef nonnull %3, ptr noundef nonnull %4)
  %37 = load i32, ptr %4, align 4, !tbaa !5
  %38 = icmp sgt i32 %37, 0
  br i1 %38, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %45, %.lr.ph62
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %39 = load i32, ptr %2, align 4, !tbaa !5
  %40 = sext i32 %39 to i64
  %41 = icmp slt i64 %indvars.iv.next, %40
  br i1 %41, label %.lr.ph62, label %.preheader56, !llvm.loop !9

.lr.ph:                                           ; preds = %.lr.ph62, %45
  %.04959 = phi i32 [ %46, %45 ], [ 0, %.lr.ph62 ]
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %11) #6
  %42 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull %11)
  %43 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %indvars.iv) #6
  %44 = invoke { ptr, i8 } @_ZNSt3setIcSt4lessIcESaIcEE6insertERKc(ptr noundef nonnull align 8 dereferenceable(48) %43, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %45 unwind label %49

45:                                               ; preds = %.lr.ph
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #6
  %46 = add nuw nsw i32 %.04959, 1
  %47 = load i32, ptr %4, align 4, !tbaa !5
  %48 = icmp slt i32 %46, %47
  br i1 %48, label %.lr.ph, label %._crit_edge, !llvm.loop !11

49:                                               ; preds = %.lr.ph
  %50 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #6
  br label %119

.preheader.loopexit:                              ; preds = %._crit_edge71
  %.pre = load i32, ptr %2, align 4, !tbaa !5
  br label %.preheader

.preheader:                                       ; preds = %.preheader.loopexit, %.preheader56
  %51 = phi i32 [ %.pre, %.preheader.loopexit ], [ %26, %.preheader56 ]
  %52 = icmp sgt i32 %51, 0
  br i1 %52, label %.lr.ph76, label %._crit_edge77.thread

.lr.ph73:                                         ; preds = %.preheader56, %._crit_edge71
  %.04272 = phi i32 [ %57, %._crit_edge71 ], [ 0, %.preheader56 ]
  %53 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.3)
  %54 = load i32, ptr %2, align 4, !tbaa !5
  %55 = icmp sgt i32 %54, 0
  br i1 %55, label %.lr.ph70, label %._crit_edge71

._crit_edge71:                                    ; preds = %88, %.lr.ph73
  %.040.lcssa = phi i32 [ 0, %.lr.ph73 ], [ %.141, %88 ]
  %56 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.7, i32 noundef %.040.lcssa)
  %57 = add nuw nsw i32 %.04272, 1
  %58 = load i32, ptr %1, align 4, !tbaa !5
  %59 = icmp slt i32 %57, %58
  br i1 %59, label %.lr.ph73, label %.preheader.loopexit, !llvm.loop !12

.lr.ph70:                                         ; preds = %.lr.ph73, %88
  %indvars.iv83 = phi i64 [ %indvars.iv.next84, %88 ], [ 0, %.lr.ph73 ]
  %.04067 = phi i32 [ %.141, %88 ], [ 0, %.lr.ph73 ]
  %.not = icmp eq i64 %indvars.iv83, 0
  br i1 %.not, label %62, label %60

60:                                               ; preds = %.lr.ph70
  %61 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.4)
  br label %62

62:                                               ; preds = %60, %.lr.ph70
  %63 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.5, ptr noundef nonnull %4)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %12) #6
  call void @_ZNSt3setIcSt4lessIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %13) #6
  %64 = load i32, ptr %4, align 4, !tbaa !5
  %65 = icmp sgt i32 %64, 0
  br i1 %65, label %.lr.ph65, label %._crit_edge66

._crit_edge66:                                    ; preds = %71, %62
  %66 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.6)
  %67 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %indvars.iv83) #6
  %68 = invoke noundef zeroext i1 @_ZSteqIcSt4lessIcESaIcEEbRKSt3setIT_T0_T1_ES9_(ptr noundef nonnull align 8 dereferenceable(48) %12, ptr noundef nonnull align 8 dereferenceable(48) %67)
          to label %77 unwind label %82

.lr.ph65:                                         ; preds = %62, %71
  %.03863 = phi i32 [ %72, %71 ], [ 0, %62 ]
  %69 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull %13)
  %70 = invoke { ptr, i8 } @_ZNSt3setIcSt4lessIcESaIcEE6insertERKc(ptr noundef nonnull align 8 dereferenceable(48) %12, ptr noundef nonnull align 1 dereferenceable(1) %13)
          to label %71 unwind label %75

71:                                               ; preds = %.lr.ph65
  %72 = add nuw nsw i32 %.03863, 1
  %73 = load i32, ptr %4, align 4, !tbaa !5
  %74 = icmp slt i32 %72, %73
  br i1 %74, label %.lr.ph65, label %._crit_edge66, !llvm.loop !13

75:                                               ; preds = %.lr.ph65
  %76 = landingpad { ptr, i32 }
          cleanup
  br label %92

77:                                               ; preds = %._crit_edge66
  br i1 %68, label %78, label %84

78:                                               ; preds = %77
  %79 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv83) #6
  %80 = load i32, ptr %79, align 4, !tbaa !5
  %81 = add nsw i32 %80, %.04067
  br label %88

82:                                               ; preds = %._crit_edge66
  %83 = landingpad { ptr, i32 }
          cleanup
  br label %92

84:                                               ; preds = %77
  %85 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %indvars.iv83) #6
  %86 = load i32, ptr %85, align 4, !tbaa !5
  %87 = add nsw i32 %86, 1
  store i32 %87, ptr %85, align 4, !tbaa !5
  br label %88

88:                                               ; preds = %84, %78
  %.141 = phi i32 [ %81, %78 ], [ %.04067, %84 ]
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %13) #6
  call void @_ZNSt3setIcSt4lessIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %12) #6
  %indvars.iv.next84 = add nuw nsw i64 %indvars.iv83, 1
  %89 = load i32, ptr %2, align 4, !tbaa !5
  %90 = sext i32 %89 to i64
  %91 = icmp slt i64 %indvars.iv.next84, %90
  br i1 %91, label %.lr.ph70, label %._crit_edge71, !llvm.loop !14

92:                                               ; preds = %82, %75
  %.pn = phi { ptr, i32 } [ %76, %75 ], [ %83, %82 ]
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %13) #6
  call void @_ZNSt3setIcSt4lessIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %12) #6
  br label %119

._crit_edge77:                                    ; preds = %100
  %93 = icmp eq i32 %.1, 0
  br i1 %93, label %._crit_edge77.thread, label %105

.lr.ph76:                                         ; preds = %.preheader, %100
  %indvars.iv86 = phi i64 [ %indvars.iv.next87, %100 ], [ 0, %.preheader ]
  %.03574 = phi i32 [ %.1, %100 ], [ 0, %.preheader ]
  %94 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %indvars.iv86) #6
  %95 = load i32, ptr %94, align 4, !tbaa !5
  %96 = icmp sgt i32 %95, %.03574
  br i1 %96, label %97, label %100

97:                                               ; preds = %.lr.ph76
  %98 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %indvars.iv86) #6
  %99 = load i32, ptr %98, align 4, !tbaa !5
  br label %100

100:                                              ; preds = %.lr.ph76, %97
  %.1 = phi i32 [ %99, %97 ], [ %.03574, %.lr.ph76 ]
  %indvars.iv.next87 = add nuw nsw i64 %indvars.iv86, 1
  %101 = load i32, ptr %2, align 4, !tbaa !5
  %102 = sext i32 %101 to i64
  %103 = icmp slt i64 %indvars.iv.next87, %102
  br i1 %103, label %.lr.ph76, label %._crit_edge77, !llvm.loop !15

._crit_edge77.thread:                             ; preds = %.preheader, %._crit_edge77
  %104 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.8)
  br label %.loopexit

105:                                              ; preds = %._crit_edge77
  %106 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.9, i32 noundef %.1)
  %107 = load i32, ptr %2, align 4, !tbaa !5
  %108 = icmp sgt i32 %107, 0
  br i1 %108, label %.lr.ph81, label %.loopexit

.lr.ph81:                                         ; preds = %105, %.lr.ph81._crit_edge
  %indvars.iv89 = phi i64 [ %112, %.lr.ph81._crit_edge ], [ 0, %105 ]
  %109 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %indvars.iv89) #6
  %110 = load i32, ptr %109, align 4, !tbaa !5
  %111 = icmp eq i32 %110, %.1
  %112 = add nuw nsw i64 %indvars.iv89, 1
  br i1 %111, label %113, label %.lr.ph81._crit_edge

113:                                              ; preds = %.lr.ph81
  %114 = trunc nuw nsw i64 %112 to i32
  %115 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.10, i32 noundef %114)
  br label %.lr.ph81._crit_edge

.lr.ph81._crit_edge:                              ; preds = %.lr.ph81, %113
  %116 = load i32, ptr %2, align 4, !tbaa !5
  %117 = sext i32 %116 to i64
  %118 = icmp slt i64 %112, %117
  br i1 %118, label %.lr.ph81, label %.loopexit, !llvm.loop !16

.loopexit:                                        ; preds = %.lr.ph81._crit_edge, %105, %._crit_edge77.thread
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #6
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #6
  call void @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #6
  ret i32 0

119:                                              ; preds = %92, %49
  %.pn51 = phi { ptr, i32 } [ %50, %49 ], [ %.pn, %92 ]
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #6
  br label %120

120:                                              ; preds = %119, %33
  %.pn51.pn = phi { ptr, i32 } [ %.pn51, %119 ], [ %34, %33 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #6
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  br label %121

121:                                              ; preds = %120, %31
  %.pn51.pn.pn = phi { ptr, i32 } [ %.pn51.pn, %120 ], [ %32, %31 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #6
  call void @_ZNSt6vectorISt3setIcSt4lessIcESaIcEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  br label %122

122:                                              ; preds = %121, %29
  %.pn51.pn.pn.pn = phi { ptr, i32 } [ %.pn51.pn.pn, %121 ], [ %30, %29 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #6
  resume { ptr, i32 } %.pn51.pn.pn.pn
}

; 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 @_ZNSaISt3setIcSt4lessIcESaIcEEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setIcSt4lessIcESaIcEE6insertERKc(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 1 dereferenceable(1)) local_unnamed_addr #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3setIcSt4lessIcESaIcEED2Ev(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 void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) 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 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}


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