From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60560) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bNfNU-0006LO-WB for qemu-devel@nongnu.org; Thu, 14 Jul 2016 08:04:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bNfNQ-00060Y-RN for qemu-devel@nongnu.org; Thu, 14 Jul 2016 08:04:27 -0400 Received: from mail-wm0-x235.google.com ([2a00:1450:400c:c09::235]:38209) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bNfNQ-00060L-LV for qemu-devel@nongnu.org; Thu, 14 Jul 2016 08:04:24 -0400 Received: by mail-wm0-x235.google.com with SMTP id o80so110400465wme.1 for ; Thu, 14 Jul 2016 05:04:24 -0700 (PDT) References: <1468354426-837-1-git-send-email-sergey.fedorov@linaro.org> <1468354426-837-7-git-send-email-sergey.fedorov@linaro.org> <87y4544iv1.fsf@linaro.org> <57877310.4070205@gmail.com> <79a897b0-107d-f647-943b-dc5247cac999@redhat.com> From: Alex =?utf-8?Q?Benn=C3=A9e?= In-reply-to: <79a897b0-107d-f647-943b-dc5247cac999@redhat.com> Date: Thu, 14 Jul 2016 13:04:25 +0100 Message-ID: <87twfs4e9i.fsf@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit 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: Paolo Bonzini Cc: Sergey Fedorov , Sergey Fedorov , 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-pp Paolo Bonzini writes: > On 14/07/2016 13:10, Sergey Fedorov wrote: >> > This has merge conflicts with the current state of master. Is there >> > anyway to have a common implementation that is specialised only when >> > needed? >> >> The point was to put the assumptions on invalid CPU TB state as close to >> cpu_get_tb_cpu_state() definitions as possible. So that if anyone make >> changes they can notice those assumptions and correct them if necessary. > > It causes some repetition indeed, but I think it's a good idea. > > restore_state_to_opc is another case where most implementations have the > same simple "env->pc = data[0]" implementation. Yeah, now I've seen cpu_get_tb_cpu_state jump up the hot-path I tend to agree ;-) -- Alex Bennée