Re: threads and libc

Eric Salo (salo@mrjones.engr.sgi.com)
Mon, 3 Mar 1997 08:29:39 -0800

> Sorry, but MPI-thread-safe is only defined that any two MPI routines
> can be started simultaniously from different threads (166:9-11).
> They are alled to internally use a POSIX-non-thread-safe malloc
> by using a mutex around the malloc.
> This mutex prevent only trouble between two MPI calls, but never
> it can prevent trouble between a call to an MPI routine and a call
> to malloc().

I think that this may just be a problem with terminology. To me, thread-safe
means safe for threads. Period. If an MPI implementation calls a routine which
is itself not thread-safe, then I would claim this also makes the MPI
implementation non-thread-safe because, exactly as you point out, it is not
possible to protect against any uses outside of MPI.

So if an implementation is truly thread-safe then nothing extra need be said
about it. However, if y'all would like to argue that implementations which
claim to be thread-safe but really aren't should be required to document the
exact nature of their unsafeness, that certainly seems like a reasonable
request.

-- 
Eric Salo    Silicon Graphics Inc.    salo@sgi.com