[gclist] Compiler specialized GC's

Dave Lloyd dave@occl-cam.demon.co.uk
Fri, 1 Mar 96 17:27:43 BST


Charles Fiterman wrote:
> > Our GC generates a marking routine for each type in the system rather than
> > interpreting a type description during GC. Makes for quite a fast 
> > traversal.
>
> Do you allow user defined mark functions. We have found those very useful. 
> The classic example is the stack where the mark function should only look in
> the live section. I have a good compiler hash table example where the table's
...

We don't have user mark functions as the type system is sufficient to find all
available pointers (we *only* trace the live stack(s) - follow up the frames, 
find where we are in the code and then check the REFmap for pointers off the 
stack). However it is an interesting idea. Particularly for finding more 
pointers than the normal GC knows where to look for. A good problem is the 
'windows words' in OS/2 PM and Windoze programming which are often used to hold
a pointer to a window class structure which is only accessed during an event 
handler and almost certainly won't exist in the normal  language address 
space. I'm less keen on the example you give as here you are lying to the GC 
that this table isn't accessible but are prepared to take the consequences if 
you access it again - I'm a bit of a runtime security junkie.

----------------------------------------------------------------------
Dave Lloyd                            Email: Dave@occl-cam.demon.co.uk
Oxford and Cambridge Compilers Ltd    Phone: (44) 1223 572074
55 Brampton Rd, Cambridge CB1 3HJ, UK