Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ARMPL Fixes and Workarounds #1543

Merged
merged 1 commit into from
Sep 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions blas/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@ KOKKOSKERNELS_INCLUDE_DIRECTORIES(REQUIRED_DURING_INSTALLATION_TESTING ${CMAKE_C
#######################

#Include BLAS, Blas host wrapper
IF (KOKKOSKERNELS_ENABLE_TPL_BLAS OR KOKKOSKERNELS_ENABLE_TPL_MKL)
IF (KOKKOSKERNELS_ENABLE_TPL_BLAS OR KOKKOSKERNELS_ENABLE_TPL_MKL OR KOKKOSKERNELS_ENABLE_TPL_ARMPL)
#Do NOT add this to include path
APPEND_GLOB(SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/tpls/KokkosBlas_Host_tpl.cpp)
ENDIF()

# Include host blas TPL source file
IF (KOKKOSKERNELS_ENABLE_TPL_BLAS OR KOKKOSKERNELS_ENABLE_TPL_MKL)
IF (KOKKOSKERNELS_ENABLE_TPL_BLAS OR KOKKOSKERNELS_ENABLE_TPL_MKL OR KOKKOSKERNELS_ENABLE_TPL_ARMPL)
LIST(APPEND SOURCES
blas/tpls/KokkosBlas_Host_tpl.cpp
)
Expand Down
1 change: 1 addition & 0 deletions blas/tpls/KokkosBlas_Host_tpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -798,6 +798,7 @@ void HostBlas<std::complex<double> >::trsv(const char uplo, const char transa,
F77_FUNC_ZTRSV(&uplo, &transa, &diag, &m, (const std::complex<double>*)a,
&lda, (std::complex<double>*)b, &ldb);
}

template <>
void HostBlas<std::complex<double> >::gemm(
const char transa, const char transb, int m, int n, int k,
Expand Down
9 changes: 9 additions & 0 deletions sparse/unit_test/Test_Sparse_bspgemm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,15 @@ void test_bspgemm(lno_t blkDim, lno_t m, lno_t k, lno_t n, size_type nnz,
lno_t bandwidth, lno_t row_size_variance,
const bool use_dynamic_scheduling = true,
const size_t shared_memory_size = 0) {
#if defined(KOKKOSKERNELS_ENABLE_TPL_ARMPL)
{
std::cerr
<< "TEST SKIPPED: See "
"https://github.com/kokkos/kokkos-kernels/issues/1542 for details."
<< std::endl;
return;
}
#endif // KOKKOSKERNELS_ENABLE_TPL_ARMPL
using namespace Test;
// device::execution_space::initialize();
// device::execution_space::print_configuration(std::cout);
Expand Down
18 changes: 18 additions & 0 deletions sparse/unit_test/Test_Sparse_spgemm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,15 @@ template <typename scalar_t, typename lno_t, typename size_type,
typename device>
void test_spgemm(lno_t m, lno_t k, lno_t n, size_type nnz, lno_t bandwidth,
lno_t row_size_variance, bool oldInterface = false) {
#if defined(KOKKOSKERNELS_ENABLE_TPL_ARMPL)
{
std::cerr
<< "TEST SKIPPED: See "
"https://github.com/kokkos/kokkos-kernels/issues/1542 for details."
<< std::endl;
return;
}
#endif // KOKKOSKERNELS_ENABLE_TPL_ARMPL
using namespace Test;
// device::execution_space::initialize();
// device::execution_space::print_configuration(std::cout);
Expand Down Expand Up @@ -369,6 +378,15 @@ void test_spgemm(lno_t m, lno_t k, lno_t n, size_type nnz, lno_t bandwidth,
template <typename scalar_t, typename lno_t, typename size_type,
typename device>
void test_issue402() {
#if defined(KOKKOSKERNELS_ENABLE_TPL_ARMPL)
{
std::cerr
<< "TEST SKIPPED: See "
"https://github.com/kokkos/kokkos-kernels/issues/1542 for details."
<< std::endl;
return;
}
#endif // KOKKOSKERNELS_ENABLE_TPL_ARMPL
using namespace Test;
typedef CrsMatrix<scalar_t, lno_t, device, void, size_type> crsMat_t;

Expand Down
9 changes: 9 additions & 0 deletions sparse/unit_test/Test_Sparse_spgemm_jacobi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,15 @@ template <typename scalar_t, typename lno_t, typename size_type,
typename device>
void test_spgemm_jacobi(lno_t numRows, size_type nnz, lno_t bandwidth,
lno_t row_size_variance) {
#if defined(KOKKOSKERNELS_ENABLE_TPL_ARMPL)
{
std::cerr
<< "TEST SKIPPED: See "
"https://github.com/kokkos/kokkos-kernels/issues/1542 for details."
<< std::endl;
return;
}
#endif // KOKKOSKERNELS_ENABLE_TPL_ARMPL
using namespace Test;
typedef CrsMatrix<scalar_t, lno_t, device, void, size_type> crsMat_t;

Expand Down
16 changes: 9 additions & 7 deletions sparse/unit_test/Test_Sparse_spmv.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -486,13 +486,6 @@ template <typename scalar_t, typename lno_t, typename size_type,
typename layout, class Device>
void test_spmv_mv(lno_t numRows, size_type nnz, lno_t bandwidth,
lno_t row_size_variance, bool heavy, int numMV) {
// The kokkos-kernels gtest does not have GTEST_SKIP defined. Suggest updating
// or using kokkos/tpls/gtest instead.
// if (std::is_same<typename Test::scalar_t, typename
// Kokkos::complex<double>>::value)
// GTEST_SKIP(
// "Skipped until https://github.com/kokkos/kokkos-kernels/issues/1331 is
// " "resolved");
using mag_t = typename Kokkos::ArithTraits<scalar_t>::mag_type;

constexpr mag_t max_x = static_cast<mag_t>(1);
Expand Down Expand Up @@ -572,6 +565,15 @@ template <typename scalar_t, typename lno_t, typename size_type,
typename layout, class Device>
void test_spmv_mv_heavy(lno_t numRows, size_type nnz, lno_t bandwidth,
lno_t row_size_variance, int numMV) {
#if defined(KOKKOSKERNELS_ENABLE_TPL_ARMPL)
if (std::is_same<scalar_t, Kokkos::complex<double>>::value) {
std::cerr
<< "TEST SKIPPED: See "
"https://github.com/kokkos/kokkos-kernels/issues/1331 for details."
<< std::endl;
return;
}
#endif // KOKKOSKERNELS_ENABLE_TPL_ARMPL
using crsMat_t = typename KokkosSparse::CrsMatrix<scalar_t, lno_t, Device,
void, size_type>;
using ViewTypeX = Kokkos::View<scalar_t **, layout, Device>;
Expand Down