]> granicus.if.org Git - llvm/commit
[AMDGPU] Internalize non-kernel symbols
authorStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Mon, 30 Jan 2017 21:05:18 +0000 (21:05 +0000)
committerStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Mon, 30 Jan 2017 21:05:18 +0000 (21:05 +0000)
commitaef8c41869c205bb23509f216e196fa3a15d3d07
tree1a3acea0a706005a3df7b1f60abd26639e28931d
parentf20c973bf81e953c2f29f007c77fb1b488907542
[AMDGPU] Internalize non-kernel symbols

Since we have no call support and late linking we can produce code
only for used symbols. This saves compilation time, size of the final
executable, and size of any intermediate dumps.

Run Internalize pass early in the opt pipeline followed by global
DCE pass. To enable it RT can pass -amdgpu-internalize-symbols option.

Differential Revision: https://reviews.llvm.org/D29214

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@293549 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
test/CodeGen/AMDGPU/internalize.ll [new file with mode: 0644]