Page MenuHomePhabricator

[PowerPC] Switch to by-name matching for instructions (part 1 of 2).
ClosedPublic

Authored by jyknight on Nov 8 2022, 11:45 AM.

Details

Summary

After https://reviews.llvm.org/D137653 we can now switch the PPC
target away from positional operand matching.

This patch fixes all of the "easy" cases. While this changes a large
number of lines of tablegen source, it results in only a single
non-comment change in the code generated by tablegen: the (unused)
codegen-only "MTVRSAVEv" instruction was previously incorrectly
encoding operand 0, and now encodes (correctly) operand 1.

Changes which result in generated-code changes have been split off
into the next (smaller) patch, for ease of review.

Diff Detail

Event Timeline

jyknight created this revision.Nov 8 2022, 11:45 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 8 2022, 11:45 AM
jyknight requested review of this revision.Nov 8 2022, 11:45 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 8 2022, 11:45 AM

Uploaded the diff from diffing the generated tablegen code -- minus comments -- to https://reviews.llvm.org/P8298

Ping -- I know this patch is textually large, but I'd really appreciate it if you could take a look ASAP, before this patch gets stale. Thanks!

Post-thanksgiving ping. :)

Ping.

Now PPC and VE are the last two targets still using useDeprecatedPositionallyEncodedOperands. This change is repetitive and large -- but necessary.

I'd be happy to get a "Yea, can't really review this very closely, but I'm happy to rubber stamp it" sort of response here -- which is why I point out the lack of change to code generated by tablegen.

barannikov88 accepted this revision.Thu, Feb 2, 12:20 AM

LGTM
I can confirm that MTVRSAVEv change is the only non-comment change in the generated files.
Thorough work!

This revision is now accepted and ready to land.Thu, Feb 2, 12:20 AM