gnustep-dev
[Top][All Lists]
Advanced

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

Re: SEGFAULT with a multithread foundation(base) tools samples


From: Thierry DELHAISE
Subject: Re: SEGFAULT with a multithread foundation(base) tools samples
Date: Mon, 10 Jan 2005 23:28:56 +0100


Le 9 janv. 05, à 18:29, Fred Kiefer a écrit :

Thierry DELHAISE wrote:
I've wrote a sample Foundation "tools" to test threads communications : this tools work on OS/X (don't segfault).
it segfault under a Linux machine :
- Kernel 2.6.8-1-686-smp (Debian 3.1) : it's really an SMP machine (2x PIII 800).
- gcc -v
Reading specs from /usr/lib/gcc-lib/i486-linux/3.3.5/specs
Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,pascal,objc,ada,treelang --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-gxx-include-dir=/usr/include/c++/3.3 --enable-shared --with-system-zlib --enable-nls --without-included-gettext --enable-__cxa_atexit --enable-clocale=gnu --enable-debug --enable-java-gc=boehm --enable-java-awt=xlib --enable-objc-gc i486-linux
Thread model: posix
gcc version 3.3.5 (Debian 1:3.3.5-5)
gnustep-base (Foundation) is the last debian package : 1.10.1-2
-
My original dev platform is an OS/X 10.3.7 with Apple Developper tools :
gcc -v
Reading specs from /usr/libexec/gcc/darwin/ppc/3.3/specs
Thread model: posix
gcc version 3.3 20030304 (Apple Computer, Inc. build 1666)
I join a gz of the GNUstep project I've made : I've modify no source code to build this sample : just add a GNUmakefile...

I just tried your code on a single processor GNUstep machine and it works there, so you may be right that there is a problem with thread safety in GNUstep. No idea how I should investigate this further as I cannot reproduce this.
Is your Apple machine also a multiprocessor one?

Yes it is a PowerMac G5 Bi Processor 2Ghz under 10.3.7 and I use for sure the Apple developper tools provide for 10.3.

Since some discussions on irc #gnustep this afternoon, I will follow advice of aeruder (may be it's you ? ;-) ) and will build my GNUstep Foundation from source with debug symbols and will post the result of the segfault :

in gdb with the libFoundation provide by debian from package libFoundation_d 1.10.1-2, it seems it segfault when the second thread reach [pool release]; at the end of class method used as the selector parameter of [NSThread] : connectWithPorts;

Just an idea : does the use of boem_gc (--enable-objc-gc) in the standard compiler tools chain provide by debian for gcc 3.3.5 in objc language could be the source of my problem ?



Cheers
Fred


THX

Thierry (befree)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]