\doxysection{gko::\+cuda\+\_\+stream Class Reference}
\hypertarget{classgko_1_1cuda__stream}{}\label{classgko_1_1cuda__stream}\index{gko::cuda\_stream@{gko::cuda\_stream}}


An RAII wrapper for a custom CUDA stream.  




{\ttfamily \+\#include $<$ginkgo/\+core/\+base/\+stream.\+hpp$>$}

\doxysubsubsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\Hypertarget{classgko_1_1cuda__stream_a885b16a70792317609f90c72a4249e3b}\label{classgko_1_1cuda__stream_a885b16a70792317609f90c72a4249e3b} 
{\bfseries cuda\+\_\+stream} ()
\begin{DoxyCompactList}\small\item\em Creates an empty stream wrapper, representing the default stream. \end{DoxyCompactList}\item 
\doxymbox{\hyperlink{classgko_1_1cuda__stream_ab68accd2a7f0796f064fc49a1c27479c}{cuda\+\_\+stream}} (int device\+\_\+id)
\begin{DoxyCompactList}\small\item\em Creates a new custom CUDA stream on the given device. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1cuda__stream_a5a6c6243d4370032a018b8ed4eb49378}\label{classgko_1_1cuda__stream_a5a6c6243d4370032a018b8ed4eb49378} 
{\bfseries \texorpdfstring{$\sim$}{\string~}cuda\+\_\+stream} ()
\begin{DoxyCompactList}\small\item\em Destroys the custom CUDA stream, if it isn\textquotesingle{}t empty. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1cuda__stream_a11d2605a5eaf1e6f268e53cfb19d6d09}\label{classgko_1_1cuda__stream_a11d2605a5eaf1e6f268e53cfb19d6d09} 
{\bfseries cuda\+\_\+stream} (const cuda\+\_\+stream \&)=delete
\item 
\Hypertarget{classgko_1_1cuda__stream_a69c4b9eb64aff16655733e952414c446}\label{classgko_1_1cuda__stream_a69c4b9eb64aff16655733e952414c446} 
{\bfseries cuda\+\_\+stream} (cuda\+\_\+stream \&\&)
\begin{DoxyCompactList}\small\item\em Move-\/constructs from an existing stream, which will be emptied. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1cuda__stream_a7c3de56c50565fcbf9af4dd190a5642d}\label{classgko_1_1cuda__stream_a7c3de56c50565fcbf9af4dd190a5642d} 
\doxymbox{\hyperlink{classgko_1_1cuda__stream_a885b16a70792317609f90c72a4249e3b}{cuda\+\_\+stream}} \& {\bfseries operator=} (const \doxymbox{\hyperlink{classgko_1_1cuda__stream_a885b16a70792317609f90c72a4249e3b}{cuda\+\_\+stream}} \&)=delete
\item 
\Hypertarget{classgko_1_1cuda__stream_a7fe861a6a988de307998b5d8f80e3671}\label{classgko_1_1cuda__stream_a7fe861a6a988de307998b5d8f80e3671} 
\doxymbox{\hyperlink{classgko_1_1cuda__stream_a885b16a70792317609f90c72a4249e3b}{cuda\+\_\+stream}} \& {\bfseries operator=} (\doxymbox{\hyperlink{classgko_1_1cuda__stream_a885b16a70792317609f90c72a4249e3b}{cuda\+\_\+stream}} \&\&)=delete
\begin{DoxyCompactList}\small\item\em Move-\/assigns from an existing stream, which will be emptied. \end{DoxyCompactList}\item 
CUstream\+\_\+st \texorpdfstring{$\ast$}{*} \doxymbox{\hyperlink{classgko_1_1cuda__stream_a8125fbcb859c04140fe4513b019251d4}{get}} () const
\begin{DoxyCompactList}\small\item\em Returns the native CUDA stream handle. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
An RAII wrapper for a custom CUDA stream. 

The stream will be created on construction and destroyed when the lifetime of the wrapper ends. 

\label{doc-constructors}
\Hypertarget{classgko_1_1cuda__stream_doc-constructors}
\doxysubsection{Constructor \& Destructor Documentation}
\Hypertarget{classgko_1_1cuda__stream_ab68accd2a7f0796f064fc49a1c27479c}\index{gko::cuda\_stream@{gko::cuda\_stream}!cuda\_stream@{cuda\_stream}}
\index{cuda\_stream@{cuda\_stream}!gko::cuda\_stream@{gko::cuda\_stream}}
\doxysubsubsection{\texorpdfstring{cuda\_stream()}{cuda\_stream()}}
{\footnotesize\ttfamily \label{classgko_1_1cuda__stream_ab68accd2a7f0796f064fc49a1c27479c} 
gko::\+cuda\+\_\+stream::\+cuda\+\_\+stream (\begin{DoxyParamCaption}\item[{int}]{device\+\_\+id}{}\end{DoxyParamCaption})}



Creates a new custom CUDA stream on the given device. 


\begin{DoxyParams}{Parameters}
{\em device\+\_\+id} & the device ID to create the stream on. \\
\hline
\end{DoxyParams}


\label{doc-func-members}
\Hypertarget{classgko_1_1cuda__stream_doc-func-members}
\doxysubsection{Member Function Documentation}
\Hypertarget{classgko_1_1cuda__stream_a8125fbcb859c04140fe4513b019251d4}\index{gko::cuda\_stream@{gko::cuda\_stream}!get@{get}}
\index{get@{get}!gko::cuda\_stream@{gko::cuda\_stream}}
\doxysubsubsection{\texorpdfstring{get()}{get()}}
{\footnotesize\ttfamily \label{classgko_1_1cuda__stream_a8125fbcb859c04140fe4513b019251d4} 
CUstream\+\_\+st \texorpdfstring{$\ast$}{*} gko::\+cuda\+\_\+stream::\+get (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const}



Returns the native CUDA stream handle. 

In an empty \doxylink{classgko_1_1cuda__stream}{cuda\+\_\+stream}, this will return nullptr. 

The documentation for this class was generated from the following file:\+\begin{DoxyCompactItemize}
\item 
ginkgo/\+core/\+base/\+stream.\+hpp\end{DoxyCompactItemize}
