mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 07:13:54 -06:00
trace: track enabled events in a separate array
This is more cache friendly on the fast path, where we already have the event id available. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
43b48cfc3e
commit
585ec7273e
5 changed files with 14 additions and 8 deletions
|
@ -27,7 +27,7 @@ def generate(events, backend):
|
|||
out('TraceEvent trace_events[TRACE_EVENT_COUNT] = {')
|
||||
|
||||
for e in events:
|
||||
out(' { .id = %(id)s, .name = \"%(name)s\", .sstate = %(sstate)s, .dstate = 0 },',
|
||||
out(' { .id = %(id)s, .name = \"%(name)s\", .sstate = %(sstate)s },',
|
||||
id = "TRACE_" + e.name.upper(),
|
||||
name = e.name,
|
||||
sstate = "TRACE_%s_ENABLED" % e.name.upper())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue