Page MenuHomePhabricator

[X86] Lower vselect with constant condition to vector_shuffle even with AVX512 instructions.
ClosedPublic

Authored by craig.topper on Oct 14 2017, 11:09 PM.

Details

Summary

It's better to use our shuffle lowering code to handle these than loading an immediate into a k-register.

It really feels like this should be a DAG combine optimization rather than a lowering operation, but that's a problem for another day.

Diff Detail

Repository
rL LLVM

Event Timeline

craig.topper created this revision.Oct 14 2017, 11:09 PM
delena accepted this revision.Oct 14 2017, 11:28 PM
This revision is now accepted and ready to land.Oct 14 2017, 11:28 PM
This revision was automatically updated to reflect the committed changes.

I suggest to open a ticket in bugzilla about possible replacement of "select" with constant mask with shuffle to avoid mask instructions on AVX-512.

How is that different than this patch?