From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:40335) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QEfQG-0000ZG-BH for qemu-devel@nongnu.org; Tue, 26 Apr 2011 06:23:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QEfQE-0000Zp-W4 for qemu-devel@nongnu.org; Tue, 26 Apr 2011 06:23:12 -0400 Received: from hall.aurel32.net ([88.191.126.93]:39203) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QEfQE-0000Zj-Q9 for qemu-devel@nongnu.org; Tue, 26 Apr 2011 06:23:10 -0400 Date: Tue, 26 Apr 2011 12:23:07 +0200 From: Aurelien Jarno Message-ID: <20110426102307.GA20532@volta.aurel32.net> References: <1303401708-5419-1-git-send-email-peter.maydell@linaro.org> <20110425210953.GH21831@volta.aurel32.net> <20110425223146.GG6181@volta.aurel32.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [PATCH] target-arm: Minimal implementation of performance counters List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Paul Brook , qemu-devel@nongnu.org, patches@linaro.org On Mon, Apr 25, 2011 at 11:35:54PM +0100, Peter Maydell wrote: > On 25 April 2011 23:31, Aurelien Jarno wrote: > > On Mon, Apr 25, 2011 at 10:59:52PM +0100, Peter Maydell wrote: > >> On 25 April 2011 22:09, Aurelien Jarno wrote: > >> > Instead of having this complex test for all cp15 access, but only for > >> > catching a few access to performance registers, wouldn't it make more > >> > sense to have this test and an exception triggering directly in > >> > helper.c? > >> > >> That was what my first design did, but in discussions on IRC > >> with Paul Brook he basically said that you can't generate an > >> exception in the helper routine, you have to either generate > >> runtime code to do the test or throw away the TBs. Unfortunately > >> I forget the exact rationale, so I've cc'd Paul to remind me :-) > > > > This is something strange, plenty of targets are raising exceptions from > > helpers without any problem. > > You'd at minimum need to move the cp15 helper functions to a different > file, they're currently in helper.c which doesn't get compiled > with access to the global 'env' register. But I got the impression > there was something more significant than that. > I agree, but it's something that has to be done sooner or later anyway. -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net