[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [buildd] Etch?



Hi,

On Thursday 03 August 2006 20:06, Stephen R Marenka wrote:

> The -O2 bug which I started playing with in 378599 in particular is
> annoying me because I haven't had time to get back to it. libgc is a good
> candidate example, something about the selftest program itself gets
> miscompiled. It looks like the library compiles fine -O2, but the self-test
> program needs to be compiled -O0.
>
> Hopefully the same bug seems to be causing the binutils problems documented
> in 378355. I doing a binNMU of binutils with -O0, which will hopefully
> get kdelibs back on track.

I'm afraid not, but at least we'll soon have a working libgc.
The thread suspend handler doesn't save all registers, so some pointers are 
lost. I attached an initial patch to fix it.

bye, Roman
diff -ur include/private/gcconfig.h include/private/gcconfig.h
--- include/private/gcconfig.h	2006-02-17 05:34:18.000000000 +0100
+++ include/private/gcconfig.h	2006-08-04 01:11:55.000000000 +0200
@@ -676,7 +676,7 @@
 #       define STACKBOTTOM ((ptr_t)0xf0000000)
 #       define USE_GENERIC_PUSH_REGS
 		/* We never got around to the assembly version. */
-/* #       define MPROTECT_VDB - Reported to not work  9/17/01 */
+#       define MPROTECT_VDB
 #       ifdef __ELF__
 #            define DYNAMIC_LOADING
 #	     include <features.h>
diff -ur pthread_stop_world.c pthread_stop_world.c
--- pthread_stop_world.c	2006-03-03 21:01:48.000000000 +0100
+++ pthread_stop_world.c	2006-08-04 02:28:42.000000000 +0200
@@ -186,7 +187,8 @@
 #   ifdef SPARC
 	me -> stop_info.stack_ptr = (ptr_t)GC_save_regs_in_stack();
 #   else
-	me -> stop_info.stack_ptr = (ptr_t)(&dummy);
+	__builtin_unwind_init();
+	me -> stop_info.stack_ptr = GC_approx_sp();
 #   endif
 #   ifdef IA64
 	me -> backing_store_ptr = (ptr_t)GC_save_regs_in_stack();
diff -ur pthread_support.c pthread_support.c
--- pthread_support.c	2006-02-17 05:07:50.000000000 +0100
+++ pthread_support.c	2006-08-04 02:17:28.000000000 +0200
@@ -1003,6 +1003,7 @@
 	me -> stop_info.stack_ptr = (ptr_t)GC_save_regs_in_stack();
 #   else
 #   ifndef GC_DARWIN_THREADS
+	__builtin_unwind_init();
 	me -> stop_info.stack_ptr = (ptr_t)GC_approx_sp();
 #   endif
 #   endif

Reply to: