This is an archive of the discontinued LLVM Phabricator instance.

[PPC64] Add TLS local dynamic to local exec relaxation
ClosedPublic

Authored by syzaara on Jun 18 2018, 12:38 PM.

Diff Detail

Repository
rL LLVM

Event Timeline

syzaara created this revision.Jun 18 2018, 12:38 PM
syzaara updated this revision to Diff 152744.Jun 25 2018, 12:14 PM
ruiu added inline comments.Jun 25 2018, 10:38 PM
lld/ELF/Arch/PPC64.cpp
178–189 ↗(On Diff #152744)

I'm little confused by this part of the comment because these instructions are not really related to this function. Maybe just explaining the first four instructions is better?

198 ↗(On Diff #152744)

What is this?

200 ↗(On Diff #152744)

nit: you don't need {} after case if you don't define any variable inside it, as {} is added to introduce a new local variable scope.

225 ↗(On Diff #152744)

ditto

syzaara updated this revision to Diff 152939.Jun 26 2018, 12:15 PM
sfertile added inline comments.Jun 27 2018, 9:10 AM
lld/ELF/Arch/PPC64.cpp
185 ↗(On Diff #152939)

I think this comment should be // addis r3, r13, 0

lld/ELF/Relocations.cpp
210 ↗(On Diff #152939)

At this point haven't we already returned if the RelExpr is a R_TLSLD_HINT? (likewise for R_TLSLD_GOT_FROM_END and R_TLSLD_PC).

lld/ELF/Relocations.h
47 ↗(On Diff #152939)

This should be put in sorted order.

syzaara updated this revision to Diff 154123.Jul 4 2018, 8:56 AM
ruiu accepted this revision.Jul 5 2018, 11:34 AM

LGTM

This revision is now accepted and ready to land.Jul 5 2018, 11:34 AM
This revision was automatically updated to reflect the committed changes.