diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c index 83c6515e425de5c22c7d7e6114492d9cc8ddb4e7..7aaee39f6774f1fc49131dd7a3d67f002bee823c 100644 --- a/tools/perf/builtin-trace.c +++ b/tools/perf/builtin-trace.c @@ -268,6 +268,13 @@ static int trace__run(struct trace *trace) if (evlist->threads->map[0] == -1 || evlist->threads->nr > 1) printf("%d ", sample.tid); + if (sample.raw_data == NULL) { + printf("%s sample with no payload for tid: %d, cpu %d, raw_size=%d, skipping...\n", + perf_evsel__name(evsel), sample.tid, + sample.cpu, sample.raw_size); + continue; + } + handler = evsel->handler.func; handler(trace, evsel, &sample); }