-
Notifications
You must be signed in to change notification settings - Fork 74
Vector Permutation Design Document #251
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from 6 commits
d96a9b2
8c54e48
bf00bb6
39c43fc
74de265
cca7b68
40833f0
86fe299
7409d6e
2f9a460
0be1cff
c008e48
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -90,11 +90,16 @@ namespace olympia | |
| REDUCTION, | ||
| REDUCTION_WIDE, | ||
| INT_EXT, | ||
| SLIDEUP, | ||
| SLIDEDOWN, | ||
| SLIDE1UP, | ||
| SLIDE1DOWN, | ||
| PERMUTE, | ||
| NONE, | ||
| UNKNOWN | ||
| SCALAR_MOVE, | ||
| RGATHER, | ||
| COMPRESS, | ||
| WHOLE_REG_MOVE, | ||
| UNKNOWN, | ||
| NONE | ||
|
||
| }; | ||
|
|
||
| static constexpr uint32_t N_UOP_GEN_TYPES = static_cast<uint32_t>(UopGenType::NONE); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -169,8 +169,15 @@ namespace olympia | |
| // Exe Uop 2: vrgather.vv v21, v9 | ||
| // Exe Uop 3: vrgather.vv v22, v10 | ||
| // Exe Uop 4: vrgather.vv v23, v11 | ||
| uop_gen_function_map_.emplace(InstArchInfo::UopGenType::PERMUTE, | ||
| &VectorUopGenerator::generatePermuteUops_); | ||
| // uop_gen_function_map_.emplace(InstArchInfo::UopGenType::RGATHER, | ||
| // &VectorUopGenerator::generatePermuteUops_); | ||
|
|
||
| // Vector scalar move uop generator | ||
| // Integer Scalar Move | ||
| // Floating-Point Scalar Move | ||
| uop_gen_function_map_.emplace( | ||
| InstArchInfo::UopGenType::SCALAR_MOVE, | ||
| &VectorUopGenerator::generateScalarMoveUops_<InstArchInfo::UopGenType::SCALAR_MOVE>); | ||
| } | ||
|
|
||
| void VectorUopGenerator::onBindTreeLate_() { mavis_facade_ = getMavis(getContainer()); } | ||
|
|
@@ -359,7 +366,7 @@ namespace olympia | |
| } | ||
| } | ||
|
|
||
| // For narrowing insturction, | ||
| // For narrowing instruction, | ||
| if constexpr (Type == InstArchInfo::UopGenType::NARROWING) | ||
| { | ||
| sparta_assert(src_rs3.field_id != mavis::InstMetaData::OperandFieldID::NONE, | ||
|
|
@@ -479,9 +486,10 @@ namespace olympia | |
| return makeInst_(srcs, dests); | ||
| } | ||
|
|
||
| InstPtr VectorUopGenerator::generatePermuteUops_() | ||
| template <InstArchInfo::UopGenType Type> | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not necessary to have a template parameter if this method is only valid for |
||
| InstPtr VectorUopGenerator::generateScalarMoveUops_() | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not sure I understand what this new generator type provides that isn't already supported. Right now, they are not sequenced at all so no uops are generated and we just send the parent inst down the pipe. If there is a need to generate a uop, we could use the |
||
| { | ||
| sparta_assert(false, "Vector permute uop generation is currently not supported!"); | ||
| sparta_assert(false, "Vector Scalar move implementation TODO ..."); | ||
| } | ||
|
|
||
| InstPtr VectorUopGenerator::makeInst_(const mavis::OperandInfo::ElementList & srcs, | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.