[PATCH] D20290: [ThinLTO] Refactor ODR resolution and internalization (NFC)

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Mon May 16 10:09:52 PDT 2016


tejohnson created this revision.
tejohnson added a reviewer: joker-eph.
tejohnson added subscribers: llvm-commits, pcc.
Herald added a subscriber: joker.eph.

This patch refactors the ODR resolution and internalization out of
libLTO's ThinLTOCodeGenerator so that it can be used by other linkers
(gold and lld) and by ThinLTO distributed backends.

In the process, the implementation is changed so that it is based on
updates to the Index, which are consumed by the backend portion of the
transformations. The pieces that perform the global summary-based
analysis are moved to a new LTO.cpp (eventually to be merged with
D20268), and the pieces that update the Module based on the index are
moved to lib/Transforms/IPO/FunctionImport.cpp so that they can be
accessed from distributed backends as well.

The global summary-based portions use callbacks so that the client can
determine the prevailing copy and other information in a client-specific
way. Eventually, with the API being developed in D20268, these may be
modified to use information such as symbol resolutions, supplied by the
clients to the API.

http://reviews.llvm.org/D20290

Files:
  include/llvm/IR/ModuleSummaryIndex.h
  include/llvm/LTO/LTO.h
  include/llvm/Transforms/IPO/FunctionImport.h
  lib/LTO/CMakeLists.txt
  lib/LTO/LTO.cpp
  lib/LTO/ThinLTOCodeGenerator.cpp
  lib/Transforms/IPO/FunctionImport.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D20290.57365.patch
Type: text/x-patch
Size: 33491 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160516/f2e03521/attachment.bin>


More information about the llvm-commits mailing list