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

Add compute_hash overloads for std::byte* to maintain backward compatibility #608

Merged
merged 3 commits into from
Oct 3, 2024

Conversation

PointKernel
Copy link
Member

Unblock rapidsai/cugraph#4686

The compute_hash function is a host-device function, so the appropriate argument type is cuda::std::byte. However, to ensure backward compatibility and avoid breaking existing use cases, this PR adds overloads that accept std::byte.

@PointKernel PointKernel added type: feature request New feature request helps: rapids Helps or needed by RAPIDS Needs Review Awaiting reviews before merging labels Oct 2, 2024
Copy link
Collaborator

@sleeepyjack sleeepyjack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR itself LGTM and can be merged to unblock cugraph.

However, I find this workaround a bit nasty given that std::byte and cuda::std::byte are virtually the same thing. In my book, there should exist at least an implicit conversion between the two.

Also, I think cugraph should use cuda::std::byte here in the first place.

@PointKernel
Copy link
Member Author

Also, I think cugraph should use cuda::std::byte here in the first place.

Agreed. I will open a cugraph PR for this once the current work is merged

@PointKernel PointKernel merged commit f768729 into NVIDIA:dev Oct 3, 2024
19 checks passed
@PointKernel PointKernel deleted the add-std-overloads branch October 3, 2024 18:18
@PointKernel
Copy link
Member Author

Also, I think cugraph should use cuda::std::byte here in the first place.

Opened rapidsai/cugraph#4707 to fix this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
helps: rapids Helps or needed by RAPIDS Needs Review Awaiting reviews before merging type: feature request New feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants