[llvm-commits] CVS: llvm/lib/System/Mutex.cpp
Chris Lattner
sabre at nondot.org
Tue Jul 12 22:51:40 PDT 2005
What does this call do? Is it even needed?
-Chris
On Tue, 12 Jul 2005, Reid Spencer wrote:
>
>
> Changes in directory llvm/lib/System:
>
> Mutex.cpp updated: 1.2 -> 1.3
> ---
> Log message:
>
> Don't call pthread_mutexattr_setpshared on FreeBSD because its implementation
> of pthreads is missing that call (despite it violating the spec).
>
>
> ---
> Diffs of the changes: (+2 -0)
>
> Mutex.cpp | 2 ++
> 1 files changed, 2 insertions(+)
>
>
> Index: llvm/lib/System/Mutex.cpp
> diff -u llvm/lib/System/Mutex.cpp:1.2 llvm/lib/System/Mutex.cpp:1.3
> --- llvm/lib/System/Mutex.cpp:1.2 Tue Jul 12 21:15:17 2005
> +++ llvm/lib/System/Mutex.cpp Tue Jul 12 22:02:06 2005
> @@ -62,8 +62,10 @@
> errorcode = pthread_mutexattr_settype(&attr, kind);
> assert(errorcode == 0);
>
> +#ifndef __FreeBSD__
> // Make it a process local mutex
> errorcode = pthread_mutexattr_setpshared(&attr, PTHREAD_PROCESS_PRIVATE);
> +#endif
>
> // Initialize the mutex
> errorcode = pthread_mutex_init(mutex, &attr);
>
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://mail.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
-Chris
--
http://nondot.org/sabre/
http://llvm.org/
More information about the llvm-commits
mailing list