; LLVM IR from sunkafei/xcpc-algorithm-templates :: 算法/动态规划 (斯坦纳树（边权）)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.SteinerTree = type { i32, i32, [110 x [11000 x i32]], [110 x i32], [110 x i32], [2200 x i32], [2200 x i32], [2200 x i32], i32, [110 x [11000 x i8]], %"class.std::queue" }
%"class.std::queue" = type { %"class.std::deque" }
%"class.std::deque" = type { %"class.std::_Deque_base" }
%"class.std::_Deque_base" = type { %"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl" }
%"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl" = type { %"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl_data" }
%"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator", %"struct.std::_Deque_iterator" }
%"struct.std::_Deque_iterator" = type { ptr, ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = 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 }

@tree = external dso_local global %struct.SteinerTree, align 8
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@k = external dso_local global i32, align 4
@d = external dso_local global [11000 x i32], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z5checki(i32 noundef) #0

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca %"class.std::vector", align 8
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca %"class.std::vector", align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  %21 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2)
  br label %22

22:                                               ; preds = %221, %0
  %23 = load i32, ptr %2, align 4, !tbaa !5
  %24 = add nsw i32 %23, -1
  store i32 %24, ptr %2, align 4, !tbaa !5
  %25 = icmp ne i32 %23, 0
  br i1 %25, label %26, label %224

26:                                               ; preds = %22
  %27 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef @n, ptr noundef @m, ptr noundef @k)
  call void @llvm.lifetime.start.p0(i64 24, ptr %3) #6
  call void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 1, ptr %4, align 4, !tbaa !5
  br label %28

28:                                               ; preds = %35, %26
  %29 = load i32, ptr %4, align 4, !tbaa !5
  %30 = load i32, ptr @k, align 4, !tbaa !5
  %31 = icmp sle i32 %29, %30
  br i1 %31, label %33, label %32

32:                                               ; preds = %28
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  br label %42

33:                                               ; preds = %28
  invoke void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 4 dereferenceable(4) %4)
          to label %34 unwind label %38

34:                                               ; preds = %33
  br label %35

35:                                               ; preds = %34
  %36 = load i32, ptr %4, align 4, !tbaa !5
  %37 = add nsw i32 %36, 1
  store i32 %37, ptr %4, align 4, !tbaa !5
  br label %28, !llvm.loop !9

38:                                               ; preds = %33
  %39 = landingpad { ptr, i32 }
          cleanup
  %40 = extractvalue { ptr, i32 } %39, 0
  store ptr %40, ptr %5, align 8
  %41 = extractvalue { ptr, i32 } %39, 1
  store i32 %41, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  br label %223

42:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  store i32 1, ptr %7, align 4, !tbaa !5
  br label %43

43:                                               ; preds = %55, %42
  %44 = load i32, ptr %7, align 4, !tbaa !5
  %45 = load i32, ptr @k, align 4, !tbaa !5
  %46 = icmp sle i32 %44, %45
  br i1 %46, label %48, label %47

47:                                               ; preds = %43
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %62

48:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  %49 = load i32, ptr @n, align 4, !tbaa !5
  %50 = load i32, ptr @k, align 4, !tbaa !5
  %51 = sub nsw i32 %49, %50
  %52 = load i32, ptr %7, align 4, !tbaa !5
  %53 = add nsw i32 %51, %52
  store i32 %53, ptr %8, align 4, !tbaa !5
  invoke void @_ZNSt6vectorIiSaIiEE9push_backEOi(ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 4 dereferenceable(4) %8)
          to label %54 unwind label %58

54:                                               ; preds = %48
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  br label %55

55:                                               ; preds = %54
  %56 = load i32, ptr %7, align 4, !tbaa !5
  %57 = add nsw i32 %56, 1
  store i32 %57, ptr %7, align 4, !tbaa !5
  br label %43, !llvm.loop !11

58:                                               ; preds = %48
  %59 = landingpad { ptr, i32 }
          cleanup
  %60 = extractvalue { ptr, i32 } %59, 0
  store ptr %60, ptr %5, align 8
  %61 = extractvalue { ptr, i32 } %59, 1
  store i32 %61, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %223

62:                                               ; preds = %47
  %63 = load i32, ptr @n, align 4, !tbaa !5
  invoke void @_ZNSt6vectorIiSaIiEEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %3)
          to label %64 unwind label %71

64:                                               ; preds = %62
  invoke void @_ZN11SteinerTree4initEiSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(6077376) @tree, i32 noundef %63, ptr noundef %9)
          to label %65 unwind label %75

65:                                               ; preds = %64
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %66

66:                                               ; preds = %90, %65
  %67 = load i32, ptr %10, align 4, !tbaa !5
  %68 = load i32, ptr @m, align 4, !tbaa !5
  %69 = icmp slt i32 %67, %68
  br i1 %69, label %79, label %70

70:                                               ; preds = %66
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  br label %97

71:                                               ; preds = %97, %62
  %72 = landingpad { ptr, i32 }
          cleanup
  %73 = extractvalue { ptr, i32 } %72, 0
  store ptr %73, ptr %5, align 8
  %74 = extractvalue { ptr, i32 } %72, 1
  store i32 %74, ptr %6, align 4
  br label %223

75:                                               ; preds = %64
  %76 = landingpad { ptr, i32 }
          cleanup
  %77 = extractvalue { ptr, i32 } %76, 0
  store ptr %77, ptr %5, align 8
  %78 = extractvalue { ptr, i32 } %76, 1
  store i32 %78, ptr %6, align 4
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #6
  br label %223

79:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  %80 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef %11, ptr noundef %12, ptr noundef %13)
          to label %81 unwind label %93

81:                                               ; preds = %79
  %82 = load i32, ptr %11, align 4, !tbaa !5
  %83 = load i32, ptr %12, align 4, !tbaa !5
  %84 = load i32, ptr %13, align 4, !tbaa !5
  invoke void @_ZN11SteinerTree8add_edgeEiii(ptr noundef nonnull align 8 dereferenceable(6077376) @tree, i32 noundef %82, i32 noundef %83, i32 noundef %84)
          to label %85 unwind label %93

85:                                               ; preds = %81
  %86 = load i32, ptr %12, align 4, !tbaa !5
  %87 = load i32, ptr %11, align 4, !tbaa !5
  %88 = load i32, ptr %13, align 4, !tbaa !5
  invoke void @_ZN11SteinerTree8add_edgeEiii(ptr noundef nonnull align 8 dereferenceable(6077376) @tree, i32 noundef %86, i32 noundef %87, i32 noundef %88)
          to label %89 unwind label %93

89:                                               ; preds = %85
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  br label %90

90:                                               ; preds = %89
  %91 = load i32, ptr %10, align 4, !tbaa !5
  %92 = add nsw i32 %91, 1
  store i32 %92, ptr %10, align 4, !tbaa !5
  br label %66, !llvm.loop !12

93:                                               ; preds = %85, %81, %79
  %94 = landingpad { ptr, i32 }
          cleanup
  %95 = extractvalue { ptr, i32 } %94, 0
  store ptr %95, ptr %5, align 8
  %96 = extractvalue { ptr, i32 } %94, 1
  store i32 %96, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  br label %223

97:                                               ; preds = %70
  invoke void @_ZN11SteinerTree5solveEv(ptr noundef nonnull align 8 dereferenceable(6077376) @tree)
          to label %98 unwind label %71

98:                                               ; preds = %97
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #6
  %99 = load i32, ptr @k, align 4, !tbaa !5
  %100 = mul nsw i32 2, %99
  %101 = shl i32 1, %100
  %102 = sub nsw i32 %101, 1
  store i32 %102, ptr %14, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #6
  store i32 0, ptr %15, align 4, !tbaa !5
  br label %103

103:                                              ; preds = %141, %98
  %104 = load i32, ptr %15, align 4, !tbaa !5
  %105 = load i32, ptr %14, align 4, !tbaa !5
  %106 = icmp sle i32 %104, %105
  br i1 %106, label %108, label %107

107:                                              ; preds = %103
  store i32 13, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #6
  br label %144

108:                                              ; preds = %103
  %109 = load i32, ptr %15, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %110
  store i32 1061109567, ptr %111, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  store i32 1, ptr %17, align 4, !tbaa !5
  br label %112

112:                                              ; preds = %133, %108
  %113 = load i32, ptr %17, align 4, !tbaa !5
  %114 = load i32, ptr @n, align 4, !tbaa !5
  %115 = icmp sle i32 %113, %114
  br i1 %115, label %117, label %116

116:                                              ; preds = %112
  store i32 16, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  br label %140

117:                                              ; preds = %112
  %118 = load i32, ptr %15, align 4, !tbaa !5
  %119 = sext i32 %118 to i64
  %120 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %119
  %121 = load i32, ptr %17, align 4, !tbaa !5
  %122 = sext i32 %121 to i64
  %123 = getelementptr inbounds [110 x [11000 x i32]], ptr getelementptr inbounds (%struct.SteinerTree, ptr @tree, i32 0, i32 2), i64 0, i64 %122
  %124 = load i32, ptr %15, align 4, !tbaa !5
  %125 = sext i32 %124 to i64
  %126 = getelementptr inbounds [11000 x i32], ptr %123, i64 0, i64 %125
  %127 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %120, ptr noundef nonnull align 4 dereferenceable(4) %126)
          to label %128 unwind label %136

128:                                              ; preds = %117
  %129 = load i32, ptr %127, align 4, !tbaa !5
  %130 = load i32, ptr %15, align 4, !tbaa !5
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %131
  store i32 %129, ptr %132, align 4, !tbaa !5
  br label %133

133:                                              ; preds = %128
  %134 = load i32, ptr %17, align 4, !tbaa !5
  %135 = add nsw i32 %134, 1
  store i32 %135, ptr %17, align 4, !tbaa !5
  br label %112, !llvm.loop !13

136:                                              ; preds = %117
  %137 = landingpad { ptr, i32 }
          cleanup
  %138 = extractvalue { ptr, i32 } %137, 0
  store ptr %138, ptr %5, align 8
  %139 = extractvalue { ptr, i32 } %137, 1
  store i32 %139, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #6
  br label %222

140:                                              ; preds = %116
  br label %141

141:                                              ; preds = %140
  %142 = load i32, ptr %15, align 4, !tbaa !5
  %143 = add nsw i32 %142, 1
  store i32 %143, ptr %15, align 4, !tbaa !5
  br label %103, !llvm.loop !14

144:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #6
  store i32 1, ptr %18, align 4, !tbaa !5
  br label %145

145:                                              ; preds = %198, %144
  %146 = load i32, ptr %18, align 4, !tbaa !5
  %147 = load i32, ptr %14, align 4, !tbaa !5
  %148 = icmp sle i32 %146, %147
  br i1 %148, label %150, label %149

149:                                              ; preds = %145
  store i32 19, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #6
  br label %201

150:                                              ; preds = %145
  %151 = load i32, ptr %18, align 4, !tbaa !5
  %152 = call noundef zeroext i1 @_Z5checki(i32 noundef %151)
  br i1 %152, label %153, label %197

153:                                              ; preds = %150
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #6
  %154 = load i32, ptr %18, align 4, !tbaa !5
  %155 = sub nsw i32 %154, 1
  %156 = load i32, ptr %18, align 4, !tbaa !5
  %157 = and i32 %155, %156
  store i32 %157, ptr %19, align 4, !tbaa !5
  br label %158

158:                                              ; preds = %191, %153
  %159 = load i32, ptr %19, align 4, !tbaa !5
  %160 = icmp ne i32 %159, 0
  br i1 %160, label %162, label %161

161:                                              ; preds = %158
  store i32 22, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  br label %196

162:                                              ; preds = %158
  %163 = load i32, ptr %19, align 4, !tbaa !5
  %164 = call noundef zeroext i1 @_Z5checki(i32 noundef %163)
  br i1 %164, label %165, label %190

165:                                              ; preds = %162
  %166 = load i32, ptr %18, align 4, !tbaa !5
  %167 = sext i32 %166 to i64
  %168 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %167
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #6
  %169 = load i32, ptr %19, align 4, !tbaa !5
  %170 = sext i32 %169 to i64
  %171 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %170
  %172 = load i32, ptr %171, align 4, !tbaa !5
  %173 = load i32, ptr %18, align 4, !tbaa !5
  %174 = load i32, ptr %19, align 4, !tbaa !5
  %175 = sub nsw i32 %173, %174
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %176
  %178 = load i32, ptr %177, align 4, !tbaa !5
  %179 = add nsw i32 %172, %178
  store i32 %179, ptr %20, align 4, !tbaa !5
  %180 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %168, ptr noundef nonnull align 4 dereferenceable(4) %20)
          to label %181 unwind label %186

181:                                              ; preds = %165
  %182 = load i32, ptr %180, align 4, !tbaa !5
  %183 = load i32, ptr %18, align 4, !tbaa !5
  %184 = sext i32 %183 to i64
  %185 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %184
  store i32 %182, ptr %185, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  br label %190

186:                                              ; preds = %165
  %187 = landingpad { ptr, i32 }
          cleanup
  %188 = extractvalue { ptr, i32 } %187, 0
  store ptr %188, ptr %5, align 8
  %189 = extractvalue { ptr, i32 } %187, 1
  store i32 %189, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #6
  br label %222

190:                                              ; preds = %181, %162
  br label %191

191:                                              ; preds = %190
  %192 = load i32, ptr %19, align 4, !tbaa !5
  %193 = sub nsw i32 %192, 1
  %194 = load i32, ptr %18, align 4, !tbaa !5
  %195 = and i32 %193, %194
  store i32 %195, ptr %19, align 4, !tbaa !5
  br label %158, !llvm.loop !15

196:                                              ; preds = %161
  br label %197

197:                                              ; preds = %196, %150
  br label %198

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

201:                                              ; preds = %149
  %202 = load i32, ptr %14, align 4, !tbaa !5
  %203 = sext i32 %202 to i64
  %204 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %203
  %205 = load i32, ptr %204, align 4, !tbaa !5
  %206 = icmp sge i32 %205, 1061109567
  br i1 %206, label %207, label %214

207:                                              ; preds = %201
  %208 = invoke i32 @puts(ptr noundef @.str.3)
          to label %209 unwind label %210

209:                                              ; preds = %207
  br label %221

210:                                              ; preds = %214, %207
  %211 = landingpad { ptr, i32 }
          cleanup
  %212 = extractvalue { ptr, i32 } %211, 0
  store ptr %212, ptr %5, align 8
  %213 = extractvalue { ptr, i32 } %211, 1
  store i32 %213, ptr %6, align 4
  br label %222

214:                                              ; preds = %201
  %215 = load i32, ptr %14, align 4, !tbaa !5
  %216 = sext i32 %215 to i64
  %217 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %216
  %218 = load i32, ptr %217, align 4, !tbaa !5
  %219 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.4, i32 noundef %218)
          to label %220 unwind label %210

220:                                              ; preds = %214
  br label %221

221:                                              ; preds = %220, %209
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %3) #6
  br label %22, !llvm.loop !17

222:                                              ; preds = %210, %186, %136
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  br label %223

223:                                              ; preds = %222, %93, %75, %71, %58, %38
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  br label %226

224:                                              ; preds = %22
  store i32 0, ptr %1, align 4
  store i32 1, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  %225 = load i32, ptr %1, align 4
  ret i32 %225

226:                                              ; preds = %223
  %227 = load ptr, ptr %5, align 8
  %228 = load i32, ptr %6, align 4
  %229 = insertvalue { ptr, i32 } poison, ptr %227, 0
  %230 = insertvalue { ptr, i32 } %229, i32 %228, 1
  resume { ptr, i32 } %230
}

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

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

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11SteinerTree4initEiSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(6077376), i32 noundef, ptr noundef) #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN11SteinerTree8add_edgeEiii(ptr noundef nonnull align 8 dereferenceable(6077376), i32 noundef, i32 noundef, i32 noundef) #0 align 2

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

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

declare i32 @puts(ptr noundef) #3

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

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

%struct.SteinerTree = type { i32, i32, [110 x [11000 x i32]], [110 x i32], [110 x i32], [2200 x i32], [2200 x i32], [2200 x i32], i32, [110 x [11000 x i8]], %"class.std::queue" }
%"class.std::queue" = type { %"class.std::deque" }
%"class.std::deque" = type { %"class.std::_Deque_base" }
%"class.std::_Deque_base" = type { %"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl" }
%"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl" = type { %"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl_data" }
%"struct.std::_Deque_base<int, std::allocator<int>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator", %"struct.std::_Deque_iterator" }
%"struct.std::_Deque_iterator" = type { ptr, ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = 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 }

@tree = external dso_local global %struct.SteinerTree, align 8
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@k = external dso_local global i32, align 4
@d = external dso_local global [11000 x i32], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z5checki(i32 noundef) local_unnamed_addr #0

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca %"class.std::vector", align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca %"class.std::vector", align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #8
  %10 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %11 = load i32, ptr %1, align 4, !tbaa !5
  %12 = add nsw i32 %11, -1
  store i32 %12, ptr %1, align 4, !tbaa !5
  %.not77 = icmp eq i32 %11, 0
  br i1 %.not77, label %._crit_edge80, label %.lr.ph79

.lr.ph79:                                         ; preds = %0, %94
  %13 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull @n, ptr noundef nonnull @m, ptr noundef nonnull @k)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %2) #8
  call void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #8
  store i32 1, ptr %3, align 4, !tbaa !5
  %14 = load i32, ptr @k, align 4, !tbaa !5
  %.not4351 = icmp slt i32 %14, 1
  br i1 %.not4351, label %._crit_edge.thread, label %.lr.ph

._crit_edge.thread:                               ; preds = %.lr.ph79
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br label %._crit_edge56

._crit_edge:                                      ; preds = %15
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  %.not4452 = icmp slt i32 %18, 1
  br i1 %.not4452, label %._crit_edge56, label %.lr.ph55

.lr.ph:                                           ; preds = %.lr.ph79, %15
  invoke void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull align 4 dereferenceable(4) %3)
          to label %15 unwind label %19

15:                                               ; preds = %.lr.ph
  %16 = load i32, ptr %3, align 4, !tbaa !5
  %17 = add nsw i32 %16, 1
  store i32 %17, ptr %3, align 4, !tbaa !5
  %18 = load i32, ptr @k, align 4, !tbaa !5
  %.not43.not = icmp slt i32 %16, %18
  br i1 %.not43.not, label %.lr.ph, label %._crit_edge, !llvm.loop !9

19:                                               ; preds = %.lr.ph
  %20 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br label %97

._crit_edge56:                                    ; preds = %26, %._crit_edge.thread, %._crit_edge
  %21 = load i32, ptr @n, align 4, !tbaa !5
  invoke void @_ZNSt6vectorIiSaIiEEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %2)
          to label %31 unwind label %35

.lr.ph55:                                         ; preds = %._crit_edge, %26
  %22 = phi i32 [ %28, %26 ], [ %18, %._crit_edge ]
  %.03853 = phi i32 [ %27, %26 ], [ 1, %._crit_edge ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #8
  %23 = load i32, ptr @n, align 4, !tbaa !5
  %24 = sub i32 %.03853, %22
  %25 = add i32 %24, %23
  store i32 %25, ptr %4, align 4, !tbaa !5
  invoke void @_ZNSt6vectorIiSaIiEE9push_backEOi(ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull align 4 dereferenceable(4) %4)
          to label %26 unwind label %29

26:                                               ; preds = %.lr.ph55
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  %27 = add nuw nsw i32 %.03853, 1
  %28 = load i32, ptr @k, align 4, !tbaa !5
  %.not44.not = icmp slt i32 %.03853, %28
  br i1 %.not44.not, label %.lr.ph55, label %._crit_edge56, !llvm.loop !11

29:                                               ; preds = %.lr.ph55
  %30 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  br label %97

31:                                               ; preds = %._crit_edge56
  invoke void @_ZN11SteinerTree4initEiSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(6077376) @tree, i32 noundef %21, ptr noundef nonnull %5)
          to label %32 unwind label %37

32:                                               ; preds = %31
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #8
  %33 = load i32, ptr @m, align 4, !tbaa !5
  %34 = icmp sgt i32 %33, 0
  br i1 %34, label %.lr.ph59, label %._crit_edge60

._crit_edge60:                                    ; preds = %.lr.ph59, %32
  invoke void @_ZN11SteinerTree5solveEv(ptr noundef nonnull align 8 dereferenceable(6077376) @tree)
          to label %49 unwind label %35

35:                                               ; preds = %._crit_edge60, %._crit_edge56
  %36 = landingpad { ptr, i32 }
          cleanup
  br label %97

37:                                               ; preds = %31
  %38 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #8
  br label %97

.lr.ph59:                                         ; preds = %32, %.lr.ph59
  %.03757 = phi i32 [ %46, %.lr.ph59 ], [ 0, %32 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #8
  %39 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull %6, ptr noundef nonnull %7, ptr noundef nonnull %8)
  %40 = load i32, ptr %6, align 4, !tbaa !5
  %41 = load i32, ptr %7, align 4, !tbaa !5
  %42 = load i32, ptr %8, align 4, !tbaa !5
  call void @_ZN11SteinerTree8add_edgeEiii(ptr noundef nonnull align 8 dereferenceable(6077376) @tree, i32 noundef %40, i32 noundef %41, i32 noundef %42)
  %43 = load i32, ptr %7, align 4, !tbaa !5
  %44 = load i32, ptr %6, align 4, !tbaa !5
  %45 = load i32, ptr %8, align 4, !tbaa !5
  call void @_ZN11SteinerTree8add_edgeEiii(ptr noundef nonnull align 8 dereferenceable(6077376) @tree, i32 noundef %43, i32 noundef %44, i32 noundef %45)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #8
  %46 = add nuw nsw i32 %.03757, 1
  %47 = load i32, ptr @m, align 4, !tbaa !5
  %48 = icmp slt i32 %46, %47
  br i1 %48, label %.lr.ph59, label %._crit_edge60, !llvm.loop !12

49:                                               ; preds = %._crit_edge60
  %50 = load i32, ptr @k, align 4, !tbaa !5
  %51 = shl nsw i32 %50, 1
  %notmask = shl nsw i32 -1, %51
  %52 = xor i32 %notmask, -1
  %53 = load i32, ptr @n, align 4, !tbaa !5
  %54 = icmp slt i32 %53, 1
  %55 = sub nsw i32 0, %notmask
  %56 = zext nneg i32 %55 to i64
  br i1 %54, label %.split.us.preheader, label %.split

.split.us.preheader:                              ; preds = %49
  %57 = shl nuw nsw i64 %56, 2
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(1) @d, i8 63, i64 %57, i1 false), !tbaa !5
  br label %.preheader

.preheader:                                       ; preds = %._crit_edge65, %.split.us.preheader
  %.not4672 = icmp eq i32 %50, 0
  br i1 %.not4672, label %._crit_edge76, label %.lr.ph75.preheader

.lr.ph75.preheader:                               ; preds = %.preheader
  %umax = call i32 @llvm.umax.i32(i32 %52, i32 1)
  %58 = add nuw nsw i32 %umax, 1
  %wide.trip.count92 = zext nneg i32 %58 to i64
  br label %.lr.ph75

.split:                                           ; preds = %49, %._crit_edge65
  %59 = phi i32 [ %61, %._crit_edge65 ], [ %53, %49 ]
  %indvars.iv83 = phi i64 [ %indvars.iv.next84, %._crit_edge65 ], [ 0, %49 ]
  %60 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %indvars.iv83
  store i32 1061109567, ptr %60, align 4, !tbaa !5
  %.not4861 = icmp slt i32 %59, 1
  br i1 %.not4861, label %._crit_edge65, label %.lr.ph64

._crit_edge65:                                    ; preds = %.lr.ph64, %.split
  %61 = phi i32 [ %59, %.split ], [ %65, %.lr.ph64 ]
  %indvars.iv.next84 = add nuw nsw i64 %indvars.iv83, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next84, %56
  br i1 %exitcond.not, label %.preheader, label %.split, !llvm.loop !13

.lr.ph64:                                         ; preds = %.split, %.lr.ph64
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph64 ], [ 1, %.split ]
  %62 = getelementptr inbounds [110 x [11000 x i32]], ptr getelementptr inbounds (i8, ptr @tree, i64 8), i64 0, i64 %indvars.iv, i64 %indvars.iv83
  %63 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %60, ptr noundef nonnull align 4 dereferenceable(4) %62)
  %64 = load i32, ptr %63, align 4, !tbaa !5
  store i32 %64, ptr %60, align 4, !tbaa !5
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %65 = load i32, ptr @n, align 4, !tbaa !5
  %66 = sext i32 %65 to i64
  %.not48.not = icmp slt i64 %indvars.iv, %66
  br i1 %.not48.not, label %.lr.ph64, label %._crit_edge65, !llvm.loop !15

._crit_edge76:                                    ; preds = %.loopexit, %.preheader
  %67 = zext nneg i32 %52 to i64
  %68 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %67
  %69 = load i32, ptr %68, align 4, !tbaa !5
  %70 = icmp sgt i32 %69, 1061109566
  br i1 %70, label %90, label %92

.lr.ph75:                                         ; preds = %.lr.ph75.preheader, %.loopexit
  %indvars.iv89 = phi i64 [ 1, %.lr.ph75.preheader ], [ %indvars.iv.next90, %.loopexit ]
  %indvars91 = trunc i64 %indvars.iv89 to i32
  %71 = call noundef zeroext i1 @_Z5checki(i32 noundef %indvars91)
  br i1 %71, label %72, label %.loopexit

72:                                               ; preds = %.lr.ph75
  %73 = add nuw i32 %indvars91, 2147483647
  %.067 = and i32 %73, %indvars91
  %.not4768 = icmp eq i32 %.067, 0
  br i1 %.not4768, label %.loopexit, label %.lr.ph71

.lr.ph71:                                         ; preds = %72
  %74 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %indvars.iv89
  br label %75

75:                                               ; preds = %.lr.ph71, %88
  %.069 = phi i32 [ %.067, %.lr.ph71 ], [ %.0, %88 ]
  %76 = call noundef zeroext i1 @_Z5checki(i32 noundef %.069)
  br i1 %76, label %77, label %88

77:                                               ; preds = %75
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #8
  %78 = zext nneg i32 %.069 to i64
  %79 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %78
  %80 = load i32, ptr %79, align 4, !tbaa !5
  %81 = sub nsw i32 %indvars91, %.069
  %82 = sext i32 %81 to i64
  %83 = getelementptr inbounds [11000 x i32], ptr @d, i64 0, i64 %82
  %84 = load i32, ptr %83, align 4, !tbaa !5
  %85 = add nsw i32 %84, %80
  store i32 %85, ptr %9, align 4, !tbaa !5
  %86 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %74, ptr noundef nonnull align 4 dereferenceable(4) %9)
  %87 = load i32, ptr %86, align 4, !tbaa !5
  store i32 %87, ptr %74, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #8
  br label %88

88:                                               ; preds = %75, %77
  %89 = add nuw i32 %.069, 2147483647
  %.0 = and i32 %89, %indvars91
  %.not47 = icmp eq i32 %.0, 0
  br i1 %.not47, label %.loopexit, label %75, !llvm.loop !16

.loopexit:                                        ; preds = %88, %72, %.lr.ph75
  %indvars.iv.next90 = add nuw nsw i64 %indvars.iv89, 1
  %exitcond93.not = icmp eq i64 %indvars.iv.next90, %wide.trip.count92
  br i1 %exitcond93.not, label %._crit_edge76, label %.lr.ph75, !llvm.loop !17

90:                                               ; preds = %._crit_edge76
  %91 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  br label %94

92:                                               ; preds = %._crit_edge76
  %93 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4, i32 noundef %69)
  br label %94

94:                                               ; preds = %92, %90
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #8
  %95 = load i32, ptr %1, align 4, !tbaa !5
  %96 = add nsw i32 %95, -1
  store i32 %96, ptr %1, align 4, !tbaa !5
  %.not = icmp eq i32 %95, 0
  br i1 %.not, label %._crit_edge80, label %.lr.ph79, !llvm.loop !18

97:                                               ; preds = %37, %35, %29, %19
  %.pn49 = phi { ptr, i32 } [ %20, %19 ], [ %30, %29 ], [ %36, %35 ], [ %38, %37 ]
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #8
  resume { ptr, i32 } %.pn49

._crit_edge80:                                    ; preds = %94, %0
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #8
  ret i32 0
}

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

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

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11SteinerTree4initEiSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(6077376), i32 noundef, ptr noundef) local_unnamed_addr #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN11SteinerTree8add_edgeEiii(ptr noundef nonnull align 8 dereferenceable(6077376), i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #0 align 2

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

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

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

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

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

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

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"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}
!14 = !{!"llvm.loop.unswitch.partial.disable"}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimpleLoopUnswitchPass,SimplifyCFGPass