e is an unsigned 8-bit field. The bias (E) is there to let you represent both positive and negative exponents. This is a slightly saner representation than two's complement for doing actual calculations, even if it's slightly awkward to think about.
What the bias is depends on the floating-point type. For a standard IEEE float, it's 127. For a standard IEEE double, it's 1023.
Not sure what you mean. For the standard float and double types, there's an implied 1 bit before the mantissa for normal numbers and none for subnormal numbers. If you have the IEEE float whose binary representation (sign, exponent, mantissa) is
0 01111111 01110111011101110111011
, you can read this as(-1)^0 * 2^(01111111b) * 1.01110111011101110111011b
Note the leading1.
before the mantissa.
When the exponent is as small as possible (zero), you have the subnormal numbers. When the exponent as large as possible (all ones), you have infinities and NaNs. The mantissa means something diferent here. All other exponents represent "normal numbers."
For Intel's 80-bit long double
type, there is no implied 1 bit (it is stored in the high bit of the mantissa) and I can't recall what happens when you try doing arithmetic with long double
s that have a normal representation but the implied bit is switched off. I think they did this to make the x87 easier to build.