aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/IR/ConstantRange.cpp
diff options
context:
space:
mode:
authorKazu Hirata <kazu@google.com>2023-02-19 23:56:52 -0800
committerKazu Hirata <kazu@google.com>2023-02-19 23:56:52 -0800
commita28b252d852c31fb7228e095a213347e6926bb0f (patch)
treef6c8c2ce5a40b70c93f8498cffba9bb43979b873 /llvm/lib/IR/ConstantRange.cpp
parent2dfa957f120244ddc0238b548282f67d89f1a832 (diff)
downloadllvm-a28b252d852c31fb7228e095a213347e6926bb0f.zip
llvm-a28b252d852c31fb7228e095a213347e6926bb0f.tar.gz
llvm-a28b252d852c31fb7228e095a213347e6926bb0f.tar.bz2
Use APInt::getSignificantBits instead of APInt::getMinSignedBits (NFC)
Note that getMinSignedBits has been soft-deprecated in favor of getSignificantBits.
Diffstat (limited to 'llvm/lib/IR/ConstantRange.cpp')
-rw-r--r--llvm/lib/IR/ConstantRange.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/IR/ConstantRange.cpp b/llvm/lib/IR/ConstantRange.cpp
index af70bfe..74cc097 100644
--- a/llvm/lib/IR/ConstantRange.cpp
+++ b/llvm/lib/IR/ConstantRange.cpp
@@ -481,8 +481,8 @@ unsigned ConstantRange::getMinSignedBits() const {
if (isEmptySet())
return 0;
- return std::max(getSignedMin().getMinSignedBits(),
- getSignedMax().getMinSignedBits());
+ return std::max(getSignedMin().getSignificantBits(),
+ getSignedMax().getSignificantBits());
}
ConstantRange ConstantRange::subtract(const APInt &Val) const {