This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Add __ILP32 and __ILP32__ for X32 programming model
- From: "H. Peter Anvin" <hpa at zytor dot com>
- To: x32-abi at googlegroups dot com
- Cc: "H.J. Lu" <hjl dot tools at gmail dot com>, GCC Development <gcc at gcc dot gnu dot org>, GNU C Library <libc-alpha at sourceware dot org>
- Date: Fri, 13 Apr 2012 09:40:25 -0700
- Subject: Re: Add __ILP32 and __ILP32__ for X32 programming model
- References: <CAMe9rOpjGH06eUguf6fT54GQbeaVC7NUj4MZN+qEM45p17DNQg@mail.gmail.com>
On 04/13/2012 09:18 AM, H.J. Lu wrote:
> Hi,
>
> We need a reliable way to tell if we are compiling for x32 through
> pre-defined preprocessor symbol. __LP64/__LP64__ aren't
> specified by x86-64 psABI, although they have been added to
> GCC 3.3. They can't be counted on to detect x32 since not x86-64
> compilers define them. I updated x32 psABI:
>
> https://sites.google.com/site/x32abi/documents
>
> to define __ILP32 and __ILP32__ for X32 programming model. I
> will submit a patch for GCC trunk and 4.7 branch.
>
Can we add __LP64__ to the psABI too?
-hpa