summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/include/llvm/IR/ConstantRange.h3
-rw-r--r--llvm/lib/IR/ConstantRange.cpp8
2 files changed, 0 insertions, 11 deletions
diff --git a/llvm/include/llvm/IR/ConstantRange.h b/llvm/include/llvm/IR/ConstantRange.h
index 16079598bec..ec57e08be72 100644
--- a/llvm/include/llvm/IR/ConstantRange.h
+++ b/llvm/include/llvm/IR/ConstantRange.h
@@ -205,9 +205,6 @@ public:
/// Return true if this set contains exactly one member.
bool isSingleElement() const { return getSingleElement() != nullptr; }
- /// Return the number of elements in this set.
- APInt getSetSize() const;
-
/// Compare set size of this range with the range CR.
bool isSizeStrictlySmallerThan(const ConstantRange &CR) const;
diff --git a/llvm/lib/IR/ConstantRange.cpp b/llvm/lib/IR/ConstantRange.cpp
index 40934d97286..87b66fa821c 100644
--- a/llvm/lib/IR/ConstantRange.cpp
+++ b/llvm/lib/IR/ConstantRange.cpp
@@ -349,14 +349,6 @@ bool ConstantRange::isUpperSignWrapped() const {
return Lower.sgt(Upper);
}
-APInt ConstantRange::getSetSize() const {
- if (isFullSet())
- return APInt::getOneBitSet(getBitWidth()+1, getBitWidth());
-
- // This is also correct for wrapped sets.
- return (Upper - Lower).zext(getBitWidth()+1);
-}
-
bool
ConstantRange::isSizeStrictlySmallerThan(const ConstantRange &Other) const {
assert(getBitWidth() == Other.getBitWidth());
OpenPOWER on IntegriCloud