| @@ -211,7 +211,7 @@ constexpr uint32_t kFp32MaxExp = 0xFFU; | |||||
| constexpr uint32_t kFp32MaxMan = 0x7FFFFFU; | constexpr uint32_t kFp32MaxMan = 0x7FFFFFU; | ||||
| /// @ingroup fp32 special value judgment | /// @ingroup fp32 special value judgment | ||||
| /// @brief whether a fp32 is NaN | /// @brief whether a fp32 is NaN | ||||
| inline bool FP32_IS_NAN(cons uint16_t x) { | |||||
| inline bool FP32_IS_NAN(const uint16_t x) { | |||||
| return ((((x) & kFp32ExpMask) == kFp32ExpMask) && ((x) & kFp32ManMask)); | return ((((x) & kFp32ExpMask) == kFp32ExpMask) && ((x) & kFp32ManMask)); | ||||
| } | } | ||||
| /// @ingroup fp32 special value judgment | /// @ingroup fp32 special value judgment | ||||
| @@ -637,7 +637,7 @@ T GetManSum(int16_t e_a, const T &m_a, int16_t e_b, const T &m_b) { | |||||
| T sum = 0; | T sum = 0; | ||||
| if (e_a != e_b) { | if (e_a != e_b) { | ||||
| T m_tmp = 0; | T m_tmp = 0; | ||||
| int16_t e_tmp = static_cast<int16_t>std::abs(e_a - e_b); | |||||
| int16_t e_tmp = static_cast<int16_t>(std::abs(e_a - e_b)); | |||||
| if (e_a > e_b) { | if (e_a > e_b) { | ||||
| m_tmp = m_b; | m_tmp = m_b; | ||||
| m_tmp = RightShift(m_tmp, e_tmp); | m_tmp = RightShift(m_tmp, e_tmp); | ||||