[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC PATCH v3 1/8] tracetool: Rewrite infrastructure as
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [RFC PATCH v3 1/8] tracetool: Rewrite infrastructure as python modules |
Date: |
Mon, 2 Apr 2012 08:36:58 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Fri, Mar 30, 2012 at 06:55:16PM +0200, Lluís Vilanova wrote:
> Stefan Hajnoczi writes:
> >> + kwargs = {}
> >> +
> >> + try:
> >> + tracetool.generate(sys.stdin, arg_format, arg_backend, **kwargs)
>
> > If forgot to ask what kwargs is doing here? Can we default to {}?
> > Otherwise let's drop it for now since there are no options defined yet.
>
> It's used later in the patch adding dtrace support. I just thought it would be
> better to maintain the interface of 'tracetool.generate' instead of adding new
> parameters later when necessary.
Thanks for pointing that out. I went back to look at how the
dtrace-specific options get passed in. I noticed you assigned them
directly to dtrace.py module variables - probably because you didn't
want to add the (mostly unused) kwargs argument to all code generation
functions?
For now I think this is okay since most backends don't care about
kwargs. If we need it more maybe we should think of a cleaner solution.
Stefan
- Re: [Qemu-devel] [RFC PATCH v3 1/8] tracetool: Rewrite infrastructure as python modules,
Stefan Hajnoczi <=