On Sun, Mar 06, 2011 at 09:52:56PM +0000, Peter Maydell wrote: > On 6 March 2011 18:18, Aurelien Jarno <aurel...@aurel32.net> wrote: > > On Wed, Feb 23, 2011 at 03:19:33PM +0000, Peter Maydell wrote: > >> This patchset removes the ad-hoc debug code in target-arm for > >> identifying cases where we leaked TCG temporary variables, in > >> favour of an implementation in tcg itself. > > > I am basically fine with this patch series modulo the small comment you > > made about patch 1. > > Thanks; I've sent a v2 which fixes that nit. > > > My only concern is that, given ARM code is quite > > sensitive to this kind of issue (there is no real rule if the caller or > > the callee should free the temp), that we forget to enable TCG debug to > > validate a patch. On the other hand I fully agree that this kind of > > check should not be done in "production" use. > > In the long term it would be good if we could make the ARM translate.c > less brittle like this. Can we at least define a rule for where we're > trying to get to so we can move in the right direction for new code? > > My suggestion would be that we should say that for gen_* functions > the callee should always have to free temps passed in as arguments. > This matches the convention for tcg_gen_$OP() and gen_helper_$WHATEVER(). >
I don't mind whatever convention, but my understanding is that this doesn't match tcg_gen_$OP() and gen_helper_$WHATEVER(), which never free temps passed in arguments. -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurel...@aurel32.net http://www.aurel32.net