Fix for 2005-08-12-rlwimi-crash.ll. Make allowance for masks being shifted to

zero.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22773 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jim Laskey 2005-08-12 23:52:46 +00:00
parent 4a17addadb
commit cf083e312c

View File

@ -640,7 +640,7 @@ static bool isRotateAndMask(unsigned Opcode, unsigned Shift, unsigned Mask,
}
// if the mask doesn't intersect any Indeterminant bits
if (!(Mask & Indeterminant)) {
if (Mask && !(Mask & Indeterminant)) {
SH = Shift;
// make sure the mask is still a mask (wrap arounds may not be)
return isRunOfOnes(Mask, MB, ME);