LLVM 22.0.0git
|
A simple and fast domtree-based CSE pass. More...
#include "llvm/Transforms/Scalar/EarlyCSE.h"
Public Member Functions | |
EarlyCSEPass (bool UseMemorySSA=false) | |
LLVM_ABI PreservedAnalyses | run (Function &F, FunctionAnalysisManager &AM) |
Run the pass over the function. | |
LLVM_ABI void | printPipeline (raw_ostream &OS, function_ref< StringRef(StringRef)> MapClassName2PassName) |
Public Member Functions inherited from llvm::PassInfoMixin< EarlyCSEPass > | |
void | printPipeline (raw_ostream &OS, function_ref< StringRef(StringRef)> MapClassName2PassName) |
Public Attributes | |
bool | UseMemorySSA |
Additional Inherited Members | |
Static Public Member Functions inherited from llvm::PassInfoMixin< EarlyCSEPass > | |
static StringRef | name () |
Gets the name of the pass we are mixed into. |
A simple and fast domtree-based CSE pass.
This pass does a simple depth-first walk over the dominator tree, eliminating trivially redundant instructions and using instsimplify to canonicalize things as it goes. It is intended to be fast and catch obvious cases so that instcombine and other passes are more effective. It is expected that a later pass of GVN will catch the interesting/hard cases.
Definition at line 31 of file EarlyCSE.h.
|
inline |
Definition at line 32 of file EarlyCSE.h.
References UseMemorySSA.
void EarlyCSEPass::printPipeline | ( | raw_ostream & | OS, |
function_ref< StringRef(StringRef)> | MapClassName2PassName ) |
Definition at line 1862 of file EarlyCSE.cpp.
References printPipeline(), and UseMemorySSA.
Referenced by printPipeline().
PreservedAnalyses EarlyCSEPass::run | ( | Function & | F, |
FunctionAnalysisManager & | AM ) |
Run the pass over the function.
Definition at line 1841 of file EarlyCSE.cpp.
References llvm::PreservedAnalyses::all(), CSE, F, llvm::AnalysisManager< IRUnitT, ExtraArgTs >::getResult(), llvm::PreservedAnalyses::preserve(), llvm::PreservedAnalyses::preserveSet(), and UseMemorySSA.
bool llvm::EarlyCSEPass::UseMemorySSA |
Definition at line 40 of file EarlyCSE.h.
Referenced by EarlyCSEPass(), printPipeline(), and run().