Closed
Bug 625873
Opened 14 years ago
Closed 6 years ago
Domain::m_parameterizedTypes should be weak
Categories
(Tamarin Graveyard :: Virtual Machine, defect)
Tamarin Graveyard
Virtual Machine
Tracking
(Not tracked)
RESOLVED
WONTFIX
Future
People
(Reporter: stejohns, Unassigned)
References
Details
Attachments
(1 file)
(deleted),
patch
|
rreitmai
:
review+
lhansen
:
superreview+
|
Details | Diff | Splinter Review |
If you ever instantive Vector<foo>, you'll be unable to unload the SWF containing foo, even if no instance remain, as there's a hard reference to foo via this table, which keeps all of the SWF in memory.
We should use WeakKeyHashtable here instead.
Also, arguably, this table should live in DomainEnv rather than Domain in the first place, since it's storing ClassClosures.
Reporter | ||
Comment 1•14 years ago
|
||
Storing in DomainEnv is a tricky problem, as we don't clearly have the correct one readily available at the point of creation; however, the essential part (a weak table) is simple (and an urgent fix for Spicy).
Reporter | ||
Comment 2•14 years ago
|
||
Assignee: nobody → stejohns
Attachment #503964 -
Flags: superreview?(edwsmith)
Attachment #503964 -
Flags: review?(rreitmai)
Comment 3•14 years ago
|
||
What stops a ClassClosure from Toplevel 1 leaking over to Toplevel2? seems like a big containment breach?
The change is obviously pretty mechanical though, nothing obviously wrong.
Reporter | ||
Comment 4•14 years ago
|
||
(In reply to comment #3)
> What stops a ClassClosure from Toplevel 1 leaking over to Toplevel2? seems
> like a big containment breach?
Yep, possibly is, I'm still pondering a followup fix for that issue. But the leak is priority #1.
Reporter | ||
Comment 5•14 years ago
|
||
Actually, this is fascinating, and a little surprising: given a ClassClosure, there doesn't seem to be an obvious way to find the AbcEnv (and thus DomainEnv) that defined it.
Reporter | ||
Comment 6•14 years ago
|
||
The current design was put in place in https://bugzilla.mozilla.org/show_bug.cgi?id=545973 -- we previously stashed thins in VectorClass, which was even leakier, apparently.
I wonder if an (even) better approach would be to move the lookup table into Toplevel, using Weak keys *and* weak values?
Reporter | ||
Comment 7•14 years ago
|
||
There may be more than meets the eye here, too: looking at the testcase that's producing the leak, it would appear that the fact that this patch "fixes" the issue means that the Domain itself is somehow leaking. Investigating...
Reporter | ||
Comment 8•14 years ago
|
||
Upon further investigation, this is almost certainly a bug in Flash's glue code, not this. Withdrawing.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
Reporter | ||
Comment 9•14 years ago
|
||
Reopening: although there is definitely a bug here on Flash's part, this fix appears to be part of the necessary solution. (ie, fixing the Flash internals solves some but not all of the leak.)
Status: RESOLVED → REOPENED
Resolution: INVALID → ---
Comment 10•14 years ago
|
||
(In reply to comment #5)
> Actually, this is fascinating, and a little surprising: given a ClassClosure,
> there doesn't seem to be an obvious way to find the AbcEnv (and thus DomainEnv)
> that defined it.
not pretty, but possible:
ClassClosure->vtable->init->abcEnv()
If needed we could add abcEnv to VTable.
Reporter | ||
Updated•14 years ago
|
Attachment #503964 -
Flags: superreview?(edwsmith) → superreview?(lhansen)
Updated•14 years ago
|
Attachment #503964 -
Flags: review?(rreitmai) → review+
Updated•14 years ago
|
Attachment #503964 -
Flags: superreview?(lhansen) → superreview+
Reporter | ||
Comment 11•14 years ago
|
||
pushed initial fix to TR 5796:25f4b2b17eca
leaving open for now to ponder if we should/can also move this table to DomainEnv.
Assignee: stejohns → nobody
Flags: flashplayer-qrb+
Flags: flashplayer-needsversioning-
Flags: flashplayer-injection-
Flags: flashplayer-bug-
Target Milestone: --- → Future
Updated•12 years ago
|
Comment 12•6 years ago
|
||
Tamarin is a dead project now. Mass WONTFIX.
Status: REOPENED → RESOLVED
Closed: 14 years ago → 6 years ago
Resolution: --- → WONTFIX
Comment 13•6 years ago
|
||
Tamarin isn't maintained anymore. WONTFIX remaining bugs.
You need to log in
before you can comment on or make changes to this bug.
Description
•