ATLAS Offline Software
|
Interface for executing AthCUDA::IKernelTask
tasks.
More...
#include <IKernelRunnerSvc.h>
Public Member Functions | |
DeclareInterfaceID (AthCUDA::IKernelRunnerSvc, 1, 0) | |
Declare the interface ID. More... | |
virtual StatusCode | execute (std::unique_ptr< IKernelTask > task)=0 |
Execute a user specified kernel task. More... | |
Interface for executing AthCUDA::IKernelTask
tasks.
The implementation of this service is supposed to be used for executing "GPU calculations" in a balanced way between the CPU and the GPU.
Definition at line 27 of file IKernelRunnerSvc.h.
AthCUDA::IKernelRunnerSvc::DeclareInterfaceID | ( | AthCUDA::IKernelRunnerSvc | , |
1 | , | ||
0 | |||
) |
Declare the interface ID.
|
pure virtual |
Execute a user specified kernel task.
If a GPU is available at runtime, and it is not doing other things at the moment, this function offloads the calculation to the GPU, and returns right away. The user code is expected to wait for the task to finish, in "some" way provided by the task object itself.
If a GPU is not available for any reason, the function just executes the task on the CPU in the caller thread, and returns only once the task is finished.
task | The task to be executed on the CPU or GPU |
StatusCode
values