Skip to content

Commit

Permalink
fix passing compilation flags in CMake
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhardmgruber committed Feb 11, 2022
1 parent 30cfe97 commit 4ff3bbe
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion examples/alpaka/daxpy/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ target_link_libraries(${PROJECT_NAME} PRIVATE llama::llama OpenMP::OpenMP_CXX al

if (MSVC)
target_compile_options(${PROJECT_NAME} PRIVATE /arch:AVX2 /fp:fast)
elseif(MSVC)
else()
target_compile_options(${PROJECT_NAME} PRIVATE -march=native -ffast-math)
endif()
2 changes: 1 addition & 1 deletion examples/heatequation/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ endif()

if (MSVC)
target_compile_options(${PROJECT_NAME} PRIVATE /arch:AVX2 /fp:fast)
elseif(MSVC)
else()
target_compile_options(${PROJECT_NAME} PRIVATE -march=native -ffast-math)
endif()
2 changes: 1 addition & 1 deletion examples/nbody_benchmark/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ target_link_libraries(${PROJECT_NAME} PRIVATE llama::llama fmt::fmt)

if (MSVC)
target_compile_options(${PROJECT_NAME} PRIVATE /arch:AVX2 /fp:fast /bigobj)
elseif(MSVC)
else()
target_compile_options(${PROJECT_NAME} PRIVATE -march=native -ffast-math)
endif()

0 comments on commit 4ff3bbe

Please sign in to comment.