Peano
Loading...
Searching...
No Matches
tarch::mpi::BooleanSemaphore::BooleanSemaphoreService::SemaphoreMapEntry Struct Reference

Public Member Functions

 SemaphoreMapEntry ()
 Create new semaphore entry.
 
std::string toString () const
 

Data Fields

bool locked
 Flag indicating if a semaphore is currently locked.
 
int rankThatLastLocked
 Bookkeeping of who has locked a semaphore last.
 

Detailed Description

Definition at line 92 of file BooleanSemaphore.h.

Constructor & Destructor Documentation

◆ SemaphoreMapEntry()

tarch::mpi::BooleanSemaphore::BooleanSemaphoreService::SemaphoreMapEntry::SemaphoreMapEntry ( )

Create new semaphore entry.

The default is that a semaphore is not locked. New entries should only be inserted by addMapEntryLazily() which in turn is triggered by tryLockSemaphoreOnGlobalMaster().

Definition at line 34 of file BooleanSemaphore.cpp.

Member Function Documentation

◆ toString()

std::string tarch::mpi::BooleanSemaphore::BooleanSemaphoreService::SemaphoreMapEntry::toString ( ) const

Definition at line 40 of file BooleanSemaphore.cpp.

Field Documentation

◆ locked

bool tarch::mpi::BooleanSemaphore::BooleanSemaphoreService::SemaphoreMapEntry::locked

Flag indicating if a semaphore is currently locked.

Definition at line 96 of file BooleanSemaphore.h.

◆ rankThatLastLocked

int tarch::mpi::BooleanSemaphore::BooleanSemaphoreService::SemaphoreMapEntry::rankThatLastLocked

Bookkeeping of who has locked a semaphore last.

I originally wanted to use this one for some fairness checks, but this all became too complicated and did not pay off. Therefore, this flag is solely there for keeping track of historic data.

Definition at line 104 of file BooleanSemaphore.h.


The documentation for this struct was generated from the following files: