aboutsummaryrefslogtreecommitdiff
path: root/scripts/tracetool
diff options
context:
space:
mode:
authorAlex Bennée <alex.bennee@linaro.org>2023-05-26 17:53:53 +0100
committerStefan Hajnoczi <stefanha@redhat.com>2023-06-01 11:05:05 -0400
commit710320137099b8d86cedb4f58de2455acd58cbde (patch)
treee5d166d22c98d46cb29cb62b32fe24be4ec80a52 /scripts/tracetool
parent78f314cf8349a76a757dbcc4da88bf9a0b20d3a1 (diff)
trace: remove vcpu_id from the TraceEvent structure
This does involve temporarily stubbing out some helper functions before we excise the rest of the code. Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Message-id: 20230526165401.574474-4-alex.bennee@linaro.org Message-Id: <20230524133952.3971948-4-alex.bennee@linaro.org> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'scripts/tracetool')
-rw-r--r--scripts/tracetool/format/c.py6
-rw-r--r--scripts/tracetool/format/h.py11
2 files changed, 1 insertions, 16 deletions
diff --git a/scripts/tracetool/format/c.py b/scripts/tracetool/format/c.py
index c390c1844a..69edf0d588 100644
--- a/scripts/tracetool/format/c.py
+++ b/scripts/tracetool/format/c.py
@@ -32,19 +32,13 @@ def generate(events, backend, group):
out('uint16_t %s;' % e.api(e.QEMU_DSTATE))
for e in events:
- if "vcpu" in e.properties:
- vcpu_id = 0
- else:
- vcpu_id = "TRACE_VCPU_EVENT_NONE"
out('TraceEvent %(event)s = {',
' .id = 0,',
- ' .vcpu_id = %(vcpu_id)s,',
' .name = \"%(name)s\",',
' .sstate = %(sstate)s,',
' .dstate = &%(dstate)s ',
'};',
event = e.api(e.QEMU_EVENT),
- vcpu_id = vcpu_id,
name = e.name,
sstate = "TRACE_%s_ENABLED" % e.name.upper(),
dstate = e.api(e.QEMU_DSTATE))
diff --git a/scripts/tracetool/format/h.py b/scripts/tracetool/format/h.py
index e94f0be7da..285d7b03a9 100644
--- a/scripts/tracetool/format/h.py
+++ b/scripts/tracetool/format/h.py
@@ -74,16 +74,7 @@ def generate(events, backend, group):
out('}')
- # tracer wrapper with checks (per-vCPU tracing)
- if "vcpu" in e.properties:
- trace_cpu = next(iter(e.args))[1]
- cond = "trace_event_get_vcpu_state(%(cpu)s,"\
- " TRACE_%(id)s)"\
- % dict(
- cpu=trace_cpu,
- id=e.name.upper())
- else:
- cond = "true"
+ cond = "true"
out('',
'static inline void %(api)s(%(args)s)',