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

UCT/ROCM/COPY: Fix test_uct_query gtest #6990

Merged
merged 1 commit into from
Jun 23, 2021
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
8 changes: 7 additions & 1 deletion src/uct/rocm/copy/rocm_copy_iface.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,20 @@ static uct_iface_ops_t uct_rocm_copy_iface_ops = {
.iface_is_reachable = uct_rocm_copy_iface_is_reachable,
};

static uct_iface_internal_ops_t uct_rocm_copy_iface_internal_ops = {
.iface_estimate_perf = (uct_iface_estimate_perf_func_t)ucs_empty_function_return_success,
.iface_vfs_refresh = (uct_iface_vfs_refresh_func_t)ucs_empty_function,
};

static UCS_CLASS_INIT_FUNC(uct_rocm_copy_iface_t, uct_md_h md, uct_worker_h worker,
const uct_iface_params_t *params,
const uct_iface_config_t *tl_config)
{
uct_rocm_copy_iface_config_t *config = ucs_derived_of(tl_config,
uct_rocm_copy_iface_config_t);

UCS_CLASS_CALL_SUPER_INIT(uct_base_iface_t, &uct_rocm_copy_iface_ops, NULL,
UCS_CLASS_CALL_SUPER_INIT(uct_base_iface_t, &uct_rocm_copy_iface_ops,
&uct_rocm_copy_iface_internal_ops,
md, worker, params,
tl_config UCS_STATS_ARG(params->stats_root)
UCS_STATS_ARG(UCT_ROCM_COPY_TL_NAME));
Expand Down
3 changes: 2 additions & 1 deletion test/gtest/uct/test_p2p_rma.cc
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,8 @@ void uct_p2p_rma_test::test_xfer(send_func_t send, size_t length,
{
ucs_memory_type_t src_mem_type = UCS_MEMORY_TYPE_HOST;

if (has_transport("cuda_ipc")) {
if (has_transport("cuda_ipc") ||
has_transport("rocm_copy")) {
src_mem_type = mem_type;
}

Expand Down
4 changes: 3 additions & 1 deletion test/gtest/uct/v2/test_uct_query.cc
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ UCS_TEST_P(test_uct_query, query_perf)
/* At least one type of bandwidth must be non-zero */
EXPECT_NE(0, perf_attr.bandwidth.shared + perf_attr.bandwidth.dedicated);

if (has_transport("cuda_copy") || has_transport("gdr_copy")) {
if (has_transport("cuda_copy") ||
has_transport("gdr_copy") ||
has_transport("rocm_copy")) {
uct_perf_attr_t perf_attr_get;
perf_attr_get.field_mask = UCT_PERF_ATTR_FIELD_OPERATION |
UCT_PERF_ATTR_FIELD_BANDWIDTH;
Expand Down