summaryrefslogtreecommitdiff
path: root/boehm-gc/include/gc.h
diff options
context:
space:
mode:
authorBryce McKinlay <bryce@waitaki.otago.ac.nz>2001-10-23 00:28:56 +0000
committerBryce McKinlay <bryce@gcc.gnu.org>2001-10-23 01:28:56 +0100
commitaeb76991de5a1a2d628685c01d66871459f8fc4f (patch)
treede56600c16419b970a38e8a7932d6f2c3e30d191 /boehm-gc/include/gc.h
parentb45bc005dc8978f353795c2886992df4a4e140f1 (diff)
downloadgcc-aeb76991de5a1a2d628685c01d66871459f8fc4f.tar.gz
linux_threads.c (GC_init_parallel): Do not declare as a static constructor.
* linux_threads.c (GC_init_parallel): Do not declare as a static constructor. * include/gc.h (GC_init): Declare here. Add description. * include/private/gc_priv.h (GC_init): Remove declaration. From-SVN: r46420
Diffstat (limited to 'boehm-gc/include/gc.h')
-rw-r--r--boehm-gc/include/gc.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/boehm-gc/include/gc.h b/boehm-gc/include/gc.h
index 8ac709b9b5d..c73ecc0ae7a 100644
--- a/boehm-gc/include/gc.h
+++ b/boehm-gc/include/gc.h
@@ -297,6 +297,14 @@ GC_API int GC_dont_precollect; /* Don't collect as part of */
/* Wizards only. */
/* Public procedures */
+
+/* Initialize the collector. This is only required when using thread-local
+ * allocation, since unlike the regular allocation routines, GC_local_malloc
+ * is not self-initializing. If you use GC_local_malloc you should arrange
+ * to call this somehow (e.g. from a constructor) before doing any allocation.
+ */
+GC_API void GC_init GC_PROTO((void));
+
/*
* general purpose allocation routines, with roughly malloc calling conv.
* The atomic versions promise that no relevant pointers are contained