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 Message-ID: <8D00C32549556B4E977F81DBC24E985DC80C@crtsmail1.technol_exch.corp.riotinto.org> From: "Billinghurst, David (CRTS)" To: cygwin AT cygwin DOT com Subject: RE: pthreads update for the adventurous Date: Fri, 13 Apr 2001 12:55:22 -0000 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain OK. I'll bite. I have built cygwin1.dll from cvs, then proceeded to build and test gcc-3.0 with --enable-threads=posix. This seems to work OK. I then tried example 1 from http://www.llnl.gov/computing/tutorials/workshops/workshop/pthreads/MAIN.htm l (below) using standard cygwin gcc-2.95.3-2 and the gcc-3.0 I built. There appears to be a problem with pthread_exit() as the program never exits. I tried to debug this, but soon got lost. /*************************************************************************** *** * FILE: hello.c * DESCRIPTION: * A "hello world" Pthreads program. Demonstrates thread creation and * termination. * * SOURCE: * LAST REVISED: 9/20/98 Blaise Barney **************************************************************************** **/ #include #include #define NUM_THREADS 5 void *PrintHello(void *threadid) { printf("\n%d: Hello World!\n", threadid); pthread_exit(NULL); } int main() { pthread_t threads[NUM_THREADS]; int rc, t; for(t=0;t