thanks to drahn@ update to gc6.1 (misc bugfixes, I've heard good things, etc,

best of all, you can drop this in on shared archs as a replacement for 6.0,
I've tested opencm and w3m)
This commit is contained in:
todd 2002-10-26 13:25:26 +00:00
parent 65096cfbee
commit 33248e4bbc
8 changed files with 59 additions and 140 deletions

View File

@ -1,9 +1,9 @@
# $OpenBSD: Makefile,v 1.21 2002/09/16 22:00:13 todd Exp $
# $OpenBSD: Makefile,v 1.22 2002/10/26 13:25:26 todd Exp $
# $FreeBSD: Makefile,v 1.4 1999/01/10 20:12:06 steve Exp $
COMMENT= "garbage collection and memory leak detection for C and C++"
VERSION= 6.0
VERSION= 6.1
DISTNAME= gc${VERSION}
PKGNAME= boehm-gc-${VERSION}
CATEGORIES= devel
@ -23,8 +23,9 @@ MAKE_ENV= CP="cp" \
INSTALL_MAN="${INSTALL_MAN}"
CONFIGURE_STYLE=gnu
CONFIGURE_ARGS= ${CONFIGURE_SHARED}
WRKDIST= ${WRKDIR}/gc6.0
WRKDIST= ${WRKDIR}/gc6.1
post-patch:
@mv ${WRKSRC}/doc/gc.man ${WRKSRC}/doc/gc.man.in

View File

@ -1,3 +1,3 @@
MD5 (gc6.0.tar.gz) = 528371164ac9838dcb263fede456eff6
RMD160 (gc6.0.tar.gz) = 51d6001d7a6d88f6f9ab4e9dbf3d38352b2460cc
SHA1 (gc6.0.tar.gz) = 9698826b33472b314d7b2eb640c1669ce05f5277
MD5 (gc6.1.tar.gz) = 00a87b68f4baa21c56fa42d811e98f7c
RMD160 (gc6.1.tar.gz) = 2d29ab16ba5467c1ca208829345a04a813529629
SHA1 (gc6.1.tar.gz) = 043d51316ebb7f0ac919e4a72c456f269e604d2f

View File

@ -1,6 +1,6 @@
$OpenBSD: patch-doc_gc_man,v 1.1 2002/08/27 15:41:30 todd Exp $
--- doc/gc.man.orig Wed Sep 22 01:55:00 1999
+++ doc/gc.man Sat Jul 27 01:04:55 2002
$OpenBSD: patch-doc_gc_man,v 1.2 2002/10/26 13:25:26 todd Exp $
--- doc/gc.man.orig Tue Sep 21 18:55:00 1999
+++ doc/gc.man Fri Oct 25 11:53:09 2002
@@ -68,6 +68,48 @@ This may temporarily write protect pages
.LP
Other facilities not discussed here include limited facilities to support incremental collection on machines without appropriate VM support, provisions for providing more explicit object layout information to the garbage collector, more direct support for ``weak'' pointers, support for ``abortable'' garbage collections during idle time, etc.

View File

@ -1,25 +1,36 @@
$OpenBSD: patch-dyn_load_c,v 1.1 2002/08/27 15:41:30 todd Exp $
--- dyn_load.c.orig Tue Jun 26 04:37:38 2001
+++ dyn_load.c Wed Jul 31 05:06:30 2002
@@ -53,6 +53,7 @@
!(defined(ALPHA) && defined(OSF1)) && \
$OpenBSD: patch-dyn_load_c,v 1.2 2002/10/26 13:25:26 todd Exp $
--- dyn_load.c.orig Tue Aug 6 15:14:31 2002
+++ dyn_load.c Fri Oct 25 12:37:33 2002
@@ -57,6 +57,7 @@
!defined(HPUX) && !(defined(LINUX) && defined(__ELF__)) && \
!defined(RS6000) && !defined(SCO_ELF) && \
!defined(RS6000) && !defined(SCO_ELF) && !defined(DGUX) && \
!(defined(FREEBSD) && defined(__ELF__)) && \
+ !(defined(OPENBSD) && defined(__ELF__)) && \
!(defined(NETBSD) && defined(__ELF__)) && !defined(HURD)
--> We only know how to find data segments of dynamic libraries for the
--> above. Additional SVR4 variants might not be too
@@ -243,6 +244,7 @@ void GC_register_dynamic_libraries()
# endif /* SUNOS */
@@ -81,9 +82,9 @@
#if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \
(defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \
+ (defined(OPENBSD) && defined(__ELF__)) || \
(defined(NETBSD) && defined(__ELF__)) || defined(HURD)
# include <stddef.h>
-# include <elf.h>
# include <link.h>
#endif
@@ -265,6 +266,7 @@ void GC_register_dynamic_libraries()
#if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \
(defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \
+ (defined(OPENBSD) && defined(__ELF__)) || \
(defined(NETBSD) && defined(__ELF__)) || defined(HURD)
@@ -424,7 +426,7 @@ static char *parse_map_entry(char *buf_p
* This code was derived from the Solaris/ELF support. Thanks to
* whatever kind soul wrote that. - Patrick Bridges */
@@ -533,7 +535,7 @@ GC_bool GC_register_dynamic_libraries_dl
/* This doesn't necessarily work in all cases, e.g. with preloaded
* dynamic libraries. */
-#if defined(NETBSD)
+#if defined(NETBSD) || defined(OPENBSD)

View File

@ -1,8 +1,8 @@
$OpenBSD: patch-include_private_gcconfig_h,v 1.2 2002/09/12 06:47:16 pvalchev Exp $
--- include/private/gcconfig.h.orig Thu Jul 26 11:28:57 2001
+++ include/private/gcconfig.h Tue Jul 23 08:22:31 2002
@@ -33,6 +33,10 @@
# define NETBSD
$OpenBSD: patch-include_private_gcconfig_h,v 1.3 2002/10/26 13:25:26 todd Exp $
--- include/private/gcconfig.h.orig Tue Aug 6 13:49:22 2002
+++ include/private/gcconfig.h Fri Oct 25 12:32:52 2002
@@ -51,6 +51,10 @@
# define FREEBSD
# endif
+# if defined(__OpenBSD__)
@ -10,52 +10,21 @@ $OpenBSD: patch-include_private_gcconfig_h,v 1.2 2002/09/12 06:47:16 pvalchev Ex
+# endif
+
/* Determine the machine type: */
# if defined(sun) && defined(mc68000)
# define M68K
@@ -46,12 +50,14 @@
# endif
# if defined(__OpenBSD__) && defined(m68k)
# define M68K
-# define OPENBSD
# define mach_type_known
# endif
# if defined(__OpenBSD__) && defined(__sparc__)
# define SPARC
-# define OPENBSD
+# define mach_type_known
+# endif
+# if defined(__OpenBSD__) && defined(__powerpc__)
+# define POWERPC
# define mach_type_known
# endif
# if defined(__NetBSD__) && defined(m68k)
@@ -66,7 +72,7 @@
# if defined(__XSCALE__)
# define ARM32
@@ -270,6 +274,11 @@
# define POWERPC
# define mach_type_known
# endif
-# if defined(vax)
+# if defined(vax) || defined(__vax__)
# define VAX
# ifdef ultrix
# define ULTRIX
@@ -196,7 +202,7 @@
# endif
# if defined(__alpha) || defined(__alpha__)
# define ALPHA
-# if !defined(LINUX) && !defined(NETBSD)
+# if !defined(LINUX) && !defined(NETBSD) && !defined(OPENBSD)
# define OSF1 /* a.k.a Digital Unix */
# endif
# define mach_type_known
@@ -241,7 +247,6 @@
# endif
# if defined(__OpenBSD__) && (defined(i386) || defined(__i386__))
# define I386
-# define OPENBSD
# define mach_type_known
# endif
# if defined(__FreeBSD__) && (defined(i386) || defined(__i386__))
@@ -664,6 +669,14 @@
+# if defined(__OpenBSD__) && (defined(__powerpc__))
+# define POWERPC
+# define OPENBSD
+# define mach_type_known
+# endif
# if defined(__APPLE__) && defined(__MACH__) && defined(__i386__)
# define MACOSX
# define I386
@@ -726,6 +735,14 @@
# define DATASTART GC_data_start
# define DYNAMIC_LOADING
# endif
@ -70,48 +39,7 @@ $OpenBSD: patch-include_private_gcconfig_h,v 1.2 2002/09/12 06:47:16 pvalchev Ex
# ifdef NOSYS
# define ALIGNMENT 4
# define OS_TYPE "NOSYS"
@@ -793,9 +806,18 @@
# endif
# ifdef OPENBSD
# define OS_TYPE "OPENBSD"
-# define STACKBOTTOM ((ptr_t) 0xf8000000)
- extern int etext;
-# define DATASTART ((ptr_t)(&etext))
+# define HEURISTIC2
+# ifdef __arch64__
+# define CPP_WORDSZ 64
+# define ELF_CLASS ELFCLASS64
+# endif
+# ifdef __ELF__
+# define DATASTART GC_data_start
+# define DYNAMIC_LOADING
+# else
+ extern char etext;
+# define DATASTART ((ptr_t)(&etext))
+# endif
# endif
# ifdef NETBSD
# define OS_TYPE "NETBSD"
@@ -1000,6 +1022,9 @@
# endif
# ifdef OPENBSD
# define OS_TYPE "OPENBSD"
+# define HEURISTIC2
+ extern char etext;
+# define DATASTART ((ptr_t)(&etext))
# endif
# ifdef FREEBSD
# define OS_TYPE "FREEBSD"
@@ -1015,7 +1040,7 @@
# ifdef BSDI
# define OS_TYPE "BSDI"
# endif
-# if defined(OPENBSD) || defined(NETBSD) || defined(FREEBSD) \
+# if defined(NETBSD) || defined(FREEBSD) \
|| defined(THREE86BSD) || defined(BSDI)
# define HEURISTIC2
extern char etext;
@@ -1238,6 +1263,14 @@
@@ -1393,6 +1410,14 @@
# define DATASTART GC_data_start
# define ELFCLASS32 32
# define ELFCLASS64 64
@ -124,5 +52,5 @@ $OpenBSD: patch-include_private_gcconfig_h,v 1.2 2002/09/12 06:47:16 pvalchev Ex
+# define HEURISTIC2
+# define DATASTART GC_data_start
# define ELF_CLASS ELFCLASS64
# define CPP_WORDSZ 64
# define DYNAMIC_LOADING
# endif

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-mach_dep_c,v 1.1 2002/08/27 15:41:30 todd Exp $
--- mach_dep.c.orig Wed Jun 27 22:54:23 2001
+++ mach_dep.c Wed Jul 31 05:04:41 2002
@@ -462,7 +462,7 @@ ptr_t cold_gc_frame;
$OpenBSD: patch-mach_dep_c,v 1.2 2002/10/26 13:25:26 todd Exp $
--- mach_dep.c.orig Wed Jul 31 17:12:03 2002
+++ mach_dep.c Fri Oct 25 11:53:09 2002
@@ -446,7 +446,7 @@ ptr_t cold_gc_frame;
/* the stack. Return sp. */
# ifdef SPARC
asm(" .seg \"text\"");

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-misc_c,v 1.1 2002/08/27 15:41:30 todd Exp $
--- misc.c.orig Wed Jul 31 06:36:17 2002
+++ misc.c Wed Jul 31 06:35:36 2002
@@ -527,6 +527,9 @@ void GC_init_inner()
# if defined(NETBSD) && defined(__ELF__)
GC_init_netbsd_elf();
# endif
+# if defined(OPENBSD) && defined(__ELF__)
+ GC_init_openbsd_elf();
+# endif
# if defined(IRIX_THREADS) || defined(LINUX_THREADS) \
|| defined(HPUX_THREADS) || defined(SOLARIS_THREADS)
GC_thr_init();

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-os_dep_c,v 1.1 2002/08/27 15:41:30 todd Exp $
--- os_dep.c.orig Thu Jul 26 20:39:45 2001
+++ os_dep.c Wed Jul 31 07:29:54 2002
@@ -232,6 +232,19 @@ static void *tiny_sbrk(ptrdiff_t increme
$OpenBSD: patch-os_dep_c,v 1.2 2002/10/26 13:25:26 todd Exp $
--- os_dep.c.orig Wed Jul 31 17:13:18 2002
+++ os_dep.c Fri Oct 25 12:30:33 2002
@@ -233,6 +233,19 @@ static void *tiny_sbrk(ptrdiff_t increme
}
#endif
@ -21,11 +21,3 @@ $OpenBSD: patch-os_dep_c,v 1.1 2002/08/27 15:41:30 todd Exp $
# ifdef OS2
# include <stddef.h>
@@ -630,7 +643,6 @@ ptr_t GC_get_stack_base()
/* preserved across the longjmp. Can safely be */
/* static since it's only called once, with the */
/* allocation lock held. */
-
GC_setup_temporary_fault_handler();
if (setjmp(GC_jmp_buf) == 0) {