Mercurial > hg > Game > Cerium
diff example/get_segment/spe/Hello1.cc @ 626:0e91ddaad798 draft
64bit mode compatibility on Cell
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 16 Nov 2009 11:37:26 +0900 |
parents | 16f0abb574b7 |
children | 74fd8d2a7b9d |
line wrap: on
line diff
--- a/example/get_segment/spe/Hello1.cc Mon Nov 16 10:59:55 2009 +0900 +++ b/example/get_segment/spe/Hello1.cc Mon Nov 16 11:37:26 2009 +0900 @@ -21,7 +21,7 @@ static int run(SchedTask *smanager, void *rbuf, void *wbuf) { - int task_id = smanager->get_param(0); + long task_id = (long)smanager->get_param(0); unsigned int pc; __asm__ __volatile__( @@ -36,7 +36,7 @@ smanager->fprintf(smanager->stderr_,"[%d] Hello, World Seg 2!!\n"+offset, task_id); - smanager->fprintf(smanager->stderr_,"pc=0x%0x 0x%0x\n"+offset,pc, (unsigned int)&runTask_Hello1); + smanager->fprintf(smanager->stderr_,"pc=0x%0x 0x%0lx\n"+offset,pc, (unsigned long)&runTask_Hello1); return 0; }