Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fcvt.w.d rounds incorrectly in rmm mode #26

Open
michael-roe opened this issue Feb 4, 2020 · 0 comments
Open

fcvt.w.d rounds incorrectly in rmm mode #26

michael-roe opened this issue Feb 4, 2020 · 0 comments

Comments

@michael-roe
Copy link

Here's a test case:

_start:
lui ra, 2
csrs mstatus, ra
_test:
li t0, 0x40e6a09e66689b2e
fmv.d.x f0, t0
fcvt.w.d a0, f0, rmm

Piccolo rounds down to 0xb504, while spike rounds up to 0xb505. I believe that spike is correct.

(If you're wondering where the strange constant came from, it's sqrt(MAXINT), but I think that isn't important for this bug).

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

No branches or pull requests

1 participant