From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MzvrS-0002Ce-AZ for qemu-devel@nongnu.org; Mon, 19 Oct 2009 13:17:34 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MzvrN-00028h-Nm for qemu-devel@nongnu.org; Mon, 19 Oct 2009 13:17:33 -0400 Received: from [199.232.76.173] (port=43298 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MzvrN-00028d-61 for qemu-devel@nongnu.org; Mon, 19 Oct 2009 13:17:29 -0400 Received: from cantor2.suse.de ([195.135.220.15]:49894 helo=mx2.suse.de) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MzvrM-0000J2-T8 for qemu-devel@nongnu.org; Mon, 19 Oct 2009 13:17:29 -0400 From: Ulrich Hecht Subject: Re: [Qemu-devel] [PATCH 1/9] TCG "sync" op Date: Mon, 19 Oct 2009 19:17:33 +0200 References: <1255696735-21396-1-git-send-email-uli@suse.de> <200910161837.31850.uli@suse.de> <20091016172908.GG4127@hall.aurel32.net> In-Reply-To: <20091016172908.GG4127@hall.aurel32.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Disposition: inline Message-Id: <200910191917.34021.uli@suse.de> Content-Transfer-Encoding: quoted-printable List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Aurelien Jarno Cc: riku.voipio@iki.fi, qemu-devel@nongnu.org, agraf@suse.de On Friday 16 October 2009, Aurelien Jarno wrote: > This example is a bit biased, as registers are only saved, and never > reused. Let's comment on it though. Yeah, well, I searched from the top for the first case where it makes a=20 difference. If it's of any help, I can upload a complete dump of both=20 versions somewhere. > and I don't understand what is the gain compared to=20 > the use of tcg_gen_ld/st. There are two sets of TCG values, tcgregs (which would arguably better=20 called tcgregs64) and tcgregs32. When doing a 32-bit access, tcgregs(64)=20 is synced, which is a nop if tcgregs(64) hasn't been touched. When doing=20 a 64-bit access, tcgregs32 is synced, which is a nop if tcgregs32 hasn't=20 been touched. In practice, 32-bit accesses followed by 64-bit accesses=20 and vice versa are very rare, so in most cases, sync is a nop.=20 tcg_gen_ld/st is never a nop. That's the benefit. CU Uli --=20 SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG N=FCrnberg)