summaryrefslogtreecommitdiff
path: root/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorKai Nacke <kai.nacke@redstar.de>2013-09-19 23:00:28 +0000
committerKai Nacke <kai.nacke@redstar.de>2013-09-19 23:00:28 +0000
commitceb3b4649086c4aa6aa535440748c5860093f6e6 (patch)
treef2d9e098f83fca6df1eb607165d32a8fd9087fe8 /lib/Bitcode/Reader/BitcodeReader.cpp
parent7cb98c9cb7688ad775d4dee07ca66570f1c030d1 (diff)
downloadllvm-ceb3b4649086c4aa6aa535440748c5860093f6e6.tar.gz
llvm-ceb3b4649086c4aa6aa535440748c5860093f6e6.tar.bz2
llvm-ceb3b4649086c4aa6aa535440748c5860093f6e6.tar.xz
PR16726: extend rol/ror matching
C-like languages promote types like unsigned short to unsigned int before performing an arithmetic operation. Currently the rotate matcher in the DAGCombiner does not consider this situation. This commit extends the DAGCombiner in the way that the pattern (or (shl ([az]ext x), (*ext y)), (srl ([az]ext x), (*ext (sub 32, y)))) is folded into ([az]ext (rotl x, y)) The matching is restricted to aext and zext because in this cases the upper bits are either undefined or known. Test case is included. This fixes PR16726. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191049 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions