FSGNJX.D

Float Sign Injection XOR (Double)

FSGNJX.D rd, rs1, rs2

Injects the XOR of signs of rs1 and rs2 (Double Precision).

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[rs1][63] ^ F[rs2][63], F[rs1][62:0]};

Example

FSGNJX.D t0, a0, a1

Encoding

Binary Layout
0010001
31:25
rs2
24:20
rs1
19:15
010
14:12
rd
11:7
1010011
6:0
 
Format R-Type
Opcode 0x53
Extension D

Operands

  • rd
    Destination register (integer)
  • rs1
    Source register 1 (integer)
  • rs2
    Source register 2 (integer)