This is an archive of the discontinued LLVM Phabricator instance.

[X86][SSE] Lower 128-bit MOVDDUP with existing VBROADCAST mechanisms
ClosedPublic

Authored by RKSimon on Feb 27 2016, 3:48 AM.

Details

Summary

We have a number of useful lowering strategies for VBROADCAST instructions (both from memory and register element 0) which the 128-bit form of the MOVDDUP instruction can make use of.

This patch tweaks lowerVectorShuffleAsBroadcast to enable it to broadcast 2f64 args using MOVDDUP as well.

It does require a slight tweak to the lowerVectorShuffleAsBroadcast mechanism as the existing MOVDDUP lowering uses isShuffleEquivalent which can match binary shuffles that can lower to (unary) broadcasts.

Diff Detail

Repository
rL LLVM

Event Timeline

RKSimon updated this revision to Diff 49293.Feb 27 2016, 3:48 AM
RKSimon retitled this revision from to [X86][SSE] Lower 128-bit MOVDDUP with existing VBROADCAST mechanisms.
RKSimon updated this object.
RKSimon added reviewers: delena, spatel, andreadb.
RKSimon set the repository for this revision to rL LLVM.
RKSimon added a subscriber: llvm-commits.
spatel accepted this revision.Mar 1 2016, 11:35 AM
spatel edited edge metadata.

LGTM.

This revision is now accepted and ready to land.Mar 1 2016, 11:35 AM
This revision was automatically updated to reflect the committed changes.