Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!uwm.edu!ux1.cso.uiuc.edu!uxc.cso.uiuc.edu!uxc.cso.uiuc.edu!m.cs.uiuc.edu!madany From: madany@m.cs.uiuc.edu Newsgroups: comp.sw.components Subject: Re: Garbage Collection & ADTs Message-ID: <71800001@m.cs.uiuc.edu> Date: 28 Sep 89 23:21:27 GMT References: <6530@hubcap.clemson.edu> Lines: 17 Nf-ID: #R:hubcap.clemson.edu:6530:m.cs.uiuc.edu:71800001:000:873 Nf-From: m.cs.uiuc.edu!madany Sep 27 20:13:00 1989 /* Written 8:29 pm Sep 26, 1989 by jesup@cbmvax.UUCP in m.cs.uiuc.edu:comp.sw.components */ >> But GC is unlikely to reclaim that storage. Yes, the graph no longer >> has pointers to the disconnected subgraph. However, the subgraph may be >> circular (you said it was cyclic), so all the nodes of the subgraph may still >> have references to them. Can current GC systems recognize such a loop and >> remove it in it's entirety? How complex can such a loop be and still be >> recognized? /* End of text from m.cs.uiuc.edu:comp.sw.components */ GC does reclaim the storage. That's one of the big reasons why people advocate it. A good garbage collector will reclaim loops of ANY complexity IFF they are garbage. I don't have the best reference handy, but page 682 of "Smalltalk-80 The Language and its Implementation" may give you a hint as to how such GC works.