[PATCH] D25874: [X86][SSE] Add support for (V)PMOVSX* constant folding
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 21 10:55:13 PDT 2016
RKSimon created this revision.
RKSimon added reviewers: zvi, delena, spatel, andreadb.
RKSimon added a subscriber: llvm-commits.
RKSimon set the repository for this revision to rL LLVM.
We already have (V)PMOVZX* combining support, this is the beginning of handling (V)PMOVSX* simililarly - other combines in combineVSZext can be generalized in future patches.
This unearthed an interesting bug in that we were generating illegal build vectors on 32-bit targets - it was proving difficult to create a test for it from PMOVZX, but it fired immediately with PMOVSX. I've created a more general form of the existing getConstVector to handle these cases - ideally this should be handled in non-target-specific code but I couldn't find an equivalent.
I have wondered whether we should not fold when OptSize=true?
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 18017 bytes
Desc: not available
More information about the llvm-commits