delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/10/08/11:04:56

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS
X-Spam-Check-By: sourceware.org
Message-ID: <4ACE0301.3090508@gmail.com>
Date: Thu, 08 Oct 2009 16:19:29 +0100
From: Dave Korn <dave DOT korn DOT cygwin AT googlemail DOT com>
User-Agent: Thunderbird 2.0.0.17 (Windows/20080914)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Thread related crash
References: <4ACDCA99 DOT 9090400 AT cwilson DOT fastmail DOT fm>
In-Reply-To: <4ACDCA99.9090400@cwilson.fastmail.fm>
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Charles Wilson wrote:

> I have an idea why this is happening: I'm managing these threads
> manually using the windows API calls: CreateThread, WaitForSingleObject,
> SetEvent, etc. They are NOT actually started by cygwin's thread
> launching facilities (e.g. pthread). 

  Then you are doomed.  Cygwin's pthread layer will believe that every single
foreign thread is in fact the same thread, and they will all crash happily
through each other's mutexes.  Fun'n'games result.  (This is the same kind of
problem that the half-ming-half-cyg gnat implementation suffers.)

    cheers,
      DaveK


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019