mirror of https://github.com/drowe67/LPCNet.git
optimization for SSE4.1 required, check SSE4.1 support
parent
ca9e9e02ab
commit
7b45883477
|
@ -64,7 +64,7 @@ if(NOT DISABLE_CPU_OPTIMIZATION)
|
||||||
OUTPUT_VARIABLE AVX2)
|
OUTPUT_VARIABLE AVX2)
|
||||||
execute_process(COMMAND grep -c "avx " /proc/cpuinfo
|
execute_process(COMMAND grep -c "avx " /proc/cpuinfo
|
||||||
OUTPUT_VARIABLE AVX)
|
OUTPUT_VARIABLE AVX)
|
||||||
execute_process(COMMAND grep -c "sse " /proc/cpuinfo
|
execute_process(COMMAND grep -c "sse4_1 " /proc/cpuinfo
|
||||||
OUTPUT_VARIABLE SSE)
|
OUTPUT_VARIABLE SSE)
|
||||||
execute_process(COMMAND grep -c "neon" /proc/cpuinfo
|
execute_process(COMMAND grep -c "neon" /proc/cpuinfo
|
||||||
OUTPUT_VARIABLE NEON)
|
OUTPUT_VARIABLE NEON)
|
||||||
|
@ -92,9 +92,9 @@ elseif(${AVX} OR ${AVX} GREATER 0)
|
||||||
message(STATUS "avx processor flags found or enabled.")
|
message(STATUS "avx processor flags found or enabled.")
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mavx")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mavx")
|
||||||
elseif(${SSE} OR ${SSE} GREATER 0)
|
elseif(${SSE} OR ${SSE} GREATER 0)
|
||||||
# AVX and AVX2 machines will also match on AVX
|
# AVX and AVX2 machines will also match on SSE
|
||||||
message(STATUS "sse processor flags found or enabled.")
|
message(STATUS "sse processor flags found or enabled.")
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse4.1")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# RPi / ARM 32bit
|
# RPi / ARM 32bit
|
||||||
|
|
Loading…
Reference in New Issue