Closed Bug 1503003 Opened 2 years ago Closed 2 years ago

Disable process priority manager for xpcshell tests


(Core :: DOM: Content Processes, enhancement)

Not set



Tracking Status
firefox66 --- fixed


(Reporter: dthayer, Assigned: mconley)




(1 file)

Taking this for now.
Assignee: nobody → mconley

So the remaining failures, at least as far as I can tell, are xpcshell test failures in the toolkit/components/extensions/test/xpcshell/ directory, with: application crashed [@ mozilla::ipc::MessageChannel::Close()]

which, I think, might be related to both bug 1451192 and bug 1465092.

Having debugged this a tiny bit and discussed things with asuth, I suspect what's happening is this:

I'm hitting this assertion:

I think what's happening is that the parent sends a "goodbye" message to the content process for the PBackground protocol. The child receives it, and the channel is marked as closing. Here:

Then... something happens in the child, maybe a queued task to try to communicate over PBackground, and it fails and hits MessageChannel::NotifyMaybeChannelError, and because the channel was closing, we transition to the ChannelClosed state:

Then we shut down the content process, and fire the xpcom-shutdown-threads observer notification, and we enter here:

we call this ThreadLocalDestructor thing here:, which causes us to try to close the channel again here:
and attempting to close an already closed channel causes us to explode.

See Also: → 1451192, 1465092

I actually have a much simpler solution.

I don't actually think it makes any sense to have the process priority manager enabled during xpcshell tests. The process priority manager only fiddles process priority when a tab becomes active in a content process, and xpcshell tests never have tabs. So they'd all be in the low priority state, which is definitely not desirable.

I think the best way forward here is probably to just disable the process priority manager when running xpcshell tests.

Summary: Fix remaining extensions test failures with dom.ipc.processPriorityManager.enabled on → Disable process priority manager for xpcshell tests
Pushed by
Disable the process priority manager when running xpcshell tests. r=gsvelto
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla66
You need to log in before you can comment on or make changes to this bug.