Skip to content

Commit

Permalink
Merge pull request #4861 from daschuer/info-vec-optimized-main
Browse files Browse the repository at this point in the history
Build option for show vectorization info
  • Loading branch information
ferranpujolcamins authored Aug 25, 2022
2 parents 4810a5c + a171dc8 commit f3ad153
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/build-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,10 @@ jobs:
-DWAVPACK=ON \
..
working-directory: build
env:
LD: clang++
CC: clang
CXX: clang++
- name: Configure (coverage)
if: matrix.name == 'coverage'
run: |
Expand Down
13 changes: 13 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1174,6 +1174,19 @@ else()
endif()
endif()

option(INFO_VECTORIZE "Let the compiler show vectorized loops" OFF)
if (INFO_VECTORIZE)
if(MSVC)
target_compile_options(mixxx-lib PUBLIC /Qvec-report:1)
elseif(GNU_GCC)
target_compile_options(mixxx-lib PUBLIC -fopt-info-vec-optimized)
elseif(LLVM_CLANG)
target_compile_options(mixxx-lib PUBLIC -Rpass=loop-vectorize)
else()
message(STATUS "INFO_VECTORIZE not implemented for this compliler.")
endif()
endif()

option(WARNINGS_FATAL "Fail if compiler generates a warning" OFF)
if(WARNINGS_FATAL)
if(MSVC)
Expand Down

0 comments on commit f3ad153

Please sign in to comment.