This is an archive of the discontinued LLVM Phabricator instance.

[ELF] - Remove dead TLS relocations relative code for MIPS and ARM
ClosedPublic

Authored by grimar on Apr 21 2017, 8:40 AM.

Details

Summary

Found that this code not used because of
handleARMTlsRelocation and handleMipsTlsRelocation methods that are called
for these platforms instead of regular TLS code.

So, it is dead code that we can remove I think, or do we need it for some reason ?

Diff Detail

Repository
rL LLVM

Event Timeline

grimar created this revision.Apr 21 2017, 8:40 AM
grimar edited the summary of this revision. (Show Details)Apr 21 2017, 8:44 AM

I don't have any objections to it being removed. It can be reintroduced if we need it later.

Perhaps the names of those functions are a bit general, for example should isTlsLocalDynamicRel() be isRelaxableTlsDynamicRel()?

atanasyan edited edge metadata.Apr 21 2017, 8:53 AM

I have no objections to removing these methods.

Perhaps the names of those functions are a bit general, for example should isTlsLocalDynamicRel() be isRelaxableTlsDynamicRel()?

I would keep the names. It seems that isRelaxableTlsDynamicRel is too generic probably.
TLS optimization spec defines explicitly the transitions between different models,
for example general dynamic model can be relaxed to initial exes or local exec, local dynamic to local exec, initial exec to local exec.
And our current code currently proccesses these models in a pretty obvious way using the current names.

Rui, are you ok with landing cleanup introduced in this patch ?

ruiu accepted this revision.Apr 26 2017, 6:27 AM

LGTM

This revision is now accepted and ready to land.Apr 26 2017, 6:27 AM
This revision was automatically updated to reflect the committed changes.