[Webkit-unassigned] [Bug 272156] New: setInterval average delay is larger than expected when it runs in Low Power Mode or in iframe
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Apr 4 07:23:36 PDT 2024
https://bugs.webkit.org/show_bug.cgi?id=272156
Bug ID: 272156
Summary: setInterval average delay is larger than expected when
it runs in Low Power Mode or in iframe
Product: WebKit
Version: Safari 17
Hardware: iPhone / iPad
OS: iOS 17
Status: NEW
Severity: Normal
Priority: P2
Component: JavaScriptCore
Assignee: webkit-unassigned at lists.webkit.org
Reporter: fuweichin at gmail.com
Created attachment 470754
--> https://bugs.webkit.org/attachment.cgi?id=470754&action=review
setInterval test results for various platforms/browsers and conditions/modes
For global function setInterval, the average delay detected may be 30% larger than the delay parameter value when Lower Power Mode is turned on or script runs in iframe. e.g. `setInterval(()=>{}, 66.66666666666667)` may actually scheduled at interval delay of 89ms.
For average delay of setInterval implementations, I must adimit mobile Safari can make it very accurate in normal conditions, since Chrome just ignores fractional part of the delay parameter, and desktop Firefox has no self-regulation to ensure an accurate average delay.
See demo [setInterval actual interval test](https://codepen.io/fuweichin/pen/PoayPbm) and attachment [setInterval test results for various platforms/browsers and conditions/modes].
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20240404/611366fb/attachment.htm>
More information about the webkit-unassigned
mailing list