This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: Prefer object over notype symbols when disassembling
- From: Alan Modra <amodra at gmail dot com>
- To: "Maciej W. Rozycki" <macro at linux-mips dot org>
- Cc: Borislav Petkov <bp at suse dot de>, binutils at sourceware dot org, Michael Matz <matz at suse dot de>
- Date: Tue, 7 Jan 2020 08:53:43 +1030
- Subject: Re: Prefer object over notype symbols when disassembling
- References: <20191211160613.28935-1-bp@suse.de> <20191212053735.GU32672@bubble.grove.modra.org> <20191215174854.GB2947@zn.tnic> <20191216055923.GD32672@bubble.grove.modra.org> <20191216161424.GC17408@zn.tnic> <20191217101559.GR32672@bubble.grove.modra.org> <alpine.LFD.2.21.2001061404440.3762799@eddie.linux-mips.org>
On Mon, Jan 06, 2020 at 02:11:23PM +0000, Maciej W. Rozycki wrote:
> On Tue, 17 Dec 2019, Alan Modra wrote:
>
> > diff --git a/ld/testsuite/ld-mips-elf/eh-frame5.s b/ld/testsuite/ld-mips-elf/eh-frame5.s
> > index 741a021685..cf5a11c37a 100644
> > --- a/ld/testsuite/ld-mips-elf/eh-frame5.s
> > +++ b/ld/testsuite/ld-mips-elf/eh-frame5.s
> > @@ -2,6 +2,7 @@
> > .cfi_personality 0x0,local_pers
> > .cfi_lsda 0x0,LSDA
> > .ent f1
> > + .type f1, @function
> > f1:
> > nop
> > .end f1
>
> If this and similar changes throughout are required, then we have a bug
> somewhere, probably in GAS, because `.ent' is supposed to set STT_FUNCTION
> for the symbol named, making a `.type' pseudo-op to do the same redundant.
> Cf. `s_mips_ent' and:
>
> symbol_get_bfdsym (symbolP)->flags |= BSF_FUNCTION;
>
> I'd rather keep the old arrangement in the test suite to provide coverage
> for this semantics.
I'll admit to going wild and adding .type @function in lots of places
after finding it was needed for some mips tests on mips-sgi-irix. It
looks like the following files should have my change reverted. I'll
test and commit.
ld/testsuite/ld-mips-elf/eh-frame5.s
ld/testsuite/ld-mips-elf/ehdr_start-new.s
ld/testsuite/ld-mips-elf/ehdr_start-o32.s
ld/testsuite/ld-mips-elf/mips16-call-global-1.s
ld/testsuite/ld-mips-elf/mips16-intermix-1.s
ld/testsuite/ld-mips-elf/mips16-pic-1b.s
ld/testsuite/ld-mips-elf/mips16-pic-4c.s
ld/testsuite/ld-mips-elf/no-shared-1-n64.s
ld/testsuite/ld-mips-elf/no-shared-1-o32.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-1b-micromips.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-1b.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-2a.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-3b.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-4b.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-5a.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n32c.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n64c.s
ld/testsuite/ld-mips-elf/pic-and-nonpic-6-o32c.s
ld/testsuite/ld-mips-elf/pie.s
ld/testsuite/ld-mips-elf/relax-jalr.s
--
Alan Modra
Australia Development Lab, IBM