projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f3f2d6d
)
fix this method for 64-bit constants
author
Chris Lattner
<sabre@nondot.org>
Fri, 8 Apr 2005 21:31:29 +0000
(21:31 +0000)
committer
Chris Lattner
<sabre@nondot.org>
Fri, 8 Apr 2005 21:31:29 +0000
(21:31 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21158
91177308
-0d34-0410-b5e6-
96231b3b80d8
include/llvm/CodeGen/SelectionDAGNodes.h
patch
|
blob
|
history
diff --git
a/include/llvm/CodeGen/SelectionDAGNodes.h
b/include/llvm/CodeGen/SelectionDAGNodes.h
index 6d5d26223f09a0cecd2a418f53a6b48949121124..adb85f0e9637375294b6595c313518caa7702c03 100644
(file)
--- a/
include/llvm/CodeGen/SelectionDAGNodes.h
+++ b/
include/llvm/CodeGen/SelectionDAGNodes.h
@@
-605,7
+605,9
@@
public:
bool isNullValue() const { return Value == 0; }
bool isAllOnesValue() const {
- return Value == (1ULL << MVT::getSizeInBits(getValueType(0)))-1;
+ int NumBits = MVT::getSizeInBits(getValueType(0));
+ if (NumBits == 64) return Value+1 == 0;
+ return Value == (1ULL << NumBits)-1;
}
static bool classof(const ConstantSDNode *) { return true; }