annotate TaskManager/kernel/ppe/TaskList.h @ 1506:a7895ab4d0e3 draft

add flip flag and NDRange flag
author Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
date Mon, 10 Sep 2012 15:04:39 +0900
parents cb57420a8219
children 806b4658ced6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
109
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
1 #ifndef INCLUDED_TASKLIST
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
2 #define INCLUDED_TASKLIST
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
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
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
6
1462
8cf62aea798f HTask/TaskList fix (on going)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 958
diff changeset
7 class HTask;
109
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
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
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
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
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
12 public:
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
13 BASE_NEW_DELETE(TaskList);
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
14
1466
cb57420a8219 TaskList on going...
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 1464
diff changeset
15 long lastTask; // 4 byte
109
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
16 TaskList *next; // 4 byte
806
fb49e881f2ed TaslListInfo
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 713
diff changeset
17 TaskList *prev; // 4 byte
fb49e881f2ed TaslListInfo
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 713
diff changeset
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
1506
a7895ab4d0e3 add flip flag and NDRange flag
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents: 1466
diff changeset
22
634
62e570ac5db2 SimpleTask start
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 631
diff changeset
23
1466
cb57420a8219 TaskList on going...
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 1464
diff changeset
24 TaskPtr last() { return (TaskPtr)(((memaddr)tasks)+lastTask); }
cb57420a8219 TaskList on going...
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 1464
diff changeset
25 void set_last(Task *t) { lastTask = ((memaddr)t) - ((memaddr)tasks); }
cb57420a8219 TaskList on going...
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 1464
diff changeset
26 void init() { lastTask = ((memaddr)&tasks[TASK_MAX_SIZE])-(memaddr)(tasks); waiter=this; }
956
197b7e19a345 unified queue worked on Mac OS X
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 899
diff changeset
27 void initOnce() { }
958
338523ff6986 add freeOnce()
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 956
diff changeset
28 void freeOnce() {}
338523ff6986 add freeOnce()
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 956
diff changeset
29
899
1b9418af3127 minor fix..
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 895
diff changeset
30 } ;
109
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
31
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
32 typedef TaskList* TaskListPtr;
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
33
028ffc9c0375 Cerium cvs version
gongo@gendarme.local
parents:
diff changeset
34 #endif