Use AutoEntryScript for firing setTimeout/setInterval callbacks on workers

RESOLVED FIXED in Firefox 47

Status

()

RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: bzbarsky, Assigned: bzbarsky)

Tracking

Trunk
mozilla47
Points:
---

Firefox Tracking Flags

(firefox47 fixed)

Details

(Whiteboard: btpp-active)

Attachments

(2 attachments, 2 obsolete attachments)

Currently we manually report exceptions here.  We do have an AutoEntryScript set up already from Run (the caller of TimerRunnable::WorkerRun), but we really want a separate one for each timeout callback we run.  This also allows us to provide a better execution reason string.
Created attachment 8723616 [details] [diff] [review]
Switch to using an AutoEntryScript in WorkerPrivate::RunExpiredTimeouts
Attachment #8723616 - Flags: review?(khuey)
Created attachment 8723617 [details] [diff] [review]
Diff -w for review convenience
Created attachment 8723702 [details] [diff] [review]
Patch, but with the obvious TakeOwnershipOfErrorReporting() we need
Attachment #8723702 - Flags: review?(khuey)
Attachment #8723616 - Attachment is obsolete: true
Attachment #8723616 - Flags: review?(khuey)
Attachment #8723617 - Attachment is obsolete: true
Comment on attachment 8723702 [details] [diff] [review]
Patch, but with the obvious TakeOwnershipOfErrorReporting() we need

Review of attachment 8723702 [details] [diff] [review]:
-----------------------------------------------------------------

::: dom/workers/WorkerPrivate.cpp
@@ +5963,5 @@
> +      reason = "setInterval handler";
> +    } else {
> +      reason = "setTimeout handler";
> +    }
> +    { // scope for the AutoEntryScript, so it comes off the stack before we do

nit: \n between the two scopes
Attachment #8723702 - Flags: review?(khuey) → review+
> nit: \n between the two scopes

Done.
Whiteboard: btpp-active

Comment 8

3 years ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/c10b6b14fce1
Status: NEW → RESOLVED
Last Resolved: 3 years ago
status-firefox47: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
You need to log in before you can comment on or make changes to this bug.