Received: from eggs.gnu.org ([2001:4830:134:3::10]:44116) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bK0q0-0002sE-NO for qemu-devel@nongnu.org; Mon, 04 Jul 2016 06:10:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bK0pw-0002YG-Bt for qemu-devel@nongnu.org; Mon, 04 Jul 2016 06:10:47 -0400 Received: from mx1.redhat.com ([209.132.183.28]:49553) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bK0pw-0002YC-67 for qemu-devel@nongnu.org; Mon, 04 Jul 2016 06:10:44 -0400 References: <1464986428-6739-1-git-send-email-alex.bennee@linaro.org> <1464986428-6739-12-git-send-email-alex.bennee@linaro.org> <87wpl4ikfi.fsf@linaro.org> <57776F6D.5010608@gmail.com> From: Paolo Bonzini Message-ID: <1116d6d5-97cf-ff92-c3c9-2fa075a4e900@redhat.com> Date: Mon, 4 Jul 2016 12:10:36 +0200 MIME-Version: 1.0 In-Reply-To: <57776F6D.5010608@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC v3 11/19] tcg: add options for enabling MTTCG List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Sergey Fedorov , =?UTF-8?Q?Alex_Benn=c3=a9e?= , Richard Henderson Cc: mttcg@greensocs.com, qemu-devel@nongnu.org, fred.konrad@greensocs.com, a.rigo@virtualopensystems.com, cota@braap.org, bobby.prani@gmail.com, mark.burton@greensocs.com, jan.kiszka@siemens.com, peter.maydell@linaro.org, claudio.fontana@huawei.com, Peter Crosthwaite On 02/07/2016 09:38, Sergey Fedorov wrote: >>>> >>> +bool qemu_tcg_mttcg_enabled(void) >>>> >>> +{ >>>> >>> + return mttcg_enabled; >>>> >>> +} >>> >> Is there a good reason to expose this via function call, rather than just test >>> >> the variable? >> > It was in Fred's original patch. I guess there could be an argument >> > versus a global variable but as mttcg_enabled is set during option >> > parsing we don't need to do anything dynamic. > I think it just resembles tcg_enabled(), kvm_enabled() etc. Those are macros however, not functions. They are macros in order to cull KVM code for files that are compiled per-target. Paolo