GPU kernels cannot appear in translation units that make any non-trivial use of HPX, because many HPX declarations are removed by the preprocessor when compiling for the device. Obviously many HPX features cannot be used on a GPU, but the implicit __host__ everywhere should generally be sufficient to enforce that without having simple name lookup fail in any class that uses HPX in one member function and launches a kernel in another.
(We've discussed this in the past; sorry if I just failed to find an existing formal issue for it.)
GPU kernels cannot appear in translation units that make any non-trivial use of HPX, because many HPX declarations are removed by the preprocessor when compiling for the device. Obviously many HPX features cannot be used on a GPU, but the implicit
__host__everywhere should generally be sufficient to enforce that without having simple name lookup fail in any class that uses HPX in one member function and launches a kernel in another.(We've discussed this in the past; sorry if I just failed to find an existing formal issue for it.)