-
Notifications
You must be signed in to change notification settings - Fork 478
Open
Description
VexRiscv FSGNJX.D Sign Bit Wrong
Reproduction
- Setup: RV32 + FD VexRiscv; run the same program on Spike for reference.
- Sequence:
li x2, 0xe1f08df2;fmv.w.x f20, x2→ f20 = 0xffffffffe1f08df2 (sign = 1).li x2, 0xc051749b;fmv.w.x f25, x2→ f25 = 0xffffffffc051749b (sign = 1).fsgnjx.d f25, f25, f20.- Store f25 to memory or read the register to check the result.
Issue
- Spike: f25 becomes 0x7fffffffc051749b; the sign bit is XORed to 0 as the spec requires.
- VexRiscv: f25 stays 0xffffffffc051749b; the sign bit does not flip, violating FSGNJX.D semantics.
Metadata
Metadata
Assignees
Labels
No labels