[CP] record spm stats after plan execution even enable_perf_event parameter is disabled
This commit is contained in:
12
deps/oblib/src/lib/container/ob_mask_set2.h
vendored
12
deps/oblib/src/lib/container/ob_mask_set2.h
vendored
@ -43,9 +43,9 @@ public:
|
|||||||
{
|
{
|
||||||
is_inited_ = false;
|
is_inited_ = false;
|
||||||
array_ = NULL;
|
array_ = NULL;
|
||||||
bitset_.reuse();
|
bitset_.reuse();
|
||||||
}
|
}
|
||||||
void clear()
|
void clear()
|
||||||
{
|
{
|
||||||
bitset_.reuse();
|
bitset_.reuse();
|
||||||
}
|
}
|
||||||
@ -123,9 +123,9 @@ public:
|
|||||||
is_new_mask = tmp_new_mask;
|
is_new_mask = tmp_new_mask;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
bool is_all_mask() const
|
bool is_all_mask() const
|
||||||
{
|
{
|
||||||
bool bool_ret = false;
|
bool bool_ret = false;
|
||||||
|
|||||||
@ -491,6 +491,15 @@ void ObPhysicalPlan::update_plan_stat(const ObAuditRecordData &record,
|
|||||||
} else {
|
} else {
|
||||||
ATOMIC_INC(&(stat_.hit_count_));
|
ATOMIC_INC(&(stat_.hit_count_));
|
||||||
}
|
}
|
||||||
|
if (ATOMIC_LOAD(&stat_.is_evolution_)) { //for spm
|
||||||
|
ATOMIC_INC(&(stat_.evolution_stat_.executions_));
|
||||||
|
// ATOMIC_AAF(&(stat_.evolution_stat_.cpu_time_),
|
||||||
|
// record.get_elapsed_time() - record.exec_record_.wait_time_end_
|
||||||
|
// - (record.exec_timestamp_.run_ts_ - record.exec_timestamp_.receive_ts_));
|
||||||
|
ATOMIC_AAF(&(stat_.evolution_stat_.cpu_time_), record.exec_timestamp_.executor_t_);
|
||||||
|
ATOMIC_AAF(&(stat_.evolution_stat_.elapsed_time_), record.get_elapsed_time());
|
||||||
|
ATOMIC_STORE(&(stat_.evolution_stat_.last_exec_ts_), record.exec_timestamp_.executor_end_ts_);
|
||||||
|
}
|
||||||
} else { // long route stat begin
|
} else { // long route stat begin
|
||||||
execute_count = ATOMIC_AAF(&stat_.execute_times_, 1);
|
execute_count = ATOMIC_AAF(&stat_.execute_times_, 1);
|
||||||
ATOMIC_AAF(&(stat_.total_process_time_), record.get_process_time());
|
ATOMIC_AAF(&(stat_.total_process_time_), record.get_process_time());
|
||||||
|
|||||||
Reference in New Issue
Block a user