https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122331
Bug ID: 122331
Summary: gas/configure.ac HAVE_AS_IX86_GOT32X is partially
dubious
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: ro at gcc dot gnu.org
CC: hjl.tools at gmail dot com
Target Milestone: ---
Target: i?86-*-solaris2*
While working on a patch to unconditionally enforce yes
on Solaris 11.4/x86 (which is the first/only Solaris release to have relax
relocation support), I noticed that the HAVE_AS_IX86_GOT32X test produces 1
even though gas on Solaris/x86 effectively defaults to -mrelax-relocations=no
since the release of Solaris 11.4.
Part of the issue has been reported as binutils PR gas/33552, but there's more:
when looking at the objdump -dw output for the resulting conftest, I wonder
how that can ever contain 0xffffff.
The output in various configurations looks like this:
08050478 <_start>:
8050478: 83 3d 0c 00 00 00 00 cmpl $0x0,0xc
805047f: ff 25 10 00 00 00 jmp *0x10
Solaris, gld:
08048074 <_START_>:
8048074: 83 3d 90 90 04 08 00 e9 f4 ff ff ff 90
.=...........
Linux, gld:
08049000 <_start>:
8049000: 83 3d f0 af 04 08 00 cmpl $0x0,0x804aff0
8049007: e9 f4 ff ff ff jmp 8049000 <_start>
804900c: 90 nop
AFAICS there's no 0xffffff anywhere. It might be 'ff ff ff', but as is that
part of the test looks dubious.
The failure to properly disassemble conftest in the Solaris gas/gld case
looks like an objdump bug. I'll report that separately.