diff options
author | Bryce McKinlay <bryce@gcc.gnu.org> | 2000-06-19 23:42:00 +0000 |
---|---|---|
committer | Bryce McKinlay <bryce@gcc.gnu.org> | 2000-06-19 23:42:00 +0000 |
commit | 2c1b930b7c19b6e9bbeec3fc6bf6beaeeb505c9f (patch) | |
tree | f568e92eec80d54ea2c1ef265e2d24165d9a2695 | |
parent | 0fb3dab320ad9d5ee391923100a1ecc1c3e50915 (diff) |
Imported GC 5.1
git-svn-id: https://gcc.gnu.org/svn/gcc/branches/boehm@34605 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | boehm-gc/include/gc.h | 3 | ||||
-rw-r--r-- | boehm-gc/reclaim.c | 49 | ||||
-rw-r--r-- | boehm-gc/typd_mlc.c | 2 | ||||
-rw-r--r-- | boehm-gc/version.h | 2 |
4 files changed, 35 insertions, 21 deletions
diff --git a/boehm-gc/include/gc.h b/boehm-gc/include/gc.h index e35f54f7d3f..d7cd8996085 100644 --- a/boehm-gc/include/gc.h +++ b/boehm-gc/include/gc.h @@ -372,8 +372,7 @@ GC_API GC_PTR GC_malloc_atomic_ignore_off_page GC_PROTO((size_t lb)); #ifdef GC_ADD_CALLER # define GC_EXTRAS GC_RETURN_ADDR, __FILE__, __LINE__ -# define GC_EXTRA_PARAMS GC_word ra, GC_CONST char * s, - int i +# define GC_EXTRA_PARAMS GC_word ra, GC_CONST char * s, int i #else # define GC_EXTRAS __FILE__, __LINE__ # define GC_EXTRA_PARAMS GC_CONST char * s, int i diff --git a/boehm-gc/reclaim.c b/boehm-gc/reclaim.c index 57c652ef265..4ace1107d62 100644 --- a/boehm-gc/reclaim.c +++ b/boehm-gc/reclaim.c @@ -236,18 +236,9 @@ register word sz; /* Clear object, advance p to next object in the process */ q = p + sz; p++; /* Skip link field */ -# if defined(SMALL_CONFIG) && defined(ALIGN_DOUBLE) - /* We assert that sz must be even */ - *p++ = 0; - while (p < q) { - CLEAR_DOUBLE(p); - p += 2; - } -# else - while (p < q) { + while (p < q) { *p++ = 0; - } -# endif + } } word_no += sz; } @@ -604,20 +595,32 @@ int report_if_found; /* Abort if a reclaimable object is found */ switch(sz) { # ifndef SMALL_CONFIG case 1: - full = GC_block_nearly_full1(hhdr, 0xffffffffl); +# if CPP_WORDSZ == 64 + full = GC_block_nearly_full1(hhdr, 0xffffffffffffffffl); +# else + full = GC_block_nearly_full1(hhdr, 0xffffffffl); +# endif if (TRUE == full) goto out; if (FALSE == full) GC_write_hint(hbp); /* In the DONT_KNOW case, we let reclaim fault. */ *flh = GC_reclaim1(hbp, hhdr, *flh); break; case 2: - full = GC_block_nearly_full1(hhdr, 0x55555555l); +# if CPP_WORDSZ == 64 + full = GC_block_nearly_full1(hhdr, 0x5555555555555555l); +# else + full = GC_block_nearly_full1(hhdr, 0x55555555l); +# endif if (TRUE == full) goto out; if (FALSE == full) GC_write_hint(hbp); *flh = GC_reclaim_clear2(hbp, hhdr, *flh); break; case 4: - full = GC_block_nearly_full1(hhdr, 0x11111111l); +# if CPP_WORDSZ == 64 + full = GC_block_nearly_full1(hhdr, 0x1111111111111111l); +# else + full = GC_block_nearly_full1(hhdr, 0x11111111l); +# endif if (TRUE == full) goto out; if (FALSE == full) GC_write_hint(hbp); *flh = GC_reclaim_clear4(hbp, hhdr, *flh); @@ -634,19 +637,31 @@ int report_if_found; /* Abort if a reclaimable object is found */ switch(sz) { # ifndef SMALL_CONFIG case 1: - full = GC_block_nearly_full1(hhdr, 0xffffffffl); +# if CPP_WORDSZ == 64 + full = GC_block_nearly_full1(hhdr, 0xffffffffffffffffl); +# else + full = GC_block_nearly_full1(hhdr, 0xffffffffl); +# endif if (TRUE == full) goto out; if (FALSE == full) GC_write_hint(hbp); *flh = GC_reclaim1(hbp, hhdr, *flh); break; case 2: - full = GC_block_nearly_full1(hhdr, 0x55555555l); +# if CPP_WORDSZ == 64 + full = GC_block_nearly_full1(hhdr, 0x5555555555555555l); +# else + full = GC_block_nearly_full1(hhdr, 0x55555555l); +# endif if (TRUE == full) goto out; if (FALSE == full) GC_write_hint(hbp); *flh = GC_reclaim_uninit2(hbp, hhdr, *flh); break; case 4: - full = GC_block_nearly_full1(hhdr, 0x11111111l); +# if CPP_WORDSZ == 64 + full = GC_block_nearly_full1(hhdr, 0x1111111111111111l); +# else + full = GC_block_nearly_full1(hhdr, 0x11111111l); +# endif if (TRUE == full) goto out; if (FALSE == full) GC_write_hint(hbp); *flh = GC_reclaim_uninit4(hbp, hhdr, *flh); diff --git a/boehm-gc/typd_mlc.c b/boehm-gc/typd_mlc.c index ce769d60fec..a198f6c154d 100644 --- a/boehm-gc/typd_mlc.c +++ b/boehm-gc/typd_mlc.c @@ -175,7 +175,7 @@ GC_descr GC_double_descr(descriptor, nwords) register GC_descr descriptor; register word nwords; { - if (descriptor && DS_TAGS == DS_LENGTH) { + if (descriptor & DS_TAGS == DS_LENGTH) { descriptor = GC_bm_table[BYTES_TO_WORDS((word)descriptor)]; }; descriptor |= (descriptor & ~DS_TAGS) >> nwords; diff --git a/boehm-gc/version.h b/boehm-gc/version.h index 2c69e44dd31..04787d85be3 100644 --- a/boehm-gc/version.h +++ b/boehm-gc/version.h @@ -1,5 +1,5 @@ #define GC_VERSION_MAJOR 5 -#define GC_VERSION_MINOR 0 +#define GC_VERSION_MINOR 1 #define GC_ALPHA_VERSION GC_NOT_ALPHA # define GC_NOT_ALPHA 0xff |