mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-01 00:33:09 +00:00
Run interprocedural const prop before global optimizer
Exposes more constant globals that can be removed by the global optimizer. A specific example is the removal of the static global block address array in clang/test/CodeGen/indirect-goto.c. This change impacts only lower optimization levels. With LTO interprocedural const prop runs already before global opt. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212284 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c029b2b785
commit
dfb53d227b
@ -156,9 +156,9 @@ void PassManagerBuilder::populateModulePassManager(PassManagerBase &MPM) {
|
||||
if (!DisableUnitAtATime) {
|
||||
addExtensionsToPM(EP_ModuleOptimizerEarly, MPM);
|
||||
|
||||
MPM.add(createIPSCCPPass()); // IP SCCP
|
||||
MPM.add(createGlobalOptimizerPass()); // Optimize out global vars
|
||||
|
||||
MPM.add(createIPSCCPPass()); // IP SCCP
|
||||
MPM.add(createDeadArgEliminationPass()); // Dead argument elimination
|
||||
|
||||
MPM.add(createInstructionCombiningPass());// Clean up after IPCP & DAE
|
||||
|
Loading…
Reference in New Issue
Block a user