This is an archive of the discontinued LLVM Phabricator instance.

[lld] Rename R_TLSGD/R_TLSLD to R_TLSGD_FROM_END/R_TLSLD_FROM_END [NFC]
ClosedPublic

Authored by sfertile on May 25 2018, 10:49 AM.

Details

Summary

getRelocTargetVA for R_TLSGD and R_TLSLD RelExprs calculate an offset from the end of the got, so adjust the names to reflect this.

Diff Detail

Repository
rLLD LLVM Linker

Event Timeline

sfertile created this revision.May 25 2018, 10:49 AM
sfertile retitled this revision from [lld] Rename R_TLSGD/R_TLSLD to R_TLSGD_FROM_END/R_TLSLD_FROM_END to [lld] Rename R_TLSGD/R_TLSLD to R_TLSGD_FROM_END/R_TLSLD_FROM_END [NFC].May 25 2018, 10:49 AM
ruiu accepted this revision.May 25 2018, 11:03 AM

LGTM

This revision is now accepted and ready to land.May 25 2018, 11:03 AM
grimar added a subscriber: grimar.May 28 2018, 1:57 AM

New naming is confusing IMO. We had R_GOTONLY_PC_FROM_END, R_GOT_FROM_END and R_GOTREL_FROM_END.
Since names contains "GOT" it is clear that "FROM_END" says about the end of GOT.

But R_TLSGD_FROM_END is different made me think about the end of TLS first of all.

New naming is confusing IMO. We had R_GOTONLY_PC_FROM_END, R_GOT_FROM_END and R_GOTREL_FROM_END.
Since names contains "GOT" it is clear that "FROM_END" says about the end of GOT.

But R_TLSGD_FROM_END is different made me think about the end of TLS first of all.

Fair enough, would anybody object to R_TLSGD_GOT_FROM_END and R_TLSLD_GOT_FROM_END?

New naming is confusing IMO. We had R_GOTONLY_PC_FROM_END, R_GOT_FROM_END and R_GOTREL_FROM_END.
Since names contains "GOT" it is clear that "FROM_END" says about the end of GOT.

But R_TLSGD_FROM_END is different made me think about the end of TLS first of all.

Fair enough, would anybody object to R_TLSGD_GOT_FROM_END and R_TLSLD_GOT_FROM_END?

Sounds good to me. Let's see what Rui think.

ruiu added a comment.May 29 2018, 4:23 PM

Sounds good to me.

This revision was automatically updated to reflect the committed changes.