The new Power10 instruction vsrq was being given the wrong shift vector.
The original code assumed that the shift would be found in bits 121 to 127.
This is not correct. The shift is found in bits 57 to 63.
This can be fixed by swaping the first and second double words.
Details
Details
- Reviewers
lei nemanjai - Group Reviewers
Restricted Project - Commits
- rGcb0c034edc98: [PowerPC] Fix issue where vsrq is given incorrect shift vector
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Unit Tests
Event Timeline
Comment Actions
LGTM.
llvm/lib/Target/PowerPC/PPCInstrPrefix.td | ||
---|---|---|
2561 | I know that the issue is not new with P10, but I think it would be good to mention here something like: // FIXME: The swap is overkill when the shift amount is a constant. // We should just fix the constant in the DAG. And then of course, not forget to follow this patch up with one that does that :). |
I know that the issue is not new with P10, but I think it would be good to mention here something like:
And then of course, not forget to follow this patch up with one that does that :).