Conversation
gumb0
reviewed
Aug 7, 2020
gumb0
reviewed
Aug 7, 2020
gumb0
reviewed
Aug 7, 2020
bd3ae4a to
e5a3d18
Compare
128ebd3 to
d677203
Compare
gumb0
reviewed
Aug 10, 2020
| {-FP32::Limits::infinity(), -FP64::Limits::infinity()}, | ||
|
|
||
| // The canonical NaN must result in canonical NaN (only the top bit set). | ||
| {FP32::nan(FP32::canon), FP64::nan(FP64::canon)}, |
Collaborator
There was a problem hiding this comment.
Add -FP32::nan(FP32::canon) case
Collaborator
Author
There was a problem hiding this comment.
Add
-FP32::nan(FP32::canon)case
Added.
And anan cases?
Outside of the loop as they require sophisticated checks.
850f0d5 to
89cd563
Compare
axic
reviewed
Aug 11, 2020
6faf11b to
4fe85a3
Compare
Codecov Report
@@ Coverage Diff @@
## master #457 +/- ##
=======================================
Coverage 99.53% 99.53%
=======================================
Files 54 54
Lines 16015 16075 +60
=======================================
+ Hits 15941 16001 +60
Misses 74 74 |
gumb0
reviewed
Aug 12, 2020
| // An arithmetic NaN must result in any arithmetic NaN (payload >= canonical payload). | ||
| // The spec allows the result to be the canonical NaN, but in the current implementation it | ||
| // is not the case and the check is more restrictive than the spec requires. | ||
| const auto res1 = execute(*instance, 0, {FP32::nan(FP32::canon + 1)}); |
Collaborator
There was a problem hiding this comment.
Add also -FP32::nan(FP32::canon + 1) and -FP32::nan(1) cases
gumb0
approved these changes
Aug 12, 2020
axic
approved these changes
Aug 12, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is rather straight forward as conversion
f32tof64is lossless. The only fancy checks are forNaNvalues. Canonical NaN must be converted to canonical one, and any other NaN must be converted to any arithmetic NaN.https://webassembly.github.io/spec/core/exec/numerics.html#op-promote