summaryrefslogtreecommitdiff
path: root/extra
Commit message (Collapse)AuthorAgeFilesLines
...
* Workaround '#error' cppcheck error messagesIvan Maidanski2016-10-061-2/+2
| | | | | | | | | | | | | | * extra/msvc_dbg.c (GetStackFramesFromContext): Skip #error pragma if CPPCHECK. * include/private/gcconfig.h [sun && mc68000]: Likewise. * include/private/gcconfig.h [hp9000s300 || ibm032 || _AUX_SOURCE || __pj__]: Likewise. * include/private/gcconfig.h [!mach_type_known]: Likewise. * include/private/gcconfig.h [HEXAGON && LINUX && !__ELF__]: Likewise. * include/private/gcconfig.h [!ALIGNMENT || !STACKBOTTOM]: Likewise. * os_dep.c [USE_MUNMAP && !USE_MMAP]: Likewise. * os_dep.c [MPROTECT_VDB && DARWIN && !ARM32 && !AARCH64 && !POWERPC && !I386]: Likewise.
* Fix printf format specifiers in extra filesIvan Maidanski2016-09-302-2/+3
| | | | | | | | | (to eliminate cppcheck warnings) * extra/MacOS.c (GC_MacFreeTemporaryMemory): Cast GC_gc_no to unsigned long, and adjust fprintf format specifier appropriately. * extra/msvc_dbg.c (GetDescriptionFromAddress): Cast line_number to int when passed to wsprintf() to match format specifier.
* Fix Clang static analyzer warning about not found gc_priv.h in extra filesIvan Maidanski2016-08-262-2/+2
| | | | | * extra/AmigaOS.c: Include "private/gc_priv.h" instead of "gc_priv.h". * extra/MacOS.c: Likewise.
* Fix GC_REALLOC to call GC_FREE if new size is zero and pointer is non-NULLIvan Maidanski2016-04-051-2/+3
| | | | | | | | | | | * dbg_mlc.c (GC_debug_realloc): Call GC_debug_free (and return NULL) if lb is zero and p is non-NULL. * extra/AmigaOS.c (GC_amiga_realloc): Do not retry and do not call WARN if new_size_in_bytes is zero. * include/gc.h (GC_realloc): Refine comment (better document the cases of NULL and/or zero arguments). * mallocx.c (GC_realloc): Call GC_free (skip it if IGNORE_FREE) and return NULL if lb is zero and p is non-NULL.
* Rename ATOMIC_UNCOLLECTABLE to GC_ATOMIC_UNCOLLECTABLEIvan Maidanski2015-05-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | (code refactoring) * Makefile.direct (CFLAGS): Add GC_ prefix to ATOMIC_UNCOLLECTABLE. * SMakefile.amiga: Likewise. * configure.ac (enable_atomic_uncollectible): Likewise. * dbg_mlc.c (GC_print_obj, GC_debug_malloc_atomic_uncollectable, GC_debug_free, GC_debug_realloc): Likewise. * doc/README.Mac: Likewise. * doc/README.macros (ATOMIC_UNCOLLECTABLE): Likewise. * extra/AmigaOS.c (GC_amiga_allocwrapper_any): Likewise. * include/new_gc_alloc.h: Likewise. * include/private/gc_priv.h (struct _GC_arrays, AUNCOLLECTABLE): Likewise. * mallocx.c (GC_auobjfreelist_ptr, GC_generic_or_special_malloc, GC_malloc_atomic_uncollectable): Likewise. * mark.c (GC_obj_kinds, GC_N_KINDS_INITIAL_VALUE): Likewise. * include/private/gc_priv.h (GC_ATOMIC_UNCOLLECTABLE): Define if ATOMIC_UNCOLLECTABLE defined (for compatibility with the clients that do not use GC makefiles).
* Remove commented out code in AmigaOS.c, gcconfig.h and os_dep.cIvan Maidanski2015-04-061-74/+1
| | | | | | | * doc/README.amiga: Remove note about "#if 0'ed" code. * extra/AmigaOS.c: Remove "#if 0'ed" code. * include/private/gcconfig.h: Likewise. * os_dep.c: Likewise.
* Fix 'attribute declaration must precede definition' warning (clang-3.1)Ivan Maidanski2013-12-181-0/+2
| | | | | | | | | | | | | * extra/gc.c: Include gc_inline.h explicitly before including mallocx.c (to workaround "attribute declaration must precede definition" warning reported by clang-3.1 for GC_generic_malloc_many); define GC_PTHREAD_REDIRECTS_ONLY before including gc_pthread_redirects.h. * include/gc_pthread_redirects.h (GC_dlopen, GC_pthread_sigmask, GC_PTHREAD_CREATE_CONST, GC_pthread_create, GC_pthread_join, GC_pthread_detach, GC_pthread_cancel, GC_pthread_exit): Do not declare if GC_PTHREAD_REDIRECTS_ONLY defined (to workaround "attribute declaration must precede definition" warning reported by clang-3.1).
* Allow to compile GC_inner_start_routine aside from extra/gc.cIvan Maidanski2013-07-161-1/+3
| | | | | | | | | | | | | | | | | | | | | (for proper exceptions support on Linux) * extra/gc.c: Do not include pthread_start.c if GC_PTHREAD_START_STANDALONE defined (thus pthread_start.c could go to a standalone compilation unit). * include/private/pthread_support.h (GC_INNER_PTHRSTART): New macro (defined to either empty or GC_INNER depending on GC_PTHREAD_START_STANDALONE). * include/private/pthread_support.h (GC_start_rtn_prepare_thread, GC_thread_exit_proc): Replace GC_INNER to GC_INNER_PTHRSTART. * pthread_support.c (GC_thread_exit_proc, GC_start_rtn_prepare_thread): Likewise. * pthread_start.c (GC_inner_start_routine): Define as GC_INNER_PTHRSTART; do not call GC_log_printf if GC_PTHREAD_START_STANDALONE (since the function might be visible only within extra/gc.c compilation unit). * pthread_support.c (GC_inner_start_routine): Declare as GC_INNER_PTHRSTART.
* Fix typos in commentsOndrej Bilka2013-07-111-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | * blacklst.c: Fix typo ("even though"). * cord/cordbscs.c: Fix typo ("exponentially"). * cord/cordxtra.c: Fix typo ("represented"). * dyn_load.c: Fix typos ("uncollectible", "occurred"). * extra/AmigaOS: Fix typos ("specific", "necessary", "always", "effectiveness"). * finalize.c: Fix typo ("descendants"). * include/cord.h: Fix typo ("idiosyncrasies"). * include/gc.h: Fix typo ("collectible"). * include/gc_allocator.h: Fix typos ("allocator", "[un]collectible"). * mach_dep.c: Fix typo ("erroneously"). * malloc.c: Fix typos ("[un]collectible", "pointer-free", "initialization"). * mallocx.c: Fix typos ("largely", "pointer-free", "uncollectible"). * mark.c: Fix typos ("[un]collectible", "even though"). * misc.c: Fix typo ("erroneously"). * os_dep.c: Fix typos ("non-addressable", "happening", "pointer-free"). * tests/test.c: Fix typos ("uncollectible", "reversed"). * tests/test_cpp.cc: Fix typos ("[un]collectible"). * typd_mlc.c: Fix typo ("copyright"). * win32_threads.c: Fix typos ("optimization", "uncollectible").
* Expand tabs to spaces in rarely used (ancient) filesIvan Maidanski2013-07-105-376/+376
| | | | | | | | | * extra/AmigaOS.c: Expand tabs to spaces. * extra/MacOS.c: Likewise. * extra/Mac_files/dataend.c: Likewise. * extra/Mac_files/datastart.c: Likewise. * extra/symbian.cpp: Likewise. * cord/cordxtra.c: Likewise.
* Remove GC_BUILD definition from build scriptsIvan Maidanski2013-05-042-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * CMakeLists.txt (ADD_DEFINITIONS): Remove -D GC_BUILD (not needed since it is defined in gc_priv.h, gc_pmark.h and gc_cpp.cc). * WCC_MAKEFILE (CFLAGS): Likewise. * build/s60v3/libgc.mmp: Likewise. * digimars.mak (DEFINES, tests/test.obj): Likewise. * windows-untested/vc60/gc.dsp (ADD CPP): Likewise. * windows-untested/vc60/libgc.dsp (ADD CPP): Likewise. * windows-untested/vc60/libgcmt.dsp (ADD CPP): Likewise. * windows-untested/vc70/gc.vcproj (PreprocessorDefinitions): Likewise. * windows-untested/vc70/libgc.vcproj (PreprocessorDefinitions): Likewise. * windows-untested/vc70/libgcmt.vcproj (PreprocessorDefinitions): Likewise. * windows-untested/vc71/gc.vcproj (PreprocessorDefinitions): Likewise. * windows-untested/vc71/libgc.vcproj (PreprocessorDefinitions): Likewise. * windows-untested/vc71/libgcmt.vcproj (PreprocessorDefinitions): Likewise. * extra/MacOS.c: Define GC_BUILD (before include of gc.h). * extra/msvc_dbg.c: Likewise. * windows-untested/vc60/gc.dsp (MESSAGE, ENDIF): Remove trailing spaces at EOLn. * windows-untested/vc60/libgc.dsp (MESSAGE, ENDIF): Likewise. * windows-untested/vc60/libgcmt.dsp (MESSAGE, ENDIF): Likewise.
* Move Symbian data-roots-related files to 'extra/symbian' folderIvan Maidanski2012-03-223-0/+0
| | | | | | | | * extra/init_global_static_roots.cpp: Move to "extra/symbian" folder. * extra/global_start.cpp: Likewise. * extra/global_end.cpp: Likewise. * Makefile.am (EXTRA_DIST): Update references to moved Symbian files. * Makefile.direct (OTHER_MAKEFILES): Likewise.
* Move 'Mac_files' folder to 'extra' oneIvan Maidanski2012-03-223-0/+46
| | | | | | | | * Mac_files: Move to "extra" folder. * Makefile.am (EXTRA_DIST): Update references to Mac_files. * Makefile.direct (OTHER_MAKEFILES): Likewise. * Makefile.dj (OTHER_MAKEFILES): Likewise. * doc/README.Mac: Update reference to MacOS_config.h file.
* Move Symbian cpp files to 'extra' folder;Ivan Maidanski2012-03-184-0/+120
| | | | add GC prefix to init_global_static_roots Symbian-special API function.
* Replace pointer relational comparisons with non-pointer onesIvan Maidanski2012-03-051-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * allchblk.c (GC_dump_regions, GC_allochblk_nth): Cast pointers to word type in relational (less-greater) comparisons. * alloc.c (GC_add_to_heap, GC_print_heap_sects, GC_expand_hp_inner): Likewise. * backgraph.c (ensure_struct, add_back_edges): Likewise. * blacklst.c (GC_number_stack_black_listed): Likewise. * checksums.c (GC_checksum, GC_check_dirty): Likewise. * darwin_stop_world.c (GC_push_all_stacks): Likewise. * dbg_mlc.c (GC_get_back_ptr_info, GC_print_smashed_obj, GC_check_heap_block): Likewise. * dyn_load.c (sort_heap_sects, GC_register_map_entries, GC_register_dynlib_callback, GC_register_dynamic_libraries_dl_iterate_phdr, GC_register_dynamic_libraries, GC_cond_add_roots): Likewise. * finalize.c (GC_ignore_self_finalize_mark_proc): Likewise. * headers.c (GC_scratch_alloc, GC_install_counts, GC_remove_counts): Likewise. * include/private/gc_pmark.h (PUSH_OBJ, PUsH_CONTENTS_HDR, GC_PUSH_ONE_STACK, GC_PUSH_ONE_HEAP, GC_mark_stack_empty): Likewise. * include/private/gc_priv.h (MAKE_COOLER, COOLER_THAN): Likewise. * mach_dep.c (GC_with_callee_saves_pushed): Likewise. * malloc.c (calloc, free): Likewise. * mark.c (GC_mark_some_inner, GC_mark_from, GC_steal_mark_stack, GC_return_mark_stack, GC_do_local_mark, GC_mark_local, GC_push_all, GC_push_selected, GC_push_all_eager, GC_push_marked1, GC_push_marked2, GC_push_marked4, GC_push_marked, GC_push_unconditionally): Likewise. * mark_rts.c (GC_is_static_root, GC_add_roots_inner, GC_remove_roots_inner, GC_is_tmp_root, GC_exclude_static_roots_inner, GC_push_conditional_with_exclusions, GC_push_all_register_sections, GC_push_all_stack_sections, GC_push_all_stack_partially_eager, GC_push_all_stack_part_eager_sections, GC_push_current_stack): Likewise. * misc.c (GC_clear_stack_inner, GC_clear_stack, GC_base, GC_call_with_gc_active): Likewise. * new_hblk.c (GC_build_fl_clear2, GC_build_fl_clear4, GC_build_fl2, GC_build_fl4, GC_build_fl): Likewise. * os_dep.c (GC_enclosing_mapping, GC_text_mapping, tiny_sbrk, GC_find_limit_openbsd, GC_skip_hole_openbsd, GC_find_limit_with_bound, GC_get_main_stack_base, GC_get_stack_base, GC_least_described_address, GC_register_root_section, GC_register_data_segments, GC_unmap_start, GC_gww_read_dirty, GC_remove_protection, GC_protect_heap, GC_unprotect_range, GC_read_dirty, GC_page_was_dirty, GC_save_callers, GC_print_callers): Likewise. * pcr_interface.c (GC_enumerate_block): Likewise. * pthread_support.c (GC_is_thread_tsd_valid, GC_segment_is_thread_stack, GC_greatest_stack_base_below, GC_call_with_gc_active): Likewise. * ptr_chck.c (GC_same_obj, GC_is_valid_displacement, GC_on_stack, GC_is_visible): Likewise. * reclaim.c (GC_reclaim_clear, GC_reclaim_uninit, GC_disclaim_and_reclaim, GC_reclaim_check, GC_start_reclaim): Likewise. * tests/test.c (cons): Likewise. * tools/setjmp_t.c (main): Likewise. * typd_mlc.c (GC_typed_mark_proc): Likewise. * win32_threads.c (GC_is_thread_tsd_valid, GC_call_with_gc_active, GC_push_stack_for, GC_get_next_stack): Likewise. * extra/msvc_dbg.c (GetDescriptionFromAddress, GetDescriptionFromStack): Cast pointers to GC_ULONG_PTR in relational comparisons. * include/gc.h (GC_DATASTART, GC_DATAEND): Cast pointers to GC_word in relational comparisons. * misc.c (GC_init): Remove static assertion on ((ptr_t)-1 > 0) since no longer required; add the comment. * pcr_interface.c: Expand tabs to spaces.
* Fix extra/gc.c to enable GC source inclusion from multi-threaded appIvan Maidanski2012-01-131-2/+8
| | | | | | | | | * extra/gc.c: Include gc_pthread_redirects.h (unless GC_NO_THREAD_REDIRECTS) to restore thread calls macro-based redirection after the corresponding undef's in pthread_support.c. * win32_threads.c: Restore thread calls macro-based redirection (unless GC_NO_THREAD_REDIRECTS) at the file end. * extra/gc.c: Remove "file not well tested" comment.
* Remove trailing spaces at EOLn in all filesIvan Maidanski2011-12-222-12/+10
|
* Rename (shorten name of) finalized_mlc.c to fnlz_mlc.c fileIvan Maidanski2011-11-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * finalized_mlc.c: Rename to fnlz_mlc.c file. * BCC_MAKEFILE (XXXOBJS): Rename "finalized_mlc" to "fnlz_mlc". * EMX_MAKEFILE (OBJS): Likewise. * Makefile.am (libgc_la_SOURCES): Likewise. * Makefile.direct (OBJS, CSRCS): Likewise. * Makefile.dj (OBJS, CSRCS): Likewise. * NT_MAKEFILE (OBJS): Likewise. * NT_STATIC_THREADS_MAKEFILE (OBJS): Likewise. * NT_X64_STATIC_THREADS_MAKEFILE (OBJS): Likewise. * NT_X64_THREADS_MAKEFILE (OBJS): Likewise. * OS2_MAKEFILE (OBJS): Likewise. * PCR-Makefile (COBJ, CSRC): Likewise. * SMakefile.amiga (OBJS, finalized_mlc.o): Likewise. * WCC_MAKEFILE (OBJS): Likewise. * digimars.mak (OBJS, finalized_mlc.o): Likewise. * extra/gc.c: Likewise. * gc.mak: Likewise. * thread_local_alloc.c: Likewise. * windows-untested/vc60/gc.dsp (SOURCE): Likewise. * windows-untested/vc60/libgc.dsp (SOURCE): Likewise. * windows-untested/vc70/gc.vcproj: Likewise. * windows-untested/vc70/libgc.vcproj: Likewise. * windows-untested/vc70/libgcmt.vcproj: Likewise. * windows-untested/vc71/gc.vcproj: Likewise. * windows-untested/vc71/libgc.vcproj: Likewise. * windows-untested/vc71/libgcmt.vcproj: Likewise.
* Fix extra/gc.c to include new finalized_mlc.c fileIvan Maidanski2011-11-111-0/+1
| | | | * extra/gc.c: Include finalized_mlc.c file (after finalize.c).
* Move build tools sources from "extra" to "tools" folder.Ivan Maidanski2011-08-256-315/+0
| | | | | | | | | | | | | | | | * EMX_MAKEFILE (setjmp_test): Move setjmp_t.c to "tools" folder. * Makefile.am (EXTRA_DIST): Move add_gc_prefix.c, gcname.c, if_mach.c, if_not_there.c, setjmp_t.c and threadlibs.c to "tools" folder. * Makefile.direct (SRCS, OTHER_FILES, if_mach, threadlibs, if_not_there, setjmp_test, add_gc_prefix, gcname): Ditto. * Makefile.dj (SRCS, OTHER_FILES, if_mach, threadlibs, if_not_there, setjmp_test, add_gc_prefix): Ditto. * PCR-Makefile (if_mach, if_not_there): Ditto. * SMakefile.amiga (setjmp_t): Ditto. * doc/simple_example.html: Change folder name for threadlibs.c file. * EMX_MAKEFILE: Remove trailing spaces at EOLn. * SMakefile.amiga: Ditto.
* 2011-04-23 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-1/+1
| | | | | | | | | | | | | | | | | | | | | * mark.c (GC_clear_hdr_marks): Don't test USE_MARK_BYTES. * extra/setjmp_t.c (main): Don't test USE_MARK_BITS. * include/private/gc_pmark.h (SET_MARK_BIT_EXIT_IF_SET): Ditto. * include/private/gc_pmark.h (SET_MARK_BIT_EXIT_IF_SET): Remove "mark_byte" local variable. * include/private/gc_pmark.h (OR_WORD_EXIT_IF_SET): Add a comment about that AO_or() is not used by GC unless USE_MARK_BITS explicitly set. * include/private/gc_priv.h (OR_WORD): Ditto. * include/private/gc_pmark.h (INCR_MARKS): Remove trailing ';', add parentheses. * include/private/gc_priv.h (ONES): Define before use by MAKE_COOLER. * include/private/gc_priv.h (MARK_BITS_SZ): Define where used. * include/private/gc_priv.h (OR_WORD): Don't define if USE_MARK_BYTES. * include/private/gcconfig.h (USE_MARK_BYTES); Remove duplicate definition; simplify expression.
* 2011-04-11 Ivan Maidanski <ivmai@mail.ru> (mostly really Jim Meyering)ivmai2011-07-261-88/+89
| | | | | | | | | | | | | * configure.host: Remove doubled words in comments. * os_dep.c: Ditto. * doc/README: Ditto. * extra/setjmp_t.c: Ditto. * tests/huge_test.c: Ditto. * extra/setjmp_t.c (getpagesize, nested_sp, main, g): Replace the K&R-style function definition with the ANSI C one. * extra/setjmp_t.c: Expand all tabs to spaces. * extra/setjmp_t.c (nested_sp): Implement in the same way as GC_approx_sp.
* 2011-03-13 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-238/+266
| | | | | | | * extra/msvc_dbg.c: Test _MSC_VER macro; include "gc.h" (for GC_word); reformat the code; expand all tabs to spaces. * extra/msvc_dbg.c (ULONG_PTR): Replace with GC_ULONG_PTR; define as word.
* 2011-01-05 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-3/+3
| | | | | | | | | | | | | | * misc.c (GC_write): Replace multiple "ifdef/endif" with "elif" (for ECOS and NOSYS). * os_dep.c (GC_get_main_stack_base): Ditto. * os_dep.c (GC_get_main_stack_base): Check USE_GET_STACKBASE_FOR_MAIN macro before checking STACKBOTTOM one; remove "dummy" variable (use result one instead); reformat the code. * doc/README.macros (SN_TARGET_PS3): Document. * extra/threadlibs.c (main): Don't output "-lpthread" (and "-ldl") for Android. * include/private/pthread_support.h: Fix comment for "endif".
* 2010-08-14 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-1/+1
| | | | | | | * extra/threadlibs.c (main): Remove --wrap for "read" (since not wrapped anymore). * doc/README.linux (GC_USE_LD_WRAP): Ditto. * os_dep.c (__wrap_read): Ditto (in the comment).
* 2010-08-14 Ivan Maidanski <ivmai@mail.ru> (with help from Hans Boehm)ivmai2011-07-261-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * include/gc_pthread_redirects.h: Test GC_PTHREADS and GC_H at the beginning of the file. * include/gc_pthread_redirects.h (GC_PTHREAD_EXIT_ATTRIBUTE): New macro (defined only for Linux and Solaris). * include/gc_pthread_redirects.h (GC_pthread_cancel, GC_pthread_exit): Declare new API function (only if GC_PTHREAD_EXIT_ATTRIBUTE). * include/gc_pthread_redirects.h (pthread_cancel, pthread_exit): Redirect (if GC_PTHREAD_EXIT_ATTRIBUTE). * include/private/pthread_support.h (DISABLED_GC): New macro. * pthread_support.c (pthread_cancel, pthread_exit): Restore original definition or declare "real" function (if needed and GC_PTHREAD_EXIT_ATTRIBUTE). * pthread_support.c (GC_pthread_cancel_t, GC_pthread_exit_t): Declare new types if needed. * pthread_support.c (GC_pthread_cancel, GC_pthread_exit): New function definition (only if GC_PTHREAD_EXIT_ATTRIBUTE). * pthread_support.c (GC_init_real_syms): Initialise pointers to the "real" pthread_cancel and pthread_exit (only if GC_PTHREAD_EXIT_ATTRIBUTE). * pthread_support.c (GC_unregister_my_thread): Enable collections if DISABLED_GC was set (only if GC_PTHREAD_EXIT_ATTRIBUTE). * pthread_support.c (pthread_cancel, pthread_exit): New wrapped function definition (only if GC_PTHREAD_EXIT_ATTRIBUTE defined). * pthread_support.c (GC_start_routine): Refine the comment. * extra/threadlibs.c (main): Adjust --wrap (add "read", "pthread_exit", "pthread_cancel" but remove "sleep"). * doc/README.linux (GC_USE_LD_WRAP): Ditto. * doc/README.linux: Expand all tabs to spaces; remove trailing spaces at EOLn.
* 2010-07-29 Ivan Maidanski <ivmai@mail.ru> (with input from NIIBE Yutaka)ivmai2011-07-261-0/+6
| | | | | | | | | | | | | | | | | | | | * pthread_start.c: New file. * CMakeLists.txt (SRC): Add pthread_start.c. * Makefile.am (libgc_la_SOURCES): Ditto. * Makefile.direct (CSRCS): Ditto. * Makefile.direct (OBJS): Add pthread_start.obj. * extra/gc.c: Add a comment; include pthread_start.c. * pthread_support.c (start_info): Move the struct definition down closer to its usage. * pthread_support.c (GC_thread_exit_proc): Replace STATIC with GC_INNER. * pthread_support.c (GC_inner_start_routine): Move to the definition to pthread_start.c; leave only the prototype; remove STATIC. * pthread_support.c (GC_start_rtn_prepare_thread): New function (contains parts of the original GC_inner_start_routine). * Makefile.in: Regenerate. * configure: Ditto.
* 2009-11-06 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-2/+2
| | | | | | | | | | | | | * dyn_load.c (WIN32_LEAN_AND_MEAN): Guard with ifndef. * misc.c (WIN32_LEAN_AND_MEAN): Ditto. * os_dep.c (WIN32_LEAN_AND_MEAN): Ditto. * allchblk.c (GC_allochblk_nth): Fix a minor typo (don't/doesn't) in a comment. * backgraph.c: Ditto. * dyn_load.c (GC_register_dynamic_libraries): Ditto. * extra/threadlibs.c (main): Ditto. * pthread_support.c (pthread_join): Ditto. * tests/test.c (main): Ditto.
* 2009-10-20 Ivan Maidanski <ivmai@mail.ru> (really mostly OpenBSD contributors)ivmai2011-07-261-18/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac (openbsd): Define GC_OPENBSD_THREADS. * configure.ac: Add AM_CONDITIONAL(OPENBSD_THREADS). * configure.ac: Add sparc-openbsd case. * doc/README.macros (GC_NETBSD_THREADS, GC_OPENBSD_THREADS): Document. * tests/test.c (main): Handle OpenBSD case. * extra/threadlibs.c: Add the copyright header; expand all tabs to spaces; remove trailing spaces at EOLn. * include/private/pthread_stop_world.h: Ditto. * extra/threadlibs.c (main): Replace K&R-style function definition with the ANSI C one. * extra/threadlibs.c (main): Handle GC_OPENBSD_THREADS case. * dyn_load.c (OPENBSD): Recognize (similar to NETBSD). * include/gc_config_macros.h (GC_SOLARIS_THREADS): Recognize; define it for OpenBSD. * include/gc_pthread_redirects.h (GC_pthread_sigmask, pthread_sigmask): Don't declare and redefine for OpenBSD. * include/private/gcconfig.h: Handle OpenBSD (on arm, sh, i386, amd64, powerpc). * mach_dep.c (NO_GETCONTEXT): Ditto. * include/private/pthread_stop_world.h (thread_stop_info): Don't define last_stop_count field if OpenBSD. * misc.c (GC_init_dyld): Add declaration (if NetBSD). * misc.c (GC_init): Don't call GC_init_netbsd_elf() for OpenBSD. * os_dep.c (GC_init_netbsd_elf): Don't define for OpenBSD. * os_dep.c (old_segv_act, GC_jmp_buf_openbsd): New static variable (only if OpenBSD). * os_dep.c (GC_fault_handler_openbsd, GC_find_limit_openbsd, GC_skip_hole_openbsd): New static function (only if OpenBSD). * os_dep.c (GC_get_stack_base, GC_get_main_stack_base, GC_register_data_segments): Define specially for OpenBSD case. * os_dep.c (GC_fault_handler_lock): Initialize to AO_TS_INITIALIZER (instead of 0). * pthread_support.c (GC_allocate_lock): Ditto. * pthread_stop_world.c (NSIG, GC_print_sig_mask, GC_remove_allowed_signals, suspend_handler_mask, GC_stop_count, GC_world_is_stopped, GC_retry_signals, SIG_THR_RESTART, GC_suspend_ack_sem, GC_suspend_handler_inner, GC_suspend_handler, GC_restart_handler): Don't define and use if OpenBSD. * pthread_stop_world.c (GC_suspend_all, GC_stop_world, GC_start_world): Handle OpenBSD case. * pthread_stop_world.c (GC_stop_init): Define as empty if OpenBSD. * pthread_support.c (pthread_sigmask): Don't undefine the macro and don't define the wrapper function if OpenBSD. * pthread_support.c (GC_thr_init): Handle OpenBSD case. * configure: Regenerate. * include/private/config.h.in: Ditto.
* 2009-10-19 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * include/private/gc_priv.h (GC_INNER): New macro (for GC-scope variable definitions). * include/private/gc_priv.h (GC_EXTERN): Update the comment. * allchblk.c (GC_unmap_threshold): Define as GC_INNER. * alloc.c (GC_incremental, GC_world_stopped, GC_n_heap_sects, GC_n_memory, GC_fail_count): Ditto. * blacklst.c (GC_black_list_spacing, GC_print_heap_obj): Ditto. * gcj_mlc.c (GC_gcj_malloc_initialized, GC_gcjobjfreelist): Ditto. * mach_dep.c (GC_save_regs_ret_val): Ditto. * mark.c (GC_n_mark_procs, GC_obj_kinds, GC_n_kinds, GC_mark_stack, GC_mark_stack_limit, GC_mark_stack_size, GC_mark_stack_top, GC_mark_state, GC_mark_stack_too_small, GC_mark_no, GC_markers): Ditto. * mark_rts.c (GC_root_size, GC_push_typed_structures): Ditto. * misc.c (GC_allocate_ml, GC_debugging_started, GC_check_heap, GC_print_all_smashed, GC_print_back_height, GC_dump_regularly, GC_backtraces, GC_force_unmap_on_gcollect, GC_large_alloc_warn_interval, GC_is_initialized, GC_write_cs, GC_current_warn_proc, GC_blocked_sp, GC_activation_frame): Ditto. * os_dep.c (GC_page_size, GC_dont_query_stack_min, GC_no_win32_dlls, GC_wnt, GC_sysinfo, GC_push_other_roots, GC_dirty_maintained, GC_fault_handler_lock): Ditto. * pthread_support.c (GC_allocate_ml, GC_lock_holder, GC_need_to_lock, GC_thr_initialized, GC_threads, GC_in_thread_creation, GC_collecting, GC_allocate_lock, GC_mark_lock_holder): Ditto. * reclaim.c (GC_bytes_found, GC_fl_builder_count, GC_have_errors): Ditto. * win32_threads.c (GC_allocate_ml, GC_lock_holder, GC_need_to_lock, GC_mark_lock_holder, GC_collecting): Ditto. * extra/gc.c (GC_INNER, GC_EXTERN): Define as STATIC. * mach_dep.c (GC_with_callee_saves_pushed): Remove redundant {}. * os_dep.c (GC_init_win32): Reformat the comment.
* 2009-10-19 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-261-0/+66
| | | | | | | * extra/gc.c: New file. * Makefile.am (EXTRA_DIST): Add "extra/gc.c". * configure: Regenerate. * Makefile.in: Ditto.
* 2009-09-19 Ivan Maidanski <ivmai@mail.ru>ivmai2011-07-269-0/+1426
(ivmai147.diff) * add_gc_prefix.c: Move the file to the new "extra" directory. * AmigaOS.c: Ditto. * gcname.c: Ditto. * if_mach.c: Ditto. * if_not_there.c: Ditto. * MacOS.c: Ditto. * msvc_dbg.c: Ditto. * setjmp_t.c: Ditto. * threadlibs.c: Ditto. * EMX_MAKEFILE: Prepend setjmp_t.c with "extra" directory. * Makefile: Prepend AmigaOS.c, MacOS.c, add_gc_prefix.c, gcname.c, if_mach.c, if_not_there.c, msvc_dbg.c, setjmp_t.c, threadlibs.c with "extra" directory. * Makefile.am: Ditto. * Makefile.direct: Ditto. * Makefile.dj: Ditto. * Makefile.in: Ditto. * NT_MAKEFILE: Prepend msvc_dbg.obj with "extra" directory. * NT_STATIC_THREADS_MAKEFILE: Ditto. * NT_X64_STATIC_THREADS_MAKEFILE: Ditto. * NT_X64_THREADS_MAKEFILE: Ditto. * NT_THREADS_MAKEFILE: Prepend msvc_dbg.c with "extra" directory. * gc.mak: Ditto. * PCR-Makefile: Prepend if_mach.c, if_not_there.c with "extra" directory. * SMakefile.amiga: Prepend AmigaOS.c, setjmp_t.c with "extra" directory. * doc/simple_example.html: Update for threadlibs.c. * os_dep.c: Prepend included AmigaOS.c with "extra" directory.