[PATCH] [libcxxabi] On single threaded systems, turn mutexes into nops

Jon Roelofs jonathan at codesourcery.com
Wed Apr 16 12:24:57 PDT 2014


  Joerg, you may be thinking of the __config in libc++. libc++abi doesn't have one, but I'd be happy to create it.  Should it go in src/, or in include/ ?


================
Comment at: src/cxa_exception_storage.cpp:35
@@ -34,2 +34,3 @@
 
 #include <pthread.h>
+#include <cstdlib>          // for calloc, free, atexit
----------------
kledzik at apple.com wrote:
> Should this be:
> 
>   #include <unistd.h>
>   #ifdef _POSIX_THREADS
>   #include <pthread.h>
>   #endif
> 
> so that this will also compile on a system without pthread.h?
ok, sounds good.


http://reviews.llvm.org/D3386






More information about the cfe-commits mailing list