dol: create target object folders when generating
[jump.git] / dol / src / dol / visitor / cell / template / spu_process_wrapper_template.h
1 /****************************************************************
2  *      Process Wrapper file
3  *      Creator: lschor, 2009-02-24
4  *      Description: Wrapper for a specific SPE process
5  *
6  *      Revision:
7  *      - 2009-02-24: Created
8  */
9
10 #ifndef @PROCESSNAME@_WRAPPER_H_
11 #define @PROCESSNAME@_WRAPPER_H_
12
13 // General includes
14 #include <spu_intrinsics.h>
15 #include <spu_mfcio.h>
16 #include <stdint.h>
17 #include <stdio.h>
18 #include <ctype.h>
19 #include <new>
20
21 // Include to allocate/free using for DMA transfers
22 #include "../lib/malloc_align.h"
23 #include "../lib/free_align.h"
24 #include "../lib/spu/Fifo.h"
25 #include "../lib/spu/WindowedFifo.h"
26
27 // Local includes
28 #include "../lib/common.h"
29 //#include "../lib/estimation.h"
30
31 #include "../lib/spu/proc_wrapper.h"
32
33 class @PROCESSNAME@Wrapper; 
34
35 typedef struct _@PROCESSNAME@_data {
36     int lc;
37     @PROCESSNAME@Wrapper *wrapper;
38 } @PROCESSNAME@_data;
39
40 class @PROCESSNAME@Wrapper  : public proc_wrapper {
41         
42 // Context file
43 public:
44         @PROCESSNAME@Wrapper(uint64_t argp);
45         virtual ~@PROCESSNAME@Wrapper();
46         
47         @FIFO@
48
49 protected:
50         LocalState _state;
51         process_context ctx_proc __attribute__ ((aligned (128)));
52         @PROCESSNAME@_data _wrapper_data;
53
54 };
55
56 #endif /* @PROCESSNAME@_WRAPPER_H_ */