Mercurial > hg > Game > Cerium
changeset 2031:f7969d7f5605 draft
fix
author | Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 25 Nov 2014 06:22:53 +0900 |
parents | 258498680128 |
children | 3494884963a5 |
files | TaskManager/kernel/schedule/SchedTask.cc TaskManager/kernel/schedule/SchedTask.h |
diffstat | 2 files changed, 6 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/TaskManager/kernel/schedule/SchedTask.cc Tue Nov 25 05:08:50 2014 +0900 +++ b/TaskManager/kernel/schedule/SchedTask.cc Tue Nov 25 06:22:53 2014 +0900 @@ -11,7 +11,7 @@ #include <stdarg.h> #include "gettime.h" -//extern TaskObject task_list[MAX_TASK_OBJECT]; +extern TaskObject task_list[MAX_TASK_OBJECT]; SchedTask::SchedTask() { @@ -44,8 +44,6 @@ manager = sc->manager; connector = sc->connector; - taskPool = new QueueInfo<TaskObject>(); - inListData.bound = din; inListData.size = 0; inListData.length = 0; @@ -55,7 +53,7 @@ outListData.length = 0; outListData.element = 0; - cur_index = _task; + cur_index = _task; this->tag = tag; if (list) @@ -103,8 +101,8 @@ void SchedTask::exec() { - taskPool->get(atask->command)->wait(scheduler,atask->command); - TaskObjectRun run = taskPool->get(atask->command)->run; + task_list[atask->command].wait(scheduler,atask->command); + TaskObjectRun run = task_list[atask->command].run; if (atask->outData_count > 0) { setup_outputData(); // we need write buffer before run() } @@ -120,7 +118,7 @@ } (*connector->end_dmawait_profile)(&connector->global_busy_time,&connector->start_time,&connector->stop_time); list->task_end_time = gettime(); - __debug(this->scheduler,"cpuid %ld %s\t0x%p time %lld\n",scheduler->id,(char *)(taskPool->get(atask->command)->name),(void*)list, list->task_end_time-list->task_start_time); + __debug(this->scheduler,"cpuid %ld %s\t0x%p time %lld\n",scheduler->id,(char *)(task_list[atask->command].name),(void*)list, list->task_end_time-list->task_start_time); connector->free_(readbuf); // User 側で作る方法が必要... // 書き込む領域がなければ無視
--- a/TaskManager/kernel/schedule/SchedTask.h Tue Nov 25 05:08:50 2014 +0900 +++ b/TaskManager/kernel/schedule/SchedTask.h Tue Nov 25 06:22:53 2014 +0900 @@ -7,7 +7,7 @@ #include "ListData.h" #include "HTask.h" #include "MemList.h" -#include "QueueInfo.h" + class SchedTask : public SchedTaskBase { public: @@ -32,8 +32,6 @@ // タスクの処理は、task_list に登録された C の関数によっておこなう public: - QueueInfo<TaskObject> *taskPool; - /* functions */ void init(TaskListPtr _list, TaskPtr _task,