Skip to content

Commit

Permalink
Remove the LoadCombine pass. It was never enabled and is unsupported.
Browse files Browse the repository at this point in the history
Based on discussions with the author on mailing lists.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@306067 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
echristo committed Jun 22, 2017
1 parent d6dbca4 commit e1ae008
Show file tree
Hide file tree
Showing 13 changed files with 0 additions and 674 deletions.
1 change: 0 additions & 1 deletion include/llvm/InitializePasses.h
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,6 @@ void initializeLiveRangeShrinkPass(PassRegistry&);
void initializeLiveRegMatrixPass(PassRegistry&);
void initializeLiveStacksPass(PassRegistry&);
void initializeLiveVariablesPass(PassRegistry&);
void initializeLoadCombinePass(PassRegistry&);
void initializeLoadStoreVectorizerPass(PassRegistry&);
void initializeLoaderPassPass(PassRegistry&);
void initializeLocalStackSlotPassPass(PassRegistry&);
Expand Down
1 change: 0 additions & 1 deletion include/llvm/Transforms/IPO/PassManagerBuilder.h
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,6 @@ class PassManagerBuilder {
bool SLPVectorize;
bool LoopVectorize;
bool RerollLoops;
bool LoadCombine;
bool NewGVN;
bool DisableGVNLoadPRE;
bool VerifyInput;
Expand Down
6 changes: 0 additions & 6 deletions include/llvm/Transforms/Scalar.h
Original file line number Diff line number Diff line change
Expand Up @@ -485,12 +485,6 @@ FunctionPass *createSpeculativeExecutionPass();
// TargetTransformInfo::hasBranchDivergence() is true.
FunctionPass *createSpeculativeExecutionIfHasBranchDivergencePass();

//===----------------------------------------------------------------------===//
//
// LoadCombine - Combine loads into bigger loads.
//
BasicBlockPass *createLoadCombinePass();

//===----------------------------------------------------------------------===//
//
// StraightLineStrengthReduce - This pass strength-reduces some certain
Expand Down
3 changes: 0 additions & 3 deletions lib/Passes/PassBuilder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -923,9 +923,6 @@ ModulePassManager PassBuilder::buildLTODefaultPipeline(OptimizationLevel Level,
MainFPM.add(AlignmentFromAssumptionsPass());
#endif

// FIXME: Conditionally run LoadCombine here, after it's ported
// (in case we still have this pass, given its questionable usefulness).

// FIXME: add peephole extensions to the PM here.
MainFPM.addPass(InstCombinePass());
MainFPM.addPass(JumpThreadingPass());
Expand Down
11 changes: 0 additions & 11 deletions lib/Transforms/IPO/PassManagerBuilder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,6 @@ static cl::opt<bool>
RunLoopRerolling("reroll-loops", cl::Hidden,
cl::desc("Run the loop rerolling pass"));

static cl::opt<bool> RunLoadCombine("combine-loads", cl::init(false),
cl::Hidden,
cl::desc("Run the load combining pass"));

static cl::opt<bool> RunNewGVN("enable-newgvn", cl::init(false), cl::Hidden,
cl::desc("Run the NewGVN pass"));

Expand Down Expand Up @@ -174,7 +170,6 @@ PassManagerBuilder::PassManagerBuilder() {
SLPVectorize = RunSLPVectorization;
LoopVectorize = RunLoopVectorization;
RerollLoops = RunLoopRerolling;
LoadCombine = RunLoadCombine;
NewGVN = RunNewGVN;
DisableGVNLoadPRE = false;
VerifyInput = false;
Expand Down Expand Up @@ -407,9 +402,6 @@ void PassManagerBuilder::addFunctionSimplificationPasses(
}
}

if (LoadCombine)
MPM.add(createLoadCombinePass());

MPM.add(createAggressiveDCEPass()); // Delete dead instructions
MPM.add(createCFGSimplificationPass()); // Merge & remove BBs
// Clean up after everything.
Expand Down Expand Up @@ -850,9 +842,6 @@ void PassManagerBuilder::addLTOOptimizationPasses(legacy::PassManagerBase &PM) {
// alignments.
PM.add(createAlignmentFromAssumptionsPass());

if (LoadCombine)
PM.add(createLoadCombinePass());

// Cleanup and simplify the code after the scalar optimizations.
addInstructionCombiningPass(PM);
addExtensionsToPM(EP_Peephole, PM);
Expand Down
1 change: 0 additions & 1 deletion lib/Transforms/Scalar/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ add_llvm_library(LLVMScalarOpts
LICM.cpp
LoopAccessAnalysisPrinter.cpp
LoopSink.cpp
LoadCombine.cpp
LoopDeletion.cpp
LoopDataPrefetch.cpp
LoopDistribute.cpp
Expand Down
295 changes: 0 additions & 295 deletions lib/Transforms/Scalar/LoadCombine.cpp

This file was deleted.

1 change: 0 additions & 1 deletion lib/Transforms/Scalar/Scalar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,6 @@ void llvm::initializeScalarOpts(PassRegistry &Registry) {
initializeSeparateConstOffsetFromGEPPass(Registry);
initializeSpeculativeExecutionLegacyPassPass(Registry);
initializeStraightLineStrengthReducePass(Registry);
initializeLoadCombinePass(Registry);
initializePlaceBackedgeSafepointsImplPass(Registry);
initializePlaceSafepointsPass(Registry);
initializeFloat2IntLegacyPassPass(Registry);
Expand Down
Loading

0 comments on commit e1ae008

Please sign in to comment.