Skip to content

Commit

Permalink
Remove the EnableEarlyCSEMemSSA set of options from the legacy
Browse files Browse the repository at this point in the history
and new pass managers. They were default to true and not being
used.

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

llvm-svn: 358789
  • Loading branch information
echristo committed Apr 19, 2019
1 parent 1810339 commit dfebd84
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
6 changes: 1 addition & 5 deletions llvm/lib/Passes/PassBuilder.cpp
Expand Up @@ -185,10 +185,6 @@ static cl::opt<bool>
cl::Hidden, cl::ZeroOrMore,
cl::desc("Run NewGVN instead of GVN"));

static cl::opt<bool> EnableEarlyCSEMemSSA(
"enable-npm-earlycse-memssa", cl::init(true), cl::Hidden,
cl::desc("Enable the EarlyCSE w/ MemorySSA pass for the new PM (default = on)"));

static cl::opt<bool> EnableGVNHoist(
"enable-npm-gvn-hoist", cl::init(false), cl::Hidden,
cl::desc("Enable the GVN hoisting pass for the new PM (default = off)"));
Expand Down Expand Up @@ -387,7 +383,7 @@ PassBuilder::buildFunctionSimplificationPipeline(OptimizationLevel Level,
FPM.addPass(SROA());

// Catch trivial redundancies
FPM.addPass(EarlyCSEPass(EnableEarlyCSEMemSSA));
FPM.addPass(EarlyCSEPass(true /* Enable mem-ssa. */));

// Hoisting of scalars and load expressions.
if (EnableGVNHoist)
Expand Down
6 changes: 1 addition & 5 deletions llvm/lib/Transforms/IPO/PassManagerBuilder.cpp
Expand Up @@ -115,10 +115,6 @@ static cl::opt<int> PreInlineThreshold(
cl::desc("Control the amount of inlining in pre-instrumentation inliner "
"(default = 75)"));

static cl::opt<bool> EnableEarlyCSEMemSSA(
"enable-earlycse-memssa", cl::init(true), cl::Hidden,
cl::desc("Enable the EarlyCSE w/ MemorySSA pass (default = on)"));

static cl::opt<bool> EnableGVNHoist(
"enable-gvn-hoist", cl::init(false), cl::Hidden,
cl::desc("Enable the GVN hoisting pass (default = off)"));
Expand Down Expand Up @@ -334,7 +330,7 @@ void PassManagerBuilder::addFunctionSimplificationPasses(
// Start of function pass.
// Break up aggregate allocas, using SSAUpdater.
MPM.add(createSROAPass());
MPM.add(createEarlyCSEPass(EnableEarlyCSEMemSSA)); // Catch trivial redundancies
MPM.add(createEarlyCSEPass(true /* Enable mem-ssa. */)); // Catch trivial redundancies
if (EnableGVNHoist)
MPM.add(createGVNHoistPass());
if (EnableGVNSink) {
Expand Down

0 comments on commit dfebd84

Please sign in to comment.