ATLAS Offline Software
Loading...
Searching...
No Matches
StreamHolder.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_STREAMHOLDER_H
6#define ATHCUDAINTERFACES_STREAMHOLDER_H
7
8namespace AthCUDA {
9
10 // Forward declaration(s).
11 class IStreamPoolSvc;
12
25
27#ifdef __CUDACC__
28 friend cudaStream_t getStream( StreamHolder& );
29#endif // __CUDACC__
30
31 public:
35 StreamHolder( void* stream, IStreamPoolSvc* pool );
37 StreamHolder( const StreamHolder& ) = delete;
39 StreamHolder( StreamHolder&& parent );
42
44 StreamHolder& operator=( const StreamHolder& ) = delete;
47
49 operator bool() const;
50
51 private:
53 void* m_stream;
56
57 }; // class StreamHolder
58
59} // namespace AthCUDA
60
61#endif // ATHCUDAINTERFACES_STREAMHOLDER_H
Interface for a CUDA stream pool service.
StreamHolder & operator=(const StreamHolder &)=delete
Copy assignment operator.
IStreamPoolSvc * m_pool
The pool that this holder is attached to.
void * m_stream
The managed stream.
~StreamHolder()
Destructor.
StreamHolder(const StreamHolder &)=delete
Copy constructor.
StreamHolder()
Friend declaration(s).
Definition Info.h:14
pool namespace
Definition libname.h:15