37
edits
No edit summary  | 
				|||
| Line 9: | Line 9: | ||
Any cycle-collecting algorithm must satisfy a few constraints imposed by the environment.  | Any cycle-collecting algorithm must satisfy a few constraints imposed by the environment.  | ||
* Some objects will never be upgraded to participate in cycle collection. The mechanism must not break if it is applied to only a subset of the objects in the graph.  | |||
* XPCOM objects cannot generally be freed in any consistent fashion, such as by calling "operator delete". Objects should be made to "self destruct" by having all their ''incoming'' edges drop.  | |||
* Adding gratuitous new interfaces, vtables, or pointer state is probably too expensive.  | |||
== A basic cycle collection algorithm ==  | == A basic cycle collection algorithm ==  | ||
edits