Skip to content

Commit

Permalink
CI: Try to fix MSVC compilation issue.
Browse files Browse the repository at this point in the history
  • Loading branch information
kouchy committed Apr 30, 2024
1 parent 51200f2 commit 6f88f89
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 33 deletions.
40 changes: 20 additions & 20 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -688,16 +688,16 @@ build-windows-x86-gcc:
- windows
artifacts:
paths:
- ./build_windows_x86_gcc_nointr/bin/run-tests
- ./build_windows_x86_gcc_sse2/bin/run-tests
- ./build_windows_x86_gcc_sse3/bin/run-tests
- ./build_windows_x86_gcc_ssse3/bin/run-tests
- ./build_windows_x86_gcc_sse4_1/bin/run-tests
- ./build_windows_x86_gcc_sse4_2/bin/run-tests
- ./build_windows_x86_gcc_avx/bin/run-tests
- ./build_windows_x86_gcc_avx2/bin/run-tests
- ./build_windows_x86_gcc_avx2_fma/bin/run-tests
# - ./build_windows_x86_gcc_avx512f/bin/run-tests
- ./build_windows_x86_gcc_nointr/bin/run-tests.exe
- ./build_windows_x86_gcc_sse2/bin/run-tests.exe
- ./build_windows_x86_gcc_sse3/bin/run-tests.exe
- ./build_windows_x86_gcc_ssse3/bin/run-tests.exe
- ./build_windows_x86_gcc_sse4_1/bin/run-tests.exe
- ./build_windows_x86_gcc_sse4_2/bin/run-tests.exe
- ./build_windows_x86_gcc_avx/bin/run-tests.exe
- ./build_windows_x86_gcc_avx2/bin/run-tests.exe
- ./build_windows_x86_gcc_avx2_fma/bin/run-tests.exe
# - ./build_windows_x86_gcc_avx512f/bin/run-tests.exe
script:
- ./ci/build-windows-x86-gcc.bat

Expand All @@ -716,16 +716,16 @@ build-windows-x86-msvc:
- windows
artifacts:
paths:
- ./build_windows_x86_msvc_nointr/bin/run-tests
- ./build_windows_x86_msvc_sse2/bin/run-tests
- ./build_windows_x86_msvc_sse3/bin/run-tests
- ./build_windows_x86_msvc_ssse3/bin/run-tests
- ./build_windows_x86_msvc_sse4_1/bin/run-tests
- ./build_windows_x86_msvc_sse4_2/bin/run-tests
- ./build_windows_x86_msvc_avx/bin/run-tests
- ./build_windows_x86_msvc_avx2/bin/run-tests
- ./build_windows_x86_msvc_avx2_fma/bin/run-tests
# - ./build_windows_x86_msvc_avx512f/bin/run-tests
- ./build_windows_x86_msvc_nointr/bin/run-tests.exe
- ./build_windows_x86_msvc_sse2/bin/run-tests.exe
- ./build_windows_x86_msvc_sse3/bin/run-tests.exe
- ./build_windows_x86_msvc_ssse3/bin/run-tests.exe
- ./build_windows_x86_msvc_sse4_1/bin/run-tests.exe
- ./build_windows_x86_msvc_sse4_2/bin/run-tests.exe
- ./build_windows_x86_msvc_avx/bin/run-tests.exe
- ./build_windows_x86_msvc_avx2/bin/run-tests.exe
- ./build_windows_x86_msvc_avx2_fma/bin/run-tests.exe
# - ./build_windows_x86_msvc_avx512f/bin/run-tests.exe
script:
- ./ci/build-windows-x86-msvc.bat

Expand Down
14 changes: 7 additions & 7 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -110,22 +110,22 @@ add_custom_target(uninstall
if (MIPP_TESTS_EXE)
# Generate the source files list
file (GLOB_RECURSE MIPP_SRCS_TEST ${CMAKE_CURRENT_SOURCE_DIR}/tests/src/*)
add_executable(run_tests ${MIPP_SRCS_TEST})
set_target_properties(run_tests PROPERTIES OUTPUT_NAME run-tests POSITION_INDEPENDENT_CODE ON) # set -fpie
add_executable(tests_exe ${MIPP_SRCS_TEST})
set_target_properties(tests_exe PROPERTIES OUTPUT_NAME run-tests POSITION_INDEPENDENT_CODE ON) # set -fpie

# include MIPP headers
target_include_directories(run_tests PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/include/")
target_include_directories(tests_exe PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/include/")

# include Catch2 header
target_include_directories(run_tests PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/tests/lib/Catch2/include/")
# include Catch2 header
target_include_directories(tests_exe PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/tests/lib/Catch2/include/")

# If MIPP was compiled as static library then link argainst it
if (MIPP_STATIC_LIB)
target_link_libraries(run_tests PUBLIC mipp)
target_link_libraries(tests_exe PUBLIC mipp)
endif()

enable_testing()
add_test(NAME mipp::test COMMAND run_tests)
add_test(NAME mipp::test COMMAND tests_exe)
endif()

# -----------------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions TODO.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# TODO

- [ ] Fix and improve GitHub actions
- [ ] Create a docker image with "Intel Software Development Emulator" to enable
AVX-512 instructions emulation on the runners that does not support
native AVX-512
Expand Down
2 changes: 1 addition & 1 deletion ci/build-coverage-linux-armv7-gcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function gen_coverage_info {
./bin/run-tests
cd ..
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
lcov --capture --directory $build/CMakeFiles/run_tests.dir/tests/src/ --output-file code_coverage_files/$build.info
lcov --capture --directory $build/CMakeFiles/tests_exe.dir/tests/src/ --output-file code_coverage_files/$build.info
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
lcov --remove code_coverage_files/$build.info "*/usr*" "*lib/*" "*/tests/src*" --output-file code_coverage_files/$build.info
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
Expand Down
2 changes: 1 addition & 1 deletion ci/build-coverage-linux-armv8-gcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ function gen_coverage_info {
fi
cd ..
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
lcov --capture --directory $build/CMakeFiles/run_tests.dir/tests/src/ --output-file code_coverage_files/$build.info
lcov --capture --directory $build/CMakeFiles/tests_exe.dir/tests/src/ --output-file code_coverage_files/$build.info
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
lcov --remove code_coverage_files/$build.info "*/usr*" "*lib/*" "*/tests/src*" --output-file code_coverage_files/$build.info
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
Expand Down
2 changes: 1 addition & 1 deletion ci/build-coverage-linux-x86-gcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function gen_coverage_info {
fi
cd ..
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
lcov --capture --directory $build/CMakeFiles/run_tests.dir/tests/src/ --output-file code_coverage_files/$build.info
lcov --capture --directory $build/CMakeFiles/tests_exe.dir/tests/src/ --output-file code_coverage_files/$build.info
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
lcov --remove code_coverage_files/$build.info "*/usr*" "*lib/*" "*/tests/src*" --output-file code_coverage_files/$build.info
# rc=$?; if [[ $rc != 0 ]]; then exit $rc; fi
Expand Down
2 changes: 1 addition & 1 deletion ci/build-windows-x86-msvc.bat
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ set build=%~1%
set params=%~2%
mkdir %build%
cd %build%
cmake .. -G"Visual Studio 15 2017 Win64" -DCMAKE_CXX_FLAGS="-D_CRT_SECURE_NO_DEPRECATE /EHsc /MP%THREADS% %params%" -DMIPP_STATIC_LIB=OFF
cmake .. -G"Visual Studio 15 2017 Win64" -DCMAKE_CXX_FLAGS="-D_CRT_SECURE_NO_DEPRECATE /EHsc /MP%THREADS% %params%" -DMIPP_STATIC_LIB=OFF -DMIPP_EXAMPLES_EXE=OFF
if %ERRORLEVEL% neq 0 exit %ERRORLEVEL%
rem devenv /build Release MIPP.sln
msbuild MIPP.sln /t:Build /p:Configuration=Release
Expand Down
1 change: 1 addition & 0 deletions examples/sorting.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include <random>
#include <algorithm>
#include <chrono>
#include <numeric>

#include <mipp.h>

Expand Down
2 changes: 0 additions & 2 deletions include/mipp_impl_AVX.hxx
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
#include "mipp.h"
#include <immintrin.h>
#include <x86intrin.h>

#if defined(MIPP_STATIC_LIB)
extern int32_t vcompress_LUT32x8_AVX[256][8]; // 8 x 32-bit for _mm_permutevar_epi32
Expand Down

0 comments on commit 6f88f89

Please sign in to comment.