Closed
Bug 1907936
Opened 2 years ago
Closed 2 years ago
ClampDoubleToUint8 incorrectly rounds towards 0
Categories
(Core :: JavaScript Engine, defect, P1)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
130 Branch
| Tracking | Status | |
|---|---|---|
| firefox130 | --- | fixed |
People
(Reporter: anba, Assigned: anba)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
Previously reported at bug 745324. The patch attached to bug 745324 is incomplete and doesn't correctly handle the case when the fractional part is .5.
| Assignee | ||
Comment 1•2 years ago
|
||
There are various ways how to implement half-to-even rounding, this C++
implementation was choosen because it's easy to translate into assembly
instructions.
- Update the x86 implementation to use half-to-even rounding when available.
- Use a single unified implementation for ARM32, because I didn't want to
spend time trying to make sense of theHasVFPv3code path which uses
fixed floating point values. - ARM64 doesn't need any changes, because it was already using
Fcvtns, which
implements half-to-even rounding.
Updated•2 years ago
|
Pushed by andre.bargull@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/e6d1732365c6
Correctly implement RoundHalfToEven in ClampDoubleToUint8. r=jandem
Comment 3•2 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
status-firefox130:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 130 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•