[gclist] GC in a Windows NT/95 threaded environment
Charles Fiterman
cef@geode.geodesic.com
Wed, 13 Nov 1996 12:00:11 +0000
A
>I apologize for my very cryptic question. Here are the details. I am
>implementing a multi-threaded Smalltalk interpreter where a Smalltalk
>process is mapped to a win32 thread. Garbage collection can be
>triggered by any thread and all other threads are stopped and a
>conservative stop-and-copy gc is done. The problem I am facing is with
>thread specific data. Windows NT/95 do not allow one thread to access
>another thread in any documented form as far as I know. I think I can
>get at the thread data by resorting to undocumented data structure
>access and I am wondering if someone has a better solution.
Look up SuspendThread & ResumeThread
>At one time, I considered doing a write-barrier based gc and did not
>pursue it based on concerns of efficiency. Is it that a better gc
>algorithm for a multi-threaded tool?
We've had very bad luck with write barrier based gc as far as
efficiency is conserned. The exception is C++ pointer wrappers
where the write barrier is simply on the pointer. Our best luck
has been with gcAttemptCollection( userIdleDetectFunction ); That
is calling for a collection but trashing it if interaction is
required. In real world applications this works very well.
Charles Fiterman Geodesic Systems
Phone 312-728-7196 4745 N. Ravenswood Suite 111
Fax 312-728-6096 Chicago Il 60015
A computer language without garbage collection is
like a city without garbage collection.