[SystemZ] Fix incorrect use of RISBG for a zero-extended right shift
authorRichard Sandiford <rsandifo@linux.vnet.ibm.com>
Tue, 26 Nov 2013 10:53:16 +0000 (10:53 +0000)
committerRichard Sandiford <rsandifo@linux.vnet.ibm.com>
Tue, 26 Nov 2013 10:53:16 +0000 (10:53 +0000)
commit396e080b3467ccdcbbfb908f9405e7dd134d5c8a
tree10ea35fa3144148755bed187dbd1f6eb3f282c7f
parent7c6be4d5586aa365c8f52289ffddf57b87da4da7
[SystemZ] Fix incorrect use of RISBG for a zero-extended right shift

We would wrongly transform the testcase into the equivalent of an AND with 1.
The problem was that, when testing whether the shifted-in bits of the right
shift were significant, we used the width of the final zero-extended result
rather than the width of the shifted value.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@195731 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
test/CodeGen/SystemZ/risbg-01.ll