![]() |
Peano
|
Namespaces | |
namespace | tests |
Data Structures | |
class | Node |
Node is Peano's abstraction for the hybrid of MPI/threads. More... | |
class | SpacetreeSet |
The spacetree set has to be a singleton, as it is reponsible to accept requests for new trees from remote ranks. More... | |
struct | StartTraversalMessage |
struct | TreeEntry |
struct | TreeManagementMessage |
Functions | |
int | getTaskType (const std::string &className) |
Get unique number (id) for task. | |
int peano4::parallel::getTaskType | ( | const std::string & | className | ) |
Get unique number (id) for task.
Each task needs a unique type (number). As I don't want to hard-code these types, I use a simple factory mechanism (aka this routine) to hand out integer types.
Originally, I worked with logInfo() here to dump some info about the used task types. However, some tasks ask for their id at start-up through static variables. At this point, the logging might not be up, i.e. we rely on the linker to get the logging up first. This is generally a bad idea. Therefore, I write to std::cout in this particular case. Otherwise, I encountered seg faults on some systems.
Definition at line 7 of file parallel.cpp.
References tarch::mpi::Rank::getInstance().