mbox series

[0/8] trace-cmd convert

Message ID 20210913124754.3679916-1-tz.stoyanov@gmail.com (mailing list archive)
Headers show
Series trace-cmd convert | expand

Message

Tzvetomir Stoyanov (VMware) Sept. 13, 2021, 12:47 p.m. UTC
A new trace-cmd subcommand is introduced:
 trace-cmd convert -i <input file> -o <output file>
The command converts trace file between different versions. There are two
parameters for controlling the type of the output file:
 --file-version < 6 / 7>
 --compression < none / any / name of the desired compression algorithm >

This patch-set depends on "[PATCH 00/20] Trace file version 7 - compression",
should be applied on top of it:
 https://lore.kernel.org/linux-trace-devel/20210913124203.3677760-1-tz.stoyanov@gmail.com/

Known issues:
 - conversion of files with empty CPU buffers does not work.

Tzvetomir Stoyanov (VMware) (8):
  trace-cmd library: Use output handler when copying data from input
    file
  trace-cmd library: Handle version 7 files when copying headers between
    files
  trace-cmd library: Copy CPU count between trace files
  trace-cmd library: New API to copy buffer description between trace
    files
  trace-cmd library: New API to copy options between trace files
  trace-cmd library: New API to copy trace data between trace files
  trace-cmd library: Extend tracecmd_copy() API
  trace-cmd: Add new subcommand "convert"

 .../include/private/trace-cmd-private.h       |  15 +-
 lib/trace-cmd/include/trace-cmd-local.h       |  13 +
 lib/trace-cmd/trace-input.c                   | 689 +++++++++++++++---
 lib/trace-cmd/trace-output.c                  | 122 +++-
 lib/trace-cmd/trace-util.c                    |   8 +-
 tracecmd/Makefile                             |   1 +
 tracecmd/include/trace-local.h                |   2 +
 tracecmd/trace-cmd.c                          |   1 +
 tracecmd/trace-convert.c                      | 106 +++
 tracecmd/trace-restore.c                      |   2 +-
 tracecmd/trace-split.c                        |   2 +-
 tracecmd/trace-usage.c                        |  13 +
 12 files changed, 870 insertions(+), 104 deletions(-)
 create mode 100644 tracecmd/trace-convert.c