FROUND.S
Float Round to Integer
FROUND.S rd, rs1, rm
Rounds a float to the nearest integer value (returned as a float).
Details
Rounds the single-precision (32-bit) floating-point value in rs1 to an integer value (still in FP format), using the rounding mode in the rm field. The result preserves the FP type.
Pseudocode Operation
F[rd] = round(F[rs1]);
Example
FROUND.S t0, a0, rm
Encoding
Binary Layout
010000000100
31:20
rs1
19:15
rm
14:12
rd
11:7
1010011
6:0
Operands
-
rd
Destination register (integer) -
rs1
Source register 1 (integer) -
rm
Mode