Many of the new gcc.target/i386/indirect-thunk*.c tests FAIL on Solaris/x86 (both 32 and 64-bit): +FAIL: gcc.target/i386/indirect-thunk-1.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-2.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-3.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-4.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-7.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-attr-1.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-attr-2.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-attr-5.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-attr-6.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-attr-7.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-bnd-1.c scan-assembler bnd jmp[ \\t]*__x86_indirect_thunk_bnd +FAIL: gcc.target/i386/indirect-thunk-bnd-2.c scan-assembler bnd jmp[ \\t]*__x86_indirect_thunk_bnd +FAIL: gcc.target/i386/indirect-thunk-extern-1.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-extern-2.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-extern-3.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-extern-4.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-extern-7.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/indirect-thunk-register-1.c scan-assembler jmp[ \\t]*__x86_indirect_thunk_(r|e)ax +FAIL: gcc.target/i386/indirect-thunk-register-3.c scan-assembler jmp[ \\t]*__x86_indirect_thunk_(r|e)ax +FAIL: gcc.target/i386/ret-thunk-1.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-10.c scan-assembler __x86_indirect_thunk: +FAIL: gcc.target/i386/ret-thunk-10.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/ret-thunk-11.c scan-assembler __x86_indirect_thunk: +FAIL: gcc.target/i386/ret-thunk-11.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/ret-thunk-11.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-12.c scan-assembler __x86_indirect_thunk: +FAIL: gcc.target/i386/ret-thunk-12.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/ret-thunk-13.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-14.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/ret-thunk-15.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/ret-thunk-15.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-3.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-5.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-7.c scan-assembler jmp[ \\t]*__x86_return_thunk +FAIL: gcc.target/i386/ret-thunk-9.c scan-assembler __x86_indirect_thunk: +FAIL: gcc.target/i386/ret-thunk-9.c scan-assembler jmp[ \\t]*__x86_indirect_thunk +FAIL: gcc.target/i386/ret-thunk-9.c scan-assembler jmp[ \\t]*__x86_return_thunk I'm adding gcc.target/i386/indirect-thunk-1.c assembler output as an example. Rainer
Created attachment 43123 [details] i386-pc-solaris2.11 -m32 assembler output
Solaris fails these tests due to sol2.h:#define USE_HIDDEN_LINKONCE 0 We can limit these tests to Linux only.
There are /* Only recent versions of Solaris 11 ld properly support hidden .gnu.linkonce sections, so don't use them. */ #ifndef USE_GLD #define USE_HIDDEN_LINKONCE 0 #endif But GCC generates comdat: .section .text.__x86_indirect_thunk,"axG",@progbits,__x86_indirec t_thunk,comdat .globl __x86_indirect_thunk .hidden __x86_indirect_thunk .type __x86_indirect_thunk, @function Does Solaris ld support comdat?
> --- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> --- > There are > > /* Only recent versions of Solaris 11 ld properly support hidden .gnu.linkonce > sections, so don't use them. */ > #ifndef USE_GLD > #define USE_HIDDEN_LINKONCE 0 > #endif If I can figure out when full support for .gnu.linkonce started in Solaris ld, I can make this dynamic in configure.ac ... > But GCC generates comdat: > > .section > .text.__x86_indirect_thunk,"axG",@progbits,__x86_indirec > t_thunk,comdat > .globl __x86_indirect_thunk > .hidden __x86_indirect_thunk > .type __x86_indirect_thunk, @function > > Does Solaris ld support comdat? ... like this one: complete Solaris ld support for comdat started sometime in the Solaris 11 timeframe, cf. configure.ac (comdat_group). Solaris 10 did not (at least not in a way that could cope with everything gcc might generate). Rainer
(In reply to ro@CeBiTec.Uni-Bielefeld.DE from comment #4) > > --- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> --- > > There are > > > > /* Only recent versions of Solaris 11 ld properly support hidden .gnu.linkonce > > sections, so don't use them. */ > > #ifndef USE_GLD > > #define USE_HIDDEN_LINKONCE 0 > > #endif > > If I can figure out when full support for .gnu.linkonce started in > Solaris ld, I can make this dynamic in configure.ac ... > > > But GCC generates comdat: > > > > .section > > .text.__x86_indirect_thunk,"axG",@progbits,__x86_indirec > > t_thunk,comdat > > .globl __x86_indirect_thunk > > .hidden __x86_indirect_thunk > > .type __x86_indirect_thunk, @function > > > > Does Solaris ld support comdat? > > ... like this one: complete Solaris ld support for comdat started > sometime in the Solaris 11 timeframe, cf. configure.ac (comdat_group). > Solaris 10 did not (at least not in a way that could cope with > everything gcc might generate). > G++ uses comdat extensively. Without comdat, g++ generates very odd codes. Please double check if libstdc++ object files on Solaris have any comdat sections.
> --- Comment #5 from H.J. Lu <hjl.tools at gmail dot com> --- [...] >> > Does Solaris ld support comdat? >> >> ... like this one: complete Solaris ld support for comdat started >> sometime in the Solaris 11 timeframe, cf. configure.ac (comdat_group). >> Solaris 10 did not (at least not in a way that could cope with >> everything gcc might generate). > > G++ uses comdat extensively. Without comdat, g++ generates very > odd codes. Please double check if libstdc++ object files on Solaris > have any comdat sections. It's exactly as I said: sol10 $ readelf -g i386-pc-solaris2.10/libstdc++-v3/src/.libs/libstdc++.a File: i386-pc-solaris2.10/libstdc++-v3/src/.libs/libstdc++.a(compatibility.o) There are no section groups in this file. [... and so on for every object] sol11 $ elfdump -g i386-pc-solaris2.11/libstdc++-v3/src/.libs/libstdc++.a i386-pc-solaris2.11/libstdc++-v3/src/.libs/libstdc++.a(compatibility.o): Group Section: .group%DW.ref._ZTIN10__cxxabiv115__forced_unwindE Signature Symbol: DW.ref._ZTIN10__cxxabiv115__forced_unwindE Members: index flags / section [0] [ COMDAT ] [1] .data.DW.ref._ZTIN10__cxxabiv115__forced_unwindE%DW.ref._ZTIN10__cxxabiv115__forced_unwindE [2] .rel.data.DW.ref._ZTIN10__cxxabiv115__forced_unwindE%DW.ref._ZTIN10__cxxabiv115__forced_unwindE [...] Even without comdat support, C++ testresults on Solaris 10 are as good as on Solaris 11. Rainer
In the meantime, I've enabled HIDDEN_LINKONCE on Solaris 11/x86. However, this (and COMDAT support) isn't possible on Solaris 10/x86 or is out of scope for GCC 8. So the ton of failures remains on Solaris 10/x86.
GCC 8.1 has been released.
GCC 8.2 has been released.
GCC 8.3 has been released.
GCC 8.4.0 has been released, adjusting target milestone.