C:/rwlock/system_abstraction.hh File Reference

#include <unistd.h>
#include <pthread.h>
#include <sched.h>

Go to the source code of this file.

Classes

class  SystemLock
class  SystemThread

Functions

void SystemSleep (unsigned millisec=0)
void thread_yield (void)


Function Documentation

void SystemSleep ( unsigned  millisec = 0  )  [inline]

Definition at line 106 of file system_abstraction.hh.

00107 {
00108     struct timeval tv;
00109     tv.tv_sec = millisec / 1000;
00110     tv.tv_usec = (millisec % 1000) * 1000;
00111         select(0, NULL, NULL, NULL, &tv);
00112 };

void thread_yield ( void   )  [inline]

Definition at line 114 of file system_abstraction.hh.

00115 {
00116         sched_yield();
00117 }


Generated on Wed Mar 19 14:57:11 2008 for rwlock by  doxygen 1.5.5