This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Default to 64-bit long double for Bionic/x86


On Wed, Aug 22, 2012 at 4:41 PM, H.J. Lu <hongjiu.lu@intel.com> wrote:

> Long double is the same as double in Bionic.  This patch
>
> 1. Add -mlong-double-80:
>         80-bit long double
>         Enabled for Linux by default.
> 2. Add -mlong-double-64:
>         64-bit long double
>         Predefine a new C/C++ macro, __LONG_DOUBLE_64__.
>         Enabled for Android by default.
>
> __float80 can still be used for 80-bit long double.  Tested on Linux/x86
> and Android/x86.  OK to install?
>
> 2012-08-22  H.J. Lu  <hongjiu.lu@intel.com>
>
>         * doc/invoke.texi: Document -mlong-double-64/-mlong-double-80.
>
>         * config/i386/i386.c (flag_opts): Add -mlong-double-64.
>         (TARGET_HAS_BIONIC): Default long double to 64-bit for Bionic.
>
>         * config/i386/i386.h (LONG_DOUBLE_TYPE_SIZE): Use 64 if
>         TARGET_LONG_DOUBLE_64 is true.
>         (LIBGCC2_LONG_DOUBLE_TYPE_SIZE): New macro.
>         (WIDEST_HARDWARE_FP_SIZE): Defined to 80.
>
>         * config/i386/i386.opt (mlong-double-80): New option.
>         (mlong-double-64): Likewise.
>
>         * config/i386/i386-c.c (ix86_target_macros): Define
>         __LONG_DOUBLE_64__ for TARGET_LONG_DOUBLE_64.
>
> gcc/testsuite/
>
> 2012-08-22  H.J. Lu  <hongjiu.lu@intel.com>
>
>         * gcc.target/i386/long-double-64-1.c: New file.
>         * gcc.target/i386/long-double-64-2.c: Likewise.
>         * gcc.target/i386/long-double-64-3.c: Likewise.
>         * gcc.target/i386/long-double-64-4.c: Likewise.
>         * gcc.target/i386/long-double-80-1.c: Likewise.
>         * gcc.target/i386/long-double-80-2.c: Likewise.
>         * gcc.target/i386/long-double-80-3.c: Likewise.
>         * gcc.target/i386/long-double-80-4.c: Likewise.
>         * gcc.target/i386/long-double-80-5.c: Likewise.
>         * gcc.target/i386/long-double-80-6.c: Likewise.
>         * gcc.target/i386/long-double-80-7.c: Likewise.
>
> libgcc/
>
> 2012-08-22  H.J. Lu  <hongjiu.lu@intel.com>
>
>         * config/i386/t-linux (HOST_LIBGCC2_CFLAGS): New.

OK.

Thanks,
Uros.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]