From: Peter Suk Date: 2005-04-09T03:09:34+09:00 Subject: Re: Seven new VMs, all in a row On Apr 8, 2005, at 12:39 PM, Charles Mills wrote: > Peter Suk wrote: >> Generational GC. (So you're not at the mercy of the system's malloc > & >> free) > > A generational GC would be great. There has been talk of including one > in the next version of the Ruby interpreter. However C extensions also > pose a problem here as well - it seems creating a write barrier that > works with C libraries not written originally with Ruby in mind will be > very difficult/slow. VisualWorks gets around this and also solves problems the paradox with not having "real" threads, wanting to do GC efficently, yet also wanting to do synchronous calls to the OS. The dilemma is this: You want real threads so your VM can utilize synchronous calls to the OS. However, this complicates GC immensely. (ObjectStudio Smalltalk lost a lot of performance because of having real threads. When it was time to GC, the main VM thread would have to raise a flag and wait for all the other threads to detect it.) VisualWorks can use real threads, but only in the case of calling out to a DLL, and these contexts are exempt from GC. This gives you the ability to make synchronous calls without freezing the entire image, yet also leaves your GC simple and fast. --Peter -- There's neither heaven nor hell, save what we grant ourselves. There's neither fairness nor justice, save what we grant each other.