Skip to content

Commit

Permalink
fixes for oneapi
Browse files Browse the repository at this point in the history
  • Loading branch information
alfC committed Dec 23, 2024
1 parent 1475273 commit ae53d47
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 2 additions & 0 deletions include/boost/multi/adaptors/fftw/test/moved.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,7 @@ auto main() -> int { // NOLINT(readability-function-cognitive-complexity,bugpro
BOOST_TEST( A1[0] == A1[1] );
}
{
// NOLINTBEGIN(fuchsia-default-arguments-calls)
multi::array<std::vector<int>, 3> A1 = {
{
{std::vector<int>(1, 0), std::vector<int>(2, 0)},
Expand All @@ -298,6 +299,7 @@ auto main() -> int { // NOLINT(readability-function-cognitive-complexity,bugpro

BOOST_TEST( A1[1][0][0] == std::vector<int>(1, 0) );
// BOOST_TEST( A1[0][0][0].empty() ); // TODO(correaa) make moved elements work
// NOLINTEND(fuchsia-default-arguments-calls)
}

return boost::report_errors();
Expand Down
8 changes: 4 additions & 4 deletions include/boost/multi/detail/layout.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,8 @@ struct extensions_t : boost::multi::detail::tuple_prepend_t<index_extension, typ
constexpr auto prev_canonical(index& idx, Indices&... rest) const -> bool { // NOLINT(google-runtime-references) idx is mutated
if(extensions_t<D-1>{this->base().tail()}.prev_canonical(rest...)) { --idx; }
if(idx < this->base().head().first()) {
assert(0); // TODO(correaa) implement
// idx = this->base().head().back();
// assert(0); // TODO(correaa) implement
idx = this->base().head().back();
return true;
}
return false;
Expand Down Expand Up @@ -373,8 +373,8 @@ template<> struct extensions_t<1> : tuple<multi::index_extension> {
constexpr auto prev_canonical(index& idx) const -> bool { // NOLINT(google-runtime-references) idx is mutated
using boost::multi::detail::get;
if(idx == get<0>(this->base()).first()) {
idx = 42; // TODO(correaa) implement and test
// idx = get<0>(this->base()).back();
// idx = 42; // TODO(correaa) implement and test
idx = get<0>(this->base()).back();
return true;
}
--idx;
Expand Down
2 changes: 1 addition & 1 deletion pre-push
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ if [[ $(uname -m) != 'arm64' ]]; then
export VALGRIND_EXE="valgrind --trace-children=yes --leak-check=full --track-origins=yes --show-leak-kinds=all --suppressions=.valgrind_suppressions --gen-suppressions=all --error-exitcode=1 "

(mkdir -p .build.g++ && cd .build.g++ && CXX=g++ cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_EXPORT_COMPILE_COMMANDS=ON && cmake --build . && ctest --parallel 2 --output-on-failure) || exit 666
(mkdir -p .build.clang++.mull && cd .build.clang++.mull && CXX=clang++-16 cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_FLAGS="-O0 -fpass-plugin=/usr/lib/mull-ir-frontend-16 -g -grecord-command-line -fprofile-instr-generate -fcoverage-mapping" && cmake --build . && (ls test/*.x | xargs -n 1 sh -c 'echo $0 && ((mull-runner-16 $0 --ld-search-path /usr/lib --test-program=ctest -- -j2 --stop-on-failure) || exit 255)') ) || exit 666
(mkdir -p .build.circle && cd .build.circle && CXX="$HOME/bin/circle" cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_EXTENSIONS=OFF -DCMAKE_CXX_STANDARD=20 -DDISABLE_MPI=1 -DENABLE_CIRCLE=1 -DCMAKE_THREAD_LIBS_INIT="-lpthread" && cmake --build . && ctest --parallel --output-on-failure --rerun-failed) || exit 666
(mkdir -p .build.clang++-rel && cd .build.clang++-rel && CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Release && cmake --build . && ctest --parallel 2 --output-on-failure) || exit 666
(mkdir -p .build.clang++ && cd .build.clang++ && CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Debug && cmake --build . && ctest --parallel 2 --output-on-failure) || exit 666
Expand All @@ -45,6 +44,7 @@ export VALGRIND_EXE="valgrind --trace-children=yes --leak-check=full --track-ori
(mkdir -p .build.icpx && cd .build.icpx && CXX=/opt/intel/oneapi/compiler/latest/bin/icpx cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=23 && cmake --build . && ctest --parallel --output-on-failure --rerun-failed) || exit 666
(mkdir -p .build.nvc++ && cd .build.nvc++ && CXX=/opt/nvidia/hpc_sdk/Linux_x86_64/2024/compilers/bin/nvc++ cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_FLAGS="-stdpar=multicore" -DBLA_PREFER_PKGCONFIG=ON -DCMAKE_C_COMPILER=/opt/nvidia/hpc_sdk/Linux_x86_64/2024/compilers/bin/nvc -DCMAKE_CXX_COMPILER=/opt/nvidia/hpc_sdk/Linux_x86_64/2024/compilers/bin/nvc++ -DCMAKE_Fortran_COMPILER=/opt/nvidia/hpc_sdk/Linux_x86_64/2024/compilers/bin/nvfortran && cmake --build . && ctest --parallel --output-on-failure --rerun-failed) || exit 666
(mkdir -p .build.culang && cd .build.culang && cmake .. -DCMAKE_BUILD_TYPE=Release -DENABLE_CUDA=1 -DCMAKE_CUDA_COMPILER=clang++ -DCMAKE_CUDA_HOST_COMPILER=clang++ -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_CUDA_ARCHITECTURES=75 && cmake --build . && ctest --parallel --output-on-failure --rerun-failed) || exit 666
(mkdir -p .build.clang++.mull && cd .build.clang++.mull && CXX=clang++-16 cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_FLAGS="-O0 -fpass-plugin=/usr/lib/mull-ir-frontend-16 -g -grecord-command-line -fprofile-instr-generate -fcoverage-mapping" && cmake --build . && (ls test/*.x | xargs -n 1 sh -c 'echo $0 && ((mull-runner-16 $0 --ld-search-path /usr/lib --test-program=ctest -- -j2 --stop-on-failure) || exit 255)') ) || exit 666
(mkdir -p .build.g++.plus && cd .build.g++.plus && CXX=g++ cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=23 -DBLA_VENDOR=OpenBLAS `#-DCMAKE_CXX_CPPCHECK="cppcheck;--enable=all;--suppress=missingIncludeSystem;--inline-suppr;--std=c++17;--checkers-report=cppcheck.report;--error-exitcode=1"` -DCMAKE_CXX_FLAGS="-D_GLIBCXX_DEBUG=1" -DCMAKE_CXX_FLAGS="-fimplicit-constexpr -fanalyzer -Wno-analyzer-null-dereference -Wno-analyzer-possible-null-dereference -Wno-analyzer-malloc-leak -Wno-analyzer-use-of-uninitialized-value -Wno-analyzer-use-after-free" && cmake --build . && ctest --parallel --output-on-failure -T memcheck) || exit 666
(mkdir -p .build.clang++.plus && cd .build.clang++.plus && CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=20 -DBLA_VENDOR=Generic -DCMAKE_CXX_CLANG_TIDY="clang-tidy" `#-DCMAKE_CXX_INCLUDE_WHAT_YOU_USE="iwyu;-Xiwyu;--mapping_file=/home/correaa/boost-multi/.iwyu-test.imp;-Xiwyu;--no_fwd_decls"` && cmake --build . && ASAN_OPTIONS="new_delete_type_mismatch=0" ctest --parallel --output-on-failure) || exit 666
#(mkdir -p .build.hip && cd .build.hip && CXX=clang++ cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_HIP_COMPILER=/opt/rocm/llvm/bin/clang++ -DCMAKE_CXX_FLAGS="-DMULTI_USE_HIP" -DCMAKE_HIP_FLAGS="-DMULTI_USE_HIP" -DENABLE_HIP=1 -DCMAKE_HIP_ARCHITECTURES=gfx90a && cmake --build . ) || exit 666
Expand Down

0 comments on commit ae53d47

Please sign in to comment.