> > In article you wrote: > >clone(). Therefore we have stacks separated by OS, and this is OS > >responsibility to reallocate them and protect them. I couldn't find in the > >JVM specification any reason to have possibility of reference from one > >process (thread) to another process' stack. > > How do you handle GC using this method? The GC thread needs to be able to > walk all other thread stacks. > There are other implementation alternatives. For instance, each thread could perform its own stack scanning and report the result back to the gc thread. Or there could be no gc thread at all and the threads cooperate to perform a gc. In fact, I think that there's no real good reason to even have a separate gc thread unless you're allowing for asynchronous gc. - Godmar