This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: GC failure w/ THREAD_LOCAL_ALLOC ?
- From: Michael Smith <msmith at spinnakernet dot com>
- To: "Boehm, Hans" <hans_boehm at hp dot com>
- Cc: "'Jeff Sturm '" <jsturm at one-point dot com>, "''Bryce McKinlay ' '"<bryce at waitaki dot otago dot ac dot nz>, "'''java at gcc dot gnu dot org' ' '"<java at gcc dot gnu dot org>
- Date: Wed, 27 Mar 2002 15:42:58 -0500
- Subject: Re: GC failure w/ THREAD_LOCAL_ALLOC ?
- References: <40700B4C02ABD5119F000090278766443BF0E2@hplex1.hpl.hp.com>
Boehm, Hans wrote:
> Can you put a breakpoint in close() to verify that the descriptor is being
> closed by a finalizer?
>
> If you can repeat this, and the GC is responsible, and you can figure out
> which object is getting collected, a good thing to do is to put a breakpoint
> in GC_finish_collection() during the offending GC, and then invoke
> GC_is_marked() on all objects in the reference chain from the debugger, with
> the process still stopped in GC_finish_collection. If you find a marked
> object pointing to an unmarked one, it would be good to know the results of
>
> print *GC_find_header(<last marked>)
>
> If it's a gcj object, so would the mark descriptor.
>
> I'm also suspicious that this is a completely separate problem, possibly
> outside the GC.
After a bit of investigation, I can confidently say that the GC is not
collecting objects prematurely, causing my /dev/urandom file descriptor
to get closed.
It turns out, I was hitting a double-close related to a failed Process
exec, which had been fixed in CVS since I got my version. I've pulled
down the patches to natPosixProcess.cc, applied them to my local tree
and my file descriptors are no longer disappearing unexpectedly.
thanks,
michael