Nios II Custom Instruction User Guide

ID 683242
Date 4/27/2020
Public
Document Table of Contents

6.2. Floating Point Hardware 2 IEEE 754 Compliance

FPH2 operations are compliant with the IEEE 754-2008 standard, except for the following:
  • No traps/exceptions.
  • No status flags.
  • Remainder and conversions between binary and decimal operations are not supported. These are provided by the software emulation library.
  • No support for round-to-nearest-even mode. Nearest Rounding, Truncation Rounding, or Faithful Rounding is used, depending on the operator.
  • Subnormals are not supported by the add, subtract, multiply, divide, and square root operations. Subnormal inputs are treated as signed zero and subnormal outputs are never created (result is signed zero instead). This treatment of subnormal values called flush-to-zero.7
  • Subnormals cannot be created by the integer2float conversion operation. This behavior is IEEE 754 compliant.
  • No distinction between signaling and quiet NaNs as input operands. Any result that produces a NaN may produce either a signaling or quiet NaN.
  • A NaN result with one or more NaN input operands is not guaranteed to return any of the input NaN values; the NaN result can be a different NaN than the input NaNs.
7 Subnormals are supported by comparison, minimum, maximum, float-to-integer, negate, and absolute operations, so these operations are IEEE 754-2008 compliant.