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 X-Apparently-From: Message-ID: <3AD06DB0.8756E06@yahoo.com> Date: Sun, 08 Apr 2001 09:54:56 -0400 From: Earnie Boyd Reply-To: Earnie Boyd X-Mailer: Mozilla 4.76 [en] (WinNT; U) X-Accept-Language: en MIME-Version: 1.0 To: Earnie Boyd CC: Joost Kraaijeveld Subject: [Fwd: FW: pthread_create problem in Cygwin 1.1.8-2] Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit -------- Original Message -------- Subject: FW: pthread_create problem in Cygwin 1.1.8-2 Date: Sun, 8 Apr 2001 15:40:43 +0200 From: Joost Kraaijeveld To: "'earnie_boyd AT yahoo DOT com'" Hi Earnie, I just received notice from the cygwin mailing list that the smtp server of my provider made it to the ORBS list so I send to reply to you directly. If you could send my reply by any chanche to the list I would be gratefull because it is a showstopping bug that I cannot resolve. I am using: Reading specs from /bin/../lib/gcc-lib/i686-pc-cygwin/2.95.3-2/specs gcc version 2.95.3-2 (cygwin special) Additional testing showes that if I insert a Sleep(500) in the threadFunction() just before the return 0 it only crahes 3-5 times of the 10 runs. Also, it crashes more often after fast repeated runs of the program. It also crashes more often on faster hardware (I have tested on two machines, PII 400 and a PIII 700, both 256 MB RAM). Running only 1 thread instead of two does not crash the program. If I run it through GDB it shows that the crash occurs after the "return 0" but before the closing bracket of the for loop (see the mixed output of the debugger source window below, the offending line is marked by me with a "+"). It gives a SIGSEGV for both threads. Joost 10 { 11 printf("%lu\n",i); - 0x4010ac : add $0xfffffff8,%esp - 0x4010af : mov 0xffffffdc(%ebp),%eax - 0x4010b2 : push %eax - 0x4010b3 : push $0x401044 - 0x4010b8 : call 0x404cc8 - 0x4010bd : add $0x10,%esp 12 } - 0x4010c0 : incl 0xffffffdc(%ebp) - 0x4010c3 : jmp 0x4010a4 - 0x4010c5 : lea 0x0(%esi),%esi 13 // Sleep(500); 14 return 0; - 0x4010c8 : mov 0xffffff9c(%ebp),%eax - 0x4010cb : add $0x4,%eax - 0x4010ce : mov (%eax),%edx + 0x4010d0 : mov (%edx),%ecx - 0x4010d2 : mov %ecx,(%eax) - 0x4010d4 : xor %eax,%eax - 0x4010d6 : jmp 0x4011bc - 0x4010db : mov 0xffffff9c(%ebp),%eax - 0x4010de : add $0x4,%eax - 0x4010e1 : mov (%eax),%edx - 0x4010e3 : mov (%edx),%ecx - 0x4010e5 : mov %ecx,(%eax) 15 } 16 catch(...) _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple