Mercurial > hg > Members > kono > Cerium
changeset 66:1034077dd217
*** empty log message ***
author | gongo |
---|---|
date | Sun, 17 Feb 2008 18:29:08 +0900 |
parents | 519d24aa7ac8 |
children | 7d2874fb0671 |
files | TaskManager/Cell/CellTaskManagerImpl.cc TaskManager/Cell/SpeThreads.cc include/TaskManager/SpeThreads.h |
diffstat | 3 files changed, 13 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/TaskManager/Cell/CellTaskManagerImpl.cc Sun Feb 17 18:06:53 2008 +0900 +++ b/TaskManager/Cell/CellTaskManagerImpl.cc Sun Feb 17 18:29:08 2008 +0900 @@ -27,6 +27,7 @@ { int id; int data; + unsigned int send; for (id = 0; id < machineNum; id++) { while (1) { @@ -40,8 +41,13 @@ __debug_ppe("[PPE] recv from [SPE %d] : 0x%x\n", data, id); bufferManager->check_task_finish((HTaskPtr)data); } + + send = (unsigned int)id; + //¥ئ¥¹¥بحر + speThreads->send_mail(id, &send); } } + return TaskManagerImpl::mail_check(mail_list); }
--- a/TaskManager/Cell/SpeThreads.cc Sun Feb 17 18:06:53 2008 +0900 +++ b/TaskManager/Cell/SpeThreads.cc Sun Feb 17 18:29:08 2008 +0900 @@ -59,3 +59,9 @@ return -1; } } + +void +SpeThreads::send_mail(int speid, unsigned int *data) +{ + spe_in_mbox_write(spe_ctx[speid], data, 1, SPE_MBOX_ANY_NONBLOCKING); +}
--- a/include/TaskManager/SpeThreads.h Sun Feb 17 18:06:53 2008 +0900 +++ b/include/TaskManager/SpeThreads.h Sun Feb 17 18:29:08 2008 +0900 @@ -19,6 +19,7 @@ /* functions */ void init(void); int get_mail(int speid); + void send_mail(int speid, unsigned int *data); static void *spe_thread_run(void *arg); static void *frontend_thread_run(void *arg);