From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47671) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bNgRi-0003kC-V4 for qemu-devel@nongnu.org; Thu, 14 Jul 2016 09:12:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bNgRh-0002gt-1i for qemu-devel@nongnu.org; Thu, 14 Jul 2016 09:12:53 -0400 References: <1468354426-837-1-git-send-email-sergey.fedorov@linaro.org> <1468354426-837-7-git-send-email-sergey.fedorov@linaro.org> <87oa604bzf.fsf@linaro.org> <57878CFA.4060604@gmail.com> From: Paolo Bonzini Message-ID: <1ff282ad-39e6-76e7-e923-5db0229baf21@redhat.com> Date: Thu, 14 Jul 2016 15:12:33 +0200 MIME-Version: 1.0 In-Reply-To: <57878CFA.4060604@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v3 06/11] tcg: Introduce tb_mark_invalid() and tb_is_invalid() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Sergey Fedorov , =?UTF-8?Q?Alex_Benn=c3=a9e?= , Sergey Fedorov Cc: qemu-devel@nongnu.org, mttcg@greensocs.com, fred.konrad@greensocs.com, a.rigo@virtualopensystems.com, cota@braap.org, bobby.prani@gmail.com, rth@twiddle.net, patches@linaro.org, mark.burton@greensocs.com, jan.kiszka@siemens.com, peter.maydell@linaro.org, claudio.fontana@huawei.com, Peter Crosthwaite , "Edgar E. Iglesias" , Eduardo Habkost , Michael Walle , Aurelien Jarno , Leon Alrae , Anthony Green , Jia Liu , David Gibson , Alexander Graf , Mark Cave-Ayland , Artyom Tarasenko , Bastian Koppelmann , Guan Xuetao , Max Filippov , qemu-arm@nongnu.org, qemu-ppc@nongnu.org On 14/07/2016 15:00, Sergey Fedorov wrote: > > > +} > > > + > > > +static inline bool tb_is_invalid(TranslationBlock *tb) > > > +{ > > > + return cpu_tb_cpu_state_is_invalidated(tb->pc, tb->cs_base, tb->flags); > > > +} > > Also why are we passing three pointers to parts of TranslationBlock? Why > > not just pass tb directly and be done with it? > > I'm not sure we want to include exec/exec-all.h in target-*/cpu.h We don't, exec/exec-all.h is TCG-specific while cpu.h isn't. Implementing tb_mark_invalid/tb_is_invalid in target-* without the indirection would be possible, but it would require splitting that out into a new header such as target-*/exec.h. Paolo