+Mon Jan 24 15:59:54 CET 2005 Paolo Molaro <lupus@ximian.com>
+
+ * gc.c: remove valgrind detection nonsense. Set GC_DONT_GC
+ if you don't want the GC to run.
+
Mon Jan 24 15:53:25 CET 2005 Paolo Molaro <lupus@ximian.com>
* Makefile.am, gc.c, mono-gc.h, boehm-gc.c, null-gc.c, gc-internal.h:
#define GC_finalize_on_demand __imp_GC_finalize_on_demand
#endif
-#ifdef HAVE_VALGRIND_MEMCHECK_H
-#include <valgrind/memcheck.h>
-#endif
-
static int finalize_slot = -1;
static gboolean gc_disabled = FALSE;
mono_trace (G_LOG_LEVEL_WARNING, MONO_TRACE_GC, msg, (unsigned long)arg);
}
-static gboolean
-mono_running_on_valgrind (void)
-{
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- if (RUNNING_ON_VALGRIND)
- return TRUE;
- else
- return FALSE;
-#else
- return FALSE;
-#endif
-}
-
-
void mono_gc_init (void)
{
InitializeCriticalSection (&handle_section);
return;
}
- /* valgrind does not play nicely with the GC,
- * so, turn it off when we are under vg.
- */
- if (mono_running_on_valgrind ()) {
- /* valgrind doesnt like g_warning for some reason... */
- printf ("You are running under valgrind. Currently, valgrind does "
- "not support the GC. This program will run with the GC "
- "turned off. Your program may take up a fair amount of "
- "memory. Also, finalizers will not be run.\n");
-
- gc_disabled = TRUE;
- return;
- }
-
finalizer_event = CreateEvent (NULL, FALSE, FALSE, NULL);
pending_done_event = CreateEvent (NULL, TRUE, FALSE, NULL);
shutdown_event = CreateEvent (NULL, TRUE, FALSE, NULL);