Open Bug 1446181 Opened 2 years ago Updated 8 months ago
Investigate whether or not APZ subprotocols are being leaked
59 bytes, text/x-review-board-request
According to https://developer.mozilla.org/en-US/docs/Mozilla/IPDL/Best_Practices, all subprotocols should have Send__delete__() called on them to delete them. However I don't think we're doing this for our APZ protocols such as PAPZCTreeManager and PAPZ. So in theory we might be leaking stuff. We should investigate and make sure we're cleaning up properly.
Depends on: 1446182
Priority: -- → P3
I added a printf to the APZCTreeManagerParent constructor and destructor, and it looks like we create an APZCTreeManagerParent for each tab, as expected, and they only get destroyed when the *process* they're attached to terminates. So if you happen to close the last tab in a process a bunch of them get freed. If you run with dom.ipc.processCount=1 then none of them get freed until shutdown. So yeah, this seems like a leak we should fix. I haven't checked PAPZ yet.
See Also: → 1469887
Looks like PAPZ is fine, when the RemoteContentController is destroyed it sends a destroy message at  which does a Send__delete__ at .  https://searchfox.org/mozilla-central/rev/28daa2806c89684b3dfa4f0b551db1d099dda7c2/gfx/layers/ipc/RemoteContentController.cpp#405  https://searchfox.org/mozilla-central/rev/28daa2806c89684b3dfa4f0b551db1d099dda7c2/gfx/layers/ipc/APZChild.cpp#99
Assignee: nobody → bugmail
Comment on attachment 8990778 [details] Bug 1446181 - Send __delete__ messages when destroying APZCTreeManagerChild instances. https://reviewboard.mozilla.org/r/255830/#review262626
Attachment #8990778 - Flags: review?(rhunt) → review+
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/autoland/rev/5b8041f7f604 Send __delete__ messages when destroying APZCTreeManagerChild instances. r=rhunt
I'm going to back this out until I have time to fully investigate the crashes this introduced (bug 1475039). I took a quick look but I didn't see anything obvious, so this will take some debugging. In the meantime, transient leaks are better than crashes.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Backout by email@example.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/fe0653a84312 Back out cset 5b8041f7f604 for introducing a low-volume crash. r=me
9 months ago
8 months ago
No longer blocks: 1465658
You need to log in before you can comment on or make changes to this bug.