Page MenuHomePhabricator

[X86][NFC] Remove unused encoding string: VK[1/2/4/8/16]PAIR
ClosedPublic

Authored by LiuChen3 on Sep 9 2021, 8:13 PM.

Details

Summary

This is also a bug. The VK[1/2/4/8/16]PAIR here should be VK[1/2/4/8/16]Pair which has its
custom PrintMethod and ParserMatchClass. However we don't have any instructions using vvvv
and ModR/M.REG field so this issue is not exposed.

Diff Detail

Event Timeline

LiuChen3 requested review of this revision.Sep 9 2021, 8:13 PM
LiuChen3 created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptSep 9 2021, 8:13 PM
This revision is now accepted and ready to land.Sep 9 2021, 8:26 PM

Change VK1PAIR to VK1Pair may be reasonable. (keep same with other xxRegisterEncodingFromString for future ISA.)

lib/Target/X86/X86RegisterInfo.td:629:def VK1PAIR : RegisterClass<"X86", [untyped], 16, (add KPAIRS)> {let Size = 32;}
lib/Target/X86/X86InstrInfo.td:817:def VK1Pair : RegisterOperand<VK1PAIR, "printVKPair"> {

Change VK1PAIR to VK1Pair may be reasonable. (keep same with other xxRegisterEncodingFromString for future ISA.)

lib/Target/X86/X86RegisterInfo.td:629:def VK1PAIR : RegisterClass<"X86", [untyped], 16, (add KPAIRS)> {let Size = 32;}
lib/Target/X86/X86InstrInfo.td:817:def VK1Pair : RegisterOperand<VK1PAIR, "printVKPair"> {

I think it is fine to remove it. Tablegen will issue an error if a new instruction is added. At that point its easy to add back.

This revision was landed with ongoing or failed builds.Sep 9 2021, 10:43 PM
This revision was automatically updated to reflect the committed changes.

Thanks for reviewing this patch!