Helper struct with common constants needed by the floating <--> decimal conversions. More...
#include <floating_conversion.hpp>
Public Types | |
using | IntegerRep = std::conditional_t< is_double, uint64_t, uint32_t > |
Integer type that can hold the value of the significand. | |
using | ShiftingRep = std::conditional_t< is_double, __uint128_t, uint64_t > |
Shift data back and forth in space of a type with 2x the starting bits, to give us enough room. | |
Static Public Attributes | |
static constexpr bool | is_double = cuda::std::is_same_v<FloatingType, double> |
Whether the type is double. | |
static constexpr auto | num_significand_bits = cuda::std::numeric_limits<FloatingType>::digits |
Num bits needed to hold the significand. | |
static constexpr int | num_2s_shift_buffer_bits = is_double ? 4 : 1 |
static constexpr int | max_digits_shift = is_double ? 18 : 9 |
Max at-once decimal place shift. | |
static constexpr int | max_bits_shift = max_digits_shift * 10 / 3 |
Max at-once bit shift. | |
static constexpr auto | max_digits_shift_pow |
10^max_digits_shift More... | |
Helper struct with common constants needed by the floating <--> decimal conversions.
Definition at line 557 of file floating_conversion.hpp.
|
staticconstexpr |
10^max_digits_shift
Definition at line 618 of file floating_conversion.hpp.
|
staticconstexpr |
Definition at line 601 of file floating_conversion.hpp.