alexcrichton commented on issue #4517:
Since this is just for the interpreter one possibility would be to use
libm::fma
which is a port of musl's implementation to Rust which should provide stability across platforms perhaps.
afonso360 commented on issue #4517:
libm's
fma
seems a lot better than MinGW's and it think it's implementation is correct.However, CI's still failing and I can't quite pin down why.
libm
disagrees with the nativefmadd
instruction inaarch64
by exactly 1 bit, in the failing input. This seems like a rounding issue somewhere,libm
has the LSB as 1 andfmadd
has it as 0.I've checked
fegetround
and we are running with the default rounding mode.The other weird issue is that when I try to extract the failing input into a separate rust program and execute there, everything works and I get the correct result that agrees with the native instructions.
I'll keep looking into this, but if anyone has any ideas, let me know.
afonso360 edited a comment on issue #4517:
libm's
fma
seems a lot better than MinGW's we are now only off by 1 LSB.I've filed https://github.com/rust-lang/libm/issues/263 to follow up with libm.
afonso360 commented on issue #4517:
@alexcrichton since there is no way to know how long this is going to take with libm. What do you think about disabling the interpreter on the
fma
tests temporarily?An alternative could be to have a reduced set of inputs that does not fail in a separate file.
That way we can resolve this now and move ahead with the CI upgrades.
alexcrichton commented on issue #4517:
Sounds reasonable to me, thanks for helping to push on this @afonso360!
Last updated: Nov 22 2024 at 16:03 UTC