diff options
author | Vlad Tsyrklevich <vlad@tsyrklevich.net> | 2018-04-26 17:33:24 +0000 |
---|---|---|
committer | Vlad Tsyrklevich <vlad@tsyrklevich.net> | 2018-04-26 17:33:24 +0000 |
commit | 42c5a9c29a846a82ddb192e3668e3c6bfbe5ba6b (patch) | |
tree | 6baa7e16b1b968234c9bc1e2f5ae84537c1a41c6 /llvm/lib/Transforms | |
parent | 06cb7c877316ad3ed8fdb5b42ea72436192fae31 (diff) | |
download | bcm5719-llvm-42c5a9c29a846a82ddb192e3668e3c6bfbe5ba6b.tar.gz bcm5719-llvm-42c5a9c29a846a82ddb192e3668e3c6bfbe5ba6b.zip |
Enable EliminateAvailableExternally pass for -O1
Summary:
Follow-up to D43690, the EliminateAvailableExternally pass currently
runs under -O0 and -O2 and up. Under -O1 we would still want to drop
available_externally symbols to reduce space without inlining having
run.
Reviewers: tejohnson
Reviewed By: tejohnson
Subscribers: mehdi_amini, llvm-commits, kcc
Differential Revision: https://reviews.llvm.org/D46093
llvm-svn: 330961
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r-- | llvm/lib/Transforms/IPO/PassManagerBuilder.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp b/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp index 997ae616114..f3bcb157552 100644 --- a/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp +++ b/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp @@ -523,7 +523,7 @@ void PassManagerBuilder::populateModulePassManager( if (RunPartialInlining) MPM.add(createPartialInliningPass()); - if (OptLevel > 1 && !PrepareForLTO && !PrepareForThinLTO) + if (!PrepareForLTO && !PrepareForThinLTO) // Remove avail extern fns and globals definitions if we aren't // compiling an object file for later LTO. For LTO we want to preserve // these so they are eligible for inlining at link-time. Note if they |