Cycle collector should traverse nsGlobalWindow::mLocalStorage

RESOLVED FIXED in mozilla14

Status

()

Core
XPCOM
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: billm, Assigned: billm)

Tracking

unspecified
mozilla14
x86_64
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

5 years ago
Created attachment 609921 [details] [diff] [review]
patch

Given that we traverse mSessionStorage, it seems like we should traverse mLocalStorage as well.

Also, with this patch, if I open and then immediately close the browser, all objects get cleaned up in one cycle collection. Without the patch, it takes two CCs.
Attachment #609921 - Flags: review?(bugs)
Comment on attachment 609921 [details] [diff] [review]
patch

You should also unlink localStorage.
Attachment #609921 - Flags: review?(bugs) → review-
(Assignee)

Comment 2

5 years ago
Created attachment 609922 [details] [diff] [review]
patch v2

Thanks, fixed.
Attachment #609921 - Attachment is obsolete: true
Attachment #609922 - Flags: review?(bugs)
Attachment #609922 - Flags: review?(bugs) → review+
Justin, this patch seems to fix at least some problems with shutdown CCs taking multiple cycles, so I'm wondering if it will fix some of the problems you saw with windows not getting killed quickly (which is why I was wondering what the bug number was so I can make this block that).
See bug 731419 comment 7.  Those comments don't really belong in that bug...

Let me know if you need me to do any testing.
(Assignee)

Comment 5

5 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/d41b23cd2359

Even with this patch, a single cycle collection rarely cleans up everything. We still have a ways to go on that.
Target Milestone: --- → mozilla14
https://hg.mozilla.org/mozilla-central/rev/d41b23cd2359
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.