diff --git a/cpp/oneapi/dal/backend/primitives/BUILD b/cpp/oneapi/dal/backend/primitives/BUILD index 694b1fabee1..2d1fc69325c 100644 --- a/cpp/oneapi/dal/backend/primitives/BUILD +++ b/cpp/oneapi/dal/backend/primitives/BUILD @@ -84,6 +84,7 @@ dal_collect_test_suites( name = "tests", modules = [ "blas", + "distance", "heap", "lapack", "optimizers", @@ -93,6 +94,7 @@ dal_collect_test_suites( "regression", "rng", "selection", + "search", "sort", "sparse_blas", "stat", diff --git a/cpp/oneapi/dal/backend/primitives/distance/test/cosine_distance_dpc.cpp b/cpp/oneapi/dal/backend/primitives/distance/test/cosine_distance_dpc.cpp index 0bf06d22a70..ac8c265d31f 100644 --- a/cpp/oneapi/dal/backend/primitives/distance/test/cosine_distance_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/distance/test/cosine_distance_dpc.cpp @@ -112,6 +112,7 @@ TEMPLATE_LIST_TEST_M(cosine_distance_test_random, "Randomly filled cosine-distance computation", "[cosine][distance][small]", distance_types) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_distance(); diff --git a/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_dpc.cpp b/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_dpc.cpp index 4e6ce6e4507..9ddb99c7263 100644 --- a/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_dpc.cpp @@ -107,6 +107,7 @@ TEMPLATE_LIST_TEST_M(sql2_distance_test_random, "Randomly filled squared L2-distance computation", "[l2][distance][small]", distance_types) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_squared_l2_distance(); diff --git a/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_misc_dpc.cpp b/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_misc_dpc.cpp index 56e296f3208..028187ca89d 100644 --- a/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_misc_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/distance/test/squared_l2_distance_misc_dpc.cpp @@ -232,6 +232,7 @@ TEMPLATE_LIST_TEST_M(inner_product_test_random, "Randomly filled Inner-Product computation", "[l2][ip][aux][small]", types_to_check) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_inner_product(); diff --git a/cpp/oneapi/dal/backend/primitives/search/test/chebyshev_search_dpc.cpp b/cpp/oneapi/dal/backend/primitives/search/test/chebyshev_search_dpc.cpp index 063ba50bb1c..70074360990 100644 --- a/cpp/oneapi/dal/backend/primitives/search/test/chebyshev_search_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/search/test/chebyshev_search_dpc.cpp @@ -60,7 +60,7 @@ template auto table_to_ndarray(sycl::queue& q, const table& t) { const auto rc = t.get_row_count(); const auto cc = t.get_column_count(); - auto res = ndarray::empty(q, { rc, cc }); + auto res = ndarray::empty(q, { rc, cc }, sycl::usm::alloc::host); for (std::int64_t r = 0; r < rc; ++r) { const auto row = row_accessor(t).pull(q, { r, r + 1 }); for (std::int64_t c = 0; c < cc; ++c) { @@ -259,6 +259,7 @@ TEMPLATE_LIST_TEST_M(search_test, "Randomly filled cosine-distance search", "[chebyshev][search][small]", search_types) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_correctness(); diff --git a/cpp/oneapi/dal/backend/primitives/search/test/cosine_search_dpc.cpp b/cpp/oneapi/dal/backend/primitives/search/test/cosine_search_dpc.cpp index cac6799e3a7..8ca803ed84d 100644 --- a/cpp/oneapi/dal/backend/primitives/search/test/cosine_search_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/search/test/cosine_search_dpc.cpp @@ -60,7 +60,7 @@ template auto table_to_ndarray(sycl::queue& q, const table& t) { const auto rc = t.get_row_count(); const auto cc = t.get_column_count(); - auto res = ndarray::empty(q, { rc, cc }); + auto res = ndarray::empty(q, { rc, cc }, sycl::usm::alloc::host); for (std::int64_t r = 0; r < rc; ++r) { const auto row = row_accessor(t).pull(q, { r, r + 1 }); for (std::int64_t c = 0; c < cc; ++c) { @@ -261,6 +261,7 @@ TEMPLATE_LIST_TEST_M(search_test, "Randomly filled cosine-distance search", "[cosine][search][small]", search_types) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_correctness(); diff --git a/cpp/oneapi/dal/backend/primitives/search/test/l2_search_dpc.cpp b/cpp/oneapi/dal/backend/primitives/search/test/l2_search_dpc.cpp index 37de637dc7a..48dbd990c34 100644 --- a/cpp/oneapi/dal/backend/primitives/search/test/l2_search_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/search/test/l2_search_dpc.cpp @@ -60,7 +60,7 @@ template auto table_to_ndarray(sycl::queue& q, const table& t) { const auto rc = t.get_row_count(); const auto cc = t.get_column_count(); - auto res = ndarray::empty(q, { rc, cc }); + auto res = ndarray::empty(q, { rc, cc }, sycl::usm::alloc::host); for (std::int64_t r = 0; r < rc; ++r) { const auto row = row_accessor(t).pull(q, { r, r + 1 }); for (std::int64_t c = 0; c < cc; ++c) { @@ -253,6 +253,7 @@ TEMPLATE_LIST_TEST_M(search_test, "Randomly filled L2-distance search", "[l2][search][small]", search_types) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_correctness(); diff --git a/cpp/oneapi/dal/backend/primitives/search/test/lp_search_dpc.cpp b/cpp/oneapi/dal/backend/primitives/search/test/lp_search_dpc.cpp index 62a58f8abf2..82a49de9bf4 100644 --- a/cpp/oneapi/dal/backend/primitives/search/test/lp_search_dpc.cpp +++ b/cpp/oneapi/dal/backend/primitives/search/test/lp_search_dpc.cpp @@ -60,7 +60,7 @@ template auto table_to_ndarray(sycl::queue& q, const table& t) { const auto rc = t.get_row_count(); const auto cc = t.get_column_count(); - auto res = ndarray::empty(q, { rc, cc }); + auto res = ndarray::empty(q, { rc, cc }, sycl::usm::alloc::host); for (std::int64_t r = 0; r < rc; ++r) { const auto row = row_accessor(t).pull(q, { r, r + 1 }); for (std::int64_t c = 0; c < cc; ++c) { @@ -264,6 +264,7 @@ TEMPLATE_LIST_TEST_M(search_test, "Randomly filled Lp-distance search", "[l2][search][small]", search_types) { + SKIP_IF(this->get_policy().is_cpu()); SKIP_IF(this->not_float64_friendly()); this->generate(); this->test_correctness();