summaryrefslogtreecommitdiff
path: root/configure.cmake
diff options
context:
space:
mode:
authorYasufumi Kinoshita <yasufumi.kinoshita@oracle.com>2016-03-30 14:32:20 +1100
committerDaniel Black <daniel.black@au.ibm.com>2016-03-31 16:34:56 +1100
commitd4ba50477e6f0092a3b83528c02c0f30a2b708a3 (patch)
treec1e445085f0ed955418afaaded1e66848870e897 /configure.cmake
parent2275640deb33af952ae094b2f742578639f1611b (diff)
downloadmariadb-git-d4ba50477e6f0092a3b83528c02c0f30a2b708a3.tar.gz
Some POWER specific optimizations
Bug#18842925 : SET THREAD PRIORITY IN INNODB MUTEX SPINLOOP Like "pause" instruction for hyper-threading at Intel CPUs, POWER has special instructions only for hinting priority of hardware-threads. Approved by Sunny in rb#6256 Backport of the 5.7 fix - https://github.com/mysql/mysql-server/commit/c92102a6ef0f280bfb56e5585fca0d0cdcc34890 (excluded cache line size patch) Suggestion by Stewart Smith
Diffstat (limited to 'configure.cmake')
-rw-r--r--configure.cmake10
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.cmake b/configure.cmake
index a1fdb98389d..acb80965a64 100644
--- a/configure.cmake
+++ b/configure.cmake
@@ -855,6 +855,16 @@ IF(NOT CMAKE_CROSSCOMPILING AND NOT MSVC)
}
" HAVE_FAKE_PAUSE_INSTRUCTION)
ENDIF()
+ IF (NOT HAVE_PAUSE_INSTRUCTION)
+ CHECK_C_SOURCE_COMPILES("
+ int main()
+ {
+ __asm__ __volatile__ (\"or 1,1,1\");
+ __asm__ __volatile__ (\"or 2,2,2\");
+ return 0;
+ }
+ " HAVE_HMT_PRIORITY_INSTRUCTION)
+ ENDIF()
ENDIF()
CHECK_SYMBOL_EXISTS(tcgetattr "termios.h" HAVE_TCGETATTR 1)