[PATCH] [X86][SSE] Enable commutation for SSE immediate blend instructions

Simon Pilgrim llvm-dev at redking.me.uk
Tue Oct 28 08:23:43 PDT 2014


Hi chandlerc, qcolombet, andreadb,

Patch to allow (v)blendps, (v)blendpd, (v)pblendw and vpblendd instructions to be commuted - swaps the src registers and inverts the blend mask.

This is primarily to improve memory folding (see new tests), but it also improves the quality of shuffles (see modified tests).

http://reviews.llvm.org/D6015

Files:
  lib/Target/X86/X86InstrInfo.cpp
  lib/Target/X86/X86InstrSSE.td
  test/CodeGen/X86/combine-or.ll
  test/CodeGen/X86/commute-blend-avx2.ll
  test/CodeGen/X86/commute-blend-sse41.ll
  test/CodeGen/X86/vector-blend.ll
  test/CodeGen/X86/vector-shuffle-128-v2.ll
  test/CodeGen/X86/vector-shuffle-combining.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6015.15525.patch
Type: text/x-patch
Size: 28142 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141028/56b79c50/attachment.bin>


More information about the llvm-commits mailing list