view src/parallel_execution/TaskManager.cbc @ 353:b07078bd1f2c

Add spawn Tasks to TaskManagerImpl
author Tatsuki IHA <innparusu@cr.ie.u-ryukyu.ac.jp>
date Tue, 20 Jun 2017 03:02:29 +0900
parents f23f6d0aa4e9
children fb50cf8aa615
line wrap: on
line source

typedef struct TaskManager<Impl>{
    union Data* taskManager;
    __code createTask(struct TaskManager* taskManager);
    __code spawn(Impl* taskManager, struct Queue* queue, struct Context* task, __code next(...));
    __code spawnTasks(struct TaskManager* taskManager, Impl* taskManagerImpl, struct Context* contexts);
    __code shutdown(struct LoopCounter* loopCounter, struct TaskManager* taskManager, Impl* taskManagerImpl, struct Queue* queue, __code next(...));
    __code next(...);
    __code task(...);
    struct Context* context;
    int worker;
    int cpu;
    int gpu;
    int io;
    int maxCPU;
} TaskManager;