view example/renew_task/spe/Renew3.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
line wrap: on
line source

#include <stdio.h>
#include "Renew3.h"
#include "SpeProfile.h"
#include "Func.h"

/* これは必須 */
SchedDefineTask(Renew3);

static int
run(SchedTask *s, void *rbuf, void *wbuf)
{
    SpeProfile *profile = (SpeProfile*) s->global_get(0);
    profile->ProfStop();
    profile->ProfPrint();

    s->printf("[SPE] ** running Renew3\n");
    
    s->printf("[SPE] Create Task : Renew4\n");
    HTaskPtr nextTask =  s->create_task(RENEW4);
    nextTask->spawn();
    
    s->printf("[SPE] ** finish  Renew3\n");
    s->printf("\n");

    profile->ProfStart();

    return 0;
}