From eb4684531307f1f1278a1e0869c8ebaf8ced4dc0 Mon Sep 17 00:00:00 2001 From: Xin Pan Date: Wed, 7 Mar 2018 18:07:42 -0800 Subject: [PATCH] Add warning --- paddle/fluid/platform/device_tracer.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/paddle/fluid/platform/device_tracer.cc b/paddle/fluid/platform/device_tracer.cc index 6efe703e227..8e1691efb5b 100644 --- a/paddle/fluid/platform/device_tracer.cc +++ b/paddle/fluid/platform/device_tracer.cc @@ -201,6 +201,7 @@ class DeviceTracerImpl : public DeviceTracer { uint32_t correlation_id, uint64_t bytes) { // 0 means timestamp information could not be collected for the kernel. if (start_ns == 0 || end_ns == 0) { + LOG(WARNING) << name << " cannot be traced"; return; } std::lock_guard l(trace_mu_); @@ -212,6 +213,7 @@ class DeviceTracerImpl : public DeviceTracer { uint32_t stream_id, uint32_t correlation_id) { // 0 means timestamp information could not be collected for the kernel. if (start == 0 || end == 0) { + LOG(WARNING) << correlation_id << " cannot be traced"; return; } std::lock_guard l(trace_mu_); -- GitLab