mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-16 00:33:10 +00:00
Make sure constant bitwidth is <= 64 bit before calling getSExtValue().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160350 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
70e10d3fe4
commit
b4d4959fdd
@ -2323,7 +2323,8 @@ TargetLowering::SimplifySetCC(EVT VT, SDValue N0, SDValue N1,
|
||||
}
|
||||
}
|
||||
|
||||
if (!isLegalICmpImmediate(C1.getSExtValue())) {
|
||||
if (C1.getMinSignedBits() <= 64 &&
|
||||
!isLegalICmpImmediate(C1.getSExtValue())) {
|
||||
// (X & -256) == 256 -> (X >> 8) == 1
|
||||
if ((Cond == ISD::SETEQ || Cond == ISD::SETNE) &&
|
||||
N0.getOpcode() == ISD::AND && N0.hasOneUse()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user