This is the mail archive of the gcc@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] |
Hello,some time ago IEEE 128-bit floating point support for PowerPC was added to GCC:
https://gcc.gnu.org/wiki/Ieee128PowerPCI noticed some issues for RTEMS in this area. Firstly, RTEMS had no __powerpc__ builtin define, so some source files were effectively disabled, e.g. ibm-ldouble.c. With __powerpc__ defined, the ibm-ldouble.c didn't compile due to:
In file included from /home/EB/sebastian_h/archive/gcc-git/libgcc/config/rs6000/ibm-ldouble.c:374:0: /home/EB/sebastian_h/archive/gcc-git/libgcc/soft-fp/quad.h:72:1: error: unable to emulate 'TF'
typedef float TFtype __attribute__ ((mode (TF))); ^~~~~~~ I added #define RS6000_DEFAULT_LONG_DOUBLE_SIZE 128 #undef TARGET_IEEEQUAD #define TARGET_IEEEQUAD 1This fixed the problem above and changes the long double type from 8 bytes to 16 bytes.
The new compiler defines now (powerpc-rtems target): #define __LONG_DOUBLE_128__ 1 #define __LONGDOUBLE128 1 #define __LONG_DOUBLE_IEEE128__ 1However, the libgcc multilib build fails due to several ICEs. See attached errors.log.
Is this supposed to work for 32-bit PowerPC. Did I miss some magic configuration switch?
-- Sebastian Huber, embedded brains GmbH Address : Dornierstr. 4, D-82178 Puchheim, Germany Phone : +49 89 189 47 41-16 Fax : +49 89 189 47 41-09 E-Mail : sebastian.huber@embedded-brains.de PGP : Public key available on request. Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
>From 23951fde45ff6b81afd2432866166b0f43401401 Mon Sep 17 00:00:00 2001 From: Sebastian Huber <sebastian.huber@embedded-brains.de> Date: Tue, 24 Jan 2017 11:20:22 +0100 Subject: [PATCH] Enable IEEE 754R 128-bit FP for powerpc-rtems --- gcc/config/rs6000/rtems.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gcc/config/rs6000/rtems.h b/gcc/config/rs6000/rtems.h index 54a36de..449de0f 100644 --- a/gcc/config/rs6000/rtems.h +++ b/gcc/config/rs6000/rtems.h @@ -25,6 +25,7 @@ do \ { \ builtin_define_std ("PPC"); \ + builtin_define_std ("powerpc"); \ builtin_define ("__rtems__"); \ builtin_define ("__USE_INIT_FINI__"); \ builtin_assert ("system=rtems"); \ @@ -58,3 +59,8 @@ #undef SUBSUBTARGET_EXTRA_SPECS #define SUBSUBTARGET_EXTRA_SPECS \ { "cpp_os_rtems", CPP_OS_RTEMS_SPEC } + +#define RS6000_DEFAULT_LONG_DOUBLE_SIZE 128 + +#undef TARGET_IEEEQUAD +#define TARGET_IEEEQUAD 1 -- 1.8.4.5
Attachment:
errors.log
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |