ATLAS Offline Software
Public Member Functions | List of all members
AthCUDA::IKernelRunnerSvc Class Referenceabstract

Interface for executing AthCUDA::IKernelTask tasks. More...

#include <IKernelRunnerSvc.h>

Inheritance diagram for AthCUDA::IKernelRunnerSvc:
Collaboration diagram for AthCUDA::IKernelRunnerSvc:

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...
 

Detailed Description

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.

Author
Attila Krasznahorkay Attil.nosp@m.a.Kr.nosp@m.aszna.nosp@m.hork.nosp@m.ay@ce.nosp@m.rn.c.nosp@m.h

Definition at line 27 of file IKernelRunnerSvc.h.

Member Function Documentation

◆ DeclareInterfaceID()

AthCUDA::IKernelRunnerSvc::DeclareInterfaceID ( AthCUDA::IKernelRunnerSvc  ,
,
 
)

Declare the interface ID.

◆ execute()

virtual StatusCode AthCUDA::IKernelRunnerSvc::execute ( std::unique_ptr< IKernelTask task)
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.

Parameters
taskThe task to be executed on the CPU or GPU
Returns
The usual StatusCode values

The documentation for this class was generated from the following file: