Kokkos Node API and Local Linear Algebra Kernels Version of the Day
Protected Member Functions
Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps > Class Template Reference

A host-compute compressed-row sparse matrix with first-touch allocation. More...

#include <Kokkos_CrsMatrix.hpp>

Inheritance diagram for Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

Constructors/Destructor
 FirstTouchHostCrsMatrix ()
 Default constructor with no graph. (Must be set later.)
 FirstTouchHostCrsMatrix (FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &graph)
 Constructor with a matrix-owned non-const graph.
 FirstTouchHostCrsMatrix (const FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &graph)
 Constructor with a non-owned const graph.
virtual ~FirstTouchHostCrsMatrix ()
 FirstTouchHostCrsMatrix Destructor.
Graph set routines.
void setOwnedGraph (FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &graph)
 Set matrix-owned graph.
void setStaticGraph (const FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &graph)
 Set static graph.
Data entry and accessor methods.
void finalize (bool OptimizeStorage)
 Instruct the matrix to perform any necessary manipulation, including (optionally) optimizing the storage of the matrix data.
Graph set routines.
void setOwnedGraph (CrsGraphHostCompute< Ordinal, Node, LocalMatOps > &graph)
 Set matrix-owned graph.
void setStaticGraph (const CrsGraphHostCompute< Ordinal, Node, LocalMatOps > &graph)
 Set static graph.
Data entry and accessor methods.
RCP< Node > getNode () const
 Node accessor.
size_t getNumRows () const
 Return the number of rows in the matrix.
size_t getNumEntries () const
 Return the number of entries in the matrix.
bool isEmpty () const
 Indicates that the graph is filled, but empty.
bool isFinalized () const
 Indicatest that the graph has been finalized.
bool is1DStructure () const
 Indicate that the structure is 1D. It will never be the case that both is1DStructure() and is2DStructure() return true.
bool is2DStructure () const
 Indicate that the structure is 2D. It will never be the case that both is1DStructure() and is2DStructure() return true.
bool isOptimized () const
 Indicate that the stucture is optimized.
void set1DValues (ArrayRCP< Scalar > vals)
 Submit the values for 1D storage.
void set2DValues (ArrayRCP< ArrayRCP< Scalar > > vals)
 Submit the values for 2D storage.
void get1DValues (ArrayRCP< Scalar > &vals)
 Retrieve the values for 1D storage.
void get2DValues (ArrayRCP< ArrayRCP< Scalar > > &inds)
 Retrieve the structure for 2D storage.
virtual void clear ()
 Release data associated with this graph.

Protected Member Functions

 FirstTouchHostCrsMatrix (const FirstTouchHostCrsMatrix &sources)
 Copy constructor (protected and not implemented)

Detailed Description

template<class Scalar, class Ordinal, class Node, class LocalMatOps>
class Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >

A host-compute compressed-row sparse matrix with first-touch allocation.

Definition at line 543 of file Kokkos_CrsMatrix.hpp.


Constructor & Destructor Documentation

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::FirstTouchHostCrsMatrix ( )

Default constructor with no graph. (Must be set later.)

Definition at line 604 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::FirstTouchHostCrsMatrix ( FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &  graph)

Constructor with a matrix-owned non-const graph.

Definition at line 620 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::FirstTouchHostCrsMatrix ( const FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &  graph)

Constructor with a non-owned const graph.

Definition at line 612 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::~FirstTouchHostCrsMatrix ( ) [virtual]

FirstTouchHostCrsMatrix Destructor.

Definition at line 628 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::FirstTouchHostCrsMatrix ( const FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps > &  sources) [protected]

Copy constructor (protected and not implemented)


Member Function Documentation

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
void Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::setOwnedGraph ( FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &  graph)

Set matrix-owned graph.

Definition at line 642 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
void Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::setStaticGraph ( const FirstTouchHostCrsGraph< Ordinal, Node, LocalMatOps > &  graph)

Set static graph.

Definition at line 633 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
void Kokkos::FirstTouchHostCrsMatrix< Scalar, Ordinal, Node, LocalMatOps >::finalize ( bool  OptimizeStorage)

Instruct the matrix to perform any necessary manipulation, including (optionally) optimizing the storage of the matrix data.

If the matrix is associated with a matrix-owned graph, then it will be finalized as well. A static graph will not be modified.

Parameters:
[in]OptimizeStoragePermit the graph to reallocate storage on the host in order to provide optimal storage and/or performance.
Postcondition:
if OptimizeStorage == true, then is2DStructure() == true

Reimplemented from Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >.

Definition at line 651 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal, class Node, class LocalMatOps>
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::setOwnedGraph ( CrsGraphHostCompute< Ordinal, Node, LocalMatOps > &  graph) [inherited]

Set matrix-owned graph.

Definition at line 213 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal, class Node, class LocalMatOps>
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::setStaticGraph ( const CrsGraphHostCompute< Ordinal, Node, LocalMatOps > &  graph) [inherited]

Set static graph.

Definition at line 203 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
RCP< Node > Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::getNode ( ) const [inherited]

Node accessor.

Definition at line 236 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
size_t Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::getNumRows ( ) const [inherited]

Return the number of rows in the matrix.

Definition at line 242 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
size_t Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::getNumEntries ( ) const [inherited]

Return the number of entries in the matrix.

Definition at line 248 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
bool Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::isEmpty ( ) const [inherited]

Indicates that the graph is filled, but empty.

Definition at line 254 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
bool Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::isFinalized ( ) const [inherited]

Indicatest that the graph has been finalized.

Definition at line 260 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
bool Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::is1DStructure ( ) const [inherited]

Indicate that the structure is 1D. It will never be the case that both is1DStructure() and is2DStructure() return true.

Definition at line 266 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
bool Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::is2DStructure ( ) const [inherited]

Indicate that the structure is 2D. It will never be the case that both is1DStructure() and is2DStructure() return true.

Definition at line 272 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
bool Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::isOptimized ( ) const [inherited]

Indicate that the stucture is optimized.

Definition at line 278 of file Kokkos_CrsMatrix.hpp.

template<class Scalar, class Ordinal , class Node , class LocalMatOps >
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::set1DValues ( ArrayRCP< Scalar >  vals) [inherited]

Submit the values for 1D storage.

Postcondition:
is1DStructure() == true

Definition at line 298 of file Kokkos_CrsMatrix.hpp.

template<class Scalar, class Ordinal , class Node , class LocalMatOps >
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::set2DValues ( ArrayRCP< ArrayRCP< Scalar > >  vals) [inherited]

Submit the values for 2D storage.

Postcondition:
is2DStructure() == true

Definition at line 310 of file Kokkos_CrsMatrix.hpp.

template<class Scalar, class Ordinal , class Node , class LocalMatOps >
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::get1DValues ( ArrayRCP< Scalar > &  vals) [inherited]

Retrieve the values for 1D storage.

If is1DStructure() == false, then

Postcondition:
vals == null

Definition at line 284 of file Kokkos_CrsMatrix.hpp.

template<class Scalar, class Ordinal , class Node , class LocalMatOps >
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::get2DValues ( ArrayRCP< ArrayRCP< Scalar > > &  inds) [inherited]

Retrieve the structure for 2D storage.

If is2DStructure() == false, then

Postcondition:
vals == null

Definition at line 291 of file Kokkos_CrsMatrix.hpp.

template<class Scalar , class Ordinal , class Node , class LocalMatOps >
void Kokkos::CrsMatrixHostCompute< Scalar, Ordinal, Node, LocalMatOps >::clear ( ) [virtual, inherited]

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends