On Thu, Dec 14, 2017 at 11:10:13PM -0500, Michael Meissner wrote: > I am working on some patches to optionally enable multilibs for the PowerPC > long double support to be switchable between IBM extended double and IEEE > 128-bit floating point. While the patches to actually enable the multlibs > need > some more tweaking, it did point up an issue in the libgcc _Float128 and IBM > extended double functions. > > These patches use the correct types for IBM extended double and __float128 if > the IEEE default is used. I have built the compiler with bootstrap builds and > there were no regressions in running the tests on a little endian power8 > system. > > In addition, I had fixed the previous changes to _divkc3.c and _mulkc3.c so > that these functions now include soft-fp.h and quad-float128.h, which provides > the appropriate prototypes. > > I have also done a bootstrap build with my preliminary multilib patches, and > it > built fine with both -mabi=ieeelongdouble and -mabi=ibmlongdouble > configurations. > > Can I apply these patches to libgcc?
As far as I can follow, it's okay for trunk. Please apply. Thanks, Segher > 2017-12-14 Michael Meissner <meiss...@linux.vnet.ibm.com> > > * config/rs6000/_divkc3.c: Switch to using soft-fp.h and > quad-float128.h include files and use the types that they define, > instead of hand-rolling the types. > * config/rs6000/_mulkc3.c: Likewise. > * config/rs6000/ibm-ldouble.c: If we have __float128/_Float128, > use __ieee128 for the IBM extended double type instead of long double. > Change all functions. > * config/rs6000/quad-float128.h (IBM128_TYPE): Always use > __ieee128. > (CVT_FLOAT128_TO_IBM128): Use long double instead of __float128 on > systems where the default long double is IEEE 128-bit floating > point. > * config/rs6000/extendkftf2-sw.c (extendkftf2_sw): Likewise. > * config/rs6000/trunctfkf2-sw.c (__trunctfkf2_sw): Likewise.