FSGNJ.S
Float Sign Injection (Single)
FSGNJ.S rd, rs1, rs2
Injects the sign of rs2 into rs1. Used to copy values or manipulate signs.
Details
Produces a result with the magnitude of rs1 and the sign bit taken from the source rs2. Used to implement floating-point absolute value, negate, and copy-sign.
Pseudocode Operation
F[rd] = {F[rs2][31], F[rs1][30:0]};
Example
FSGNJ.S f1, f2, f3
Encoding
Binary Layout
0010000
31:25
rs2
24:20
rs1
19:15
000
14:12
rd
11:7
1010011
6:0
Operands
-
rd
Destination register (integer) -
rs1
Source (Body) -
rs2
Source (Sign)