Bugs in s12z test suite.

Alan Modra amodra@gmail.com
Sun Sep 2 12:57:00 GMT 2018


On Sun, Sep 02, 2018 at 09:22:08AM +0200, John Darrington wrote:
> Running objdump -Wi on tmpdir/dw2-1-compressed.o
[snip]
> Using gdb to investigate it seems that objdump is calling apply_reloc on
> these values.   This is wrong isn't it?

Nope.

> What is happening is that the datum is read (it's value is say 0x4) and
> the reloc is applied (the addend is 0x4) so the result 0x8 and in general
> many (all) of these test failures result from the value being double what
> the test expects.
> 
> Why is the reloc being applied by objdump?  The value was relocated when
> the  file was written.  It's not apppropriate for it to be relocated again.
> Or have I missed something?

Your reloc howtos look broken to me.  Your target uses rela relocs,
yet the howtos have non-zero src_mask.  Rela targets normally ignore
the section contents when applying relocations.

-- 
Alan Modra
Australia Development Lab, IBM



More information about the Binutils mailing list