[lld] r280630 - [ELF][MIPS] Do not emit DT_REL[A]COUNT for MIPS targets

Simon Atanasyan via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 7 01:46:20 PDT 2016


Yes, the comment is not clear.

When LLD emits DT_RELCOUNT, MIPS binaries just crashed. If gold/bfd
emitted this tag, this result definitely points to the bug in the LLD
MIPS backend. But both GNU linkers either disable combreloc at all
(bfd) or do not emit DT_RELCOUNT (gold). So maybe the problem is in
the dynamic loader which tries to handle DT_RELCOUNT but this code has
never been tested on MIPS.

I need a time to investigate the problem. After that I will fix the
code or update the comment.

Simon

On Tue, Sep 6, 2016 at 7:18 PM, Rafael EspĂ­ndola
<rafael.espindola at gmail.com> wrote:
> "does not support" sounds like it would just ignore the tag, which is
> fine. Do you mean that it refuses to load DSOs with the tag present?
>
> Cheers,
> Rafael
>
>
> On 4 September 2016 at 13:40, Simon Atanasyan via llvm-commits
> <llvm-commits at lists.llvm.org> wrote:
>> Author: atanasyan
>> Date: Sun Sep  4 12:40:12 2016
>> New Revision: 280630
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=280630&view=rev
>> Log:
>> [ELF][MIPS] Do not emit DT_REL[A]COUNT for MIPS targets
>>
>> It looks like MIPS dynamic loader does not support RELCOUNT tag.
>> Both gold/bfd linkers does not emit this tag on MIPS. I will investigate
>> the problem further but for now it is better to behave like GNU linkers.


More information about the llvm-commits mailing list