Skip to content

Commit

Permalink
address PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ChuckHastings committed Sep 17, 2021
1 parent b43b93c commit 4507c8c
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions cpp/tests/structure/renumbering_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,6 @@
#include <random>
#include <vector>

// do the perf measurements
// enabled by command line parameter s'--perf'
//
static int PERF = 0;

struct Renumbering_Usecase {
bool check_correctness{true};
};
Expand Down Expand Up @@ -87,17 +82,17 @@ class Tests_Renumbering
raft::update_host(h_original_dst_v.data(), dst_v.data(), dst_v.size(), handle.get_stream());
}

if (PERF) {
handle.get_stream_view().synchronize(); // for consistent performance measurement
if (cugraph::test::g_perf) {
CUDA_TRY(cudaDeviceSynchronize()); // for consistent performance measurement
hr_clock.start();
}

std::tie(renumber_map_labels_v, std::ignore) =
cugraph::renumber_edgelist<vertex_t, edge_t, false>(
handle, std::nullopt, src_v.begin(), dst_v.begin(), src_v.size());

if (PERF) {
handle.get_stream_view().synchronize(); // for consistent performance measurement
if (cugraph::test::g_perf) {
CUDA_TRY(cudaDeviceSynchronize()); // for consistent performance measurement
double elapsed_time{0.0};
hr_clock.stop(&elapsed_time);
std::cout << "renumbering took " << elapsed_time * 1e-6 << " s.\n";
Expand Down Expand Up @@ -166,7 +161,11 @@ INSTANTIATE_TEST_SUITE_P(
::testing::Values(cugraph::test::Rmat_Usecase(10, 16, 0.57, 0.19, 0.19, 0, false, false))));

INSTANTIATE_TEST_SUITE_P(
rmat_large_tests,
rmat_benchmark_test, /* note that scale & edge factor can be overridden in benchmarking (with
--gtest_filter to select only the rmat_benchmark_test with a specific
vertex & edge type combination) by command line arguments and do not
include more than one Rmat_Usecase that differ only in scale or edge
factor (to avoid running same benchmarks more than once) */
Tests_Renumbering_Rmat,
::testing::Combine(
// disable correctness checks for large graphs
Expand Down

0 comments on commit 4507c8c

Please sign in to comment.