view include/TaskManager/CellTaskManagerImpl.h @ 1559:c60caac2f345 draft

fix fft
author Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
date Sat, 09 Mar 2013 21:23:40 +0900
parents
children 948bafd61d96
line wrap: on
line source

#ifndef INCLUDED_CELL_TASK_MANAGER_IMPL
#define INCLUDED_CELL_TASK_MANAGER_IMPL

#include "TaskManagerImpl.h"
#include "FifoTaskManagerImpl.h"
#ifdef __CERIUM_CELL__
#include "SpeThreads.h"
#else
#include "CpuThreads.h"
#endif

class CellTaskManagerImpl : public TaskManagerImpl {
public:
    /* constructor */
    CellTaskManagerImpl(int num, Threads *cpus) : TaskManagerImpl(num) {speThreads = cpus;}
    ~CellTaskManagerImpl();

    /* variables */
    QueueInfo<TaskList> **taskListInfo;
    QueueInfo<TaskList> **speTaskList;  // running task

    Threads *speThreads;
    FifoTaskManagerImpl *ppeManager;
    int spe_running;
    int spuIdle;

    /* functions */
    // system
    void init(int spuIdle,int useRefDma, int export_task_log);
    void run();
    void poll();
    void poll1(int spu_limit);
    void poll2(int spu_limit);
    void mail_check(int id);
    TaskListPtr createTaskList();
    //void set_runTaskList(*QueueInfo<HTask>);
    void set_runTaskList(QueueInfo<HTask>* activeTaskQueue);
    void sendTaskList();
    void append_activeTask(HTaskPtr);
    void show_profile() ;
    void start_profile() ;
    void export_task_log() ;
    void polling();
    void debug_check_spe_idle(QueueInfo<HTask> * activeTaskQueue, int spe_running_);
    void print_arch();
private:
    void send_taskList(int id);
    void show_dead_lock_info();

};

#endif