mxlib
c++ tools for analyzing astronomical data and other tasks by Jared R. Males. [git repo]
Loading...
Searching...
No Matches
mx::cuda::cusolverDnHandle Struct Reference

Management of a cusolverDn handle.

RAII management of a cusolverDn handle.

The handle is not created automatically on default construction, e.g. in case it is desired to do so in a critical block scope.

The handle is destroyed on the call to this class's destructor.

Todo:
throw exceptions in cuda::cusolverDNHandle

Definition at line 48 of file cusolverDnHandle.hpp.

#include <math/cuda/cusolverDnHandle.hpp>

Public Member Functions

 cusolverDnHandle ()
 Default c'tor.
 
 cusolverDnHandle (bool create)
 Constructor with option to create / not create the handle.
 
 cusolverDnHandle (cudaStream_t stream)
 Constructor which creates the handle and sets the stream.
 
 ~cusolverDnHandle ()
 Destructor.
 
void create ()
 Create (allocate) the handle.
 
void create (cudaStream_t stream)
 Create (allocate) the handle.
 
void setStream (cudaStream_t stream)
 Create (allocate) the handle.
 
cusolverDnHandle_t operator() ()
 Get the handle for use in calls to cusolverDN routines.
 
 operator cusolverDnHandle_t ()
 Conversion operator, allows objects of this class to be used as if they are the handle.
 

Constructor & Destructor Documentation

◆ cusolverDnHandle() [1/3]

mx::cuda::cusolverDnHandle::cusolverDnHandle ( )
inline

Default c'tor.

Creates (allocates) the handle and sets the stream to nullptr

Definition at line 58 of file cusolverDnHandle.hpp.

References create().

◆ cusolverDnHandle() [2/3]

mx::cuda::cusolverDnHandle::cusolverDnHandle ( bool  create)
inlineexplicit

Constructor with option to create / not create the handle.

Parameters
[in]createif true the handle is created. if false it is not created.

Definition at line 64 of file cusolverDnHandle.hpp.

References create().

◆ cusolverDnHandle() [3/3]

mx::cuda::cusolverDnHandle::cusolverDnHandle ( cudaStream_t  stream)
inlineexplicit

Constructor which creates the handle and sets the stream.

Parameters
[in]streamcuda stream to associate with this handle.

Definition at line 73 of file cusolverDnHandle.hpp.

References create().

◆ ~cusolverDnHandle()

mx::cuda::cusolverDnHandle::~cusolverDnHandle ( )
inline

Destructor.

Definition at line 79 of file cusolverDnHandle.hpp.

Member Function Documentation

◆ create() [1/2]

void mx::cuda::cusolverDnHandle::create ( )
inline

Create (allocate) the handle.

Definition at line 88 of file cusolverDnHandle.hpp.

Referenced by cusolverDnHandle(), cusolverDnHandle(), and cusolverDnHandle().

◆ create() [2/2]

void mx::cuda::cusolverDnHandle::create ( cudaStream_t  stream)
inline

Create (allocate) the handle.

Definition at line 99 of file cusolverDnHandle.hpp.

References setStream().

◆ operator cusolverDnHandle_t()

mx::cuda::cusolverDnHandle::operator cusolverDnHandle_t ( )
inline

Conversion operator, allows objects of this class to be used as if they are the handle.

Returns
the cusolverDn handle

Definition at line 140 of file cusolverDnHandle.hpp.

◆ operator()()

cusolverDnHandle_t mx::cuda::cusolverDnHandle::operator() ( )
inline

Get the handle for use in calls to cusolverDN routines.

Returns
the cusolverDn handle

Definition at line 131 of file cusolverDnHandle.hpp.

◆ setStream()

void mx::cuda::cusolverDnHandle::setStream ( cudaStream_t  stream)
inline

Create (allocate) the handle.

Definition at line 111 of file cusolverDnHandle.hpp.

Referenced by create().


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