This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Plans for Linux ELF "i686+" ABI ? Like SPARC V8+ ?
- From: Andi Kleen <andi at firstfloor dot org>
- To: Michael Meissner <michael dot meissner at amd dot com>, Andi Kleen <andi at firstfloor dot org>, Richard Guenther <richard dot guenther at gmail dot com>, gcc at gcc dot gnu dot org
- Date: Tue, 16 Oct 2007 00:53:13 +0200
- Subject: Re: Plans for Linux ELF "i686+" ABI ? Like SPARC V8+ ?
- References: <4712CE64.7050804@netbauds.net.suse.lists.egcs> <18195.11443.885432.966676@zebedee.pink.suse.lists.egcs> <47135A83.5040705@netbauds.net.suse.lists.egcs> <18195.24423.287047.842193@zebedee.pink.suse.lists.egcs> <47136430.5080907@netbauds.net.suse.lists.egcs> <84fc9c000710150639w1c234d45m44ecbfb3e41f8293@mail.gmail.com.suse.lists.egcs> <p73wsto1cmi.fsf@bingen.suse.de> <20071015190447.GA19641@mmeissner-gold.amd.com>
> Actually no. In 32-bit mode, double is aligned on a 4 byte boundary, not an 8
> byte boundary, unless you use -malign-double, which breaks the ABI. This has
> been a 'feature' of the original AT&T 386 System V ABI that Linux uses for
> 32-bit x86 processors. With the SCO mess, it may be hard to ever change that
> ABI....
My gcc doesn't agree with you (I actually checked before posting)
~> cat t.c
int main(void)
{
double x;
printf("%d\n", __alignof__(x));
return 0;
}
~> gcc -m32 -o t t.c
t.c: In function âmainâ:
t.c:5: warning: incompatible implicit declaration of built-in function âprintfâ
~> ./t
8
~>
-Andi