From 741bee2e2f99602946abc9a77da2b5262ee02669 Mon Sep 17 00:00:00 2001 From: fireice-uk Date: Fri, 21 Apr 2017 17:43:47 +0100 Subject: [PATCH] Windows build fix + gcc cmake opts --- CMakeLists.txt | 6 +++--- minethd.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e87d69d..2667f42 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -84,9 +84,9 @@ endif() # Compile & Link ################################################################################ -# activate sse2 and aes-ni -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -msse2 -maes") -set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse2 -maes") +# activate sse2, aes-ni and bmi2 +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -msse2 -maes -mbmi2") +set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse2 -maes -mbmi2") # activate static libgcc and libstdc++ linking if(CMAKE_LINK_STATIC) diff --git a/minethd.h b/minethd.h index aa40344..fbee325 100644 --- a/minethd.h +++ b/minethd.h @@ -99,7 +99,7 @@ public: private: typedef void (*cn_hash_fun)(const void*, size_t, void*, cryptonight_ctx*); - typedef void (*cn_hash_fun_dbl)(const void*, size_t, void*, __restrict cryptonight_ctx*, __restrict cryptonight_ctx*); + typedef void (*cn_hash_fun_dbl)(const void*, size_t, void*, cryptonight_ctx* __restrict, cryptonight_ctx* __restrict); minethd(miner_work& pWork, size_t iNo, bool double_work, bool no_prefetch);