[Gc] GC_gcj_malloc does not invoke finalizers

Boehm, Hans hans.boehm at hp.com
Thu Mar 18 14:52:11 PST 2004


I hadn't seen this with gcj, since gcj tends to invoke other allocators now and then as
well.  But there's no convincing argument that should always be true.

Could you try the attached patch (unfortunately extracted from a larger one)?
I'm still testing it.

This is slightly subtle, since GC_INVOKE_FINALIZERS should be called without
the lock, but on an infrequently executed path.  I think the attached patch does 
the right thing, but I wish it were smaller.


> -----Original Message-----
> From: gc-bounces at napali.hpl.hp.com 
> [mailto:gc-bounces at napali.hpl.hp.com]On Behalf Of Varga Zoltan
> Sent: Thursday, March 18, 2004 5:31 AM
> To: gc at napali.hpl.hp.com
> Subject: [Gc] GC_gcj_malloc does not invoke finalizers
>                                      Hi,
>   I have a problem with GC_gcj_malloc. It calls
> GC_generic_malloc_inner
> instead of GC_generic_malloc, which means that
> does not get called. This means that if a program uses
> gcj_malloc only,
> then finalizers will never get called.
>                            Zoltan
> _______________________________________________
> Gc mailing list
> Gc at linux.hpl.hp.com
> https://www.hpl.hp.com/hosted/linux/mail-archives/gc/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: diff
Type: application/octet-stream
Size: 3168 bytes
Desc: not available
Url : https://napali.hpl.hp.com/pipermail/gc/attachments/20040318/24327e72/diff.obj

More information about the Gc mailing list