GR740-UM-DS, Nov 2017, Version 1.7
84
www.cobham.com/gaisler
GR740
table 63). Add, sub and multiply can be started on every clock cycle, providing high throughput for
these common operations. Divide and square-root operations have lower throughput and higher
latency due to complexity of the algorithms, but are executed in parallel with all other FP operations
in a non-blocking iteration unit. Out-of-order execution of operations with different latencies is easily
handled through the GRFPU interface by assigning an id to every operation which appears with the
result on the output once the operation is completed.
Conversion operations execute in a pipelined execution unit and have throughput of one clock cycle
and latency of four clock cycles. Conversion operations provide conversion between different float-
ing-point numbers and between floating-point numbers and integers.
Comparison functions offering two different types of quiet Not-a-Numbers (QNaNs) handling are
provided. Move, negate and absolute value are also provided. These operations do not ever generate
unfinished exception (unfinished exception is never signaled since compare, negate, absolute value
and move handle denormalized numbers).
8.2.3
Exceptions
GRFPU detects all exceptions defined by the IEEE-754 standard. This includes detection of Invalid
Operation (NV), Overflow (OF), Underflow (UF), Division-by-Zero (DZ) and Inexact (NX) excep-
tion conditions. Generation of special results such as NaNs and infinity is also implemented. Over-
flow (OF) and underflow (UF) are detected before rounding. If an operation underflows the result is
flushed to zero (GRFPU does not support denormalized numbers or gradual underflow). A special
Unfinished exception (UNF) is signaled when one of the operands is a denormalized number which is
not handled by the arithmetic and conversion operations.
8.2.4
Rounding
All four rounding modes defined in the IEEE-754 standard are supported: round-to-nearest, round-to-
+inf, round-to--inf and round-to-zero.
8.2.5
Denormalized numbers
Denormalized numbers are not handled by the GRFPU arithmetic and conversion operations. A sys-
tem (microprocessor) with the GRFPU could emulate rare cases of operations on denormals in soft-
ware using non-FPU operations. A special Unfinished exception (UNF) is used to signal an arithmetic
or conversion operation on the denormalized numbers. Compare, move, negate and absolute value
operations can handle denormalized numbers and do not raise the unfinished exception. GRFPU does
not generate any denormalized numbers during arithmetic and conversion operations on normalized
numbers. If the infinitely precise result of an operation is a tiny number (smaller than minimum value
representable in normal format) the result is flushed to zero (with underflow and inexact flags set).
Table 63.
: Throughput and latency
Operation
Throughput
Latency
FADDS, FADDD, FSUBS, FSUBD, FMULS, FMULD, FSMULD
1
4
FITOS, FITOD, FSTOI, FSTOI_RND, FDTOI, FDTOI_RND, FSTOD,
FDTOS
1
4
FCMPS, FCMPD, FCMPES, FCMPED
1
4
FDIVS
16
16
FDIVD
16.5 (15/18)*
16.5 (15/18)*
FSQRTS
24
24
FSQRTD
24.5 (23/26)*
24.5 (23/26)*
* Throughput and latency are data dependant with two possible cases with equal statistical possibility.