Mercurial > hg > Members > e085722 > Cerium
annotate example/dependency_task/ppe/Print.cc @ 0:04e28d8d3c6f
first commit
author | Daiki KINJYO <e085722@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 08 Nov 2010 01:23:25 +0900 |
parents | |
children |
rev | line source |
---|---|
0 | 1 #include <stdio.h> |
2 #include <string.h> | |
3 #include "Print.h" | |
4 #include "Func.h" | |
5 | |
6 /* これは必須 */ | |
7 SchedDefineTask(Print); | |
8 | |
9 static int | |
10 run(SchedTask *s, void *rbuf, void *wbuf) | |
11 { | |
12 int *idata = (int*)s->get_input(rbuf, 0); | |
13 long length = (long)s->get_param(0); | |
14 | |
15 s->printf("[TASK_PRINT]\n"); | |
16 for (int i = 0; i < length; i++) { | |
17 s->printf("%2d ", idata[i]); | |
18 } | |
19 s->printf("\n"); | |
20 | |
21 return 0; | |
22 } |