\doxysection{gko::\+Hip\+Executor Class Reference}
\hypertarget{classgko_1_1HipExecutor}{}\label{classgko_1_1HipExecutor}\index{gko::HipExecutor@{gko::HipExecutor}}


This is the \doxylink{classgko_1_1Executor}{Executor} subclass which represents the HIP enhanced device.  




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



Inheritance diagram for gko::\+Hip\+Executor:\+
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{classgko_1_1HipExecutor__inherit__graph}
\end{center}
\end{figure}


Collaboration diagram for gko::\+Hip\+Executor:\+
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{classgko_1_1HipExecutor__coll__graph}
\end{center}
\end{figure}
\doxysubsubsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$ \doxymbox{\hyperlink{classgko_1_1HipExecutor_aa7f1d797dbce7f64f0bd458d55b42db5}{get\+\_\+master}} () noexcept override
\begin{DoxyCompactList}\small\item\em Returns the master \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} of this \doxylink{classgko_1_1Executor}{Executor}. \end{DoxyCompactList}\item 
std::\+shared\+\_\+ptr$<$ const \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$ \doxymbox{\hyperlink{classgko_1_1HipExecutor_a6ad248f899a60fc779f36119afe62ca0}{get\+\_\+master}} () const noexcept override
\begin{DoxyCompactList}\small\item\em Returns the master \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} of this \doxylink{classgko_1_1Executor}{Executor}.    \end{DoxyCompactList}\item 
void \doxymbox{\hyperlink{classgko_1_1HipExecutor_a0ea0ec8722767138953110b52d325b4a}{synchronize}} () const override
\begin{DoxyCompactList}\small\item\em Synchronize the operations launched on the executor with its master. \end{DoxyCompactList}\item 
\doxymbox{\hyperlink{classgko_1_1scoped__device__id__guard}{scoped\+\_\+device\+\_\+id\+\_\+guard}} \doxymbox{\hyperlink{classgko_1_1HipExecutor_ac14589119a116de96dc3b5f63fe3bc54}{get\+\_\+scoped\+\_\+device\+\_\+id\+\_\+guard}} () const override
\item 
std::\+string \doxymbox{\hyperlink{classgko_1_1HipExecutor_a205464163af208922487c35a6d198418}{get\+\_\+description}} () const override
\item 
\Hypertarget{classgko_1_1HipExecutor_a37a35665c3983e56105c6acea9de73c6}\label{classgko_1_1HipExecutor_a37a35665c3983e56105c6acea9de73c6} 
int {\bfseries get\+\_\+device\+\_\+id} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the HIP device id of the device associated to this executor. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_a43bc417378f1c0f07ef49d2856ddd37c}\label{classgko_1_1HipExecutor_a43bc417378f1c0f07ef49d2856ddd37c} 
int {\bfseries get\+\_\+num\+\_\+warps\+\_\+per\+\_\+sm} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the number of warps per SM of this executor. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_ac69c763f9d90e948d03ed1e5ed23903c}\label{classgko_1_1HipExecutor_ac69c763f9d90e948d03ed1e5ed23903c} 
int {\bfseries get\+\_\+num\+\_\+multiprocessor} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the number of multiprocessor of this executor. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_a4cdda4e0d7031ab353555193927d0975}\label{classgko_1_1HipExecutor_a4cdda4e0d7031ab353555193927d0975} 
int {\bfseries get\+\_\+major\+\_\+version} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the major version of compute capability. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_a78f3bfa05f6d38c286309436781a6f7a}\label{classgko_1_1HipExecutor_a78f3bfa05f6d38c286309436781a6f7a} 
int {\bfseries get\+\_\+minor\+\_\+version} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the minor version of compute capability. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_add2eb69abc3225f1ab7e5b01d9ebb307}\label{classgko_1_1HipExecutor_add2eb69abc3225f1ab7e5b01d9ebb307} 
int {\bfseries get\+\_\+num\+\_\+warps} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the number of warps of this executor. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_ae470cdfd4273b02b2563101d6146db26}\label{classgko_1_1HipExecutor_ae470cdfd4273b02b2563101d6146db26} 
int {\bfseries get\+\_\+warp\+\_\+size} () const noexcept
\begin{DoxyCompactList}\small\item\em Get the warp size of this executor. \end{DoxyCompactList}\item 
hipblas\+Context \texorpdfstring{$\ast$}{*} \doxymbox{\hyperlink{classgko_1_1HipExecutor_aecd53c50e8c23e18a0ee9b1907a6f936}{get\+\_\+hipblas\+\_\+handle}} () const
\begin{DoxyCompactList}\small\item\em Get the hipblas handle for this executor. \end{DoxyCompactList}\item 
hipblas\+Context \texorpdfstring{$\ast$}{*} \doxymbox{\hyperlink{classgko_1_1HipExecutor_ac9f490d7994dc2449d89b23e1470e10f}{get\+\_\+blas\+\_\+handle}} () const
\begin{DoxyCompactList}\small\item\em Get the hipblas handle for this executor.    \end{DoxyCompactList}\item 
hipsparse\+Context \texorpdfstring{$\ast$}{*} \doxymbox{\hyperlink{classgko_1_1HipExecutor_addb09880cd9944899e1115636598cc06}{get\+\_\+hipsparse\+\_\+handle}} () const
\begin{DoxyCompactList}\small\item\em Get the hipsparse handle for this executor. \end{DoxyCompactList}\item 
hipsparse\+Context \texorpdfstring{$\ast$}{*} \doxymbox{\hyperlink{classgko_1_1HipExecutor_aa6f204632ad7562b49d72675024ea2d7}{get\+\_\+sparselib\+\_\+handle}} () const
\begin{DoxyCompactList}\small\item\em Get the hipsparse handle for this executor.    \end{DoxyCompactList}\item 
int \doxymbox{\hyperlink{classgko_1_1HipExecutor_ae39be6e255dfe5ecf6fe542da914afec}{get\+\_\+closest\+\_\+numa}} () const
\begin{DoxyCompactList}\small\item\em Get the closest NUMA node. \end{DoxyCompactList}\item 
std::\+vector$<$ int $>$ \doxymbox{\hyperlink{classgko_1_1HipExecutor_a739d2395233434cb6fbf9e90684ca052}{get\+\_\+closest\+\_\+pus}} () const
\begin{DoxyCompactList}\small\item\em Get the closest PUs. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_ad25e1bdf31ce4c6e9923643fb76c884a}\label{classgko_1_1HipExecutor_ad25e1bdf31ce4c6e9923643fb76c884a} 
CUstream\+\_\+st \texorpdfstring{$\ast$}{*} {\bfseries get\+\_\+stream} () const
\item 
virtual void \doxymbox{\hyperlink{classgko_1_1HipExecutor_a4fdbf8100b039d3858634bf9c502f5d7}{run}} (const \doxymbox{\hyperlink{classgko_1_1Operation}{Operation}} \&op) const=0
\begin{DoxyCompactList}\small\item\em Runs the specified \doxylink{classgko_1_1Operation}{Operation} using this \doxylink{classgko_1_1Executor}{Executor}. \end{DoxyCompactList}\item 
{\footnotesize template$<$typename Closure\+Omp, typename Closure\+Cuda, typename Closure\+Hip, typename Closure\+Dpcpp$>$ }\\void \doxymbox{\hyperlink{classgko_1_1HipExecutor_a294787f033b02fd013af087d02a4ae1b}{run}} (const Closure\+Omp \&op\+\_\+omp, const Closure\+Cuda \&op\+\_\+cuda, const Closure\+Hip \&op\+\_\+hip, const Closure\+Dpcpp \&op\+\_\+dpcpp) const
\begin{DoxyCompactList}\small\item\em Runs one of the passed in functors, depending on the \doxylink{classgko_1_1Executor}{Executor} type. \end{DoxyCompactList}\item 
{\footnotesize template$<$typename Closure\+Reference, typename Closure\+Omp, typename Closure\+Cuda, typename Closure\+Hip, typename Closure\+Dpcpp$>$ }\\void \doxymbox{\hyperlink{classgko_1_1HipExecutor_abe906f109824da54447e504ff88aa97f}{run}} (std::\+string name, const Closure\+Reference \&op\+\_\+ref, const Closure\+Omp \&op\+\_\+omp, const Closure\+Cuda \&op\+\_\+cuda, const Closure\+Hip \&op\+\_\+hip, const Closure\+Dpcpp \&op\+\_\+dpcpp) const
\begin{DoxyCompactList}\small\item\em Runs one of the passed in functors, depending on the \doxylink{classgko_1_1Executor}{Executor} type. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsubsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
static std::\+shared\+\_\+ptr$<$ Hip\+Executor $>$ \doxymbox{\hyperlink{classgko_1_1HipExecutor_a8afc5210bf8dd8aedfceab4b73f0047b}{create}} (int device\+\_\+id, std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$ master, bool device\+\_\+reset, \doxymbox{\hyperlink{namespacegko_afbed8e2cbd3ee4ca962e12f688858bdb}{allocation\+\_\+mode}} alloc\+\_\+mode=default\+\_\+hip\+\_\+alloc\+\_\+mode, CUstream\+\_\+st \texorpdfstring{$\ast$}{*}stream=nullptr)
\begin{DoxyCompactList}\small\item\em Creates a new \doxylink{classgko_1_1HipExecutor}{Hip\+Executor}. \end{DoxyCompactList}\item 
\Hypertarget{classgko_1_1HipExecutor_aed29e517f16887258df6dcda7dd30f1c}\label{classgko_1_1HipExecutor_aed29e517f16887258df6dcda7dd30f1c} 
static std::\+shared\+\_\+ptr$<$ Hip\+Executor $>$ {\bfseries create} (int device\+\_\+id, std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$ master, std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1HipAllocatorBase}{Hip\+Allocator\+Base}} $>$ \doxymbox{\hyperlink{classgko_1_1Executor_a99e1d008646298b06ce10979253de1ec}{alloc}}=std::\+make\+\_\+shared$<$ \doxymbox{\hyperlink{classgko_1_1HipAllocator}{Hip\+Allocator}} $>$(), CUstream\+\_\+st \texorpdfstring{$\ast$}{*}stream=nullptr)
\item 
\Hypertarget{classgko_1_1HipExecutor_a7b34cbd84692dafa2290e6630754aa97}\label{classgko_1_1HipExecutor_a7b34cbd84692dafa2290e6630754aa97} 
static int {\bfseries get\+\_\+num\+\_\+devices} ()
\begin{DoxyCompactList}\small\item\em Get the number of devices present on the system. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
This is the \doxylink{classgko_1_1Executor}{Executor} subclass which represents the HIP enhanced device. 

\label{doc-func-members}
\Hypertarget{classgko_1_1HipExecutor_doc-func-members}
\doxysubsection{Member Function Documentation}
\Hypertarget{classgko_1_1HipExecutor_a8afc5210bf8dd8aedfceab4b73f0047b}\index{gko::HipExecutor@{gko::HipExecutor}!create@{create}}
\index{create@{create}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{create()}{create()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a8afc5210bf8dd8aedfceab4b73f0047b} 
std::\+shared\+\_\+ptr$<$ Hip\+Executor $>$ gko::\+\+Hip\+Executor::\+create (\begin{DoxyParamCaption}\item[{int}]{device\+\_\+id}{, }\item[{std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$}]{master}{, }\item[{bool}]{device\+\_\+reset}{, }\item[{\doxymbox{\hyperlink{namespacegko_afbed8e2cbd3ee4ca962e12f688858bdb}{allocation\+\_\+mode}}}]{alloc\+\_\+mode}{ = {\ttfamily default\+\_\+hip\+\_\+alloc\+\_\+mode}, }\item[{CUstream\+\_\+st \texorpdfstring{$\ast$}{*}}]{stream}{ = {\ttfamily nullptr}}\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [static]}}



Creates a new \doxylink{classgko_1_1HipExecutor}{Hip\+Executor}. 


\begin{DoxyParams}{Parameters}
{\em device\+\_\+id} & the HIP device id of this device \\
\hline
{\em master} & an executor on the host that is used to invoke the device kernels \\
\hline
{\em device\+\_\+reset} & whether to reset the device after the object exits the scope. \\
\hline
{\em alloc\+\_\+mode} & the allocation mode that the executor should operate on. See @allocation\+\_\+mode for more details \\
\hline
\end{DoxyParams}


References \doxymbox{\hyperlink{classgko_1_1Executor_a99e1d008646298b06ce10979253de1ec}{gko::\+\+Executor::\+alloc()}}, and \doxymbox{\hyperlink{classgko_1_1HipExecutor_a8afc5210bf8dd8aedfceab4b73f0047b}{create()}}.



Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_a8afc5210bf8dd8aedfceab4b73f0047b}{create()}}.

\Hypertarget{classgko_1_1HipExecutor_ac9f490d7994dc2449d89b23e1470e10f}\index{gko::HipExecutor@{gko::HipExecutor}!get\_blas\_handle@{get\_blas\_handle}}
\index{get\_blas\_handle@{get\_blas\_handle}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_blas\_handle()}{get\_blas\_handle()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_ac9f490d7994dc2449d89b23e1470e10f} 
hipblas\+Context \texorpdfstring{$\ast$}{*} gko::\+\+Hip\+Executor::\+get\+\_\+blas\+\_\+handle (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Get the hipblas handle for this executor.    

\begin{DoxyReturn}{Returns}
the hipblas handle (hipblas\+Context\texorpdfstring{$\ast$}{*}) for this executor    
\end{DoxyReturn}


Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_aecd53c50e8c23e18a0ee9b1907a6f936}{get\+\_\+hipblas\+\_\+handle()}}.

\Hypertarget{classgko_1_1HipExecutor_ae39be6e255dfe5ecf6fe542da914afec}\index{gko::HipExecutor@{gko::HipExecutor}!get\_closest\_numa@{get\_closest\_numa}}
\index{get\_closest\_numa@{get\_closest\_numa}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_closest\_numa()}{get\_closest\_numa()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_ae39be6e255dfe5ecf6fe542da914afec} 
int gko::\+\+Hip\+Executor::\+get\+\_\+closest\+\_\+numa (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Get the closest NUMA node. 

\begin{DoxyReturn}{Returns}
the closest NUMA node closest to this device 
\end{DoxyReturn}
\Hypertarget{classgko_1_1HipExecutor_a739d2395233434cb6fbf9e90684ca052}\index{gko::HipExecutor@{gko::HipExecutor}!get\_closest\_pus@{get\_closest\_pus}}
\index{get\_closest\_pus@{get\_closest\_pus}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_closest\_pus()}{get\_closest\_pus()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a739d2395233434cb6fbf9e90684ca052} 
std::\+vector$<$ int $>$ gko::\+\+Hip\+Executor::\+get\+\_\+closest\+\_\+pus (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Get the closest PUs. 

\begin{DoxyReturn}{Returns}
the array of PUs closest to this device 
\end{DoxyReturn}
\Hypertarget{classgko_1_1HipExecutor_a205464163af208922487c35a6d198418}\index{gko::HipExecutor@{gko::HipExecutor}!get\_description@{get\_description}}
\index{get\_description@{get\_description}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_description()}{get\_description()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a205464163af208922487c35a6d198418} 
std::\+string gko::\+\+Hip\+Executor::\+get\+\_\+description (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}

\begin{DoxyReturn}{Returns}
a textual representation of the executor and its device. 
\end{DoxyReturn}


Implements \doxymbox{\hyperlink{classgko_1_1Executor_a9b25713dfacc7914b69115f815e616b0}{gko::\+\+Executor}}.



References \doxymbox{\hyperlink{classgko_1_1HipExecutor_a205464163af208922487c35a6d198418}{get\+\_\+description()}}.



Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_a205464163af208922487c35a6d198418}{get\+\_\+description()}}.

\Hypertarget{classgko_1_1HipExecutor_aecd53c50e8c23e18a0ee9b1907a6f936}\index{gko::HipExecutor@{gko::HipExecutor}!get\_hipblas\_handle@{get\_hipblas\_handle}}
\index{get\_hipblas\_handle@{get\_hipblas\_handle}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_hipblas\_handle()}{get\_hipblas\_handle()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_aecd53c50e8c23e18a0ee9b1907a6f936} 
hipblas\+Context \texorpdfstring{$\ast$}{*} gko::\+\+Hip\+Executor::\+get\+\_\+hipblas\+\_\+handle (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Get the hipblas handle for this executor. 

\begin{DoxyReturn}{Returns}
the hipblas handle (hipblas\+Context\texorpdfstring{$\ast$}{*}) for this executor 
\end{DoxyReturn}


References \doxymbox{\hyperlink{classgko_1_1HipExecutor_ac9f490d7994dc2449d89b23e1470e10f}{get\+\_\+blas\+\_\+handle()}}, and \doxymbox{\hyperlink{classgko_1_1HipExecutor_aecd53c50e8c23e18a0ee9b1907a6f936}{get\+\_\+hipblas\+\_\+handle()}}.



Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_aecd53c50e8c23e18a0ee9b1907a6f936}{get\+\_\+hipblas\+\_\+handle()}}.

\Hypertarget{classgko_1_1HipExecutor_addb09880cd9944899e1115636598cc06}\index{gko::HipExecutor@{gko::HipExecutor}!get\_hipsparse\_handle@{get\_hipsparse\_handle}}
\index{get\_hipsparse\_handle@{get\_hipsparse\_handle}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_hipsparse\_handle()}{get\_hipsparse\_handle()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_addb09880cd9944899e1115636598cc06} 
hipsparse\+Context \texorpdfstring{$\ast$}{*} gko::\+\+Hip\+Executor::\+get\+\_\+hipsparse\+\_\+handle (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Get the hipsparse handle for this executor. 

\begin{DoxyReturn}{Returns}
the hipsparse handle (hipsparse\+Context\texorpdfstring{$\ast$}{*}) for this executor 
\end{DoxyReturn}


References \doxymbox{\hyperlink{classgko_1_1HipExecutor_addb09880cd9944899e1115636598cc06}{get\+\_\+hipsparse\+\_\+handle()}}, and \doxymbox{\hyperlink{classgko_1_1HipExecutor_aa6f204632ad7562b49d72675024ea2d7}{get\+\_\+sparselib\+\_\+handle()}}.



Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_addb09880cd9944899e1115636598cc06}{get\+\_\+hipsparse\+\_\+handle()}}.

\Hypertarget{classgko_1_1HipExecutor_a6ad248f899a60fc779f36119afe62ca0}\index{gko::HipExecutor@{gko::HipExecutor}!get\_master@{get\_master}}
\index{get\_master@{get\_master}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_master()}{get\_master()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a6ad248f899a60fc779f36119afe62ca0} 
std::\+shared\+\_\+ptr$<$ const \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$ gko::\+\+Hip\+Executor::\+get\+\_\+master (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}, {\ttfamily [noexcept]}}



Returns the master \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} of this \doxylink{classgko_1_1Executor}{Executor}.    

\begin{DoxyReturn}{Returns}
the master \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} of this \doxylink{classgko_1_1Executor}{Executor}.    
\end{DoxyReturn}


Implements \doxymbox{\hyperlink{classgko_1_1Executor_a30d5407c37711d49184914026d815708}{gko::\+\+Executor}}.



References \doxymbox{\hyperlink{classgko_1_1HipExecutor_aa7f1d797dbce7f64f0bd458d55b42db5}{get\+\_\+master()}}.

\Hypertarget{classgko_1_1HipExecutor_aa7f1d797dbce7f64f0bd458d55b42db5}\index{gko::HipExecutor@{gko::HipExecutor}!get\_master@{get\_master}}
\index{get\_master@{get\_master}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_master()}{get\_master()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_aa7f1d797dbce7f64f0bd458d55b42db5} 
std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1Executor}{Executor}} $>$ gko::\+\+Hip\+Executor::\+get\+\_\+master (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}, {\ttfamily [noexcept]}}



Returns the master \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} of this \doxylink{classgko_1_1Executor}{Executor}. 

\begin{DoxyReturn}{Returns}
the master \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} of this \doxylink{classgko_1_1Executor}{Executor}. 
\end{DoxyReturn}


Implements \doxymbox{\hyperlink{classgko_1_1Executor_aa23172c7579fe4a9a41af8eba62ed54f}{gko::\+\+Executor}}.



References \doxymbox{\hyperlink{classgko_1_1HipExecutor_aa7f1d797dbce7f64f0bd458d55b42db5}{get\+\_\+master()}}.



Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_a6ad248f899a60fc779f36119afe62ca0}{get\+\_\+master()}}, and \doxymbox{\hyperlink{classgko_1_1HipExecutor_aa7f1d797dbce7f64f0bd458d55b42db5}{get\+\_\+master()}}.

\Hypertarget{classgko_1_1HipExecutor_ac14589119a116de96dc3b5f63fe3bc54}\index{gko::HipExecutor@{gko::HipExecutor}!get\_scoped\_device\_id\_guard@{get\_scoped\_device\_id\_guard}}
\index{get\_scoped\_device\_id\_guard@{get\_scoped\_device\_id\_guard}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_scoped\_device\_id\_guard()}{get\_scoped\_device\_id\_guard()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_ac14589119a116de96dc3b5f63fe3bc54} 
\doxymbox{\hyperlink{classgko_1_1scoped__device__id__guard}{scoped\+\_\+device\+\_\+id\+\_\+guard}} gko::\+\+Hip\+Executor::\+get\+\_\+scoped\+\_\+device\+\_\+id\+\_\+guard (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}



Implements \doxymbox{\hyperlink{classgko_1_1Executor}{gko::\+\+Executor}}.

\Hypertarget{classgko_1_1HipExecutor_aa6f204632ad7562b49d72675024ea2d7}\index{gko::HipExecutor@{gko::HipExecutor}!get\_sparselib\_handle@{get\_sparselib\_handle}}
\index{get\_sparselib\_handle@{get\_sparselib\_handle}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{get\_sparselib\_handle()}{get\_sparselib\_handle()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_aa6f204632ad7562b49d72675024ea2d7} 
hipsparse\+Context \texorpdfstring{$\ast$}{*} gko::\+\+Hip\+Executor::\+get\+\_\+sparselib\+\_\+handle (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Get the hipsparse handle for this executor.    

\begin{DoxyReturn}{Returns}
the hipsparse handle (hipsparse\+Context\texorpdfstring{$\ast$}{*}) for this executor    
\end{DoxyReturn}


Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_addb09880cd9944899e1115636598cc06}{get\+\_\+hipsparse\+\_\+handle()}}.

\Hypertarget{classgko_1_1HipExecutor_a294787f033b02fd013af087d02a4ae1b}\index{gko::HipExecutor@{gko::HipExecutor}!run@{run}}
\index{run@{run}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{run()}{run()}\hspace{0.1cm}{\footnotesize\ttfamily [1/3]}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a294787f033b02fd013af087d02a4ae1b} 
template$<$typename Closure\+Omp, typename Closure\+Cuda, typename Closure\+Hip, typename Closure\+Dpcpp$>$ \\
void \doxymbox{\hyperlink{classgko_1_1Executor_a1de8e2668b76e66690acf5eef9e8324d}{gko::\+\+Executor::\+run}} (\begin{DoxyParamCaption}\item[{const Closure\+Omp \&}]{op\+\_\+omp}{, }\item[{const Closure\+Cuda \&}]{op\+\_\+cuda}{, }\item[{const Closure\+Hip \&}]{op\+\_\+hip}{, }\item[{const Closure\+Dpcpp \&}]{op\+\_\+dpcpp}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Runs one of the passed in functors, depending on the \doxylink{classgko_1_1Executor}{Executor} type. 


\begin{DoxyTemplParams}{Template Parameters}
{\em Closure\+Omp} & type of op\+\_\+omp \\
\hline
{\em Closure\+Cuda} & type of op\+\_\+cuda \\
\hline
{\em Closure\+Hip} & type of op\+\_\+hip \\
\hline
{\em Closure\+Dpcpp} & type of op\+\_\+dpcpp\\
\hline
\end{DoxyTemplParams}

\begin{DoxyParams}{Parameters}
{\em op\+\_\+omp} & functor to run in case of a \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} or \doxylink{classgko_1_1ReferenceExecutor}{Reference\+Executor} \\
\hline
{\em op\+\_\+cuda} & functor to run in case of a \doxylink{classgko_1_1CudaExecutor}{Cuda\+Executor} \\
\hline
{\em op\+\_\+hip} & functor to run in case of a \doxylink{classgko_1_1HipExecutor}{Hip\+Executor} \\
\hline
{\em op\+\_\+dpcpp} & functor to run in case of a \doxylink{classgko_1_1DpcppExecutor}{Dpcpp\+Executor} \\
\hline
\end{DoxyParams}
\Hypertarget{classgko_1_1HipExecutor_a4fdbf8100b039d3858634bf9c502f5d7}\index{gko::HipExecutor@{gko::HipExecutor}!run@{run}}
\index{run@{run}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{run()}{run()}\hspace{0.1cm}{\footnotesize\ttfamily [2/3]}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a4fdbf8100b039d3858634bf9c502f5d7} 
virtual void \doxymbox{\hyperlink{classgko_1_1Executor_a1de8e2668b76e66690acf5eef9e8324d}{gko::\+\+Executor::\+run}} (\begin{DoxyParamCaption}\item[{const \doxymbox{\hyperlink{classgko_1_1Operation}{Operation}} \&}]{op}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [virtual]}}



Runs the specified \doxylink{classgko_1_1Operation}{Operation} using this \doxylink{classgko_1_1Executor}{Executor}. 


\begin{DoxyParams}{Parameters}
{\em op} & the operation to run \\
\hline
\end{DoxyParams}


Implements \doxymbox{\hyperlink{classgko_1_1Executor_a1de8e2668b76e66690acf5eef9e8324d}{gko::\+\+Executor}}.

\Hypertarget{classgko_1_1HipExecutor_abe906f109824da54447e504ff88aa97f}\index{gko::HipExecutor@{gko::HipExecutor}!run@{run}}
\index{run@{run}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{run()}{run()}\hspace{0.1cm}{\footnotesize\ttfamily [3/3]}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_abe906f109824da54447e504ff88aa97f} 
template$<$typename Closure\+Reference, typename Closure\+Omp, typename Closure\+Cuda, typename Closure\+Hip, typename Closure\+Dpcpp$>$ \\
void \doxymbox{\hyperlink{classgko_1_1Executor_a1de8e2668b76e66690acf5eef9e8324d}{gko::\+\+Executor::\+run}} (\begin{DoxyParamCaption}\item[{std::\+string}]{name}{, }\item[{const Closure\+Reference \&}]{op\+\_\+ref}{, }\item[{const Closure\+Omp \&}]{op\+\_\+omp}{, }\item[{const Closure\+Cuda \&}]{op\+\_\+cuda}{, }\item[{const Closure\+Hip \&}]{op\+\_\+hip}{, }\item[{const Closure\+Dpcpp \&}]{op\+\_\+dpcpp}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Runs one of the passed in functors, depending on the \doxylink{classgko_1_1Executor}{Executor} type. 


\begin{DoxyTemplParams}{Template Parameters}
{\em Closure\+Reference} & type of op\+\_\+ref \\
\hline
{\em Closure\+Omp} & type of op\+\_\+omp \\
\hline
{\em Closure\+Cuda} & type of op\+\_\+cuda \\
\hline
{\em Closure\+Hip} & type of op\+\_\+hip \\
\hline
{\em Closure\+Dpcpp} & type of op\+\_\+dpcpp\\
\hline
\end{DoxyTemplParams}

\begin{DoxyParams}{Parameters}
{\em name} & the name of the operation \\
\hline
{\em op\+\_\+ref} & functor to run in case of a \doxylink{classgko_1_1ReferenceExecutor}{Reference\+Executor} \\
\hline
{\em op\+\_\+omp} & functor to run in case of a \doxylink{classgko_1_1OmpExecutor}{Omp\+Executor} \\
\hline
{\em op\+\_\+cuda} & functor to run in case of a \doxylink{classgko_1_1CudaExecutor}{Cuda\+Executor} \\
\hline
{\em op\+\_\+hip} & functor to run in case of a \doxylink{classgko_1_1HipExecutor}{Hip\+Executor} \\
\hline
{\em op\+\_\+dpcpp} & functor to run in case of a \doxylink{classgko_1_1DpcppExecutor}{Dpcpp\+Executor} \\
\hline
\end{DoxyParams}
\Hypertarget{classgko_1_1HipExecutor_a0ea0ec8722767138953110b52d325b4a}\index{gko::HipExecutor@{gko::HipExecutor}!synchronize@{synchronize}}
\index{synchronize@{synchronize}!gko::HipExecutor@{gko::HipExecutor}}
\doxysubsubsection{\texorpdfstring{synchronize()}{synchronize()}}
{\footnotesize\ttfamily \label{classgko_1_1HipExecutor_a0ea0ec8722767138953110b52d325b4a} 
void gko::\+\+Hip\+Executor::\+synchronize (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}



Synchronize the operations launched on the executor with its master. 



Implements \doxymbox{\hyperlink{classgko_1_1Executor_a24eeee7648c0f0fd07c9866d07154875}{gko::\+\+Executor}}.



References \doxymbox{\hyperlink{classgko_1_1HipExecutor_a0ea0ec8722767138953110b52d325b4a}{synchronize()}}.



Referenced by \doxymbox{\hyperlink{classgko_1_1HipExecutor_a0ea0ec8722767138953110b52d325b4a}{synchronize()}}.



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