[refactor] Replace boost::function with std::function (#5700)

Replace boost::function with std::function
This commit is contained in:
Zhengguo Yang
2021-05-09 22:00:48 +08:00
committed by GitHub
parent 11cce06962
commit 98e80aa65e
44 changed files with 182 additions and 174 deletions

View File

@ -169,13 +169,14 @@ Status ExecNode::prepare(RuntimeState* state) {
_rows_returned_counter = ADD_COUNTER(_runtime_profile, "RowsReturned", TUnit::UNIT);
_rows_returned_rate = runtime_profile()->add_derived_counter(
ROW_THROUGHPUT_COUNTER, TUnit::UNIT_PER_SECOND,
boost::bind<int64_t>(&RuntimeProfile::units_per_second, _rows_returned_counter,
runtime_profile()->total_time_counter()),
std::bind<int64_t>(&RuntimeProfile::units_per_second, _rows_returned_counter,
runtime_profile()->total_time_counter()),
"");
_mem_tracker = MemTracker::CreateTracker(_runtime_profile.get(), -1,
"ExecNode:" + _runtime_profile->name(),
state->instance_mem_tracker());
_expr_mem_tracker = MemTracker::CreateTracker(-1, "ExecNode:Exprs:" + _runtime_profile->name(), _mem_tracker);
_expr_mem_tracker = MemTracker::CreateTracker(-1, "ExecNode:Exprs:" + _runtime_profile->name(),
_mem_tracker);
_expr_mem_pool.reset(new MemPool(_expr_mem_tracker.get()));
// TODO chenhao
RETURN_IF_ERROR(Expr::prepare(_conjunct_ctxs, state, row_desc(), expr_mem_tracker()));