[PATCH] D18346: ThinLTO: special handling for LinkOnce functions

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 30 12:25:54 PDT 2016


tejohnson added a comment.

In http://reviews.llvm.org/D18346#386449, @joker.eph wrote:

> I'm surprised you want to use this from the gold plugin, the linker already did the resolution for you. Here I'm using the summary because we don't have an API to interact with the inker.


Right, I forgot about the fact that when the backend threads are launched through the gold plugin that it will already make it weak. Gold isn't marking the others available externally, but that should be a simple change.

Where I will want to do something like this is in the distributed build case, where we don't go through the symbol resolution in gold. However, there I will need to mark the change in the combined index and have the backend actually change the symbol linkage based on what is in the index. In that case I would need to refactor this anyway since we don't have an actual GlobalValue, just the summary entries. I can do that myself when I am ready to leverage it.


http://reviews.llvm.org/D18346





More information about the llvm-commits mailing list