celeritas
celeritas copied to clipboard
Always launch a GPU step from Geant4 push
We should be able to use a stream-local status flag and CUDA's cudaLaunchHostFunc to set and clear a flag indicating whether the GPU is currently running a step in the current stream. Whenever we push a particle, if the GPU isn't running, we can launch a step and let Geant4 continue. This will allow us to manage the CUDA execution asynchronously without having a separate management thread.