GaloisRuntime::ThreadPool Class Reference

#include <Threads.h>

List of all members.

Public Member Functions

virtual void run (Galois::Executable *work)=0
 execute work on all threads The work object is not duplicated in any way
virtual unsigned int setActiveThreads (unsigned int num)=0
 change the number of threads to num returns the number that the runtime chooses (may not be num)
unsigned int getActiveThreads () const
 How many threads will be used.

Static Public Member Functions

static unsigned int getMyID () __attribute__((pure))

Static Protected Member Functions

static void NotifyAware (bool starting)

Protected Attributes

unsigned int activeThreads

Static Private Attributes

static __thread unsigned int LocalThreadID = ~0
 This, once initialized by a thread, stores an dense index/label for that thread.
static int nextThreadID = 0
 This stores the next thread id.

Friends

struct initMainThread

Member Function Documentation

unsigned int GaloisRuntime::ThreadPool::getActiveThreads (  )  const [inline]

How many threads will be used.

unsigned int ThreadPool::getMyID (  )  [static]
void ThreadPool::NotifyAware ( bool  starting  )  [static, protected]
virtual void GaloisRuntime::ThreadPool::run ( Galois::Executable work  )  [pure virtual]

execute work on all threads The work object is not duplicated in any way

virtual unsigned int GaloisRuntime::ThreadPool::setActiveThreads ( unsigned int  num  )  [pure virtual]

change the number of threads to num returns the number that the runtime chooses (may not be num)


Friends And Related Function Documentation

friend struct initMainThread [friend]

Member Data Documentation

unsigned int GaloisRuntime::ThreadPool::activeThreads [protected]
__thread unsigned int ThreadPool::LocalThreadID = ~0 [static, private]

This, once initialized by a thread, stores an dense index/label for that thread.

int ThreadPool::nextThreadID = 0 [static, private]

This stores the next thread id.


The documentation for this class was generated from the following files:
Generated on Tue Aug 2 11:51:30 2011 for Galois by  doxygen 1.6.3