Re: [power-ieee128] RFH: LTO broken

2022-01-07 Thread Thomas Koenig via Fortran
Hi Jakub, So, the following patch adds -fbuilding-libgfortran option and uses it together with TARGET_GLIBC_M* checks to decide whether to use libquadmath APIs (for the IEEE quad kind=16 if -fbuilding-libgfortran and not glibc or glibc is older than 2.32) or glibc 2.32 APIs (otherwise). This

Re: [power-ieee128] RFH: LTO broken

2022-01-07 Thread Jakub Jelinek via Fortran
On Fri, Jan 07, 2022 at 03:25:57PM +0100, Thomas Koenig wrote: > > > 00251038 06ad0015 R_PPC64_JMP_SLOT > > > __cabsieee128 + 0 > > > All these should for POWER_IEEE128 use atan2q@QUADMATH_1.0 etc. > > > > So, seems all these come from f951 compiled sources

Re: [power-ieee128] RFH: LTO broken

2022-01-07 Thread Thomas Koenig via Fortran
Hi Jakub, 00251038 06ad0015 R_PPC64_JMP_SLOT __cabsieee128 + 0 All these should for POWER_IEEE128 use atan2q@QUADMATH_1.0 etc. So, seems all these come from f951 compiled sources. For user code, I think the agreement was if you want to use successfull

Re: [power-ieee128] RFH: LTO broken

2022-01-07 Thread Jakub Jelinek via Fortran
On Fri, Jan 07, 2022 at 12:29:25PM +0100, Jakub Jelinek wrote: > we don't do it consistently: > readelf -Wr > /home/jakub/gcc/obj38/powerpc64le-unknown-linux-gnu/libgfortran/.libs/libgfortran.so.5.0.0 > | grep ieee128 > 00250310 01280015 R_PPC64_JMP_SLOT >

Re: [power-ieee128] RFH: LTO broken

2022-01-07 Thread Jakub Jelinek via Fortran
On Thu, Jan 06, 2022 at 09:01:54PM +0100, Thomas Koenig wrote: > > On 06.01.22 06:00, Michael Meissner via Fortran wrote: > > I pushed the patch to the branch. > > Test results are looking quite good right now. I've just tried to build libgfortran on an old glibc system (gcc112.fsffrance.org) an

Re: [power-ieee128] RFH: LTO broken

2022-01-06 Thread Jakub Jelinek via Fortran
On Thu, Jan 06, 2022 at 09:01:54PM +0100, Thomas Koenig wrote: > On 06.01.22 06:00, Michael Meissner via Fortran wrote: > > I pushed the patch to the branch. > > Test results are looking quite good right now. > > What is still missing is the conversion for unformatted I/O, both > ways. I'll star

Re: [power-ieee128] RFH: LTO broken

2022-01-06 Thread Thomas Koenig via Fortran
On 06.01.22 06:00, Michael Meissner via Fortran wrote: I pushed the patch to the branch. Test results are looking quite good right now. What is still missing is the conversion for unformatted I/O, both ways. I'll start doing some stuff on it. Just one question: What are functions that I can

Re: [power-ieee128] RFH: LTO broken

2022-01-05 Thread Michael Meissner via Fortran
On Tue, Jan 04, 2022 at 12:07:49PM +0100, Jakub Jelinek wrote: > On Mon, Jan 03, 2022 at 11:43:57PM +0100, Thomas Koenig wrote: > > > clearly there is still work to fix (but seems e.g. most of the lto tests > > > are related to the gnu attributes stuff:( ). > > > > This is looking better than wha

Re: [power-ieee128] RFH: LTO broken

2022-01-05 Thread Michael Meissner via Fortran
On Tue, Jan 04, 2022 at 12:07:49PM +0100, Jakub Jelinek wrote: > On Mon, Jan 03, 2022 at 11:43:57PM +0100, Thomas Koenig wrote: > > > clearly there is still work to fix (but seems e.g. most of the lto tests > > > are related to the gnu attributes stuff:( ). > > > > This is looking better than wha

Re: [power-ieee128] RFH: LTO broken

2022-01-05 Thread Michael Meissner via Fortran
On Tue, Jan 04, 2022 at 12:07:49PM +0100, Jakub Jelinek wrote: > On Mon, Jan 03, 2022 at 11:43:57PM +0100, Thomas Koenig wrote: > > > clearly there is still work to fix (but seems e.g. most of the lto tests > > > are related to the gnu attributes stuff:( ). > > > > This is looking better than wha

[power-ieee128] RFH: LTO broken

2022-01-04 Thread Jakub Jelinek via Fortran
On Mon, Jan 03, 2022 at 11:43:57PM +0100, Thomas Koenig wrote: > > clearly there is still work to fix (but seems e.g. most of the lto tests > > are related to the gnu attributes stuff:( ). > > This is looking better than what I expected. Apart from LTO, I expect I've just verified that LTO is b