Searched defs:fp16 (Results 1 – 2 of 2) sorted by relevance
58 struct fp16 { struct60 explicit constexpr fp16() noexcept : bits(0) { } in fp16() argument61 explicit constexpr fp16(uint16_t b) noexcept : bits(b) { } in fp16() function62 void setS(unsigned int s) noexcept { bits = uint16_t((bits & 0x7FFF) | (s<<15)); } in setS()63 void setE(unsigned int s) noexcept { bits = uint16_t((bits & 0xE3FF) | (s<<10)); } in setE()64 void setM(unsigned int s) noexcept { bits = uint16_t((bits & 0xFC00) | (s<< 0)); } in setM()65 constexpr unsigned int getS() const noexcept { return bits >> 15u; } in getS()66 constexpr unsigned int getE() const noexcept { return (bits >> 10u) & 0x1Fu; } in getE()67 constexpr unsigned int getM() const noexcept { return bits & 0x3FFu; } in getM()
172 [](_Float16 fp16) { return static_cast<float>(fp16); }); in expectMultinomialDistributionWithinTolerance()