Received: from PACIFIC-CARRIER-ANNEX.MIT.EDU by po7.MIT.EDU (5.61/4.7) id AA21072; Fri, 19 Jan 96 22:40:49 EST
Received: from cygnus.com by MIT.EDU with SMTP
	id AA09227; Fri, 19 Jan 96 22:39:11 EST
Received: from tweedledumb.cygnus.com (tweedledumb.cygnus.com [192.80.44.1]) by cygnus.com (8.6.12/8.6.9) with SMTP id TAA29027; Fri, 19 Jan 1996 19:39:01 -0800
Received: from cujo.cygnus.com by tweedledumb.cygnus.com (4.1/4.7) id AA25117; Fri, 19 Jan 96 22:38:53 EST
Received: by cujo.cygnus.com; (5.65v3.2/1.1.8.2/20Sep95-0235PM)
	id AA25461; Fri, 19 Jan 1996 22:38:51 -0500
To: "Lars Jonas Olsson" <jonas@mcs.com>
Cc: pthreads@MIT.EDU
Subject: Re: pthreads and C++
References: <m0tdHBi-0005yYC@mars.mcs.com>
From: raeburn@cygnus.com (Ken Raeburn)
Date: 19 Jan 1996 22:38:51 -0500
In-Reply-To: "Lars Jonas Olsson"'s message of Fri, 19 Jan 1996 07:49:06 -0600 (CST)
Message-Id: <tx1rawvilh0.fsf@cujo.cygnus.com>
Organization: Cygnus Support, Cambridge MA
Lines: 19


   From: "Lars Jonas Olsson" <jonas@mcs.com>
   Date: Fri, 19 Jan 1996 07:49:06 -0600 (CST)


    I have done these on UnixWare so far and now plan to do some similar
   things on FreeBSD (no SMP yet) and pthreads. Are there any special
   installation or other notes for using pthreads on FreeBSD? To
   what extent is lib++/g++ thread-safe?

libg++: I haven't looked, but I would guess "not very".  Look for
anything with static data (.data or .bss); if it's not something that
can be made "const", it's probably not safe.  Don't manipulate any
libg++ object from multiple threads at the same time, unless you
verify yourself that none of the operations can alter the contents;
there are no locks.

g++: Don't use set_new_handler from multiple threads.  Forget
exception handling and profiling.
