[PATCH] [X86] Memory folding for commutative instructions (updated)
Simon Pilgrim
llvm-dev at redking.me.uk
Thu Oct 16 03:41:41 PDT 2014
Hi qcolombet, andreadb, spatel, nadav,
This patch improves support for commutative instructions in the x86 memory folding implementation by attempting to fold a commuted version of the instruction if the original folding fails - if that folding fails as well the instruction is 're-commuted' back to its original order before returning.
Updated version of http://reviews.llvm.org/D5701 (reverted in r219595) - the commutation attempt now explicitly ensures that neither of the commuted source operands are tied to the destination operand / register, which was the source of all the regressions that occurred with the original patch attempt.
Added additional regression test case provided by Joerg Sonnenberger.
http://reviews.llvm.org/D5818
Files:
lib/Target/X86/X86FastISel.cpp
lib/Target/X86/X86InstrInfo.cpp
lib/Target/X86/X86InstrInfo.h
test/CodeGen/X86/2014-10-16-xxhash.ll
test/CodeGen/X86/avx1-stack-reload-folding.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D5818.15004.patch
Type: text/x-patch
Size: 11912 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141016/d4e943a4/attachment.bin>
More information about the llvm-commits
mailing list