bug 1015:deferring the TODO, it can wait. spelling. whitespace
[libreriscv.git] / openpower / sv / int_fp_mv / cvt_fp_to_int_overview.mdwn
index 3187d5322cf6ea0a7ec480a552a1dae693f1aac0..e9be58c36c2fd530945af5f877a9be700b570369 100644 (file)
@@ -2,7 +2,7 @@
 
 <div id="fpr-to-gpr-conversion-mode"></div>
 
-IEEE 754 doesn't specify what results are obtained when converting a NaN
+IEEE 754 does not specify what results are obtained when converting a NaN
 or out-of-range floating-point value to integer, so different programming
 languages and ISAs have made different choices.  The different conversion
 modes supported by the `cffpr` instruction are as follows:
@@ -53,26 +53,26 @@ modes supported by the `cffpr` instruction are as follows:
 
 ### Floating-point to Integer Conversion Semantics Summary
 
-Let `rounded` be the result of `bfp_ROUND_TO_INTEGER(rmode, input)`.
+Let `round` be the result of `bfp_ROUND_TO_INTEGER(rmode, input)`.
 Let `w` be the number of bits in the result's type.
 The result of Floating-point to Integer conversion is as follows:
 
 ```
-+--------+------------+-----------------------------------------------------------------------+
-| Type   | Result's   | Category of rounded                                                   |
-|        | Signedness +-----------+-----------+-----------+-----------+-----------+-----------+
-|        |            | NaN       | +Infinity | -Infinity | > Maximum | < Minimum | Otherwise |
-|        |            |           |           |           | Possible  | Possible  |           |
-|        |            |           |           |           | Result    | Result    |           |
-+--------+------------+-----------+-----------+-----------+-----------+-----------+-----------+
-| P-Type | Unsigned   | 0         | 2^w - 1   | 0         | 2^w - 1   | 0         | rounded   |
-|        +------------+-----------+-----------+-----------+-----------+-----------+-----------+
-|        | Signed     | -2^(w-1)  | 2^(w-1)-1 | -2^(w-1)  | 2^(w-1)-1 | -2^(w-1)  | rounded   |
-+--------+------------+-----------+-----------+-----------+-----------+-----------+-----------+
-| S-Type | Unsigned   | 0         | 2^w - 1   | 0         | 2^w - 1   | 0         | rounded   |
-|        +------------+-----------+-----------+-----------+-----------+-----------+-----------+
-|        | Signed     | 0         | 2^(w-1)-1 | -2^(w-1)  | 2^(w-1)-1 | -2^(w-1)  | rounded   |
-+--------+------------+-----------+-----------+-----------+-----------+-----------+-----------+
-| E-Type | Either     | 0                                 | rounded & (2^w - 1)               |
-+--------+------------+-----------------------------------+-----------------------------------+
++------+------+---------------------------------------------------------------+
+|Type| Result | Category of rounding                                          |
+|    | Sign   +----------+-----------+----------+-----------+---------+-------+
+|    |        | NaN      | +Inf      | -Inf     | > Max     | < Min   | Else  |
+|    |        |          |           |          | Possible  | Possible|       |
+|    |        |          |           |          | Result    | Result  |       |
++----+--------+----------+-----------+----------+-----------+---------+-------+
+|  P |Unsigned| 0        | 2^w - 1   | 0        | 2^w - 1   | 0       | round |
+|    +--------+----------+-----------+----------+-----------+---------+-------+
+|    | Signed | -2^(w-1) | 2^(w-1)-1 | -2^(w-1) | 2^(w-1)-1 | -2^(w-1)| round |
++----+--------+----------+-----------+----------+-----------+---------+-------+
+|  S |Unsigned| 0        | 2^w - 1   | 0        | 2^w - 1   | 0       | round |
+|    +--------+----------+-----------+----------+-----------+---------+-------+
+|    | Signed | 0        | 2^(w-1)-1 | -2^(w-1) | 2^(w-1)-1 | -2^(w-1)| round |
++----+--------+----------+-----------+----------+-----------+---------+-------+
+|  E | Either | 0                               | round & (2^w - 1)           |
++----+--------+---------------------------------+-----------------------------+
 ```