[PATCH] D45642: [PPC64] V2 abi: Add glink section for lazy symbol resolution.

Rafael Avila de Espindola via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 16 19:23:41 PDT 2018


espindola added a comment.

In https://reviews.llvm.org/D45642#1069073, @sfertile wrote:

> In https://reviews.llvm.org/D45642#1068980, @espindola wrote:
>
> > This is a plt by another name, no?
> >
> > Do you know why it is defined to have  another name?
>
>
> I'm not sure what you mean by 'plt' here. In this abi the `.plt` section is just the array of addresses of external functions that the dynamic linker fills out at runtime.  The `.glink` section holds the lazy resolution stubs which will setup the environment for the dynamic linker to do so. Then there are also stubs for calling the external functions by loading their address out of the `.plt`. Am I right to assume by 'plt' you mean a combination of lazy resolver and the call stub?


The question is why there is such a difference of terminology. At least of x86_64/x86/aarch64 the the array of addresses is the .got.plt section and the .plt section is what has the stubs. Just like .glink it has a special first entry. That is:

pp64 v2     |     others
.glink          |    .plt
.plt             |    .got.plt


Repository:
  rLLD LLVM Linker

https://reviews.llvm.org/D45642





More information about the llvm-commits mailing list