Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Commits on Apr 22, 2014
  1. Fix MS VC redefinition warning for functions declared with GC_ATTR_MA…

    authored
    …LLOC
    
    * dbg_mlc.c (GC_debug_malloc, GC_debug_malloc_ignore_off_page,
    GC_debug_malloc_atomic_ignore_off_page, GC_debug_malloc_stubborn,
    GC_debug_malloc_atomic, GC_debug_strdup, GC_debug_strndup,
    GC_debug_wcsdup, GC_debug_malloc_uncollectable,
    GC_debug_malloc_atomic_uncollectable,
    GC_debug_generic_or_special_malloc, GC_debug_malloc_replacement): Add
    GC_ATTR_MALLOC attribute to API function definition (to avoid MS VC
    warning about redefinition of a symbol previously declared with
    __declspec).
    * fnlz_mlc.c (GC_finalized_malloc): Likewise.
    * gcj_mlc.c (GC_gcj_malloc, GC_debug_gcj_malloc,
    GC_gcj_malloc_ignore_off_page): Likewise.
    * malloc.c (GC_generic_malloc, GC_malloc_atomic, GC_malloc,
    GC_malloc_uncollectable): Likewise.
    * mallocx.c (GC_generic_or_special_malloc,
    GC_generic_malloc_ignore_off_page, GC_malloc_ignore_off_page,
    GC_malloc_atomic_ignore_off_page, GC_malloc_many, GC_memalign,
    GC_malloc_atomic_uncollectable, GC_strdup, GC_strndup, GC_wcsdup):
    Likewise.
    * stubborn.c (GC_malloc_stubborn): Likewise.
    * thread_local_alloc.c (GC_malloc, GC_malloc_atomic, GC_gcj_malloc):
    Likewise.
    * typd_mlc.c (GC_malloc_explicitly_typed,
    GC_malloc_explicitly_typed_ignore_off_page,
    GC_calloc_explicitly_typed): Likewise.
Commits on Mar 30, 2014
  1. Define ROUNDUP_PAGESIZE, ROUNDUP_GRANULE_SIZE macros (code refactoring)

    authored
    * alloc.c (GC_expand_hp_inner): Use ROUNDUP_PAGESIZE().
    * checksums.c (GC_record_fault, GC_was_faulted): Likewise.
    * os_dep.c (GC_unix_mmap_get_mem, GC_wince_get_mem, GC_unmap_start,
    GC_remove_protection): Likewise.
    * headers.c (GC_scratch_alloc): Use ROUNDUP_GRANULE_SIZE().
    * malloc.c (GC_alloc_large): Likewise.
    * mallocx.c (GC_malloc_many): Likewise.
    * headers.c (GC_scratch_alloc): Use ROUNDUP_PAGESIZE() (only if
    USE_MMAP).
    * include/private/gc_priv.h (ROUNDUP_GRANULE_SIZE, ROUNDUP_PAGESIZE):
    Define macro to round up a value to a multiple of a granule or a page,
    respectively.
Commits on Mar 10, 2014
  1. Define public GC_GENERIC_OR_SPECIAL_MALLOC and GC_get_kind_and_size

    authored
    * dbg_mlc.c (GC_debug_generic_malloc,
    GC_debug_generic_or_special_malloc): New function.
    * mallocx.c (GC_get_kind_and_size): Likewise.
    * tests/test.c (test_generic_malloc_or_special): Likewise.
    * include/gc_mark.h (GC_generic_or_special_malloc,
    GC_debug_generic_or_special_malloc, GC_get_kind_and_size): New API
    prototype.
    * include/gc_mark.h (GC_GENERIC_OR_SPECIAL_MALLOC): New public macro.
    * mallocx.c (GC_generic_or_special_malloc): Turn into API function.
    * tests/test.c (reverse_test_inner, run_one_test): Invoke
    test_generic_malloc_or_special (to test GC_GENERIC_OR_SPECIAL_MALLOC
    and GC_get_kind_and_size).
Commits on Feb 20, 2014
  1. Remove redundant casts in GC_generic_or_special_malloc and similar

    authored
    (refactoring)
    
    * mallocx.c (GC_generic_or_special_malloc,
    GC_generic_malloc_ignore_off_page): Remove redundant casts for
    "lb" argument; remove redundant parentheses.
    * fnlz_mlc.c (GC_finalized_malloc): Likewise.
    * malloc.c (GC_generic_malloc, GC_malloc_uncollectable): Likewise.
    * malloc.c (GC_malloc_uncollectable): Remove redundant cast of
    returned value.
    * mallocx.c (GC_malloc_ignore_off_page,
    GC_malloc_atomic_ignore_off_page): Likewise.
Commits on Dec 21, 2013
  1. Remove hb_large_block field (use 1 extra bit of hb_flags instead)

    authored
    * allchblk.c (setup_header): Use (hb_flags & LARGE_BLOCK) != 0
    instead of hb_large_block.
    * private/gc_pmark.h (PUSH_CONTENTS_HDR): Likewise.
    * mallocx.c (GC_realloc): Likewise.
    * include/private/gc_priv.h (struct hblkhdr): Remove hb_large_block;
    define LARGE_BLOCK to access corresponding bit in hb_flags (only if
    MARK_BIT_PER_GRANULE).
Commits on Dec 15, 2013
  1. Remove 'opp' local variable in GC_malloc_X

    authored
    (code refactoring)
    
    * alloc.c: Update comment (about free lists).
    * fnlz_mlc.c (GC_finalized_malloc): Remove "opp" local variable
    (replace *opp with <kind>freelist[lg]).
    * gcj_mlc.c (GC_gcj_malloc, GC_gcj_malloc_ignore_off_page): Likewise.
    * malloc.c (GC_malloc_atomic, GC_malloc, GC_malloc_uncollectable):
    Likewise.
    * mallocx.c (GC_malloc_atomic_uncollectable): Likewise.
    * typd_mlc.c (GC_malloc_explicitly_typed,
    GC_malloc_explicitly_typed_ignore_off_page,
    GC_calloc_explicitly_typed): Likewise.
Commits on Aug 25, 2013
  1. Replace GC_DBG_RA with GC_DBG_EXTRAS macro

    authored
    * dbg_mlc.c (GC_debug_malloc_replacement,
    GC_debug_realloc_replacement): Use GC_DBG_EXTRAS (instead of
    "GC_DBG_RA NULL, 0").
    * malloc.c (GC_debug_malloc_replacement): Likewise.
    * mallocx.c (GC_debug_realloc_replacement): Likewise.
    * include/private/gc_priv.h (GC_DBG_EXTRAS): New macro (similar to
    GC_EXTRAS but pass NULL/0 instead of __FILE__and __LINE__);
    pass "unknown" instead of NULL unless GC_ADD_CALLER.
    * include/private/gc_priv.h (GC_DBG_RA): Remove.
  2. Adjust GC_debug_malloc/realloc_replacement macro to match the API fun…

    authored
    …ction
    
    * malloc.c (GC_debug_malloc_replacement): Pass NULL (instead of
    "unknown") to "s" argument of GC_debug_malloc to match that
    replacement definition in dbg_mlc.c.
    * mallocx.c (GC_debug_realloc_replacement): Likewise.
Commits on Dec 8, 2012
  1. Make GC_generic_malloc_ignore_off_page() public

    authored
    * include/gc_mark.h (GC_generic_malloc): Refine comment.
    * include/gc_mark.h (GC_generic_malloc_ignore_off_page): Move
    prototype from gc_priv.h and make it public; add GC_ATTR_MALLOC
    attribute.
    * include/private/gc_priv.h (GC_generic_malloc): Move comment to
    gc_mark.h.
    * include/private/gc_priv.h (GC_generic_malloc_ignore_off_page):
    Remove GC-inner prototype.
    * include/private/gc_priv.h (GC_generic_malloc_inner): Update comment.
    * mallocx.c (GC_generic_malloc_ignore_off_page): Likewise.
    * mallocx.c (GC_generic_malloc_ignore_off_page): Make public.
Commits on Sep 11, 2012
  1. Enable 'Force GC at every GC_malloc' debug-related functionality

    authored
    * doc/README.environment (GC_COLLECT_AT_MALLOC): Document.
    * doc/README.macros (GC_COLLECT_AT_MALLOC): Likewise.
    * fnlz_mlc.c (GC_core_finalized_malloc): Insert
    GC_DBG_COLLECT_AT_MALLOC invocation (before LOCK).
    * gcj_mlc.c (GC_core_gcj_malloc, GC_gcj_malloc_ignore_off_page):
    Likewise.
    * malloc.c (GC_generic_malloc, GC_malloc_atomic, GC_malloc,
    GC_malloc_uncollectable): Likewise.
    * mallocx.c (GC_generic_malloc_ignore_off_page,
    GC_generic_malloc_many, GC_malloc_atomic_uncollectable): Likewise.
    * typd_mlc.c (GC_malloc_explicitly_typed,
    GC_malloc_explicitly_typed_ignore_off_page): Likewise.
    * include/private/gc_priv.h (GC_COLLECT_AT_MALLOC): Recognize new
    macro.
    (GC_dbg_collect_at_malloc_min_lb): New global variable declaration
    (only if GC_COLLECT_AT_MALLOC defined).
    (GC_DBG_COLLECT_AT_MALLOC): Define new macro (invoking GC_gcollect).
    * malloc.c (GC_dbg_collect_at_malloc_min_lb): New global variable
    (only if GC_COLLECT_AT_MALLOC defined).
    * misc.c (GC_init): Test "GC_COLLECT_AT_MALLOC" environment variable
    and alter default GC_dbg_collect_at_malloc_min_lb value (only if
    GC_COLLECT_AT_MALLOC macro defined).
Commits on Jul 20, 2012
  1. Use memcpy (BCOPY) instead of strcpy (to suppress GCC warning)

    authored
    * cord/cordbscs.c (CORD_from_fn, CORD_substr_checked): Use memcpy
    instead of strcpy (to suppress GCC/ld warning
    "strcpy() is almost always misused").
    * dbg_mlc.c (GC_debug_strdup): Replace strcpy and memcpy with
    cross-platform BCOPY (with reversed order of "src" and "dest"
    arguments).
    * mallocx.c (GC_strdup): Likewise.
    * misc.c (GC_envfile_init, GC_CreateLogFile): Likewise.
    * os_dep.c (GC_print_callers): Likewise.
Commits on Jun 8, 2012
  1. Add comment in GC_memalign

    authored
    * mallocx.c (GC_memalign): Add comment for GC_malloc invocation result.
Commits on May 16, 2012
  1. Fix assertion in GC_malloc_[atomic_]uncollectable (THREADS case only)

    authored
    * malloc.c (GC_malloc_uncollectable): Do not check assertion on
    hb_n_marks to be zero if multi-threaded; add comment.
    * mallocx.c (GC_malloc_atomic_uncollectable): Likewise.
Commits on Jan 29, 2012
  1. Add missing 'volatile' for AO_t variable definitions

    authored
    (to minimize number of casts breaking strict-aliasing rules)
    
    * mallocx.c (GC_bytes_allocd_tmp): Change type from signed_word to
    AO_t.
    * mallocx.c (GC_generic_malloc_many): Use AO_load to get
    GC_bytes_allocd_tmp value; remove type cast for GC_bytes_allocd_tmp
    passed to AO_fetch_and_add.
    * pthread_support.c (GC_spin_count, GC_block_count,
    GC_unlocked_count): Add "volatile" for AO_t global variable (defined
    only if LOCK_STATS).
    * win32_threads.c (GC_attached_thread, GC_block_count,
    GC_unlocked_count): Likewise.
    * win32_threads.c (GC_Thread_Rep): Add "volatile" for "in_use" AO_t
    field.
    * win32_threads.c (GC_started_thread_while_stopped): Remove "result"
    local variable; use AO_compare_and_swap_release (if available) instead
    of AO_nop_full/load/store for GC_attached_thread.
    * win32_threads.c (GC_stop_world): Clear GC_attached_thread using
    AO_store.
Commits on Jan 18, 2012
  1. Use EXPECT in malloc result testing for NULL

    authored
    * gcj_mlc.c (GC_gcj_malloc_ignore_off_page): Use EXPECT to test "op"
    value for NULL.
    * malloc.c (GC_generic_malloc_inner, GC_malloc_uncollectable):
    Likewise.
    * mallocx.c (GC_generic_malloc_many, GC_posix_memalign): Likewise.
    * typd_mlc.c (GC_malloc_explicitly_typed,
    GC_malloc_explicitly_typed_ignore_off_page,
    GC_calloc_explicitly_typed): Likewise.
Commits on Dec 29, 2011
  1. Use EXPECT for checking various 'initialized' boolean variables

    authored
    * alloc.c (GC_try_to_collect_general, GC_expand_hp): Use "expect true"
    for GC_is_initialized value.
    * gcj_mlc.c (maybe_finalize): Likewise.
    * malloc.c (GC_alloc_large, GC_generic_malloc_inner, malloc): Likewise.
    * mallocx.c (GC_generic_malloc_many): Likewise.
    * mark_rts.c (GC_add_roots, GC_clear_roots): Likewise.
    * misc.c (GC_base, GC_init): Likewise.
    * ptr_chck.c (GC_same_obj, GC_is_valid_displacement, GC_is_visible):
    Likewise.
    * darwin_stop_world.c (GC_push_all_stacks): Use "expect true"
    for GC_thr_initialized value.
    * pthread_stop_world.c (GC_push_all_stacks): Likewise.
    * pthread_support.c (pthread_create): Likewise.
    * dyn_load.c (GC_register_dynamic_libraries_dl_iterate_phdr): Use
    "expect true" for excluded_segs value.
    * include/private/gc_priv.h (COND_DUMP): Use "expect false"
    for GC_dump_regularly value.
    * malloc.c (GC_generic_malloc): Use "expect false" for GC_have_errors
    value.
    * mallocx.c (GC_generic_malloc_ignore_off_page,
    GC_generic_malloc_many): Likewise.
    * malloc.c (calloc): Use "expect true" for lib_bounds_set value.
    * os_dep.c (GC_unix_mmap_get_mem): Use "expect true" for "initialized"
    value.
    * pthread_stop_world.c (GC_nacl_initialize_gc_thread): Use
    "expect true" for GC_nacl_thread_parking_inited value.
    * pthread_support.c (INIT_REAL_SYMS): Use "expect true" for
    GC_syms_initialized value; remove redundant trailing ';'.
    * pthread_support.c (GC_new_thread):  Use "expect true" for
    first_thread_used value.
    * win32_threads.c (GC_new_thread): Likewise.
    * pthread_support.c (pthread_create): Use "expect true" for
    parallel_initialized value.
    * win32_threads.c (GC_CreateThread, GC_beginthreadex,
    GC_pthread_join, GC_pthread_create, GC_pthread_sigmask,
    GC_pthread_detach): Likewise.
    * pthread_support.c (pthread_create): Use "expect false" for "si"
    value to be NULL.
    * thread_local_alloc.c (GC_init_thread_local): Use "expect true" for
    keys_initialized value.
    * typd_mlc.c (GC_make_descriptor): Use "expect true" for
    GC_explicit_typing_initialized value.
Commits on Aug 21, 2011
  1. Resolve "comparison of signed and unsigned values" compiler warnings.

    authored
    * allchblk.c (GC_allochblk_nth): Cast MAX_BLACK_LIST_ALLOC and
    HBLKSIZE to signed_word.
    * mallocx.c (GC_generic_malloc_many): Cast my_bytes_allocd to word.
    * mark.c (GC_do_local_mark): Cast the result of local_top minus
    local_mark_stack to word (since is non-negative).
    * misc.c (GC_base): Declare sz as unsigned word.
    * misc.c (GC_enable_incremental): Cast bytes_written to size_t in
    comparison to len.
    * obj_map.c (GC_initialize_offsets): Declare 'i' as unsigned.
    * os_dep.c (GC_or_pages): Ditto.
    * typd_mlc.c (GC_init_explicit_typing): Ditto.
    * ptr_chck.c (GC_is_visible): Cast the result of p minus base to word.
    * typd_mlc.c (GC_make_descriptor): Cast last_set_bit to word (since
    non-negative) when compared to BITMAP_BITS.
Commits on Jul 26, 2011
  1. gc7.0alpha5 tarball import

    authored
  2. gc7.0alpha2 tarball import

    authored
  3. gc7.0alpha1 tarball import

    authored
  4. gc6.3alpha5 tarball import

    authored
  5. gc6.3alpha4 tarball import

    authored
  6. gc6.1 tarball import

    authored
  7. gc6.1alpha4 tarball import

    authored
  8. gc6.0 tarball import

    authored
  9. gc5.3 tarball import

    authored
  10. gc5.0alpha3 tarball import

    authored
  11. gc4.14 tarball import

    authored
  12. gc4.13 tarball import

    authored
  13. gc4.12 tarball import

    authored
  14. gc4.11 tarball import

    authored
Something went wrong with that request. Please try again.