dest = ( float ) ( unsigned long ) src;
This instruction converts the signed longword (32-bit) integer stored in src into a single-precision floating-point number and places the result in dest. Rounding of the result is in accord with the setting of the RM[1:0] bits in the FPSW. 00000000h is handled as +0 regardless of the rounding mode. You can assemble assembly-language code that includes this instruction if you have specified the assembler option -isa with selection of the instruction set of the RXv2 or a later version.
* For the RX Family assembler manufactured by Renesas Electronics Corp., enter a scaled value (the actual value multiplied by 2 when the size extension specifier is .W or .UW, or by 4 when the specifier is .L) as the displacement value (dsp:8, dsp:16). With dsp:8, values from 0 to 510 (255 × 2) can be specified when the size extension specifier is .W or .UW, or values from 0 to 1020 (255 × 4) when the specifier is .L. With dsp:16, values from 0 to 131070 (65535 × 2) can be specified when the size extension specifier is .W or .UW, or values from 0 to 262140 (65535 × 4) when the specifier is .L. The value divided by 2 or 4 will be stored in the instruction code. |
Z : The flag is set if the result of the operation is 0; otherwise it is cleared.
S : The value of the flag is 0.
CV : The value of the flag is 0.
CO : The value of the flag is 0.
CZ : The value of the flag is 0.
CU : The value of the flag is 0.
CX : The flag is set if an inexact exception is generated; otherwise it is cleared.
CE : The value of the flag is 0.
FX : The flag is set if an inexact exception is generated, and otherwise left unchanged.
The FX flag does not change if the exception enable bit EX is 1. The S and Z flags do not change when an exception is generated. |