Mercurial > hg > Members > kono > Cerium
view TaskManager/kernel/ppe/Threads.h @ 817:4e8fc627ed33
add CpuThreads.cc
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sun, 23 May 2010 09:43:27 +0900 |
parents | |
children | 19c6cdeb23d6 |
line wrap: on
line source
#ifndef INCLUDED_THREADS #define INCLUDED_THREADS #include <pthread.h> class Threads { public: /* constructor */ Threads(int num = 1); virtual ~Threads(); /* functions */ virtual void init() = 0; virtual int get_mail(int speid, int count, memaddr *ret) = 0; // BLOCKING virtual int has_mail(int speid, int count, memaddr *ret) = 0; // NONBLOCK virtual void send_mail(int speid, int num, memaddr *data) = 0; // BLOCKING /* variables */ pthread_t *threads; thread_arg_t *args; int cpu_num; }; #endif