This is an archive of the discontinued LLVM Phabricator instance.

[Power9] Add missing Power9 instructions.
ClosedPublic

Authored by jtony on Sep 14 2017, 6:22 AM.

Details

Summary

The following 8 instructions are introduced in the ISA 3.0, but not implemented yet, implement them in this patch.
addpcis(subpcis, lnia), darn, maddhd, maddhdu, maddld, setb

Diff Detail

Event Timeline

jtony created this revision.Sep 14 2017, 6:22 AM
jtony updated this revision to Diff 115407.Sep 15 2017, 7:42 AM

Delete the p9-instrs.txt file, since all the needed instructions in it have been implemented.

nemanjai requested changes to this revision.Sep 18 2017, 4:30 AM
nemanjai added inline comments.
lib/Target/PowerPC/PPCInstr64Bit.td
687–699

No need for an extra block with the exact same predicate.

lib/Target/PowerPC/PPCInstrFormats.td
399

Line up the comments on these lines please.

lib/Target/PowerPC/PPCInstrInfo.td
3805

Do we not want 32-bit and 64-bit variants of these? If so, please stick to the naming convention of <MNEMONIC>/<MNEMONIC>8 and set Interpretation64Bit accordingly. If they're 64-bit only, please move them to the right file and have them inherit isPPC64.

3807

Remove the space between i32imm and the colon. Here and for ADDPCIS.

test/MC/Disassembler/PowerPC/ppc64-encoding.txt
346

Add one case where we'll emit an lnia.

This revision now requires changes to proceed.Sep 18 2017, 4:30 AM
jtony marked 5 inline comments as done.Sep 18 2017, 2:25 PM
jtony added inline comments.
lib/Target/PowerPC/PPCInstrInfo.td
3805

We just need 64 bit only, I will move them to PPCInstr64Bit.td

jtony updated this revision to Diff 115728.Sep 18 2017, 2:50 PM
jtony edited edge metadata.
jtony marked 2 inline comments as done.

Address all the comments from Nemanja.

echristo accepted this revision.Sep 18 2017, 3:10 PM

LGTM. Let Nemanja give the final approval.

nemanjai accepted this revision.Sep 19 2017, 1:13 AM

LGTM.

This revision is now accepted and ready to land.Sep 19 2017, 1:13 AM
jtony closed this revision.Sep 19 2017, 9:10 AM
lib/Target/PowerPC/PPCInstrInfo.td