ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Control
AthCUDA
AthCUDAInterfaces
AthCUDAInterfaces
IKernelTask.h
Go to the documentation of this file.
1
// Dear emacs, this is -*- c++ -*-
2
//
3
// Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
4
//
5
#ifndef ATHCUDAINTERFACES_IKERNELTASK_H
6
#define ATHCUDAINTERFACES_IKERNELTASK_H
7
8
namespace
AthCUDA
{
9
10
// Forward declaration(s).
11
class
StreamHolder
;
12
22
class
IKernelTask
{
23
24
public
:
26
virtual
~IKernelTask
() =
default
;
27
29
enum
KernelExecMode
{
31
Synchronous
= 0,
33
Asynchronous
= 1
34
};
35
44
virtual
int
execute
(
StreamHolder
& stream ) = 0;
45
58
virtual
int
finished
(
int
code,
KernelExecMode
mode ) = 0;
59
60
};
// class IKernelTask
61
62
}
// namespace AthCUDA
63
64
#endif
// ATHCUDAINTERFACES_IKERNELTASK_H
AthCUDA::IKernelTask
Abstract interface for setting up / running a CUDA task.
Definition
IKernelTask.h:22
AthCUDA::IKernelTask::KernelExecMode
KernelExecMode
Possible modes in which the kernel was executed.
Definition
IKernelTask.h:29
AthCUDA::IKernelTask::Synchronous
@ Synchronous
The kernel was executed synchronously on the CPU.
Definition
IKernelTask.h:31
AthCUDA::IKernelTask::Asynchronous
@ Asynchronous
The kernel was executed asynchronously on a CUDA device.
Definition
IKernelTask.h:33
AthCUDA::IKernelTask::finished
virtual int finished(int code, KernelExecMode mode)=0
Function called when an asynchronous execution finishes.
AthCUDA::IKernelTask::execute
virtual int execute(StreamHolder &stream)=0
Execute the kernel using a specific stream.
AthCUDA::IKernelTask::~IKernelTask
virtual ~IKernelTask()=default
Virtual destructor, to make vtable happy.
AthCUDA::StreamHolder
Helper class for handling CUDA streams.
Definition
StreamHolder.h:24
AthCUDA
Definition
Info.h:14
Generated on
for ATLAS Offline Software by
1.17.0