11#include <unordered_map>
16 class EnclaveBookkeeping;
46 Entry(
int numberOfResultValues_,
double* data_,
double maxEigenvalue_ );
132 void finishedTask(
int taskNumber,
int numberOfResultValues,
double* data,
double maxEigenvalue);
static EnclaveBookkeeping & getInstance()
static tarch::logging::Log _log
std::set< int > _tasksThatHaveToBeCancelled
void dumpStatistics()
For debugging only.
void waitForTaskAndDiscardResult(int number)
Wait for a task and copy outcome into destination.
static const std::string MemoryAllocationsInLookupTableIdentifier
std::unordered_map< int, Entry > _finishedTasks
Plain map onto ouput array.
void finishedTask(int taskNumber, int numberOfResultValues, double *data, double maxEigenvalue)
Usually called directly by EnclaveTask.
EnclaveBookkeeping()=default
static constexpr int SkeletonTask
Skeletons are not really tasks in the traditional sense.
Entry waitForTaskToTerminateAndReturnResult(int number)
Wait for a task result to become available.
void cancelTask(int number)
tarch::multicore::BooleanSemaphore _finishedTasksSemaphore
void waitForTaskToTerminateAndCopyResultOver(int number, double *destination, double &maxEigenvalue)
Wait for a task and copy outcome into destination.
static constexpr int NoEnclaveTaskNumber
For the generic kernels that I use here most of the time.
Entry(int numberOfResultValues_, double *data_, double maxEigenvalue_)
std::string toString() const