Merge commit '60eb70f5436c41dc6e227b5b1d7f9a6445b17892' into develop

This commit is contained in:
assistant-librarian[bot]
2025-07-02 07:07:50 +00:00
parent ef3d90cf5f
commit 350b20868b

View File

@@ -213,7 +213,7 @@ __host__ __device__ inline T convert_to_type(float value)
{
// closer to 0
if(std::abs(value) <= std::abs(min_subnorm - value))
return 0;
return sign << (NumericUtils<T>::exp + NumericUtils<T>::mant);
else
return 1 | (sign << (NumericUtils<T>::exp + NumericUtils<T>::mant));
}
@@ -249,7 +249,7 @@ __host__ __device__ inline T convert_to_type(float value)
if(out_exponent == 0 && mantissa == 0)
{
return 0;
return sign << (NumericUtils<T>::exp + NumericUtils<T>::mant);
}
mantissa &= (1UL << NumericUtils<T>::mant) - 1;