My recent patch to implement software floating point emulation for
long double 128 caused a build failure when not configured for 128 bit
long double type size. The emulation support requires TFmode, but GCC
does not appear to provide that without LNG_DUBLE_TYPE_SIZE 128, despite
FLAT_MDE TF defined in rs6000-modes.def.
This patch cloaks the new software emulation part of the
darwin-ldouble.c file if not compiled in long double 128 mode. I
considered always building the file with -mlong-double-128, but if the
rest of the compiler was not configured for long double 128 and configure
did not automatically detect support, this likely will lead to problems,
so better to nip it in the bud.
Bootstrapped tested on powerpc64-linux.
David
* build _SFT_FLAT if
configured for long double 128.
Index: darwin-ldouble.c
darwin-ldouble.c(revision 120845)
darwin-ldouble.c(working copy)
@@ -219,7 +219,7 @@
return z.ldval;
}
-#ifdef _SFT_FLAT
+#if defined (_SFT_FLAT) && defined (__LNG_DUBLE_128__)
long double __gcc_qneg (double, double);
int __gcc_qeq (double, double, double, double);