Mercurial > hg > Game > Cerium
changeset 1876:5e17ab506299 draft
change CPU_TYPE SPE_ANY to IO/0 ( cannot running )
author | Masataka Kohagura <e085726@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 30 Dec 2013 20:52:21 +0900 |
parents | 2f04c761bf9f |
children | b74327adede7 |
files | TaskManager/kernel/ppe/CpuThreads.cc example/fileread/main.cc |
diffstat | 2 files changed, 5 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/TaskManager/kernel/ppe/CpuThreads.cc Mon Dec 30 20:16:36 2013 +0900 +++ b/TaskManager/kernel/ppe/CpuThreads.cc Mon Dec 30 20:52:21 2013 +0900 @@ -32,7 +32,7 @@ CpuThreads::~CpuThreads() { memaddr mail = (memaddr)MY_SPE_COMMAND_EXIT; - + for (int i = 0; i < cpu_num+io_num; i++) { send_mail(i+id_offset, 1, &mail); } @@ -68,13 +68,13 @@ SchedRegister(StartProfile); if (argt->cpuid >= argt->cpu_num) { // set IO thread priory maximum - int policy; - struct sched_param param; + int policy; + struct sched_param param; pthread_getschedparam(pthread_self(), &policy, ¶m); param.sched_priority = 1; pthread_setschedparam(pthread_self(), policy, ¶m); } - + argt->wait->sem_v(); //準備完了したスレッドができるたびに+1していく c_scheduler->run(new SchedNop());
--- a/example/fileread/main.cc Mon Dec 30 20:16:36 2013 +0900 +++ b/example/fileread/main.cc Mon Dec 30 20:52:21 2013 +0900 @@ -16,7 +16,7 @@ static double ed_time; static int spe_num = 1; int divide_read_flag = 0; -static CPU_TYPE spe_cpu = SPE_ANY; +static CPU_TYPE spe_cpu = IO_0; static int DIVISION_SIZE = 4096*4; extern TaskManager *manager;