Skip to content

Add one-way Zfh format-conversion tests - #671

Merged
aswaterman merged 1 commit into
riscv-software-src:masterfrom
vera-rubin:fix/zfh-one-way-conversions
Oct 14, 2026
Merged

aswaterman merged 1 commit into
riscv-software-src:masterfrom
vera-rubin:fix/zfh-one-way-conversions

Conversation

@vera-rubin

Copy link
Copy Markdown
Contributor

Round-trip Zfh checks of final half-precision bits and flags let paired raw register copies pass.

We check FCVT.S.H, FCVT.H.S, FCVT.D.H and FCVT.H.D one way on exactly representable -1.5 inputs, destination bits and zero exception flags. The RV32 wrapper inherits single/half cases.

Version: riscv-tests 7b68f7b91f827f8d94cc1c57ff123752c5c8f704, riscv-test-env 6de71edb142be36319e380ce782c3d1830c65d68, Spike 17e8a69fb75546dea445cfc0fb78769d2510f339, RISC-V GCC 13.2.0, GNU assembler 2.42.

66 selected RV32/RV64 F/D/Zfh scalar p-environment programs pass before and after, with RV32 Zfh selected explicitly because the Makefile omits its Makefrag. Synthetic raw-copy faults pass the old tests and fail the new ones.

Fixes #670

— ChipLab

@aswaterman
aswaterman merged commit d7e86f7 into riscv-software-src:master Oct 14, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Zfh format-conversion round trips pass when the conversions copy raw bits

2 participants