pelib  2.0.0
pelib::Schedule Class Reference

#include <Schedule.hpp>

Inheritance diagram for pelib::Schedule:
[legend]

List of all members.

Public Types

typedef std::pair< const Task
*, double > 
work
typedef std::map< float, worksequence
typedef std::map< int, sequencetable

Public Member Functions

 Schedule (const std::string &name, const std::string &appName, const table &schedule)
 Schedule (const std::string &name, const Algebra &algebra)
 Schedule (const std::string &name, const std::string &appName, const Algebra &algebra)
 Schedule (const Schedule &src)
virtual ~Schedule ()
virtual Scheduleclone () const
virtual Algebra buildAlgebra () const
virtual std::string getName () const
virtual std::string getAppName () const
virtual const tablegetSchedule () const
virtual const set< Task > & getTasks () const
virtual Scheduleoperator= (const Schedule &)
virtual const set< const Task * > & getTasks (int core) const
virtual const TaskgetTask (int id) const
multiset< const Task * > getRemoteProducers (int core, const Taskgraph &tg, const Platform &pt) const
multiset< const Task * > getRemoteConsumers (int core, const Taskgraph &tg, const Platform &pt) const
multiset< const Task * > getRemoteTaskProducers (const Task &, const Taskgraph &tg, const Platform &pt) const
multiset< const Task * > getRemoteTaskConsumers (const Task &, const Taskgraph &tg, const Platform &pt) const
multiset< const Link * > getRemoteProducersLink (int core, const Taskgraph &tg, const Platform &pt) const
multiset< const Link * > getRemoteConsumersLink (int core, const Taskgraph &tg, const Platform &pt) const
multimap< const Task *, const
Link * > 
getRemoteProducersTaskLink (int core, const Taskgraph &tg, const Platform &pt) const
multimap< const Task *, const
Link * > 
getRemoteConsumersTaskLink (int core, const Taskgraph &tg, const Platform &pt) const
virtual set< const Task * > getTasksSharedMemoryIsland (const set< int > &islands, const Platform &pt) const
virtual multiset< const Task * > getRemoteSharedMemoryIslandProducers (const set< int > &islands, const Taskgraph &tg, const Platform &pt) const
virtual multiset< const Task * > getRemoteSharedMemoryIslandTaskProducers (const Task &t, const Taskgraph &tg, const Platform &pt) const
virtual multiset< const Task * > getRemoteSharedMemoryIslandConsumers (const set< int > &islands, const Taskgraph &tg, const Platform &pt) const
virtual multiset< const Task * > getRemoteSharedMemoryIslandTaskConsumers (const Task &t, const Taskgraph &tg, const Platform &pt) const
virtual const set< intgetCores (const Task &t) const

Static Public Member Functions

static Algebra addStartTime (const Algebra &data, const Taskgraph &tg, const Platform &platform)

Protected Member Functions

virtual void setSchedule (const table &)

Protected Attributes

std::string name
std::string appName
table schedule
set< Tasktasks
std::map< int, set< const Task * > > core_tasks

Detailed Description

Schedule of a streaming application

Definition at line 35 of file Schedule.hpp.


Member Typedef Documentation

Sequence of tasks to run for a processor

Definition at line 41 of file Schedule.hpp.

Collection to task sequences, one element per core

Definition at line 43 of file Schedule.hpp.

typedef std::pair<const Task*, double> pelib::Schedule::work

Models the workload portion of a task computed in a portion of time of a schedule

Definition at line 39 of file Schedule.hpp.


Constructor & Destructor Documentation

pelib::Schedule::Schedule ( const std::string name,
const std::string appName,
const table schedule 
)

Constructor

Parameters:
namename of the schedule. This is only for human-redability purpose
appNamename of the application this schedule is designed for
schedulecollection of task sequences to run by each processor in the schedule

Definition at line 42 of file Schedule.cpp.

pelib::Schedule::Schedule ( const std::string name,
const Algebra algebra 
)

Constructor

Parameters:
algebraCollection of AlgebraData descendant class instances that describes a schedule in an algebraic form, used as basis to build the Schedule class instance

Definition at line 87 of file Schedule.cpp.

pelib::Schedule::Schedule ( const std::string name,
const std::string appName,
const Algebra algebra 
)

Constructor

Parameters:
algebraCollection of AlgebraData descendant class instances that describes a schedule in an algebraic form, used as basis to build the Schedule class instance

Definition at line 92 of file Schedule.cpp.

Definition at line 97 of file Schedule.cpp.

Destructor

Definition at line 51 of file Schedule.cpp.


Member Function Documentation

Algebra pelib::Schedule::addStartTime ( const Algebra data,
const Taskgraph tg,
const Platform platform 
) [static]

Computes the starting time of each task in a schedule and add this starting time to a copy of the algebraic form schedule

Parameters:
dataSchedule in algebraic form that lacks the starting time of tasks
tgTaskgraph that contains extended information about tasks
platformPlatform description that matches the algebraic schedule

Definition at line 745 of file Schedule.cpp.

Generate an algebraic representation of this schedule

Definition at line 187 of file Schedule.cpp.

Schedule * pelib::Schedule::clone ( ) const [virtual]

Returns a pointer to a copy of this class instance

Implements pelib::Record.

Definition at line 179 of file Schedule.cpp.

Returns the name of the application this schedule is generated for

Definition at line 252 of file Schedule.cpp.

const set< int > pelib::Schedule::getCores ( const Task t) const [virtual]

Returns the set of cores that execute a Task

Parameters:
tTask that is run by the set of cores returned by the function

Definition at line 719 of file Schedule.cpp.

Returns the name of the schedule

Definition at line 246 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteConsumers ( int  core,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 480 of file Schedule.cpp.

multiset< const Link * > pelib::Schedule::getRemoteConsumersLink ( int  core,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 494 of file Schedule.cpp.

multimap< const Task *, const Link * > pelib::Schedule::getRemoteConsumersTaskLink ( int  core,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 528 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteProducers ( int  core,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 542 of file Schedule.cpp.

multiset< const Link * > pelib::Schedule::getRemoteProducersLink ( int  core,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 556 of file Schedule.cpp.

multimap< const Task *, const Link * > pelib::Schedule::getRemoteProducersTaskLink ( int  core,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 590 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteSharedMemoryIslandConsumers ( const set< int > &  islands,
const Taskgraph tg,
const Platform pt 
) const [virtual]

Returns the set of Task that are mapped to other shared memory islands than the island collection given as parameter, and consume data produced by tasks mapped in the set of islands given as parameters

Parameters:
islandsSet of islands
tgTaskgraph that describe links between tasks
ptPlatform description that defines shared memory islands

Definition at line 604 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteSharedMemoryIslandProducers ( const set< int > &  islands,
const Taskgraph tg,
const Platform pt 
) const [virtual]

Returns the set of Task that are mapped to other shared memory islands than the island collection given as parameter, and produce data consumed by tasks mapped in the set of islands given as parameters

Parameters:
islandsSet of islands
tgTaskgraph that describe links between tasks
ptPlatform description that defines shared memory islands

Definition at line 320 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteSharedMemoryIslandTaskConsumers ( const Task t,
const Taskgraph tg,
const Platform pt 
) const [virtual]

Returns the set of Task that are mapped to another shared memory island than Task t, and consume data that Task t produces

Parameters:
tTask for which this function computes the set of remote tasks that consume data from it
tgTaskgraph that defines the links between tasks
ptPlatform that defines the core shared memory islands

Definition at line 664 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteSharedMemoryIslandTaskProducers ( const Task t,
const Taskgraph tg,
const Platform pt 
) const [virtual]

Returns the set of Task that are mapped to another shared memory island than Task t, and produce data that Task t consumes

Parameters:
tTask for which this function computes the set of remote tasks that produce data for it.
tgTaskgraph that defines the links between tasks
ptPlatform that defines the core shared memory islands

Definition at line 379 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteTaskConsumers ( const Task t,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 434 of file Schedule.cpp.

multiset< const Task * > pelib::Schedule::getRemoteTaskProducers ( const Task t,
const Taskgraph tg,
const Platform pt 
) const

Definition at line 457 of file Schedule.cpp.

const Schedule::table & pelib::Schedule::getSchedule ( ) const [virtual]

Returns a C++ standard collection that hold processors' task sequences

Definition at line 258 of file Schedule.cpp.

const Task & pelib::Schedule::getTask ( int  id) const [virtual]

Returns the ith task in the Schedule tasks collection

Parameters:
idIndex of the task, starting from 1, to be read from the Schedule's internal collection of Task

Definition at line 270 of file Schedule.cpp.

const set< Task > & pelib::Schedule::getTasks ( ) const [virtual]

Return the set of tasks scheduled in this class instance

Definition at line 264 of file Schedule.cpp.

const set< const Task * > & pelib::Schedule::getTasks ( int  core) const [virtual]

Returns the set of tasks run by a core identified by its number

Parameters:
coreCore number, starting from 1

Definition at line 291 of file Schedule.cpp.

set< const Task * > pelib::Schedule::getTasksSharedMemoryIsland ( const set< int > &  islands,
const Platform pt 
) const [virtual]

Returns the tasks contained in a shared memory island, identified by the set of cores that forms this island.

Parameters:
islandsSet of core id (starting from 1) that form a shared memory island
ptExecution platform that corresponds to this schedule

Definition at line 297 of file Schedule.cpp.

Schedule & pelib::Schedule::operator= ( const Schedule copy) [virtual]

Flushes this schedule instance and copies an instance of Schedule in this instance

Definition at line 278 of file Schedule.cpp.

void pelib::Schedule::setSchedule ( const table schedule) [protected, virtual]

Set the schedule of this class instance from a collection of task sequences. This method duplicates the tasks so the Schedule instance owns all instances of Tasks that the schedule refers to

Definition at line 57 of file Schedule.cpp.


Member Data Documentation

Definition at line 165 of file Schedule.hpp.

Definition at line 168 of file Schedule.hpp.

Definition at line 165 of file Schedule.hpp.

Definition at line 166 of file Schedule.hpp.

Definition at line 167 of file Schedule.hpp.


The documentation for this class was generated from the following files: