commit | 6c6de44f0479b202c39555f5c22ef8c494837d3c | [log] [tgz] |
---|---|---|
author | David 'Digit' Turner <digit@google.com> | Wed Dec 07 12:20:44 2011 +0100 |
committer | David 'Digit' Turner <digit@google.com> | Wed Dec 07 22:06:36 2011 +0100 |
tree | cad3f812fe4ac0edab614c73fab734d98bf06a63 | |
parent | 6e9d51701eabe26d2132a214e07b10384ea60a8c [diff] |
libc: optimize pthread_once() implementation. This patch changes the implementation of pthread_once() to avoid the use of a single global recursive mutex. This should also slightly speed up the non-common case where we have to call the init function, or wait for another thread to finish the call. Change-Id: I8a93f4386c56fb89b5d0eb716689c2ce43bdcad9