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

std::is_trivially_copyable constraint on kernel type #2248

Open
jasminmohnke opened this issue Mar 13, 2024 · 1 comment
Open

std::is_trivially_copyable constraint on kernel type #2248

jasminmohnke opened this issue Mar 13, 2024 · 1 comment

Comments

@jasminmohnke
Copy link

While #2198 clears the issue we had with the check on kernel arguments being trivially copyable as discussed in #2195, unfortunately I am running into a comparable issue with the check done on the kernel itself in

std::is_trivially_copyable_v<TKernelFnObj> || __nv_is_extended_device_lambda_closure_type(TKernelFnObj)
|| __nv_is_extended_host_device_lambda_closure_type(TKernelFnObj),
"Kernels must be trivially copyable or an extended CUDA lambda expression!");

If, for instance, a user kernel has a member that is of a type such as described previously (#2195), std::is_trivially_copyable evaluates to false as well. A trait similarly to the one you introduced for the kernel argument would be helpful to have for the kernel as well.

@psychocoderHPC
Copy link
Member

Thanks for opening the issue, we will have a look into it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants