-
Notifications
You must be signed in to change notification settings - Fork 58
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
Added Vector Uop Generation Support for Mask Generation and Widening Instructions #181
Added Vector Uop Generation Support for Mask Generation and Widening Instructions #181
Conversation
@aarongchan and @klingaard there is still a lot to do here, but I wanted to start this PR before it got any larger. I have a couple of questions for Aaron, but I'll put them in separate comments. |
@@ -72,14 +75,14 @@ namespace olympia | |||
// will truncate, but we have each adder support the largest SEW possible | |||
if (ex_inst->getPipe() == InstArchInfo::TargetPipe::VINT) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to define some additional resources for other types of vector resources like boolean logicals, compares, min/max, multiplies and divides. I'm not sure which operations should be supported by the VALU adder.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can just support all under VALU adder, and then have a separate unit for masks, slides, and more complex computations like scatter/gather. I guess in the case of scatter/gathers, we just define a new unit that has a state machine to track for the VALU that is used only by that unit.
core/ROB.cpp
Outdated
@@ -159,6 +162,7 @@ namespace olympia | |||
out_rob_retire_ack_rename_.send(ex_inst_ptr); | |||
|
|||
++num_retired_; | |||
num_uops_retired_ += ex_inst_ptr->getUOpCount(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI I'm counting every instruction as 1 uop.
core/VectorUopGenerator.cpp
Outdated
sparta_assert(uop_gen_type != InstArchInfo::UopGenType::NONE, | ||
"Inst: " << current_inst_ << " uop gen type is unknown"); | ||
auto x = uop_gen_function_map_.at(uop_gen_type); | ||
return x(this); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably a cleaner way to do this. Open to suggestions...
@@ -18,7 +18,7 @@ | |||
{0000000000 00000000 top.dispatch info} Dispatch: mapping target: F2Iiq3 | |||
{0000000000 00000000 top.dispatch info} Dispatch: mapping target: BRiq4 | |||
{0000000000 00000000 top.dispatch info} Dispatch: mapping target: VINTiq5 | |||
{0000000000 00000000 top.dispatch info} Dispatch: mapping target: VINTiq5 | |||
{0000000000 00000000 top.dispatch info} Dispatch: mapping target: VSETiq5 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is just from a bug fix in the print operator.
Did you want to remove the Uop checking code from rename in this PR, since you're already removing all old Uop requirements from ROB? riscv-perf-model/core/Rename.cpp Line 212 in 9e10a68
|
Yes that would be great. We should just treat all instructions/uops the same way. |
@aarongchan I'm going to go ahead and merge this PR. Can you remove the uop checking code from rename in your VLSU PR? |
Continuing to add support for more and more vector instructions.