Mercurial > hg > Game > Cerium
annotate TaskManager/kernel/ppe/TaskList.h @ 1463:f7e497c8e8a3 draft
TaskList on going...
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 14 Jul 2012 20:44:23 +0900 |
parents | 8cf62aea798f |
children | 3f2230d79eba |
rev | line source |
---|---|
109 | 1 #ifndef INCLUDED_TASKLIST |
2 #define INCLUDED_TASKLIST | |
3 | |
301
7f991471d43f
remove deprecated source. not work.
tkaito@localhost.localdomain
parents:
244
diff
changeset
|
4 #include "base.h" |
7f991471d43f
remove deprecated source. not work.
tkaito@localhost.localdomain
parents:
244
diff
changeset
|
5 #include "Task.h" |
109 | 6 |
1462
8cf62aea798f
HTask/TaskList fix (on going)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
958
diff
changeset
|
7 class HTask; |
109 | 8 |
895
b662e9dd26b0
add alignment of classes in SPU
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
830
diff
changeset
|
9 #define TASK_MAX_SIZE 31 |
109 | 10 |
895
b662e9dd26b0
add alignment of classes in SPU
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
830
diff
changeset
|
11 class TaskList { // 1024 byte |
109 | 12 public: |
13 BASE_NEW_DELETE(TaskList); | |
14 | |
1463 | 15 TaskList *lastTask; // 4 byte |
109 | 16 TaskList *next; // 4 byte |
806 | 17 TaskList *prev; // 4 byte |
18 TaskList *waiter; // 4 byte | |
1462
8cf62aea798f
HTask/TaskList fix (on going)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
958
diff
changeset
|
19 HTask *self; // 4 byte |
8cf62aea798f
HTask/TaskList fix (on going)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
958
diff
changeset
|
20 long dummy[3]; // 16 byte |
8cf62aea798f
HTask/TaskList fix (on going)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
958
diff
changeset
|
21 Task tasks[TASK_MAX_SIZE]; // 32*TASK_MAX_SIZE |
634 | 22 |
1463 | 23 TaskPtr last() { return &tasks; } |
24 void init() { lastTask = &tasks[TASK_MAX_SIZE]; waiter=this; } | |
956
197b7e19a345
unified queue worked on Mac OS X
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
899
diff
changeset
|
25 void initOnce() { } |
958 | 26 void freeOnce() {} |
27 | |
899 | 28 } ; |
109 | 29 |
30 typedef TaskList* TaskListPtr; | |
31 | |
32 #endif |