Compadre 1.6.8
Loading...
Searching...
No Matches
Public Attributes | List of all members
Compadre::ParallelManager Class Reference

Parallel Manager. More...

Detailed Description

Parallel Manager.

This class sets and manages thread / teams levels, scratch memory sizes, and kernel executions. ex: Compadre::ConvertLayoutLeftToRight clr; Compadre::ParallelManager pm; // no tag specified pm.CallFunctorWithTeamThreads(clr, 100, "MyFunctorName"); // some tag specified pm.CallFunctorWithTeamThreads<DefaultTag>(clr, 100);

Definition at line 29 of file Compadre_ParallelManager.hpp.

#include <Compadre_ParallelManager.hpp>

Public Member Functions

Instantiation / Destruction
 ParallelManager ()
 
Accessors

Retrieve member variables through public member functions

Kokkos::TeamPolicy< device_execution_spaceTeamPolicyThreadsAndVectors (const global_index_type batch_size, const int threads_per_team=-1, const int vector_lanes_per_thread=-1) const
 Creates a team policy for a parallel_for parallel_for will break out over loops over teams with each vector lane executing code be default.
 
KOKKOS_INLINE_FUNCTION int getTeamScratchLevel (const int level) const
 
KOKKOS_INLINE_FUNCTION int getThreadScratchLevel (const int level) const
 
KOKKOS_INLINE_FUNCTION int getTeamScratchSize (const int level) const
 
KOKKOS_INLINE_FUNCTION int getThreadScratchSize (const int level) const
 
Modifiers

Changed member variables through public member functions

void setTeamScratchLevel (const int level, const int value)
 
void setThreadScratchLevel (const int level, const int value)
 
void setTeamScratchSize (const int level, const int value)
 
void setThreadScratchSize (const int level, const int value)
 
void clearScratchSizes ()
 

Public Attributes

int _scratch_team_level_a
 lowest level memory for Kokkos::parallel_for for team access memory
 
int _team_scratch_size_a
 
int _scratch_thread_level_a
 higher (slower) level memory for Kokkos::parallel_for for team access memory
 
int _thread_scratch_size_a
 
int _scratch_team_level_b
 lowest level memory for Kokkos::parallel_for for thread access memory
 
int _team_scratch_size_b
 
int _scratch_thread_level_b
 higher (slower) level memory for Kokkos::parallel_for for thread access memory
 
int _thread_scratch_size_b
 
int _environment_threads
 number of threads and vector lanes if not specified through environment variables THREADS and VECTORLANES, then set to Kokkos::AUTO
 
int _environment_vector_lanes
 

Constructor & Destructor Documentation

◆ ParallelManager()

Compadre::ParallelManager::ParallelManager ( )
inline

Definition at line 80 of file Compadre_ParallelManager.hpp.

Member Function Documentation

◆ clearScratchSizes()

void Compadre::ParallelManager::clearScratchSizes ( )
inline

Definition at line 254 of file Compadre_ParallelManager.hpp.

◆ getTeamScratchLevel()

KOKKOS_INLINE_FUNCTION int Compadre::ParallelManager::getTeamScratchLevel ( const int  level) const
inline

Definition at line 179 of file Compadre_ParallelManager.hpp.

◆ getTeamScratchSize()

KOKKOS_INLINE_FUNCTION int Compadre::ParallelManager::getTeamScratchSize ( const int  level) const
inline

Definition at line 197 of file Compadre_ParallelManager.hpp.

◆ getThreadScratchLevel()

KOKKOS_INLINE_FUNCTION int Compadre::ParallelManager::getThreadScratchLevel ( const int  level) const
inline

Definition at line 188 of file Compadre_ParallelManager.hpp.

◆ getThreadScratchSize()

KOKKOS_INLINE_FUNCTION int Compadre::ParallelManager::getThreadScratchSize ( const int  level) const
inline

Definition at line 206 of file Compadre_ParallelManager.hpp.

◆ setTeamScratchLevel()

void Compadre::ParallelManager::setTeamScratchLevel ( const int  level,
const int  value 
)
inline

Definition at line 222 of file Compadre_ParallelManager.hpp.

◆ setTeamScratchSize()

void Compadre::ParallelManager::setTeamScratchSize ( const int  level,
const int  value 
)
inline

Definition at line 238 of file Compadre_ParallelManager.hpp.

◆ setThreadScratchLevel()

void Compadre::ParallelManager::setThreadScratchLevel ( const int  level,
const int  value 
)
inline

Definition at line 230 of file Compadre_ParallelManager.hpp.

◆ setThreadScratchSize()

void Compadre::ParallelManager::setThreadScratchSize ( const int  level,
const int  value 
)
inline

Definition at line 246 of file Compadre_ParallelManager.hpp.

◆ TeamPolicyThreadsAndVectors()

Kokkos::TeamPolicy< device_execution_space > Compadre::ParallelManager::TeamPolicyThreadsAndVectors ( const global_index_type  batch_size,
const int  threads_per_team = -1,
const int  vector_lanes_per_thread = -1 
) const
inline

Creates a team policy for a parallel_for parallel_for will break out over loops over teams with each vector lane executing code be default.

Definition at line 127 of file Compadre_ParallelManager.hpp.

Member Data Documentation

◆ _environment_threads

int Compadre::ParallelManager::_environment_threads

number of threads and vector lanes if not specified through environment variables THREADS and VECTORLANES, then set to Kokkos::AUTO

Definition at line 51 of file Compadre_ParallelManager.hpp.

◆ _environment_vector_lanes

int Compadre::ParallelManager::_environment_vector_lanes

Definition at line 52 of file Compadre_ParallelManager.hpp.

◆ _scratch_team_level_a

int Compadre::ParallelManager::_scratch_team_level_a

lowest level memory for Kokkos::parallel_for for team access memory

Definition at line 33 of file Compadre_ParallelManager.hpp.

◆ _scratch_team_level_b

int Compadre::ParallelManager::_scratch_team_level_b

lowest level memory for Kokkos::parallel_for for thread access memory

Definition at line 41 of file Compadre_ParallelManager.hpp.

◆ _scratch_thread_level_a

int Compadre::ParallelManager::_scratch_thread_level_a

higher (slower) level memory for Kokkos::parallel_for for team access memory

Definition at line 37 of file Compadre_ParallelManager.hpp.

◆ _scratch_thread_level_b

int Compadre::ParallelManager::_scratch_thread_level_b

higher (slower) level memory for Kokkos::parallel_for for thread access memory

Definition at line 45 of file Compadre_ParallelManager.hpp.

◆ _team_scratch_size_a

int Compadre::ParallelManager::_team_scratch_size_a

Definition at line 34 of file Compadre_ParallelManager.hpp.

◆ _team_scratch_size_b

int Compadre::ParallelManager::_team_scratch_size_b

Definition at line 42 of file Compadre_ParallelManager.hpp.

◆ _thread_scratch_size_a

int Compadre::ParallelManager::_thread_scratch_size_a

Definition at line 38 of file Compadre_ParallelManager.hpp.

◆ _thread_scratch_size_b

int Compadre::ParallelManager::_thread_scratch_size_b

Definition at line 46 of file Compadre_ParallelManager.hpp.


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