[llvm-dev] [RFC][LLVM] New Constant type for representing function PLT entries

Renato Golin via llvm-dev llvm-dev at lists.llvm.org
Fri Aug 21 09:12:21 PDT 2020


On Fri, 21 Aug 2020 at 16:49, Hal Finkel <hfinkel at anl.gov> wrote:

> But it's not a property of the functions, as I understand it, it's a
> function of place where the function is referenced. In this case, maybe we
> could consider it a property of the vtable itself, and some attribute on
> the array/global would work?
>
I see.

This is a first-class IR entity. It seems the opposite of fragile.
>
I didn't mean passes could remove them, like metadata. I mean the front-end
will have to assume all entries point to actual functions that don't get
deleted half-way through (LTO? global analysis?), meaning the PLT entry
will have to be taught to some optimisations anyway.


> The interesting question is going to be: do we have a wile bunch of other
> code that generally handles constant expressions that needs to learn about
> this new kind of function reference?
>
Indeed.

>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20200821/b5bfff61/attachment.html>


More information about the llvm-dev mailing list