All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrange" <berrange@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: qemu-devel@nongnu.org, "Peter Maydell" <peter.maydell@linaro.org>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Dr. David Alan Gilbert" <dgilbert@redhat.com>,
	"Lluís Vilanova" <vilanova@ac.upc.edu>
Subject: Re: [Qemu-devel] Our use of #include is undisciplined, and what to do about it
Date: Tue, 15 Mar 2016 13:51:36 +0000	[thread overview]
Message-ID: <20160315135136.GD3168@redhat.com> (raw)
In-Reply-To: <20160315133916.GM27203@stefanha-x1.localdomain>

On Tue, Mar 15, 2016 at 01:39:17PM +0000, Stefan Hajnoczi wrote:
> On Tue, Mar 15, 2016 at 10:29:06AM +0100, Markus Armbruster wrote:
> > Stefan cc'ed because tracing is part of the problem.  Search for
> > "tracers".
> 
> Thanks for bringing up the generated tracing headers.  David Gilbert and
> I discussed splitting them up a few months ago.  I'll summarize the
> problem and we can think about solutions:
> 
> trace.h includes generated-tracers.h and generated-events.h.  These
> files are generated from scripts/tracetool.py.  The contents of the
> files depends on the configured --enable-trace-backends= list (log,
> simple, ftrace, dtrace, ust).
> 
> Idealy ./trace-events would have "sections" so that multiple files are
> generated:
> 
>   # section virtio-blk
>   foo() ...
> 
>   # section memory
>   bar() ...
> 
> This would put trace_foo() in generated-tracers-virtio-blk.h and
> trace_bar() in generated-tracers-memory.h.  Source files using tracing
> would need to include headers for relevant sections.

I'd actually like to see the trace events associated with the subsystem
eg any trace events for block devices should live in block/trace-events,
likewise for things like crypto/trace-events, io/trace-events, etc, etc.

This would naturally lead to generating a block/trace-events.h file that
only contained the block trace point definitions.

As well as simplifying compilation deps, it means the trace-events file
changes get associated with correct people for get_maintainer.pl usage,
and we reduce liklihood of merge conflicts for pull requests by getting
rid of the single big file

Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

  reply	other threads:[~2016-03-15 13:51 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-15  9:29 [Qemu-devel] Our use of #include is undisciplined, and what to do about it Markus Armbruster
2016-03-15  9:40 ` Paolo Bonzini
2016-03-15 12:19   ` Markus Armbruster
2016-03-15 14:51     ` Paolo Bonzini
2016-03-15 10:03 ` Peter Maydell
2016-03-15 12:28   ` Markus Armbruster
2016-03-15 12:56     ` Peter Maydell
2016-03-15 13:39 ` Stefan Hajnoczi
2016-03-15 13:51   ` Daniel P. Berrange [this message]
2016-03-15 13:56   ` Dr. David Alan Gilbert
2016-03-16 18:23     ` Stefan Hajnoczi
2016-03-16 18:27       ` Dr. David Alan Gilbert
2016-03-17 11:25         ` Stefan Hajnoczi
2016-03-17 16:29           ` Dr. David Alan Gilbert
2016-03-17 19:21             ` Paolo Bonzini
2016-03-17 19:43               ` Dr. David Alan Gilbert
2016-03-17 19:58               ` Paolo Bonzini
2016-03-17 20:14               ` Richard Henderson
2016-03-17 20:27                 ` Peter Maydell
2016-03-17 20:29                   ` Richard Henderson
2016-03-17 21:02                     ` Paolo Bonzini
2016-03-17 20:59                 ` Paolo Bonzini
2016-03-17 19:40 ` Richard Henderson
2019-05-27 13:12 ` Markus Armbruster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160315135136.GD3168@redhat.com \
    --to=berrange@redhat.com \
    --cc=armbru@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    --cc=vilanova@ac.upc.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.