From 08f7b3221d58e480d8ede105bd70b09a2104c5fb Mon Sep 17 00:00:00 2001 From: Benoit Steiner Date: Mon, 24 Mar 2014 09:52:45 -0700 Subject: Added proper support for AVX and FMA in the makefiles. --- CMakeLists.txt | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 16a9b5bcb..fb13769f4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -196,12 +196,18 @@ if(NOT MSVC) message(STATUS "Enabling SSE4.2 in tests/examples") endif() - option(EIGEN_TEST_AVX "Enable/Disable AVX in tests/examples" ON) + option(EIGEN_TEST_AVX "Enable/Disable AVX in tests/examples" OFF) if(EIGEN_TEST_AVX) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mavx") message(STATUS "Enabling AVX in tests/examples") endif() + option(EIGEN_TEST_FMA "Enable/Disable FMA in tests/examples" OFF) + if(EIGEN_TEST_FMA) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mfma") + message(STATUS "Enabling FMA in tests/examples") + endif() + option(EIGEN_TEST_ALTIVEC "Enable/Disable AltiVec in tests/examples" OFF) if(EIGEN_TEST_ALTIVEC) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -maltivec -mabi=altivec") -- cgit v1.2.3