WASM C standard library atan2(-1,0) is returning pi/2 instead of -pi/2
Categories
(Core :: JavaScript: WebAssembly, defect, P2)
Tracking
()
People
(Reporter: rhunt, Assigned: yury)
References
Details
Attachments
(1 file, 1 obsolete file)
48 bytes,
text/x-phabricator-request
|
diannaS
:
approval-mozilla-beta+
dmeehan
:
approval-mozilla-release+
RyanVM
:
approval-mozilla-esr91+
|
Details | Review |
Source: https://github.com/mozilla-mobile/fenix/issues/24565
According to RyanVM, this still reproduces on his Pixel 3 with Fenix Nightly.
Yury, can you take a look?
Updated•3 years ago
|
Updated•3 years ago
|
Assignee | ||
Comment 1•3 years ago
•
|
||
I can reproduce on arm64 simulator.
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Comment 2•3 years ago
|
||
Assignee | ||
Comment 3•3 years ago
|
||
The guess about copysign was the correct one: in case when rhs == output
in MacroAssembler::copySignDouble
we were overwriting rhs
by lhs
, so the operation becomes noop. The simple test case to reproduce is:
(func (param f64 f64) (result f64)
f64.const 0x1.921fb54442d18p+0 (;=1.5708;)
local.get 0
f64.copysign
)
Updated•3 years ago
|
Assignee | ||
Comment 4•3 years ago
|
||
Using defineReuseInput in LIRGenerator to avoid rhs == output case in copySignDouble().
Updated•3 years ago
|
Comment 6•3 years ago
|
||
bugherder |
Assignee | ||
Comment 7•3 years ago
|
||
Comment on attachment 9270975 [details]
Bug 1762899 - Fix {f32,f64}.copysign for Aarch64. r?lth
Beta/Release Uplift Approval Request
- User impact if declined: Some wasm application may not work properly on Aarch64 or Apple M1 hardware.
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: No
- If yes, steps to reproduce:
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): The changes only affect the code that produces the error, limited to the affected platform, and tests are provided.
- String changes made/needed:
ESR Uplift Approval Request
- If this is not a sec:{high,crit} bug, please state case for ESR consideration: Having the proper implementation of Wasm SIMD is somewhat important -- new application that use this technology are appearing on the market at this moment and could cause issues for ESRs.
- User impact if declined: Some wasm application may not work properly on Aarch64 or Apple M1 hardware.
- Fix Landed on Version: 101
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): The changes only affect the code that produces the error, limited to the affected platform, and tests are provided.
Comment 8•3 years ago
|
||
Comment on attachment 9270975 [details]
Bug 1762899 - Fix {f32,f64}.copysign for Aarch64. r?lth
Approved for 100.0b3
Comment 9•3 years ago
|
||
Comment on attachment 9270975 [details]
Bug 1762899 - Fix {f32,f64}.copysign for Aarch64. r?lth
Important ARM64 WASM correctness fix with tests. Approved for 91.9esr.
Comment 10•3 years ago
|
||
bugherder uplift |
Comment 11•3 years ago
|
||
bugherder uplift |
Comment 12•3 years ago
|
||
Comment on attachment 9270975 [details]
Bug 1762899 - Fix {f32,f64}.copysign for Aarch64. r?lth
Approved for 99.0.1 and Fenix/Focus 99.2.0
Comment 13•3 years ago
|
||
bugherder uplift |
![]() |
||
Updated•3 years ago
|
Description
•