view TaskManager/kernel/ppe/TaskList.h @ 1142:801d57ae1e29 draft

cut compile CreatePolygonTask on spe side because not enough spe memory. We have to use code loading. And I found light error. see you tomorrow. (This version can work Mac OSX and Cell arch.)
author yutaka@localhost.localdomain
date Thu, 17 Feb 2011 05:23:34 +0900
parents 338523ff6986
children 8cf62aea798f
line wrap: on
line source

#ifndef INCLUDED_TASKLIST
#define INCLUDED_TASKLIST

#include "base.h"
#include "Task.h"


#define TASK_MAX_SIZE 31

class TaskList { // 1024 byte 
public:
    BASE_NEW_DELETE(TaskList);

    int length; // 4 byte
    TaskList *next; // 4 byte
    TaskList *prev; // 4 byte
    TaskList *waiter; // 4 byte
    int dummy[4]; // 16 byte
    SimpleTask tasks[TASK_MAX_SIZE]; // 32*TASK_MAX_SIZE

    void init() { length = 0; waiter=this; }
    void initOnce() { }
    void freeOnce() {}

} ;

typedef TaskList* TaskListPtr;

#endif