diff options
author | Ian Rogers <[email protected]> | 2024-08-29 08:01:51 -0700 |
---|---|---|
committer | Arnaldo Carvalho de Melo <[email protected]> | 2024-08-29 16:17:43 -0300 |
commit | e9a7053da377e19ebc6f1afe55c7f75219aaef79 (patch) | |
tree | 02eb771941d1c04e9991f83d9e7307de9391b303 /scripts/clang-tools/gen_compile_commands.py | |
parent | 10df481fda13d29c2d9893b7460b8a7095d0ccf5 (diff) |
perf header: Allow attributes to be written after data
With a file, to write data an offset needs to be known. Typically data
follows the event attributes in a file.
However, if processing a pipe the number of event attributes may not be
known.
It is convenient in that case to write the attributes after the data.
Expand perf_session__do_write_header() to allow this when the data
offset and size are known.
This approach may be useful for more than just taking a pipe file to
write into a data file, `perf inject --itrace` will reserve and
additional 8kb for attributes, which would be unnecessary if the
attributes were written after the data.
Signed-off-by: Ian Rogers <[email protected]>
Cc: Adrian Hunter <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: James Clark <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Kan Liang <[email protected]>
Cc: Mark Rutland <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Nick Terrell <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Yanteng Si <[email protected]>
Cc: Yicong Yang <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'scripts/clang-tools/gen_compile_commands.py')
0 files changed, 0 insertions, 0 deletions