Public Types |
Public Member Functions |
Static Public Member Functions |
Static Public Attributes |
List of all members
Opm::gpuistl::GpuSparseMatrix< T > Class Template Reference The GpuSparseMatrix class simple wrapper class for a CuSparse matrix. More...
Inheritance diagram for Opm::gpuistl::GpuSparseMatrix< T >:
![]()
Detailed Descriptiontemplate<typename T> class Opm::gpuistl::GpuSparseMatrix< T > The GpuSparseMatrix class simple wrapper class for a CuSparse matrix.
Member Typedef Documentation◆ field_type
template<typename T >
Constructor & Destructor Documentation◆ GpuSparseMatrix() [1/3]
template<typename T >
Create the sparse matrix specified by the raw data.
◆ GpuSparseMatrix() [2/3]
template<typename T >
Create a sparse matrix by copying the sparsity structure of another matrix, not filling in the values
◆ GpuSparseMatrix() [3/3]
template<typename T >
◆ ~GpuSparseMatrix()
template<typename T >
Member Function Documentation◆ blockSize()
template<typename T >
blockSize size of the blocks References Opm::gpuistl::detail::to_size_t(). Referenced by Opm::gpuistl::GpuSeqILU0< M, X, Y, l >::GpuSeqILU0(), and Opm::gpuistl::AmgxInterface::updateAmgxMatrixFromGpuSparseMatrix(). ◆ dim()
template<typename T >
dim returns the dimension of the vector space on which this matrix acts This is equivalent to matrix.N() * matrix.blockSize()
References Opm::gpuistl::detail::to_size_t(). Referenced by Opm::gpuistl::GpuSeqILU0< M, X, Y, l >::GpuSeqILU0(). ◆ dispatchOnBlocksize()
template<typename T >
template<class FunctionType >
Dispatches a function based on the block size of the matrix. This method allows executing different code paths depending on the block size of the matrix, up to the maximum block size specified by max_block_size. Use this function if you need the block size to be known at compile time.
You can use this function as matrix.dispatchOnBlocksize([](auto val) {
});
size_t blockSize() const blockSize size of the blocks Definition: GpuSparseMatrix.hpp:273 ◆ fromMatrix()
template<typename T >
template<class MatrixType >
fromMatrix creates a new matrix with the same block size and values as the given matrix
◆ getColumnIndices() [1/2]
template<typename T >
getColumnIndices returns the column indices used to represent the BSR structure.
Referenced by Opm::gpuistl::AmgxInterface::updateAmgxMatrixFromGpuSparseMatrix(). ◆ getColumnIndices() [2/2]
template<typename T >
getColumnIndices returns the column indices used to represent the BSR structure.
◆ getDescription()
template<typename T >
getDescription the cusparse matrix description. This description is needed for most calls to the CuSparse library ◆ getNonZeroValues() [1/2]
template<typename T >
getNonZeroValues returns the GPU vector containing the non-zero values (ordered by block)
Referenced by Opm::gpuistl::AmgxInterface::updateAmgxMatrixCoefficientsFromGpuSparseMatrix(), Opm::gpuistl::AmgxInterface::updateAmgxMatrixFromGpuSparseMatrix(), and Opm::gpuistl::AmgxInterface::updateGpuSparseMatrixFromAmgxMatrix(). ◆ getNonZeroValues() [2/2]
template<typename T >
getNonZeroValues returns the GPU vector containing the non-zero values (ordered by block)
◆ getRowIndices() [1/2]
template<typename T >
getRowIndices returns the row indices used to represent the BSR structure.
Referenced by Opm::gpuistl::AmgxInterface::updateAmgxMatrixFromGpuSparseMatrix(). ◆ getRowIndices() [2/2]
template<typename T >
getRowIndices returns the row indices used to represent the BSR structure.
◆ mv()
template<typename T >
mv performs matrix vector multiply y = Ax
◆ N()
template<typename T >
N returns the number of rows (which is equal to the number of columns) References Opm::gpuistl::detail::to_size_t(). Referenced by Opm::gpuistl::GpuSeqILU0< M, X, Y, l >::GpuSeqILU0(), Opm::gpuistl::AmgxInterface::updateAmgxMatrixCoefficientsFromGpuSparseMatrix(), and Opm::gpuistl::AmgxInterface::updateAmgxMatrixFromGpuSparseMatrix(). ◆ nonzeroes()
template<typename T >
nonzeroes behaves as the Dune::BCRSMatrix::nonzeros() function and returns the number of non zero blocks
References Opm::gpuistl::detail::to_size_t(). Referenced by Opm::gpuistl::GpuSeqILU0< M, X, Y, l >::GpuSeqILU0(), Opm::gpuistl::AmgxInterface::updateAmgxMatrixCoefficientsFromGpuSparseMatrix(), and Opm::gpuistl::AmgxInterface::updateAmgxMatrixFromGpuSparseMatrix(). ◆ operator=()
template<typename T >
◆ setLowerTriangular()
template<typename T >
setLowerTriangular sets the CuSparse flag that this is an lower diagonal (with non-unit diagonal) matrix. ◆ setNonUnitDiagonal()
template<typename T >
setNonUnitDiagonal sets the CuSparse flag that this has non-unit diagional. ◆ setUnitDiagonal()
template<typename T >
setUnitDiagonal sets the CuSparse flag that this has unit diagional. ◆ setUpperTriangular()
template<typename T >
setUpperTriangular sets the CuSparse flag that this is an upper diagonal (with unit diagonal) matrix. ◆ umv()
template<typename T >
umv computes y=Ax+y
◆ updateNonzeroValues() [1/2]
template<typename T >
updateNonzeroValues updates the non-zero values by using the non-zero values of the supplied matrix
◆ updateNonzeroValues() [2/2]
template<typename T >
template<class MatrixType >
updateNonzeroValues updates the non-zero values by using the non-zero values of the supplied matrix
Referenced by Opm::gpuistl::SolverAdapter< Operator, UnderlyingSolver, X >::apply(), and Opm::gpuistl::PreconditionerCPUMatrixToGPUMatrix< X, Y, CudaPreconditionerType, CPUMatrixType >::update(). ◆ usmv()
template<typename T >
umv computes y=alpha * Ax + y
Member Data Documentation◆ max_block_size
template<typename T >
Maximum block size supported by this implementation. This constant defines an upper bound on the block size to ensure reasonable compilation times. While this class itself could support larger values, functions that call dispatchOnBlocksize() might have limitations. This value can be increased if needed, but will increase compilation time due to template instantiations. The documentation for this class was generated from the following files: |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||