Received: from eggs.gnu.org ([208.118.235.92]:33742) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UN5Sn-0006YY-BE for qemu-devel@nongnu.org; Tue, 02 Apr 2013 13:57:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UN5Sk-0002jq-Vy for qemu-devel@nongnu.org; Tue, 02 Apr 2013 13:57:41 -0400 Received: from hall.aurel32.net ([2001:470:1f15:c4f::1]:60143) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UN5Sk-0002jU-MZ for qemu-devel@nongnu.org; Tue, 02 Apr 2013 13:57:38 -0400 Date: Tue, 2 Apr 2013 19:57:36 +0200 From: Aurelien Jarno Message-ID: <20130402175736.GG22106@hall.aurel32.net> References: <1364913860-25159-1-git-send-email-pbonzini@redhat.com> <1364913860-25159-2-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: Sender: Aurelien Jarno Subject: Re: [Qemu-devel] [PATCH 1/5] configure: move TARGET_*_ALIGNMENT to target-*/cpu.h List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Paolo Bonzini , qemu-devel@nongnu.org On Tue, Apr 02, 2013 at 05:43:36PM +0100, Peter Maydell wrote: > On 2 April 2013 15:44, Paolo Bonzini wrote: > > This is no different from, for example, TARGET_LONG_BITS. It does > > not belong in configure. > > > diff --git a/target-ppc/cpu.h b/target-ppc/cpu.h > > index 42c36e2..19d4e4c 100644 > > --- a/target-ppc/cpu.h > > +++ b/target-ppc/cpu.h > > @@ -27,6 +27,7 @@ > > #if defined (TARGET_PPC64) > > /* PowerPC 64 definitions */ > > #define TARGET_LONG_BITS 64 > > +#define TARGET_LONG_ALIGNMENT 8 > > #define TARGET_PAGE_BITS 12 > > Doesn't this incorrectly set the long alignment to 8 > for ppc64abi32? (Probably similar problem for > sparc32plus and mipsn32. The underlying point here is that > alignment is an ABI decision and you can have more than one > ABI for a particular TARGET_FOO.) > I'll do a test for mipsn32, but first I'll try to look how/where it is used. Note that ppc64abi32 and sparc32plus are different than mipsn32. The first two are basically executing a 32-bit binary (with the 32-bit ABI) on a 64-bit emulated CPU, with for sparc access to more instructions. mipsn32 is a different ABI using 64-bit registers, but 32-bit pointers, simlar to x32. -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net