Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Date: Sun, 8 Apr 2001 19:35:22 -0400 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: G++ guru's please comment - Re: FW: pthread_create problem in Cygwin 1.1.8-2] Message-ID: <20010408193522.B19783@redhat.com> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <001301c0c071$d5aaec80$0200a8c0 AT lifelesswks> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.11i In-Reply-To: <001301c0c071$d5aaec80$0200a8c0@lifelesswks>; from robert.collins@itdomain.com.au on Mon, Apr 09, 2001 at 07:21:09AM +1000 On Mon, Apr 09, 2001 at 07:21:09AM +1000, Robert Collins wrote: >----- Original Message ----- >From: "Joost Kraaijeveld" >To: "'Robert Collins'" >Sent: Monday, April 09, 2001 1:45 AM >Subject: RE: G++ guru's please comment - Re: FW: pthread_create problem >in Cygwin 1.1.8-2] > >> > Also, printf doesn't appear to be atomic and threadsafe (lines got >> > interspersed). You might be hitting something there, but I doubt it >> > (crashing in the wrong place). >> I have noticed that, but crashing was a little bit more urgent than a >> non-thread safe printf. >> >> >>>1) It's possible it's a problem with the thread exiting code, could you >>>try using a pthread_exit call instead of return and report back. >>I replaced return 0 with pthread_exit(0) andf now id does not crash on >>any computer. > >hmm. This really needs a compiler expert to jump in and comment now >(that reduces the likelyhood that it's a thread specific fault. It's not likely that it is a compiler problem. pthread_create calls __pthread_create which calls the user function. If the user function returns it should it a __pthread_exit. If it doesn't hit the __pthread_exit, then that would mean that the stack is corrupted somehow. That should be pretty simple to debug. >>> 2) What cygwin1.dll are you using? I'm using a custom build ~= to the >> > latest snapshot. >> $ uname -a >> CYGWIN_NT-5.0 ABRARACOURCIX 1.1.8(0.34/3/2) 2001-01-31 10:08 i686 unknown i.e., not a snapshot. cgf -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple