From: "M. Edward (Ed) Borasky" Date: 2007-12-27T05:28:02+09:00 Subject: Re: Destroying an Object tekwiz wrote: > On Dec 26, 11:18 am, Tim Hunter wrote: >> Ken A. wrote: >>> Tim Hunter wrote: >>>> Ken Awamura wrote: >>> Does ruby's garbage collector really work, or it's as lame as .NET >>> garbage collector? >> It really works. > > That's not entirely correct. The newest .NET GC uses an algorithm > that is actually more efficient than the inefficient Mark and Sweep GC > algorithm that Ruby uses. However, Ruby's GC is much less buggy > than .NET's in my experience. > > -- > Travis > > Well ... I think some universities still give degrees for garbage collector research, although hopefully not PhDs any more. ;) But seriously, folks, there is so much research out there that statements like "as lame as .NET" or "the inefficient Mark and Sweep GC" aren't particularly informative. In any event, there are efficient Mark Sweep GCs, inefficient Stop Copy GCs, generational GCs, compacting vs. non-compacting GCs, GCs that attempt to work with the OS memory management rather than independent of it, etc. For Ruby, I suspect the jRuby/JVM garbage collector is probably the best one out there, simply because it has more person-decades invested in it than the ones in MRI or KRI. So there are indeed "opportunities" for the GC experts.