[Mono-devel-list] The debugger is working again :-)

Martin Baulig martin at gnome.org
Sat Apr 5 15:21:25 EST 2003


Hi guys,

the new code is now in CVS and the debugger is working again :-)

You need a modified version of Boehm GC for this, you can find it in the `libgc' module in
CVS.  Compile and install it like the normal GC (ie. with the --enable-threads=pthreads
configure argument) and then recompile everything.

Note that you need to fully recompile the runtime after installing the new libgc as it
#define's some things in its header files.

After that, you can compile the debugger and it should work with garbage collection.

Here's a small test case:

====
using System;
using System.Threading;

class X
{
	static void ThreadFunc ()
	{
		while (true) {
			Console.WriteLine ("Test!");
			Thread.Sleep (500);
		}
	}

	static void Main ()
	{
		Thread thread = new Thread (new ThreadStart (ThreadFunc));
		thread.Start ();

		Console.WriteLine ("Starting to collect");
		GC.Collect ();
		Console.WriteLine ("Done collecting.");
	}
}
====

You should be able to single-step this in the debugger without getting a hang in the
GC.Collect() call.

I'll make a new debugger release really soon, I'm just waiting for new Mono and gtk#
releases.

If you have any questions or problems, just ask ....

-- 
Martin Baulig
martin at gnome.org
martin at ximian.com



More information about the Mono-devel-list mailing list