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

Replace int_div_ceil with cuda::std::ceil #631

Open
sleeepyjack opened this issue Oct 31, 2024 · 2 comments · May be fixed by #651
Open

Replace int_div_ceil with cuda::std::ceil #631

sleeepyjack opened this issue Oct 31, 2024 · 2 comments · May be fixed by #651
Labels
good first issue Good for newcomers type: improvement Improvement / enhancement to an existing function

Comments

@sleeepyjack
Copy link
Collaborator

we can probably remove

__host__ __device__ constexpr T int_div_ceil(T dividend, U divisor) noexcept

and use cuda::std::ceil instead

Originally posted by @PointKernel in #630 (comment)

@PointKernel PointKernel added good first issue Good for newcomers type: improvement Improvement / enhancement to an existing function labels Nov 1, 2024
@willtryagain
Copy link

willtryagain commented Dec 4, 2024

Hello,

what header file to include for cuda::std::ceil?

should we delete the math.cuh file as no other functions defined?

@PointKernel
Copy link
Member

Hi @willtryagain, std::ceil is defined in the cmath header per https://en.cppreference.com/w/cpp/numeric/math/ceil. Similarly, cuda::std::ceil can be found in the cuda/std/cmath header. Once all instances of int_div_ceil are replaced with cuda::std::ceil, we can remove the detail math.cuh file.

@willtryagain willtryagain linked a pull request Dec 5, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers type: improvement Improvement / enhancement to an existing function
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants