From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41129) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bnQhB-0000Lb-MP for qemu-devel@nongnu.org; Fri, 23 Sep 2016 09:39:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bnQh7-0001Ic-HI for qemu-devel@nongnu.org; Fri, 23 Sep 2016 09:39:16 -0400 Received: from mx1.redhat.com ([209.132.183.28]:40544) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bnQh7-0001IV-Au for qemu-devel@nongnu.org; Fri, 23 Sep 2016 09:39:13 -0400 Date: Fri, 23 Sep 2016 14:39:11 +0100 From: Stefan Hajnoczi Message-ID: <20160923133911.GP8221@stefanha-x1.localdomain> References: <1474533652-31170-1-git-send-email-berrange@redhat.com> <1474533652-31170-2-git-send-email-berrange@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Vhqu5qQ3bjg0ZI9i" Content-Disposition: inline In-Reply-To: <1474533652-31170-2-git-send-email-berrange@redhat.com> Subject: Re: [Qemu-devel] [PATCH v4 01/17] trace: add trace event iterator APIs List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Daniel P. Berrange" Cc: qemu-devel@nongnu.org, =?iso-8859-1?Q?Llu=EDs?= Vilanova , Eric Blake --Vhqu5qQ3bjg0ZI9i Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Sep 22, 2016 at 09:40:36AM +0100, Daniel P. Berrange wrote: > Currently methods which want to iterate over trace events, > do so using the trace_event_count() and trace_event_id() > methods. This leaks the concept of a single ID enum to > the callers. There is an alternative trace_event_pattern() > method which can be used in an iteration context, but its > design is stateless, so is not easy to expand it in the > future. >=20 > This defines a formal iterator API will provide a future- > proof way of iterating over events. >=20 > The iterator is also able to apply a pattern match filter > to events, further removing the need for the pattern >=20 > Reviewed-by: Llu=EDs Vilanova > Signed-off-by: Daniel P. Berrange > --- > trace/control.c | 21 +++++++++++++++++++++ > trace/control.h | 27 +++++++++++++++++++++++++++ > 2 files changed, 48 insertions(+) Reviewed-by: Stefan Hajnoczi --Vhqu5qQ3bjg0ZI9i Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEcBAEBAgAGBQJX5TB/AAoJEJykq7OBq3PIOd4H/iP4J8eSTJ5bCAHAq1wFAOUM IKP/0G4Ym6e63qFvDkZCjH3dira9hT226k5g862txpiuRgYHjj/e3CdE8cAet8u5 2UighqJecbTpWF1ZUtv0jCgTYoF9D6MvXprBh/VdIUjCr9dTUYAr1xgaAZPQPHeQ uXVQMsoHfHFY/ZuZiHBmSNJLjxyBbxrHawOd0GQj1zBW96ajcI/QMZ9ylyp8McZr cuM7xucfFEnuLLUyQnZC2k5YxUB9AtvvH1467zFUJ7zkChqQBVVM3QjRLD2dWtCR 1A14yOrJE1Ul/jvFO5bAZruYV7PwnvgWBZf6ujrJ5m/RpmWIus10BfPD+oqsptI= =JJ9a -----END PGP SIGNATURE----- --Vhqu5qQ3bjg0ZI9i--