On Fri, Jan 05, 2018 at 05:47:39PM +0000, Joseph Myers wrote:
> On Fri, 5 Jan 2018, Jakub Jelinek wrote:
> 
> > On Thu, Jan 04, 2018 at 06:05:55PM -0500, Michael Meissner wrote:
> > > This patch is the beginning step to switching the PowerPC long double 
> > > support
> > > from IBM extended double to IEEE 128-bit floating point on PowerPC 
> > > servers.  It
> > > will be necessary to have this patch or a similar patch to allow the 
> > > GLIBC team
> > > to begin their modifications in GLIBC 2.28, so that by the time GCC 9 
> > > comes
> > > out, we can decide to switch the default.  It is likely, the default will 
> > > only
> > > be switched on the 64-bit little endian PowerPC systems, when a 
> > > distribution
> > > goes through a major level, such that they can contemplate major changes.
> > 
> > When you're mentioning multilibs, does that mean that we'll have two ABI
> > incompatible libgcc.so.* libraries, two ABI incompatible libstdc++.so.*
> > libraries etc.?  Just one or 2 libc.so.*/libm.so.*?
> 
> The existing GCC code tries to fix the libgcc function names so *tf* 
> always means IBM long double and *kf* always means IEEE long double.  As 
> noted in my reply to this patch, I suspect it might fail to handle 
> __div?c3, __mul?c3 and __powi?c2 (at least) properly to avoid two 
> different libgcc ABIs there.
> 
> I don't know the intent for libstdc++, libgfortran etc. - but it's been 
> stated the intent is a single set of glibc libraries.  (Of course a 
> distribution probably has other libraries influenced by the long double 
> format in some way.)

It would have been much simpler if we didn't already have a 128-bit floating
point type.  But we had the existing long double support.

In any case, even if you switch default long double format to IEEE, the kf/kc
functions in libgcc will be called, even though the type is now TFmode/TCmode.
It is unfortunate that the IBM extended double support did not define all of
the interfaces to be __gcc_q<xxx>, but there were some tf/tc functions defined
that are called, and I needed to pick unique names.

-- 
Michael Meissner, IBM
IBM, M/S 2506R, 550 King Street, Littleton, MA 01460-6245, USA
email: meiss...@linux.vnet.ibm.com, phone: +1 (978) 899-4797

Reply via email to