[libc-commits] [PATCH] D82036: [libc] Add implementations long double fabsl and truncl functions.

Siva Chandra via Phabricator via libc-commits libc-commits at lists.llvm.org
Thu Jun 18 11:27:05 PDT 2020


sivachandra added inline comments.


================
Comment at: libc/utils/FPUtil/FPBits.h:34
+};
+template <> struct ExponentWidth<long double> {
+  static constexpr unsigned value = 15;
----------------
asteinhauser wrote:
> This should be moved to MantissaWidth<long double> (10 lines below) if for visual studio long double and double are equivalent. You can hardly have 15 bytes for exponent and 52 bits for mantissa.
When we start adding MSVC support, we will have to enclose this in separate `#define` and friends. Without MSVC support, this is correct as is because all architectures use 15 bit exponent for `long double`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D82036/new/

https://reviews.llvm.org/D82036





More information about the libc-commits mailing list