heap headers

Matthew Fluet fluet@research.nj.nec.com
Mon, 14 Aug 2000 15:04:04 -0400 (EDT)

> > > On an unrelated note, does any code besides the GC ever look at the headers
> > > of heap objects?  I.e., suppose I went to a generational GC and I wanted
> > > small things ('a * 'b and 'a list where 'a and 'b require indirection) to be
> > > stored in older generations without the 1 word header.  Would that work or would
> > > some generated code get screwed up.
> > 
> > None of the generated code looks at headers, IIRC.  All of the code that does is 
> > in gc.c, I think.  The only other thing I can think of besides the gc is
> > saveWorld and size.
> I just remebered that size does rely on having a mark bit in each header word so 
> that it can do a dfs traversal of an object.  I like having size around, so
> maybe we could think of a fix.

Doesn't size also need the header word to determine which fields are
pointers for the traversal?  (But, I guess that information must be around
somewhere.  I'm not quite following where Henry is going with a
generational GC without headers; my thought had been that you could
sub-heap everything with the same header word together and then only need
one header word for the whole group.)