tests: use identical(NA_real_+0, NA_real_) to skip tests that depend on NA payload propagation#7702
tests: use identical(NA_real_+0, NA_real_) to skip tests that depend on NA payload propagation#7702
identical(NA_real_+0, NA_real_) to skip tests that depend on NA payload propagation#7702Conversation
RISC-V chips do not propagate NaN payload through arithmetic operations.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #7702 +/- ##
=======================================
Coverage 99.04% 99.04%
=======================================
Files 87 87
Lines 17037 17037
=======================================
Hits 16874 16874
Misses 163 163 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Thanks a lot! In my understanding we do not need to fix anything else. |
There was a problem hiding this comment.
Is this truly unique to riscv64? I saw something in another thread about this platform supporting 128-bit long doubles, I think this issue is separate, right?
I also saw this might be the same as some behavior observable with {base}, could this be a behavioral skip instead? if (identical(NA+0, NaN)) something like that (sorry I didn't read very carefully)?
Basically my preference ordering here:
- Skip on a behavior observable in base R
- Skip on
capabilities() - Skip on a specific
Sys.info()entry
I trust your judgment on if either of 1/2 are feasible without inordinate effort. Thanks!
Co-Authored-By: Michael Chirico <chiricom@google.com>
identical(NA_real_+0, NA_real_) to skip tests that depend on NA payload propagation
|
Of course, you're right! Checking whether an arithmetic operation on |
RISC-V chips do not propagate NaN payload through arithmetic operations, so skip two tests on this architecture. If this surfaces again, we can modify
test()to ignoreNA/NaNdifferences on such architectures. Ironically, the tests infroll.Rrawthat are skipped on RISC-V due tolong doublesize ("under Valgrind") do pass on Valgrind now, but they probably won't pass on RISC-V (for the same reason) if enabled. Should I reuse theexact_NaNtest instead?@charles-plessy, this seems to work for me in a Trixie QEMU chroot. Does anything else need fixing?
Fixes: #7695