This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
RE: GC_enable_incremental()
- From: "Boehm, Hans" <hans dot boehm at hp dot com>
- To: "'Andrew Haley'" <aph at redhat dot com>,"Boehm, Hans" <hans dot boehm at hp dot com>
- Cc: Bryce McKinlay <mckinlay at redhat dot com>,"'DHollenbeck'" <dick at softplc dot com>, java at gcc dot gnu dot org
- Date: Wed, 8 Sep 2004 17:42:04 -0700
- Subject: RE: GC_enable_incremental()
We could. The collector used to encourage that, but it turns out
it's actually a bit tricky if system calls block for multiple
GCs, etc.
I think it's not terribly hard to ensure that
1) We don't really turn on incremental GC unless the page size is
such that pointer-free objects do not have to be protected.
2) System calls only write to objects that the collector knows
are pointer-free, or that are not in the collected heap.
I think we do at least 95% of (2). And it's probably easy to
do the other 5%. It's just that nobody has ever checked carefully.
Hans
> -----Original Message-----
> From: Andrew Haley [mailto:aph@redhat.com]
> Sent: Wednesday, September 08, 2004 8:48 AM
> To: Hans Boehm
> Cc: Bryce McKinlay; 'DHollenbeck'; java@gcc.gnu.org
> Subject: Re: GC_enable_incremental()
>
>
> Hans Boehm writes:
> >
> > The problem isn't really a system call writing pointers. The
> > problem is that if a system call writes into the heap, the GC needs
> > to have been told in advance that that section of memory is
> > pointerfree. Otherwise the system call may fail, since the memory
> > may not be writable.
>
> Interesting. Could we not intercept system calls?
>
> Andrew.
>