mirror of
https://github.com/qemu/qemu.git
synced 2026-02-04 05:35:39 +00:00
tracetool: removed the unused vcpu property
The vcpu property is no longer used in these backends. Removing it avoids unnecessary checks and simplifies the code generation for these trace backends. Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Tanish Desai <tanishdesai37@gmail.com> Message-id: 20250722114352.3624-1-tanishdesai37@gmail.com Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
committed by
Stefan Hajnoczi
parent
ebcc602aae
commit
2b1791323e
@@ -219,7 +219,7 @@ class Event(object):
|
||||
r"(?:(?:(?P<fmt_trans>\".+),)?\s*(?P<fmt>\".+))?"
|
||||
r"\s*")
|
||||
|
||||
_VALID_PROPS = set(["disable", "vcpu"])
|
||||
_VALID_PROPS = set(["disable"])
|
||||
|
||||
def __init__(self, name, props, fmt, args, lineno, filename, orig=None,
|
||||
event_trans=None, event_exec=None):
|
||||
|
||||
@@ -29,11 +29,7 @@ def generate_h(event, group):
|
||||
if len(event.args) > 0:
|
||||
argnames = ", " + argnames
|
||||
|
||||
if "vcpu" in event.properties:
|
||||
# already checked on the generic format code
|
||||
cond = "true"
|
||||
else:
|
||||
cond = "trace_event_get_state(%s)" % ("TRACE_" + event.name.upper())
|
||||
cond = "trace_event_get_state(%s)" % ("TRACE_" + event.name.upper())
|
||||
|
||||
out(' if (%(cond)s && qemu_loglevel_mask(LOG_TRACE)) {',
|
||||
' if (message_with_timestamp) {',
|
||||
|
||||
@@ -37,11 +37,7 @@ def generate_h_begin(events, group):
|
||||
|
||||
def generate_h(event, group):
|
||||
event_id = 'TRACE_' + event.name.upper()
|
||||
if "vcpu" in event.properties:
|
||||
# already checked on the generic format code
|
||||
cond = "true"
|
||||
else:
|
||||
cond = "trace_event_get_state(%s)" % event_id
|
||||
cond = "trace_event_get_state(%s)" % event_id
|
||||
out(' if (%(cond)s) {',
|
||||
' _simple_%(api)s(%(args)s);',
|
||||
' }',
|
||||
|
||||
@@ -28,11 +28,7 @@ def generate_h(event, group):
|
||||
if len(event.args) > 0:
|
||||
argnames = ", " + argnames
|
||||
|
||||
if "vcpu" in event.properties:
|
||||
# already checked on the generic format code
|
||||
cond = "true"
|
||||
else:
|
||||
cond = "trace_event_get_state(%s)" % ("TRACE_" + event.name.upper())
|
||||
cond = "trace_event_get_state(%s)" % ("TRACE_" + event.name.upper())
|
||||
|
||||
out(' if (%(cond)s) {',
|
||||
'#line %(event_lineno)d "%(event_filename)s"',
|
||||
|
||||
Reference in New Issue
Block a user