From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49931) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bhzbl-0000ou-V3 for qemu-devel@nongnu.org; Thu, 08 Sep 2016 09:43:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bhzbh-00081B-9E for qemu-devel@nongnu.org; Thu, 08 Sep 2016 09:43:12 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52628) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bhzbh-000815-3Q for qemu-devel@nongnu.org; Thu, 08 Sep 2016 09:43:09 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 93B5E61970 for ; Thu, 8 Sep 2016 13:43:08 +0000 (UTC) Date: Thu, 8 Sep 2016 14:43:05 +0100 From: "Daniel P. Berrange" Message-ID: <20160908134305.GL30602@redhat.com> Reply-To: "Daniel P. Berrange" References: <1470756748-18933-1-git-send-email-berrange@redhat.com> <87vay6ed9t.fsf@fimbulvetr.bsc.es> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <87vay6ed9t.fsf@fimbulvetr.bsc.es> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH for-2.8 v1 00/60] Modular build of trace event files List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org, Stefan Hajnoczi On Thu, Sep 08, 2016 at 03:23:26PM +0200, Llu=C3=ADs Vilanova wrote: > Daniel P Berrange writes: >=20 > > I previously split the global trace-events file up into one file > > per-subdirectory to avoid merge conflict hell. > [...] >=20 > Sorry, I could not find the message where the infrastructure is modifie= d to > provide this. But I think there's a more efficient way to provide modul= ar > auto-generated tracing code without the hierarchical indexing you propo= sed. [snip] > struct TraceEvent ___trace_events[] =3D { > { > .name =3D "eventname", > .sstate =3D 1, > .dstate =3D ___trace_eventname_dstate; > } > } >=20 > TraceEvent *TRACE_EVENTNAME =3D &___trace_events[...]; Life would be simpler if we had the 'bool dstate' as part of the TraceEvent struct, but doing so would essentially be reverting this previous change: commit 585ec7273e6fdab902b2128bc6c2a8136aafef04 Author: Paolo Bonzini Date: Wed Oct 28 07:06:27 2015 +0100 trace: track enabled events in a separate array =20 This is more cache friendly on the fast path, where we already have the event id available. I asked Paolo about this previously and he indicated it was a notable performance improvement, so we can't put dstate back into the TraceEvent struct :-( Regards, Daniel --=20 |: http://berrange.com -o- http://www.flickr.com/photos/dberrange= / :| |: http://libvirt.org -o- http://virt-manager.or= g :| |: http://autobuild.org -o- http://search.cpan.org/~danberr= / :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vn= c :|