[PATCH] Change base mutex implementations to use STL-provided mutexes

Joerg Sonnenberger joerg at britannica.bec.de
Tue Jun 10 05:45:01 PDT 2014

On Fri, Jun 06, 2014 at 09:52:34AM -0700, Zachary Turner wrote:
> Another thing is that this is a mutex.  All of the performance cost
> associated with these methods are going to be that of waiting on the actual
> mutex, and an extra pointer indirection should be negligible.

For single threaded application, the question is whether libpthread/libc
special case the "single threaded" case. An atomic cmpchg is far from
negligible, even in the non-contented case.


More information about the llvm-commits mailing list