Closed
Bug 870541
Opened 12 years ago
Closed 7 years ago
B2G: Slow script mechanism uses wall clock time, could cause lower priority background processes to have scripts aborted
Categories
(Core :: XPConnect, defect, P2)
Tracking
()
RESOLVED
INCOMPLETE
blocking-b2g | - |
People
(Reporter: bent.mozilla, Unassigned)
References
Details
(Keywords: perf, Whiteboard: [c= p= s= u=])
While chatting about bug 870043 jlebar realized that we could be shooting ourselves in the foot here. The slow script mechanism uses wall clock time and that could cause lower priority background processes to have their scripts aborted even though they haven't really run for very long. We need something better, maybe counting js instructions or per-thread CPU time?
Reporter | ||
Updated•12 years ago
|
blocking-b2g: --- → leo?
Comment 1•12 years ago
|
||
Since nobody looks at the "Platform" field: This bug is specifically about b2g.
Updated•12 years ago
|
Summary: Slow script mechanism uses wall clock time, could cause lower priority background processes to have scripts aborted → B2G: Slow script mechanism uses wall clock time, could cause lower priority background processes to have scripts aborted
Comment 2•12 years ago
|
||
This sounds like a useful enhancement but not something we'd block release on without partner request for it. We can track, and look at an uplift nomination when one is ready. Also putting c= to get this into scrum backlog.
Updated•11 years ago
|
Priority: -- → P2
Comment 4•11 years ago
|
||
Ben,
Since bug 870043 comment 31, the slow script watchdog has been disabled on B2G. Is that bug still valid?
Flags: needinfo?(bent.mozilla)
Comment 5•11 years ago
|
||
My understanding was that it was disabled on the b2g-18 branch but it's still enabled for b2g on trunk, and will remain so after bholley fixes up the watchdog mechanism in bug 870043.
Comment 6•11 years ago
|
||
(In reply to Johnny Stenback (:jst, jst@mozilla.com) from comment #5)
> My understanding was that it was disabled on the b2g-18 branch but it's
> still enabled for b2g on trunk, and will remain so after bholley fixes up
> the watchdog mechanism in bug 870043.
Yeah. That bug is just waiting for inbound to open, and then it'll land.
Reporter | ||
Updated•11 years ago
|
Flags: needinfo?(bent.mozilla)
Comment 7•11 years ago
|
||
Do we have a JS "tick" that would be available to use? I couldn't find anything in the documentation or the code.
Nor could I find something that could give me the "cpu time" in the thread APIs.
Comment 8•11 years ago
|
||
Bobby, do you have an idea or do you know who might have? (comment 7)
Thanks.
Flags: needinfo?(bobbyholley+bmo)
Comment 9•11 years ago
|
||
I have no idea. Kyle might know.
Flags: needinfo?(bobbyholley+bmo) → needinfo?(khuey)
I don't understand the question. What does "tick" mean?
Flags: needinfo?(khuey)
Comment 11•11 years ago
|
||
Tick is something about elapsed time (clock ticking). I don't really know how you'd call it.
To know if the JS runtime has done something, unrelated to actual elapsed time from the clock, because we my not run all the time.
Ok, you should ask the JS team then. Not sure why bholley needinfoed me ...
Comment 13•11 years ago
|
||
The JS engine doesn't really have a way to measure time than actual elapsed time.
Comment 14•11 years ago
|
||
Thanks. I was afraid that this was the case.
Comment 15•11 years ago
|
||
I think it is a bit out of are of expertise and think that this should be handled by the JS team.
Assignee: hub → nobody
Comment 16•11 years ago
|
||
Hi Ben, since bug 870043 resolved some of the watchdog timer issues, is this bug still an issue?
Flags: needinfo?(bent.mozilla)
Reporter | ||
Comment 17•11 years ago
|
||
Yes, as far as I know the issue is unresolved. The slow script dialog relies on wall clock time and we have no way to know if any actual work was done between two arbitrary wall clock times.
Reporter | ||
Updated•11 years ago
|
Flags: needinfo?(bent.mozilla)
Updated•7 years ago
|
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•