Patch: Imported boehm-gc 5.0alpha6
Bryce McKinlay
bryce@albatross.co.nz
Wed Apr 19 03:21:00 GMT 2000
I have imported gc 5.0alpha6 into libgcj. The new version obsoletes many
of our libgcj-local hacks (for example, it should now know to look at
data_start on linux systems). Rather than post the entire patch, I have
posted the remaining diffs against the stock gc distribution. The
changes in dyn_load.c are some minor typo fixes that I have sent back to
Hans.
Here's the list of changes from the gc's README file:
- GC_malloc_explicitly_typed and friends sometimes failed to
initialize first word.
- Added allocation routines and support in the marker for mark
descriptors
in a type structure referenced by the first word of an object. This
was
introduced to support gcj, but hopefully in a way that makes it
generically useful.
- Added GC_requested_heapsize, and inhibited collections in
nonincremental
mode if the actual used heap size is less than what was explicitly
requested.
- The Solaris pthreads version of GC_pthread_create didn't handle a
NULL
attribute pointer. Solaris thread support used the wrong default
thread
stack size. (Thanks to Melissa O'Neill for the patch.)
- Changed PUSH_CONTENTS macro to no longer modify first parameter.
This usually doesn't matter, but it was certainly an accident waiting
to happen ...
- Added GC_register_finalizer_no_order and friends to gc.h. They're
needed by Java implementations.
- Integrated a fix for a win32 deadlock resulting from clock() calling
malloc. (Thanks to Chris Dodd.)
- Integrated Hiroshi Kawashima's port to Linux/MIPS. This was designed
for a handheld platform, and may or may not be sufficient for other
machines.
- Fixed a va_arg problem with the %c specifier in cordprnt.c. It
appears
that this was always broken, but recent versions of gcc are the first
to
report the (statically detectable) bug.
- Added an attempt at a more general solution to dlopen
races/deadlocks.
GC_dlopen now temporarily disables collection. Still not ideal, but
...
- Added -DUSE_I686_PREFETCH, -DUSE_3DNOW_PREFETCH, and support for IA64
prefetch instructions. May improve performance measurably, but I'm
not
sure the code will run correctly on processors that don't support the
instruction. Won't build except with very recent gcc.
- Added caching for header lookups in the marker. This seems to result
in a barely measurable performance gain. Added support for
interleaved
lookups of two pointers, but unconfigured that since the performance
gain is currently near zero, and it adds to code size.
- Changed Linux DATA_START definition to check both data_start and
__data_start, since nothing else seems to be portable.
- Added -DUSE_LD_WRAP to optionally take advantage of the GNU ld
function
wrapping mechanism. Probably currently useful only on Linux.
- Moved some variables for the scratch allocator into GC_arrays, on
Martin Hirzel's suggestion.
- Fixed a win32 threads bug that caused the collector to not look for
interior pointers from one of the thread stacks without
ALL_INTERIOR_POINTERS. (Thanks to Jeff Sturm.)
- Added Mingw32 support. (Thanks again to Jeff Sturm for the patch.)
- Changed the alpha port to use the generic register scanning code
instead
of alpha_mach_dep.s. Alpha_mach_dep.s doesn't look for pointers in
fp
registers, but gcc sometimes spills pointers there. (Thanks to
Manuel Serrano
for helping me debug this by email.) Changed the IA64 code to do
something
similar for similar reasons.
2000-04-19 Bryce McKinlay <bryce@albatross.co.nz>
Imported version version 5.0alpha6.
* acinclude.m4: Bump version to 5.0a6.
* configure.in: Don't use alpha_mach_dep.s.
* include/private/config.h, irix_threads.c gc_watcom.asm: Delete
obsolete files.
More information about the Java-patches
mailing list