From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Lgloh-0001Z3-5r for qemu-devel@nongnu.org; Mon, 09 Mar 2009 16:11:15 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Lglog-0001Xk-Br for qemu-devel@nongnu.org; Mon, 09 Mar 2009 16:11:14 -0400 Received: from [199.232.76.173] (port=57338 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Lglof-0001XF-Q1 for qemu-devel@nongnu.org; Mon, 09 Mar 2009 16:11:13 -0400 Received: from mx20.gnu.org ([199.232.41.8]:2705) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Lglob-0007Gl-IT for qemu-devel@nongnu.org; Mon, 09 Mar 2009 16:11:09 -0400 Received: from mx2.redhat.com ([66.187.237.31]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Lgc3R-0002Rf-UI for qemu-devel@nongnu.org; Mon, 09 Mar 2009 05:45:50 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n299gnQc026297 for ; Mon, 9 Mar 2009 05:42:49 -0400 Message-ID: <49B4E498.6010709@redhat.com> Date: Mon, 09 Mar 2009 11:42:48 +0200 From: Avi Kivity MIME-Version: 1.0 Subject: Re: [Qemu-devel] Re: [6684] Fix "info registers" under kvm. References: <49B3EAA8.6050900@web.de> <49B3EE01.3090402@codemonkey.ws> <27E8D756-2550-4804-BE0D-54002A41E8A6@web.de> In-Reply-To: <27E8D756-2550-4804-BE0D-54002A41E8A6@web.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Andreas F=E4rber wrote: > > Am 08.03.2009 um 17:10 schrieb Anthony Liguori: > >> Jan Kiszka wrote: >>> I'm just still waiting for a reply from Anthony on how to embed best=20 >>> all >>> the "if (kvm_enabled()) foo();" patterns [2]. [...] >> >> I really don't have a great suggestion. I've been hoping we could=20 >> come up with something better than if (kvm_enabled()) foo(). If we=20 >> can't, we can't. > > What about this pattern: > > #define KVM(x) if (kvm_enabled()) { x; } > KVM(foo()); > > That would make it shorter to type and allows to #define KVM(x) for=20 > the no-KVM case. > Need to work out what to do if the function returns a value. --=20 error compiling committee.c: too many arguments to function