NeoN
A framework for CFD software
Loading...
Searching...
No Matches
NeoN::CPUExecutor Class Reference

Executor for handling multicore CPU based parallelization. More...

#include <CPUExecutor.hpp>

Inheritance diagram for NeoN::CPUExecutor:
NeoN::Logging::SupportsLoggingMixin

Public Types

using exec = Kokkos::DefaultHostExecutionSpace

Public Member Functions

 CPUExecutor ()
 CPUExecutor (std::unique_ptr< AllocatorStrategy > strategy)
 ~CPUExecutor ()
template<typename T>
T * alloc (sizeType elements) const
template<typename T>
T * realloc (void *ptr, sizeType elements) const
void free (void *ptr) const noexcept
MemorySpace memorySpace () const noexcept
template<typename ValueType>
decltype(auto) createKokkosView (ValueType *ptr, sizeType size) const
 create a Kokkos view for a given ptr
std::string name () const
exec underlyingExec () const
Public Member Functions inherited from NeoN::Logging::SupportsLoggingMixin
void setLogger (const std::shared_ptr< BaseLogger > logger)
std::shared_ptr< const BaseLogger > getLogger () const

Detailed Description

Executor for handling multicore CPU based parallelization.

Definition at line 23 of file CPUExecutor.hpp.

Member Typedef Documentation

◆ exec

using NeoN::CPUExecutor::exec = Kokkos::DefaultHostExecutionSpace

Definition at line 29 of file CPUExecutor.hpp.

Constructor & Destructor Documentation

◆ CPUExecutor() [1/2]

NeoN::CPUExecutor::CPUExecutor ( )

◆ CPUExecutor() [2/2]

NeoN::CPUExecutor::CPUExecutor ( std::unique_ptr< AllocatorStrategy > strategy)

◆ ~CPUExecutor()

NeoN::CPUExecutor::~CPUExecutor ( )

Member Function Documentation

◆ alloc()

template<typename T>
T * NeoN::CPUExecutor::alloc ( sizeType elements) const
inline

Definition at line 38 of file CPUExecutor.hpp.

◆ createKokkosView()

template<typename ValueType>
decltype(auto) NeoN::CPUExecutor::createKokkosView ( ValueType * ptr,
sizeType size ) const
inline

create a Kokkos view for a given ptr

Based on the executor this function creates a Kokkos view into the data managed by ptr

Parameters
ptrPointer to data for which a view should be created
sizeNumber of elements this view contains
Template Parameters
ValueTypeThe value type the underlying memory holds

Definition at line 69 of file CPUExecutor.hpp.

◆ free()

void NeoN::CPUExecutor::free ( void * ptr) const
inlinenoexcept

Definition at line 57 of file CPUExecutor.hpp.

◆ memorySpace()

MemorySpace NeoN::CPUExecutor::memorySpace ( ) const
inlinenoexcept

Definition at line 59 of file CPUExecutor.hpp.

◆ name()

std::string NeoN::CPUExecutor::name ( ) const
inline

Definition at line 74 of file CPUExecutor.hpp.

◆ realloc()

template<typename T>
T * NeoN::CPUExecutor::realloc ( void * ptr,
sizeType elements ) const
inline

Definition at line 48 of file CPUExecutor.hpp.

◆ underlyingExec()

exec NeoN::CPUExecutor::underlyingExec ( ) const
inline

Definition at line 76 of file CPUExecutor.hpp.


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