Skip to content

Commit

Permalink
Disable lock elision for PTHREAD_MUTEX_NORMAL.
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan Liebler authored and Andreas Krebbel committed May 26, 2014
1 parent f8bdf1f commit 6736592
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2014-05-26 Stefan Liebler <stli@linux.vnet.ibm.com>

* nptl/pthread_mutexattr_settype.c
(__pthread_mutexattr_settype):
Disable lock elision for PTHREAD_MUTEX_NORMAL.

2014-05-26 Stefan Liebler <stli@linux.vnet.ibm.com>

* nptl/tst-mutex5 (do_test):
Expand Down
2 changes: 1 addition & 1 deletion nptl/pthread_mutexattr_settype.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ __pthread_mutexattr_settype (attr, kind)

/* Cannot distinguish between DEFAULT and NORMAL. So any settype
call disables elision for now. */
if (kind == PTHREAD_MUTEX_DEFAULT)
if (kind == PTHREAD_MUTEX_NORMAL)
kind |= PTHREAD_MUTEX_NO_ELISION_NP;

iattr = (struct pthread_mutexattr *) attr;
Expand Down

0 comments on commit 6736592

Please sign in to comment.