diff options
author | Daniel P. Berrange <berrange@redhat.com> | 2016-10-04 14:35:57 +0100 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@redhat.com> | 2016-10-12 09:54:52 +0200 |
commit | 9096b78a38a22963ca59bb16d54a772aa86d5159 (patch) | |
tree | 4e779f2acd0f30ccfe295cf14c0e165eb48bb49a /scripts/tracetool | |
parent | d1b97bcea3586bad572879f22437f44c690874cb (diff) | |
download | qemu-9096b78a38a22963ca59bb16d54a772aa86d5159.zip qemu-9096b78a38a22963ca59bb16d54a772aa86d5159.tar.gz qemu-9096b78a38a22963ca59bb16d54a772aa86d5159.tar.bz2 |
trace: push reading of events up a level to tracetool main
Move the reading of events out of the 'tracetool.generate'
method and into tracetool.main, so that the latter is not
tied to generating from a single source of events.
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: LluĂs Vilanova <vilanova@ac.upc.edu>
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Message-id: 1475588159-30598-19-git-send-email-berrange@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'scripts/tracetool')
-rw-r--r-- | scripts/tracetool/__init__.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/scripts/tracetool/__init__.py b/scripts/tracetool/__init__.py index bf01e93..ac2cb8f 100644 --- a/scripts/tracetool/__init__.py +++ b/scripts/tracetool/__init__.py @@ -364,14 +364,14 @@ def try_import(mod_name, attr_name=None, attr_default=None): return False, None -def generate(fevents, format, backends, +def generate(events, format, backends, binary=None, probe_prefix=None): """Generate the output for the given (format, backends) pair. Parameters ---------- - fevents : file - Event description file. + events : list + list of Event objects to generate for format : str Output format name. backends : list @@ -401,6 +401,4 @@ def generate(fevents, format, backends, tracetool.backend.dtrace.BINARY = binary tracetool.backend.dtrace.PROBEPREFIX = probe_prefix - events = read_events(fevents) - tracetool.format.generate(events, format, backend) |