This is an archive of the discontinued LLVM Phabricator instance.

[lld-macho] Don't emit rebase opcodes for relocs in TLV sections
ClosedPublic

Authored by int3 on Dec 14 2020, 4:06 PM.

Details

Summary

Their addresses are already encoded as section-relative offsets, so
there's no need to rebase them at runtime. D85080: [lld-macho] Support static linking of thread-locals has some context
on the weirdness of TLV sections.

Fixes llvm.org/PR48491.

Diff Detail

Event Timeline

int3 requested review of this revision.Dec 14 2020, 4:06 PM
int3 created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptDec 14 2020, 4:06 PM
int3 edited the summary of this revision. (Show Details)Dec 14 2020, 4:07 PM
This revision is now accepted and ready to land.Dec 14 2020, 5:02 PM
int3 added a comment.Dec 14 2020, 5:23 PM

Looks like it, yup

int3 updated this revision to Diff 311774.Dec 14 2020, 7:42 PM

don't forget to emit binding for __tlv_bootstrap

This revision was landed with ongoing or failed builds.Dec 15 2020, 1:00 PM
This revision was automatically updated to reflect the committed changes.