Received: from eggs.gnu.org ([140.186.70.92]:55249) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtQQb-0005ei-Rm for qemu-devel@nongnu.org; Fri, 03 Feb 2012 16:12:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RtQQa-00073v-KL for qemu-devel@nongnu.org; Fri, 03 Feb 2012 16:12:17 -0500 Received: from gw.ac.upc.edu ([147.83.30.3]:50403) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtQQa-00073o-As for qemu-devel@nongnu.org; Fri, 03 Feb 2012 16:12:16 -0500 From: =?utf-8?b?TGx1w61z?= Vilanova Date: Fri, 03 Feb 2012 22:12:05 +0100 Message-ID: <20120203211205.30134.94337.stgit@ginnungagap.bsc.es> In-Reply-To: <20120203211030.30134.94075.stgit@ginnungagap.bsc.es> References: <20120203211030.30134.94075.stgit@ginnungagap.bsc.es> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PATCH v2 06/11] trace: [tracetool] Process the "disable" event property List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: stefanha@gmail.com, harsh@linux.vnet.ibm.com Signed-off-by: Llu=C3=ADs Vilanova --- scripts/tracetool.py | 13 +++++++++++-- 1 files changed, 11 insertions(+), 2 deletions(-) diff --git a/scripts/tracetool.py b/scripts/tracetool.py index de867bd..b735a54 100755 --- a/scripts/tracetool.py +++ b/scripts/tracetool.py @@ -365,6 +365,9 @@ def dtrace_d(events): print '};' return =20 +def dtrace_nop_d(events): + pass + def dtrace_stp(events): for event in events: # Define prototype for probe arguments @@ -387,6 +390,9 @@ probe %(probeprefix)s.%(name)s =3D process("%(binary)= s").mark("%(name)s") print return =20 +def dtrace_nop_stp(events): + pass + def trace_stap_begin(): global probeprefix if backend !=3D "dtrace": @@ -429,6 +435,8 @@ converters =3D { 'nop': { 'h': nop_h, 'c': nop_c, + 'd': dtrace_nop_d, + 'stap': dtrace_nop_stp, }, =20 'stderr': { @@ -560,10 +568,11 @@ def main(): sys.exit(0) =20 events =3D read_events(sys.stdin) + trace_gen[output]['begin']() - converters[backend][output](events) + converters[backend][output]([ e for e in events if 'disable' not in = e.properties ]) + converters['nop'][output]([ e for e in events if 'disable' in e.prop= erties ]) trace_gen[output]['end']() - return =20 if __name__ =3D=3D "__main__": main()