Various datatypes in GEMM
Review GEMM datatypes.
To convert the binary representation of a number to a decimal, we use the following formula: $(-1)^{sign} \times 2^{exponent-bias} \times 1.mantisa$
Normalized numbers have the implicit leading binary digit is a 1. To reduce the loss of precision when an underflow occurs, IEEE 754 includes the ability to represent fractions smaller than are possible in the normalized representation, by making the implicit leading digit a 0. Such numbers are called denormal/subnormal. They don't include as many significant digits as a normalized number, but they enable a gradual loss of precision when the result of an operation is not exactly zero but is too close to zero to be represented by a normalized number.
A denormal number is represented with a biased exponent of all 0 bits, which represents, for example, an exponent of -126 in single precision (not -127), or -1022 in double precision (not -1023). In contrast, the smallest biased exponent representing a normal number is 1.
There are three kinds of operations that can return NaN: