[kaffe] [PATCH] Re: reproducible lockup with jit3 in System.runFinalization()
Noa Resare
noa at resare.com
Thu Sep 16 12:25:09 PDT 2004
On tor, 2004-09-16 at 11:29 +0200, Guilhem Lavaux wrote:
>
> The problems is that the "free" field has two meanings. Either a pointer
> on the next element pointer of the former one (followed ? :) ) either a
> direct entry point in the free list of the small blocks. Maybe the two
> lists are messed up at that point. As you suggest we may set "free" to
> NULL in gc_remove_from_primfreelist, it will ease the debugging a bit
> and keep the list consistent. In the case of small blocks, I think you
> may clear free just before gc_primitive_free. If you find some other
> places feel free to do it.
>
> Meanwhile, I'll look at the freelist management ... again... ;)
>
I have found the problem now. What I didn't notice at first was the
relocation of the gc_block array that realloc() sometimes preforms. It
doesn't take into account when gc_block->free holds a pointer into the
old array. The attached patch fixes that.
Please apply.
/noa
--
And the lions ate the christians and the christians burned the witches,
and even I am out of explanations -- Ola Salo
gpg fingerprint: F3C4 AC90 B885 FE15 344B 4D05 220B 7662 A190 6F09
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kaffe-freelist-corruption.patch
Type: text/x-patch
Size: 1625 bytes
Desc: not available
Url : http://kaffe.org/pipermail/kaffe/attachments/20040916/2db79248/attachment-0002.bin
More information about the kaffe
mailing list