qapi/commands: Optionally generate trace for QMP commands
commitbd2017bc41566a94fbdfd8728b6e805ce2a2c124
authorVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Wed, 26 Jan 2022 16:11:26 +0000 (26 17:11 +0100)
committerMarkus Armbruster <armbru@redhat.com>
Thu, 27 Jan 2022 10:25:52 +0000 (27 11:25 +0100)
tree0aa773733c29a5f40f83c44144bc7f987017d11a
parent167d913f34aa469fa30b0c51a04d8d2b9a5f1fa5
qapi/commands: Optionally generate trace for QMP commands

Add trace generation disabled by default and new option --gen-trace to
enable it.  The next commit will enable it for qapi/, but not for qga/
and tests/.  Making it work for the latter two would involve some Meson
hackery to ensure we generate the trace-events files before trace-tool
uses them.  Since we don't actually support tracing there, we'll bypass
that problem.

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Message-Id: <20220126161130.3240892-4-vsementsov@virtuozzo.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
[Superfluous #include dropped]
Signed-off-by: Markus Armbruster <armbru@redhat.com>
scripts/qapi/commands.py
scripts/qapi/main.py