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

[WIP] Memory footprint reduction in graph creation #4642

Closed
wants to merge 6 commits into from
Closed
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
24 changes: 24 additions & 0 deletions cpp/include/cugraph/partition_manager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,30 @@ class partition_manager {
: (major_comm_rank * minor_comm_size + minor_comm_rank);
}

#ifdef __CUDACC__
__host__ __device__
#endif
static int
compute_major_comm_rank_from_global_comm_rank(int major_comm_size,
int minor_comm_size,
int comm_rank)
{
return map_major_comm_to_gpu_row_comm ? comm_rank % major_comm_size
: comm_rank / minor_comm_size;
}

#ifdef __CUDACC__
__host__ __device__
#endif
static int
compute_minor_comm_rank_from_global_comm_rank(int major_comm_size,
int minor_comm_size,
int comm_rank)
{
return map_major_comm_to_gpu_row_comm ? comm_rank / major_comm_size
: comm_rank % minor_comm_size;
}

#ifdef __CUDACC__
__host__ __device__
#endif
Expand Down
Loading
Loading