aboutsummaryrefslogtreecommitdiff
path: root/boehm-gc/misc.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@gcc.gnu.org>1999-04-07 08:01:42 +0000
committerTom Tromey <tromey@gcc.gnu.org>1999-04-07 08:01:42 +0000
commit1530be84fcd15570f9885c29a8cc94880ecd6d57 (patch)
tree7f963ae6b27df44232d80c837e9ccc32932e94af /boehm-gc/misc.c
parent537cff9c871369177f5c01fe02d3a9dd85492750 (diff)
downloadgcc-1530be84fcd15570f9885c29a8cc94880ecd6d57.zip
gcc-1530be84fcd15570f9885c29a8cc94880ecd6d57.tar.gz
gcc-1530be84fcd15570f9885c29a8cc94880ecd6d57.tar.bz2
Cygnus/libgcj changes to Boehm GC.
From-SVN: r26257
Diffstat (limited to 'boehm-gc/misc.c')
-rw-r--r--boehm-gc/misc.c27
1 files changed, 24 insertions, 3 deletions
diff --git a/boehm-gc/misc.c b/boehm-gc/misc.c
index 4c76af8..94e1957 100644
--- a/boehm-gc/misc.c
+++ b/boehm-gc/misc.c
@@ -48,7 +48,11 @@
# endif
pthread_t GC_lock_holder = NO_THREAD;
# else
- --> declare allocator lock here
+# if defined(QUICK_THREADS)
+ /* Nothing. */
+# else
+ --> declare allocator lock here
+# endif
# endif
# endif
# endif
@@ -56,6 +60,10 @@
# endif
# endif
+#ifdef ECOS
+#undef STACKBASE
+#endif
+
GC_FAR struct _GC_arrays GC_arrays /* = { 0 } */;
@@ -391,6 +399,10 @@ size_t GC_get_bytes_since_gc GC_PROTO(())
GC_bool GC_is_initialized = FALSE;
+#if defined(SOLARIS_THREADS) || defined(IRIX_THREADS)
+ extern void GC_thr_init();
+#endif
+
void GC_init()
{
DCL_LOCK_STATE;
@@ -435,7 +447,7 @@ void GC_init_inner()
# if !defined(THREADS) || defined(SOLARIS_THREADS) || defined(WIN32_THREADS) \
|| defined(IRIX_THREADS) || defined(LINUX_THREADS)
if (GC_stackbottom == 0) {
- GC_stackbottom = GC_get_stack_base();
+ GC_stackbottom = GC_get_stack_base();
}
# endif
if (sizeof (ptr_t) != sizeof(word)) {
@@ -637,7 +649,7 @@ int GC_tmp; /* Should really be local ... */
# endif
#endif
-#if !defined(MSWIN32) && !defined(OS2) && !defined(MACOS)
+#if !defined(MSWIN32) && !defined(OS2) && !defined(MACOS) && !defined(ECOS)
int GC_write(fd, buf, len)
int fd;
char *buf;
@@ -660,6 +672,15 @@ size_t len;
}
#endif /* UN*X */
+#if defined(ECOS)
+int GC_write(fd, buf, len)
+{
+ _Jv_diag_write (buf, len);
+ return len;
+}
+#endif
+
+
#ifdef MSWIN32
# define WRITE(f, buf, len) (GC_set_files(), \
GC_tmp = WriteFile((f), (buf), \