[PATCH] D22114: [InstCombine] extend vector select matching for non-splat constants

Sanjay Patel via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 13 10:13:38 PDT 2016


spatel added a comment.

In http://reviews.llvm.org/D22114#482459, @eli.friedman wrote:

> The question isn't really what instructions we expect targets to have, but rather which version makes LLVM simpler overall.  That said, if we assume almost every vector target has some sort of blend instruction, and therefore almost every target would need to pattern match the shuffle into a select, that would be a reason to prefer the select form, I guess.


Agree - that was the point I was trying to ineffectively make: if targets are going to prefer the select/blend anyway, we save some slight codegen churn from producing that form here in IR directly.


http://reviews.llvm.org/D22114





More information about the llvm-commits mailing list