MMIX LOGO

MMIX Instruction Set

Table of Content

Content

Floating Point Conversion

Name:
FLOT $X,$Z FLOT $X,Z
FLOTU $X,$ZFLOTU $X,Z
FIX $X,$Z FIXU $X,$Z

Specification:
FLOT: f($X) ← s($Z)
FLOTU: f($X) ← u($Z)
FIX: s($X) ← int(f($Z))
FIXU: u($X) ← (int(f($Z)))mod264

Timing:

Description:

Converts numbers from integer representation to floating point representation and vice versa. An optional Y-Operand can be used to specify one of the following rounding modes: ROUND_OFF, ROUND_UP, ROUND_DOWN, or ROUND_NEAR.

FLOT: "convert fixed to floating". The integer in $Z or the immediate constant Z is converted to the nearest floating point value (using the current rounding mode) and placed in register $X. A floating inexact exception occurs if rounding is necessary.
FLOTU: "convert fixed to floating unsigned". FLOTU is like FLOT, but $Z is treated as an unsigned integer.
FIX: "convert floating to fixed". The floating point number in register $Z is converted to an integer as with the FINT instruction, and the resulting integer (mod 264) is placed in register $X. An invalid exception occurs if $Z is infinite or a NaN; in that case $X is simply set equal to $Z. A float-to-fix exception occurs if the result is less than −264 or greater than 264 - 1.
FIXU: "convert floating to fixed unsigned". This instruction is identical to FIX except that no float-to-fix exception occurs.

Please help to keep this site up to date! If you want to point out important material or projects that are not listed here, if you find errors or want to suggest improvements, please send email to email