This is an archive of the discontinued LLVM Phabricator instance.

[Power9]Legalize and emit code for DW vector extract and convert to Quad-Precision
ClosedPublic

Authored by lei on May 1 2018, 2:54 PM.

Diff Detail

Repository
rL LLVM

Event Timeline

lei created this revision.May 1 2018, 2:54 PM
nemanjai accepted this revision.May 3 2018, 5:53 AM

If the definition of the new instruction can be avoided, feel free to do so on the commit. If it can't, add a comment as to why it is necessary in the code.
Other than that, LGTM.

lib/Target/PowerPC/PPCInstrVSX.td
3163 ↗(On Diff #144795)

I am curious why we need another CodeGenOnly instruction here. It seems that for the version that doesn't require the splat, you can just accomplish what is necessary with a COPY_TO_REGCLASS. Why can't the output pattern here be something like:
(f128 (XSCVSDQP (COPY_TO_REGCLASS (XXPERMDI $src, $src, 3), VFRC)))

This revision is now accepted and ready to land.May 3 2018, 5:53 AM
lei updated this revision to Diff 145204.EditedMay 4 2018, 8:50 AM

Remove extra CodeGenOnly pattern and update pattern with EXTRACT_SUBREG.

This revision was automatically updated to reflect the committed changes.