mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-04 10:04:33 +00:00
simplify this method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27338 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
5295122b0d
commit
885a87ef85
@ -1076,9 +1076,7 @@ public:
|
||||
|
||||
bool isNullValue() const { return Value == 0; }
|
||||
bool isAllOnesValue() const {
|
||||
int NumBits = MVT::getSizeInBits(getValueType(0));
|
||||
if (NumBits == 64) return Value+1 == 0;
|
||||
return Value == (1ULL << NumBits)-1;
|
||||
return Value == MVT::getIntVTBitMask(getValueType(0));
|
||||
}
|
||||
|
||||
static bool classof(const ConstantSDNode *) { return true; }
|
||||
|
Loading…
Reference in New Issue
Block a user