WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED CONFIGURATION CHANGED
62629
Sputnik math test cases issue
https://bugs.webkit.org/show_bug.cgi?id=62629
Summary
Sputnik math test cases issue
Mahesh Kulkarni
Reported
2011-06-14 04:39:26 PDT
Couple of Sputnik test cases are failing on all browser's fast/js/sputnik/Conformance/15_Native_Objects/15.8_Math/15.8.2/15.8.2.16_sin/S15.8.2.16_A7.html fast/js/sputnik/Conformance/15_Native_Objects/15.8_Math/15.8.2/15.8.2.18_tan/S15.8.2.18_A7.html ------------------------------------------------------------- Because "libc's sin(6.28318530717958620000) != Javascript.Math.sin(6.28318530717958620000)"!! Tested the above javascript on Chrome, Firefox, Opera and QtTestbrowser all results in, S15.8.2.16_A7 FAIL SputnikError: x = 6.283185307179586 libc.sin(x) = -2.4492935982947064e-16 Math.sin(x) = -2.4492127076447545e-16 Math.abs(libc.sin(x) - Math.sin(x)) > 1.9721522630525295e-31 ------------------------------------------------------------- Tested few online calculators (for example
http://www.calcoolate.com/
) and sin(6.283185307179586) results in same value of JS::Math.sin(). Any thoughts on how to fix this?
Attachments
Add attachment
proposed patch, testcase, etc.
Laszlo Gombos
Comment 1
2011-06-14 09:23:32 PDT
Based on my testing differences (in libc precision) on different platforms seems to cause this issue. Webkit ports on Windows and Mac seems to pass this test, but not on Linux.
Venkat Penukonda
Comment 2
2011-06-27 13:09:55 PDT
The two tests: fast/js/sputnik/Conformance/15_Native_Objects/15.8_Math/15.8.2/15.8.2.16_sin/S15.8.2.16_A7.html fast/js/sputnik/Conformance/15_Native_Objects/15.8_Math/15.8.2/15.8.2.18_tan/S15.8.2.18_A7.html pass on Safari on iOS.
Sanders Shen
Comment 3
2012-02-24 19:35:04 PST
(In reply to
comment #1
)
> Based on my testing differences (in libc precision) on different platforms seems to cause this issue. Webkit ports on Windows and Mac seems to pass this test, but not on Linux.
The linux is 32-bit linux os, right? This issue may be caused by the "sin" function of libc. On 32-bit linux os, "sin(2*PI)" would return "-0.00000000000000024492127076447545", but on 64-bit linux os, it would return "-0.00000000000000024492935982947064". So, I think these cases would be passed on 64-bit linux os.
sergey.s
Comment 4
2013-03-21 02:20:40 PDT
Corresponding bug on Ubuntu tracker
https://bugs.launchpad.net/ubuntu/+source/eglibc/+bug/1156579
Ahmad Saleem
Comment 5
2023-12-24 06:17:11 PST
These tests are gone -
https://github.com/WebKit/WebKit/commit/011fe7359898b678e31fabdc17df1ff69b910764
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug