https://mooseframework.inl.gov
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
Moose::Kokkos::MemoryPoolHolder Class Reference

The Kokkos interface that holds the Kokkos memory pool. More...

#include <KokkosMemoryPool.h>

Public Member Functions

 MemoryPoolHolder (const MooseApp &app)
 Constructor. More...
 
 MemoryPoolHolder (const MemoryPoolHolder &holder)
 Copy constructor. More...
 

Protected Member Functions

KOKKOS_FUNCTION const MemoryPoolkokkosMemoryPool () const
 Get the const reference of the Kokkos memory pool. More...
 

Private Attributes

const MooseApp_app
 Reference of the MOOSE app. More...
 
MemoryPool _pool
 Device copy of the Kokkos memory pool. More...
 

Detailed Description

The Kokkos interface that holds the Kokkos memory pool.

Copies the latest Kokkos memory pool object to device during parallel dispatch.

Definition at line 113 of file KokkosMemoryPool.h.

Constructor & Destructor Documentation

◆ MemoryPoolHolder() [1/2]

Moose::Kokkos::MemoryPoolHolder::MemoryPoolHolder ( const MooseApp app)
inline

Constructor.

Parameters
appThe MOOSE app

Definition at line 120 of file KokkosMemoryPool.h.

120 : _app(app), _pool(_app.getKokkosMemoryPool()) {}
const MooseApp & _app
Reference of the MOOSE app.
MemoryPool _pool
Device copy of the Kokkos memory pool.
const Moose::Kokkos::MemoryPool & getKokkosMemoryPool() const
Get Kokkos memory pool.

◆ MemoryPoolHolder() [2/2]

Moose::Kokkos::MemoryPoolHolder::MemoryPoolHolder ( const MemoryPoolHolder holder)
inline

Copy constructor.

Definition at line 124 of file KokkosMemoryPool.h.

125  : _app(holder._app), _pool(_app.getKokkosMemoryPool())
126  {
127  }
const MooseApp & _app
Reference of the MOOSE app.
MemoryPool _pool
Device copy of the Kokkos memory pool.
const Moose::Kokkos::MemoryPool & getKokkosMemoryPool() const
Get Kokkos memory pool.

Member Function Documentation

◆ kokkosMemoryPool()

KOKKOS_FUNCTION const MemoryPool& Moose::Kokkos::MemoryPoolHolder::kokkosMemoryPool ( ) const
inlineprotected

Get the const reference of the Kokkos memory pool.

Returns
The const reference of the Kokkos memory pool

Definition at line 134 of file KokkosMemoryPool.h.

134 { return _pool; }
MemoryPool _pool
Device copy of the Kokkos memory pool.

Member Data Documentation

◆ _app

const MooseApp& Moose::Kokkos::MemoryPoolHolder::_app
private

Reference of the MOOSE app.

Definition at line 140 of file KokkosMemoryPool.h.

◆ _pool

MemoryPool Moose::Kokkos::MemoryPoolHolder::_pool
private

Device copy of the Kokkos memory pool.

Definition at line 144 of file KokkosMemoryPool.h.

Referenced by kokkosMemoryPool().


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