File tree Expand file tree Collapse file tree 2 files changed +14
-0
lines changed
llvm/include/llvm/Transforms/Vectorize/SandboxVectorizer/Passes Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change 22
22
23
23
namespace llvm ::sandboxir {
24
24
25
+ // / This is a simple bottom-up vectorizer Region pass.
26
+ // / It expects a "seed slice" as an input in the Region's Aux vector.
27
+ // / The "seed slice" is a vector of instructions that can be used as a starting
28
+ // / point for vectorization, like stores to consecutive memory addresses.
29
+ // / Starting from the seed instructions, it walks up the def-use chain looking
30
+ // / for more instructions that can be vectorized. This pass will generate vector
31
+ // / code if it can legally vectorize the code, regardless of whether it is
32
+ // / profitable or not. For now profitability is checked at the end of the region
33
+ // / pass pipeline by a dedicated pass that accepts or rejects the IR
34
+ // / transaction, depending on the cost.
25
35
class BottomUpVec final : public RegionPass {
26
36
bool Change = false ;
27
37
std::unique_ptr<LegalityAnalysis> Legality;
Original file line number Diff line number Diff line change 17
17
18
18
namespace llvm ::sandboxir {
19
19
20
+ // / This pass collects the instructions that can become vectorization "seeds",
21
+ // / like stores to consecutive memory addresses. It then goes over the collected
22
+ // / seeds, slicing them into appropriately sized chunks, creating a Region with
23
+ // / the seed slice as the Auxiliary vector and runs the region pass pipeline.
20
24
class SeedCollection final : public FunctionPass {
21
25
22
26
// / The PM containing the pipeline of region passes.
You can’t perform that action at this time.
0 commit comments