On Tue, Jun 5, 2018 at 12:05 AM, Michael Meissner <meiss...@linux.ibm.com> wrote: > On Mon, Jun 04, 2018 at 12:46:42PM -0500, Segher Boessenkool wrote: >> Hi Mike, >> >> On Fri, Jun 01, 2018 at 07:28:40PM -0400, Michael Meissner wrote: >> > This patch also makes __ibm128 or __float128 use the long double mode if >> > long >> > double uses the IBM extended double or IEEE 128-bit representations. >> >> Does that need to be the same patch? Please split such things out when >> you can. > > Well it can be split, but it will then have the test failure still. > >> > This >> > allows templates to work again with those types (the template code aborts >> > if >> > you have two distinct types use the same mangling). However, overloaded >> > types >> > won't work, but I suspect these days people use templates over overloaded >> > functions. I fixed up the test case for this (pr85657.C) so that it only >> > tests >> > for templates. >> >> If tests fail, do not delete the test. If we have a problem, we have >> a problem, and it needs to be fixed (not necessarily today of course, >> and there is xfail for long-standing problems). > > This is a fundamental detail of the current changes. There is no way it can > be > 'fixed'. > > If __float128/__ibm128 each use the long double type internally when long > double uses that representation, then you cannot have overloaded functions > that > use the two types. > > I.e. > > class foo { > // ... > long double arith (long double); > __float128 arith (__float128); > __ibm128 arith (__ibm128); > } > > In the previous changes that the test was written for, we had 3 types within > the compiler. We had a __float128 type, we had a long double type, and we had > an __ibm128 type. We had different manglings for each of the different types. > > Now that we only have two types, you can't have explicit overloading of the > same type. You can have templates, because only one version of the template > is > created for the two types.
I thought that the two long double types would be __ibm128 and __ieee128, and __float128 would be a third type, to satisfy the _Float128 requirement that it be distinct from long double. Or are you thinking that _Float128 will be different from __float128? >> The test currently ICEs. That needs to be fixed. > Well that is a C++ front end bug. What's the bug? Jason