https://mooseframework.inl.gov
Public Member Functions | List of all members
Moose::Kokkos::DispatcherBase Class Reference

Base class for Kokkos functor dispatcher. More...

#include <KokkosDispatcher.h>

Inheritance diagram for Moose::Kokkos::DispatcherBase:
[legend]

Public Member Functions

virtual ~DispatcherBase ()
 
virtual void parallelFor (const Policy &)
 Dispatch this functor with Kokkos parallel_for() given a Kokkos execution policy. More...
 
virtual void parallelReduce (const Policy &, ::Kokkos::View< Real *, ::Kokkos::HostSpace > &)
 Dispatch this functor with Kokkos parallel_reduce() given a Kokkos execution policy and result buffer. More...
 

Detailed Description

Base class for Kokkos functor dispatcher.

Used for type erasure so that the base class of functors can hold the dispatcher without knowing the actual type of functors.

Definition at line 27 of file KokkosDispatcher.h.

Constructor & Destructor Documentation

◆ ~DispatcherBase()

virtual Moose::Kokkos::DispatcherBase::~DispatcherBase ( )
inlinevirtual

Definition at line 30 of file KokkosDispatcher.h.

30 {}

Member Function Documentation

◆ parallelFor()

virtual void Moose::Kokkos::DispatcherBase::parallelFor ( const Policy )
inlinevirtual

Dispatch this functor with Kokkos parallel_for() given a Kokkos execution policy.

Parameters
policyThe Kokkos execution policy

Reimplemented in Moose::Kokkos::Dispatcher< Operation, Object >.

Definition at line 35 of file KokkosDispatcher.h.

36  {
37  mooseError("parallelFor() called for an instance that is not a dispatcher.");
38  }
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:311

◆ parallelReduce()

virtual void Moose::Kokkos::DispatcherBase::parallelReduce ( const Policy ,
::Kokkos::View< Real *, ::Kokkos::HostSpace > &   
)
inlinevirtual

Dispatch this functor with Kokkos parallel_reduce() given a Kokkos execution policy and result buffer.

Parameters
policyThe Kokkos execution policy
resultThe result buffer

Reimplemented in Moose::Kokkos::Reducer< Operation, Object >.

Definition at line 45 of file KokkosDispatcher.h.

47  {
48  mooseError("parallelReduce() called for an instance that is not a reducer.");
49  }
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:311

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