未验证 提交 6b3371e0 编写于 作者: C Chengmo 提交者: GitHub

Remove PE special profiler (#30886)

* remove pe special profiler

* add profiler info
上级 6beeafe7
...@@ -372,6 +372,7 @@ void Communicator::SendGlobalStep(const CommContext &ctx, int batches, ...@@ -372,6 +372,7 @@ void Communicator::SendGlobalStep(const CommContext &ctx, int batches,
if (batches == 0) { if (batches == 0) {
return; return;
} }
platform::RecordEvent record_event("Communicator->SendGlobalStep");
auto &table_id = ctx.table_id; auto &table_id = ctx.table_id;
size_t request_call_num = _worker_ptr->get_server_nums(); size_t request_call_num = _worker_ptr->get_server_nums();
...@@ -775,6 +776,7 @@ void SyncCommunicator::BarrierRecv() { ...@@ -775,6 +776,7 @@ void SyncCommunicator::BarrierRecv() {
void GeoCommunicator::Send(const std::vector<std::string> &var_names, void GeoCommunicator::Send(const std::vector<std::string> &var_names,
const framework::Scope &scope) { const framework::Scope &scope) {
platform::RecordEvent record_event("GeoCommunicator->Send");
waiting_ = false; waiting_ = false;
auto before_send = GetCurrentUS(); auto before_send = GetCurrentUS();
auto table_name = var_names[0]; auto table_name = var_names[0];
...@@ -1011,6 +1013,7 @@ void GeoCommunicator::InitSparse(const std::string &var_name, int table_id) { ...@@ -1011,6 +1013,7 @@ void GeoCommunicator::InitSparse(const std::string &var_name, int table_id) {
std::vector<int64_t> GeoCommunicator::MergeSparseIds( std::vector<int64_t> GeoCommunicator::MergeSparseIds(
const std::string &send_varname) { const std::string &send_varname) {
platform::RecordEvent record_event("GeoCommunicator->MergeSparseIds");
size_t merge_num = 0, wait_times = 0; size_t merge_num = 0, wait_times = 0;
std::unordered_set<int64_t> sparse_ids; std::unordered_set<int64_t> sparse_ids;
while (merge_num < static_cast<size_t>(max_merge_var_num_)) { while (merge_num < static_cast<size_t>(max_merge_var_num_)) {
......
...@@ -1122,8 +1122,6 @@ void ParallelExecutor::BCastParamsToDevices( ...@@ -1122,8 +1122,6 @@ void ParallelExecutor::BCastParamsToDevices(
FetchResultType ParallelExecutor::Run( FetchResultType ParallelExecutor::Run(
const std::vector<std::string> &fetch_tensors, bool return_merged) { const std::vector<std::string> &fetch_tensors, bool return_merged) {
VLOG(3) << "enter ParallelExecutor Run"; VLOG(3) << "enter ParallelExecutor Run";
platform::RecordEvent parallel_executor_event(
"ParallelExecutor::Run", paddle::platform::EventRole::kSpecial);
#ifdef WITH_GPERFTOOLS #ifdef WITH_GPERFTOOLS
if (gProfileStarted) { if (gProfileStarted) {
ProfilerFlush(); ProfilerFlush();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册