summary refs log tree commit diff
path: root/configure
diff options
context:
space:
mode:
authorAndi Kleen <ak@linux.intel.com>2013-05-16 19:17:14 -0700
committerAndi Kleen <ak@linux.intel.com>2013-07-02 08:46:55 -0700
commit1717da59aed9612becd56aaa1249aac695af4c8a (patch)
tree0b69e8ee62804482fd7bd951c918abdd9d15c0a3 /configure
parent49186d21ef2d87986bccaf0a7c45c48c91b265f3 (diff)
downloadglibc-1717da59aed9612becd56aaa1249aac695af4c8a.tar.gz
glibc-1717da59aed9612becd56aaa1249aac695af4c8a.tar.xz
glibc-1717da59aed9612becd56aaa1249aac695af4c8a.zip
Add a configure option to enable lock elision and disable by default
Can be enabled with --enable-lock-elision=yes at configure time.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure16
1 files changed, 16 insertions, 0 deletions
diff --git a/configure b/configure
index edde31032c..a873b20617 100755
--- a/configure
+++ b/configure
@@ -742,6 +742,7 @@ enable_versioning
 enable_oldest_abi
 enable_hardcoded_path_in_tests
 enable_stackguard_randomization
+enable_lock_elision
 enable_add_ons
 enable_hidden_plt
 enable_bind_now
@@ -1399,6 +1400,9 @@ Optional Features:
   --enable-stackguard-randomization
                           initialize __stack_chk_guard canary with a random
                           number at program start
+  --enable-lock-elision=yes/no
+                          Enable lock elision for pthread mutexes and rwlocks
+                          by default
   --enable-add-ons[=DIRS...]
                           configure and build add-ons in DIR1,DIR2,... search
                           for add-ons if no parameter given
@@ -3472,6 +3476,18 @@ if test "$enable_stackguard_randomize" = yes; then
 
 fi
 
+# Check whether --enable-lock-elision was given.
+if test "${enable_lock_elision+set}" = set; then :
+  enableval=$enable_lock_elision; enable_lock_elision=$enableval
+else
+  enable_lock_elision=no
+fi
+
+if test "$enable_lock_elision" = yes ; then
+  $as_echo "#define ENABLE_LOCK_ELISION 1" >>confdefs.h
+
+fi
+
 # Check whether --enable-add-ons was given.
 if test "${enable_add_ons+set}" = set; then :
   enableval=$enable_add_ons;