HL::SpinLockType Class Reference

#include <spinlock.h>

List of all members.

Public Member Functions

 SpinLockType (void)
 ~SpinLockType (void)
void lock (void)
void unlock (void)

Static Public Member Functions

static unsigned long MyInterlockedExchange (unsigned long *, unsigned long)

Private Types

enum  { UNLOCKED = 0, LOCKED = 1 }
enum  { MAX_SPIN_LIMIT = 1024 }

Private Member Functions

NO_INLINE void contendedLock (void)
bool onMultiprocessor (void)
void yieldProcessor (void)

Private Attributes

union {
   volatile unsigned long   mutex
}; 

Member Enumeration Documentation

anonymous enum [private]
Enumerator:
UNLOCKED 
LOCKED 
anonymous enum [private]
Enumerator:
MAX_SPIN_LIMIT 

Constructor & Destructor Documentation

HL::SpinLockType::SpinLockType ( void   )  [inline]
HL::SpinLockType::~SpinLockType ( void   )  [inline]

Member Function Documentation

NO_INLINE void HL::SpinLockType::contendedLock ( void   )  [inline, private]
void HL::SpinLockType::lock ( void   )  [inline]
unsigned long HL::SpinLockType::MyInterlockedExchange ( unsigned long *  oldval,
unsigned long  newval 
) [inline, static]
bool HL::SpinLockType::onMultiprocessor ( void   )  [inline, private]
void HL::SpinLockType::unlock ( void   )  [inline]
void HL::SpinLockType::yieldProcessor ( void   )  [inline, private]

Member Data Documentation

union { ... } [private]
volatile unsigned long HL::SpinLockType::mutex

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