Bug 196764

Summary: Date.setDate is too slow in WKWebView
Product: WebKit Reporter: chenfeng <348018533>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: fpizlo, keith_miller, msaboff, saam, webkit-bug-importer, ysuzuki
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

chenfeng
Reported 2019-04-10 00:20:38 PDT
var sTime = Date.now(); var curTime = new Date(); for (var i = 0; i < 10000; i++) { curTime.setDate(i); } console.log(Date.now() - sTime) The execution time of the above code in different browsers: Wkwebview: 16000ms Safari: 120ms Chrome: 3ms
Attachments
Radar WebKit Bug Importer
Comment 1 2019-04-12 10:13:47 PDT
Yusuke Suzuki
Comment 2 2021-02-01 02:34:16 PST
Now, Safari's perf is on per to Chrome. Note: previously, JSC uses localtime_r. But this is super slow. Now we use ICU instead. *** This bug has been marked as a duplicate of bug 218348 ***
Note You need to log in before you can comment on or make changes to this bug.