[M3devel] State of threads? pthreads not safe to use on some platforms?

Mika Nystrom mika at async.caltech.edu
Mon Apr 18 20:37:20 CEST 2011

I don't think the pthreads implementation has ever been 100% correct.

If it has, please let me know which CVS date to check out!!!  (I use a
PM3 that is almost ten years old simply because this stuff works and am
happy to work with ANYTHING newer that works.)

As far as user ("green") threads goes, I think they *may* be right if you
are careful not to link with -pthread.  This means you have to change RTThreadC.c
(remove pthread_atfork) or your program won't link.

(Please don't call pthreads "Posix" threads on this list: I know it is
correct but it is confusing because Modula-3's user threads implementation
for Unix is called "POSIX"---i.e., as opposed to "WIN32".  Modula-3 usage 
predates IEEE/ISO standardization of threads so there was no confusion at 
the time the name was introduced.)


=?utf-8?Q?Dragi=C5=A1a_Duri=C4=87?= writes:
>But, what recent change when my now problematic platform is on =
>On Apr 17, 2011, at 8:13 PM, Tony Hosking wrote:
>> On Apr 17, 2011, at 1:34 PM, Hendrik Boom wrote:
>>> On Sun, Apr 17, 2011 at 12:43:16PM -0400, Tony Hosking wrote:
>>>> So the question is what has changed.
>>>> I know threads were functional and stable at one point.
>>> Was that back when they were green threads?
>> User threads have historically been pretty stable, and I believe still =
>> Similarly, our use of pthreads was stable at one point but there have =
>been recent changes that appear to have degraded them.
>>> Has our use of posix threads ever been stable?
>>> Are green threads still available?
>>> -- hendrik

More information about the M3devel mailing list