diff options
author | Jay Foad <jay.foad@amd.com> | 2021-10-04 10:20:18 +0100 |
---|---|---|
committer | Jay Foad <jay.foad@amd.com> | 2021-10-04 11:32:16 +0100 |
commit | 566690b067c8175314fa657b899c99bccf96821c (patch) | |
tree | b02900a1d19503f866d8b52f50b6599a9a6100b1 /llvm/lib/Support | |
parent | 45f9795085ee0fe6fd23129d80aad5a2ea5026a0 (diff) | |
download | llvm-566690b067c8175314fa657b899c99bccf96821c.zip llvm-566690b067c8175314fa657b899c99bccf96821c.tar.gz llvm-566690b067c8175314fa657b899c99bccf96821c.tar.bz2 |
[APFloat] Remove BitWidth argument from getAllOnesValue
There's no need to pass this in explicitly because it is
trivially available from the semantics.
Diffstat (limited to 'llvm/lib/Support')
-rw-r--r-- | llvm/lib/Support/APFloat.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Support/APFloat.cpp b/llvm/lib/Support/APFloat.cpp index 780d1d0c..fc2b1ae 100644 --- a/llvm/lib/Support/APFloat.cpp +++ b/llvm/lib/Support/APFloat.cpp @@ -4864,9 +4864,8 @@ APFloat::opStatus APFloat::convert(const fltSemantics &ToSemantics, llvm_unreachable("Unexpected semantics"); } -APFloat APFloat::getAllOnesValue(const fltSemantics &Semantics, - unsigned BitWidth) { - return APFloat(Semantics, APInt::getAllOnes(BitWidth)); +APFloat APFloat::getAllOnesValue(const fltSemantics &Semantics) { + return APFloat(Semantics, APInt::getAllOnes(Semantics.sizeInBits)); } void APFloat::print(raw_ostream &OS) const { |