Skip to content

Commit

Permalink
Tweaking make for build with infra
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Gaievski <[email protected]>
  • Loading branch information
martin-gaievski committed Nov 6, 2024
1 parent 64bae92 commit ade2ee1
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions jni/cmake/init-faiss.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ set(BUILD_TESTING OFF) # Avoid building faiss tests
set(FAISS_ENABLE_GPU OFF)
set(FAISS_ENABLE_PYTHON OFF)

if(NOT DEFINED AVX2_ENABLED)
set(AVX2_ENABLED true) # set default value as true if the argument is not set
endif()
#if(NOT DEFINED AVX2_ENABLED)
# set(AVX2_ENABLED true) # set default value as true if the argument is not set
#endif()

if(NOT DEFINED AVX512_ENABLED)
set(AVX512_ENABLED true) # set default value as true if the argument is not set
endif()
#if(NOT DEFINED AVX512_ENABLED)
# set(AVX512_ENABLED true) # set default value as true if the argument is not set
#endif()

if(${CMAKE_SYSTEM_NAME} STREQUAL Windows OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES "aarch64" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm64" OR ( NOT AVX2_ENABLED AND NOT AVX512_ENABLED))
set(FAISS_OPT_LEVEL generic) # Keep optimization level as generic on Windows OS as it is not supported due to MINGW64 compiler issue. Also, on aarch64 avx2 is not supported.
Expand Down

0 comments on commit ade2ee1

Please sign in to comment.