Re: [PATCH v1] rtla: Save trace when option `--trace` is specified
From: Steven Rostedt
Date: Thu Feb 27 2025 - 20:05:55 EST
On Mon, 27 Jan 2025 19:02:40 +0200
Costa Shulyupin <costa.shul@xxxxxxxxxx> wrote:
> +++ b/tools/tracing/rtla/src/osnoise_hist.c
> @@ -981,12 +981,11 @@ int osnoise_hist_main(int argc, char *argv[])
>
> return_value = 0;
>
> - if (osnoise_trace_is_off(tool, record)) {
> + if (osnoise_trace_is_off(tool, record))
> printf("rtla osnoise hit stop tracing\n");
> - if (params->trace_output) {
> - printf(" Saving trace to %s\n", params->trace_output);
> - save_trace_to_file(record->trace.inst, params->trace_output);
> - }
> + if (params->trace_output) {
> + printf(" Saving trace to %s\n", params->trace_output);
> + save_trace_to_file(record->trace.inst, params->trace_output);
> }
Without tracing being off, this can run forever if the events come in
faster than it can be recorded. And save trace uses the "trace" file, which
is slow to read.
Are you sure you want that?
-- Steve