[PATCH] D24004: [ThinLTO] Indirect call promotion fixes for promoted local functions

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 29 14:11:28 PDT 2016


tejohnson created this revision.
tejohnson added reviewers: davidxl, mehdi_amini.
tejohnson added subscribers: llvm-commits, Prazek.
Herald added a subscriber: mehdi_amini.

Fix a couple issues limiting the application of indirect call promotion
in ThinLTO mode:
- Invoke indirect call promotion before globalopt, since it may
  eliminate imported functions which appear unreferenced.
- Invoke indirect call promotion with InLTO=true so that the PGOFuncName
  metadata is used to get the name for locals which would have been
  renamed during promotion.

https://reviews.llvm.org/D24004

Files:
  lib/ProfileData/InstrProf.cpp
  lib/Transforms/IPO/PassManagerBuilder.cpp
  test/Transforms/PGOProfile/Inputs/thinlto_indirect_call_promotion.ll
  test/Transforms/PGOProfile/thinlto_indirect_call_promotion.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D24004.69615.patch
Type: text/x-patch
Size: 5248 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160829/8c469708/attachment.bin>


More information about the llvm-commits mailing list