[Gc] Patches resubmission 7

Ivan Maidanski ivmai at mail.ru
Fri Jun 12 11:27:44 PDT 2009


This cumulative patch (resembling diff3, diff27, diff59, diff61, diff66, diff73 partly) deals with various small fixes for dbg_mlc.c, finalize.c, gcj_mlc.c, mark.c, typd_mlc.c and gc_pmark.h. The patch doesn't depend on my previous pending cumulative patches (diff88_cvs, diff95_cvs, diff96_cvs, diff97_cvs).

My (short) comments for GC_finalize_all are in:

The problem with FIXUP_POINTER was pointed by Adam Warner <lists at consulting.net.nz>

See the comments for FIXUP_POINTER in:

ChangeLog entries:

        * dbg_mlc.c (GC_print_smashed_obj): Convert a group of printf()
        calls into a single one (for output atomicity).
        * typd_mlc.c (GC_calloc_explicitly_typed): Don't declare and use
        GC_finalization_failures variable; check the result of
        GC_general_register_disappearing_link() (for lack of memory)
        * finalize.c (GC_finalization_failures): Remove unused global
        * finalize.c (GC_general_register_disappearing_link,
        GC_general_register_disappearing_link): Don't update the value of
        GC_finalization_failures (since unused).
        * include/private/gc_pmark.h (PUSH_ONE_CHECKED_STACK,
        GC_PUSH_ONE_STACK, GC_PUSH_ONE_HEAP): The first parameter is of
        word type now (as FIXUP_POINTER requires numeric argument).
        * finalize.c (GC_ignore_self_finalize_mark_proc): GC_PUSH_ONE_HEAP
        requires the first parameter of word type.
        * mark.c (PUSH_GRANULE): Ditto.
        * mark.c (GC_push_one, GC_push_all_eager): Ditto (for
        * finalize.c (GC_finalize_all): Call GC_invoke_finalizers() instead
        of GC_INVOKE_FINALIZERS() to prevent infinite looping (according
        to the definition, the function should invoke all remaining
        finalizers, not invoke finalizer notifier).
        * gcj_mlc.c: Include gc_pmark.h before "ifdef GC_GCJ_SUPPORT" (not
        after) for configuration information.
        * gcj_mlc.c (GC_gcj_malloc_ignore_off_page): Add comment.
        * gcj_mlc.c (GC_gcj_malloc_ignore_off_page): Check "op" local
        variable for NULL before dereferencing it, return GC_oom_fn() in
        this case.
        * typd_mlc.c (GC_malloc_explicitly_typed,
        GC_malloc_explicitly_typed_ignore_off_page): Transform the code to
        suppress compiler warning (for uninitialized "lg" variable).


More information about the Gc mailing list