Skip to content

Commit eb46845

Browse files
committed
Add warning
1 parent cf6244c commit eb46845

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

paddle/fluid/platform/device_tracer.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,7 @@ class DeviceTracerImpl : public DeviceTracer {
201201
uint32_t correlation_id, uint64_t bytes) {
202202
// 0 means timestamp information could not be collected for the kernel.
203203
if (start_ns == 0 || end_ns == 0) {
204+
LOG(WARNING) << name << " cannot be traced";
204205
return;
205206
}
206207
std::lock_guard<std::mutex> l(trace_mu_);
@@ -212,6 +213,7 @@ class DeviceTracerImpl : public DeviceTracer {
212213
uint32_t stream_id, uint32_t correlation_id) {
213214
// 0 means timestamp information could not be collected for the kernel.
214215
if (start == 0 || end == 0) {
216+
LOG(WARNING) << correlation_id << " cannot be traced";
215217
return;
216218
}
217219
std::lock_guard<std::mutex> l(trace_mu_);

0 commit comments

Comments
 (0)