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

Make Alpaka EDProducers to implicitly copy their host products to device if a copy function exists #1116

Open
makortel opened this issue Dec 23, 2024 · 0 comments

Comments

@makortel
Copy link
Collaborator

This would make the few EDModules that only reformat and copy a data product to device simpler. It would also make those cases a bit more efficient if another EDModule consumes the corresponding host product (avoiding the implicit device->host copy). It would also make the EDProducer behavior more consistent with ESProducers.

Given that the Alpaka EDModules can produce "legacy data products" that are not intended to be copied to device, the implicit copy can be done only if the copy function (CopyToDevice<T> specialization) is defined. This is in contrast to implicit device-to-host copies, where the copy function (CopyToHost<T> specialization) is required to exists, and thus leaves door open for subtle problems if a developer expects the implicit host-to-device copy to happen but it isn't, and the error message might not help towards a solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 🔖 Ready
Development

No branches or pull requests

1 participant