diff options
author | Evan Cheng <evan.cheng@apple.com> | 2009-02-02 09:15:04 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2009-02-02 09:15:04 +0000 |
commit | 97d0e0e31409865b2077248a05b1b91b4a259d95 (patch) | |
tree | 4482d68e872f2c1338f1884cceb653ac0029d8f7 /lib | |
parent | 781f2fb76344e3fe4e750b31adfa459343462628 (diff) |
ADD / SUB / SMUL / UMUL with overflow second result top bits must be zero.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63509 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Target/X86/X86ISelLowering.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 846acd0219..7a4d34d10a 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -7515,6 +7515,14 @@ void X86TargetLowering::computeMaskedBitsForTargetNode(const SDValue Op, KnownZero = KnownOne = APInt(Mask.getBitWidth(), 0); // Don't know anything. switch (Opc) { default: break; + case X86ISD::ADD: + case X86ISD::SUB: + case X86ISD::SMUL: + case X86ISD::UMUL: + // These nodes' second result is a boolean. + if (Op.getResNo() == 0) + break; + // Fallthrough case X86ISD::SETCC: KnownZero |= APInt::getHighBitsSet(Mask.getBitWidth(), Mask.getBitWidth() - 1); |