From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:54180) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QcP4O-0002d9-AB for qemu-devel@nongnu.org; Thu, 30 Jun 2011 17:46:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QcP4M-00035J-Ku for qemu-devel@nongnu.org; Thu, 30 Jun 2011 17:46:43 -0400 Received: from am1ehsobe001.messaging.microsoft.com ([213.199.154.204]:13782 helo=AM1EHSOBE001.bigfish.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QcP4M-00034s-2E for qemu-devel@nongnu.org; Thu, 30 Jun 2011 17:46:42 -0400 Date: Thu, 30 Jun 2011 16:46:30 -0500 From: Scott Wood Message-ID: <20110630164630.2bd57166@schlenkerla.am.freescale.net> In-Reply-To: <86AF921C-3FD1-409A-ACFD-EEEA23BBE130@suse.de> References: <1309180555-3942-1-git-send-email-chouteau@adacore.com> <20110627112807.22346e82@schlenkerla.am.freescale.net> <4E098E23.3040605@adacore.com> <20110628112008.31cf6237@schlenkerla.am.freescale.net> <4E0C32FB.40302@adacore.com> <20110630111745.7c544a06@schlenkerla.am.freescale.net> <86AF921C-3FD1-409A-ACFD-EEEA23BBE130@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] Add e500 instructions dcblc, dcbtls and dcbtstl as no-op List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexander Graf Cc: qemu-devel@nongnu.org, Fabien Chouteau On Thu, 30 Jun 2011 23:34:37 +0200 Alexander Graf wrote: > We could just keep an internal counter that memorizes how much memory is locked and sets the bit after exceeding the fake cache size. And keep track of unlocks, decrementing the counter only if the address was already locked... seems better to keep it simple and just be honest about the failure until a real need for trickery arises. > The only problem I could see remaining is that CAR could potentially fail, as it can access addresses in cache directly that don't have to have underlying RAM mapped. However, I'd hope that only firmware does this and we usually don't execute real firmware in qemu :) This is a case where it would be nice for the guest to see the failure indication, if we're lucky enough that it bothers to check. But yeah, it's unlikely to happen outside of firmware. > Also, lock set instructions seem to raise DSIs, so we need to generate some loads that don't go anywhere. Yes. Note that dcbtstls is treated as a store, which is a little trickier. -Scott