[llvm-commits] [PATCH] x86: Allow using unpack for shuffles in more situations
Jeff Muizelaar
jmuizelaar at mozilla.com
Fri Jul 22 16:28:05 PDT 2011
On 2011-07-21, at 9:10 PM, Bruno Cardoso Lopes wrote:
> Hi Jeff,
>
> On Thu, Jul 21, 2011 at 12:41 PM, Jeff Muizelaar <jmuizelaar at mozilla.com> wrote:
>> When investigating PR10171 I noticed that we already have code to turn shuffles into unpacks we just don't use it when VT == MVT::v2i64 or MVT::v2f64. I couldn't see any reason not to use it in those situations so this patch removes the check.
>
> The checks are there because we're in the middle of a shuffle handling
> rewritten, and we are keeping some track of the types. However, your
> patch looks good to me, can you provide testcases (as in
> test/CodeGen/X86/...) with the patch? With a testcase showing the
> improvements I would be happy to apply.
Another thing I noticed about this code is that it only uses unpack for OptSize. Take a quick look here http://www.agner.org/optimize/instruction_tables.pdf I didn't see any cases where pshufd was faster than unpack. Do you know if the OptSize check is needed?
-Jeff
More information about the llvm-commits
mailing list