mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-03 10:54:42 +00:00
Fix miscompilation of MallocBench/espresso which code review pointed out
but apparently didn't make it into the final patch. llvm-svn: 31070
This commit is contained in:
parent
da5290e752
commit
38ed7d9e49
@ -4913,7 +4913,7 @@ Instruction *InstCombiner::visitShiftInst(ShiftInst &I) {
|
||||
// shr int -1, X = -1 (for any arithmetic shift rights of ~0)
|
||||
if (!isLeftShift)
|
||||
if (ConstantInt *CSI = dyn_cast<ConstantInt>(Op0))
|
||||
if (CSI->isAllOnesValue())
|
||||
if (CSI->isAllOnesValue() && Op0->getType()->isSigned())
|
||||
return ReplaceInstUsesWith(I, CSI);
|
||||
|
||||
// Try to fold constant and into select arguments.
|
||||
|
Loading…
x
Reference in New Issue
Block a user