LLVM 22.0.0git
|
This pass aims at de-duplicating packs, i.e., try to reuse already existing pack patterns instead of keeping both. More...
#include "llvm/Transforms/Vectorize/SandboxVectorizer/Passes/PackReuse.h"
Public Member Functions | |
PackReuse () | |
bool | runOnRegion (Region &Rgn, const Analyses &A) final |
\Returns true if it modifies R . | |
Public Member Functions inherited from llvm::sandboxir::RegionPass | |
RegionPass (StringRef Name) | |
Name can't contain any spaces or start with '-'. | |
Public Member Functions inherited from llvm::sandboxir::Pass | |
Pass (StringRef Name) | |
Name can't contain any spaces or start with '-'. | |
virtual | ~Pass () |
StringRef | getName () const |
\Returns the name of the pass. | |
virtual void | print (raw_ostream &OS) const |
virtual LLVM_DUMP_METHOD void | dump () const |
virtual void | printPipeline (raw_ostream &OS) const |
Similar to print() but adds a newline. Used for testing. |
Additional Inherited Members | |
Protected Attributes inherited from llvm::sandboxir::Pass | |
const std::string | Name |
The pass name. |
This pass aims at de-duplicating packs, i.e., try to reuse already existing pack patterns instead of keeping both.
This is useful because even though the duplicates will most probably be optimized away by future passes, their added cost can make vectorization more conservative than it should be.
Definition at line 26 of file PackReuse.h.
|
inline |
Definition at line 30 of file PackReuse.h.
References llvm::sandboxir::RegionPass::RegionPass().
\Returns true if it modifies R
.
Implements llvm::sandboxir::RegionPass.
Definition at line 14 of file PackReuse.cpp.
References A(), llvm::sandboxir::BasicBlock(), llvm::sandboxir::Region::empty(), I, llvm::make_range(), llvm::sandboxir::VecUtils::matchPack(), and llvm::sort().