• Tidak ada hasil yang ditemukan

Chapter 4

Optimal Scheduling of PTGs on Heterogeneous Distributed Systems

In the previous chapter, we have considered the problem of scheduling real-time indepen- dent task sets running on homogeneous multiprocessor systems. However, Continuous demands for higher performance and reliability within stringent resource budgets is driving a shift from homogeneous to heterogeneous processing platforms for the imple- mentation of today’s CPSs. These CPSs are often distributed in nature and typically represented as PTGs due to the complex interactions between their functional compo- nents. This chapter discusses two optimal scheduling mechanism for a real-time sys- tem modelled as a PTG to be executed on a fully connected distributed heterogeneous platform. Here, tasks may have multiple implementations designated as service-levels, with higher service-levels producing more accurate results and contributing to higher rewards/QoS for the system. To solve the problem, an ILP based optimal solution ap- proach namely, ILP - Service-level Allocation with Timed Constraints (ILP-SATC), is proposed. Though the formulation of ILP-SATC follows an intuitive design flow, its scalability is limited primarily due to the explicit manipulation of task mobilities be- tween their earliest and latest start times. In order to improve scalability, a second ILP based strategy namely, ILP - Service-level Allocation with Non-overlapping Con- straints (ILP-SANC), has been designed. Instead of explicitly relying on task mobility based manipulations as ILP-SATC, ILP-SANC guarantees that the executions of no two tasks in the system overlap in time on the same processor. This modification in the de-

sign approach allows the constraint set in ILP-SANC to be independent of the deadline of a given PTG.

In this chapter, we first present a detailed description of the problem considered in this work, followed by the formulation of ILP-SATC and ILP-SANC. Then, both the ILP formulations have been comprehensively evaluated through an extensive set of experiments over benchmark PTGs. Performance of the design strategies have also been compared against a state-of-the-art approach [1]. Finally, we demonstrate the practical applicability of the ILP based formulation using a real-world case study on anAdaptive Cruise Controller (ACC) application and conclude the chapter.

4.1 The Task and Platform Models

This work considers a periodic application represented as a PTG G= (T,E) to be exe- cuted on a fully-connected heterogeneous multiprocessor platform consisting of a set of processors P = {P1, P2, . . . , Pp}. Figure 4.1 shows the pictorial representation of the fully-connected heterogeneous multiprocessor platform as considered here. Each proces- sor has its own private memory. For any given processor, task execution and communi- cation with other processors can be conducted simultaneously, without any contention.

Specifically, we assume that tasks on different processors communicate by transmitting data from the source processor via the fully-connected network to the local memory of the receiving processor. On the other hand, intra-processor communication is realized through the reading and writing of variables stored in the local memory of the processor.

Processing ElementP1

Processing ElementP2

Processing ElementP3

Processing ElementP4

Figure 4.1: Fully connected multiprocessor system

T ={T1, T2, . . . , Tn} represents n task nodes.

• E⊆T×T denotes the edge-set that describesprecedence-constraintsbetween pairs of tasks inT. The symbol mij is used to denote the communication cost associated with the edgeTi −→Tj;mij = 0, whenTi andTj are assigned to the same processor.

All tasks/messages in PTG Gexecute/transmit non-preemptively.

• Each taskTihasSLi ={sli1, sli2, . . . , sli|SLi|}alternative service-levels. Associated with a given service-level slil of task Ti, there exists ppossibly distinct worst-case execution times eilr (i ∈ [1, n], l ∈ [1,|SLi|], r ∈ [1, p]) corresponding to the p heterogeneous processors. There is a reward QoSil which is obtained on successful completion of every instance of Ti.

• Given any two service-levels slil and slil0 of task Ti such that l < l0, the execution times on any processor Pr are related as eilreil0r. However, the processors being heterogeneous, the execution times of a task on two different processors are completely unrelated.

• The execution times of a task Ti on processor Pr for all service-levels is set to ∞, to model the scenario in which the execution of Ti is infeasible on Pr.

• Each instance of application G has an associated deadline D. Two consecutive instances ofGare separated by aperiod π. We assume the deadline to beimplicit, i.e., D=π.

To denote in-degree and out-degree of the task nodeTi, we use the notationsindeg(Ti) and outdeg(Ti), respectively. Given a pair of task nodes hTi, Tji, Ti (Tj) is said to be the predecessor (successor) of Tj (Ti) if there is an edge (TiTj) form Ti to Tj. To denote predecessor and successor of the task nodeTi, we use the notationspred(Ti) and succ(Ti), respectively. Similarly, given two tasks Ti and Tj, Ti (Tj) is said to be the ancestor (descendant) ofTj (Ti), ifTiTj i.e., there exists a path from Ti toTj, in the PTG.

Example: An example of a PTG G and its task parameters are shown in Figure 4.2 and Table 4.1, respectively. PTGGconsists of 6 tasks, each task having 2 service-levels.

Each task Ti may have distinct execution times eilr on each processor Pr for any given service-level slil along with associated reward QoSil. For example, at service-level sl11, taskT1 has execution times e111= 3 and e112 = 1 on processors P1 and P2, respectively, and an associated reward QoS11 = 4. An edge between T1 and T2 has an associated communication cost of 2.

T1

T3

T2 T4

T5

T6

2 1 3

1 3

1 2

D=10

Figure 4.2: Example of a PTG G

TaskSLi

eilr QoSil

P1 P2

T1 sl11 3 1 4 sl12 4 2 7 T2 sl21 1 2 5 sl22 2 3 9 T3

sl31 2 3 2 sl32 3 4 6 T4

sl41 4 1 3 sl42 6 3 9 T5

sl51 1 4 1 sl52 3 7 8 T6

sl61 3 2 2 sl62 4 3 4

Table 4.1: Values of tasks in Figure 4.2

Problem Statement: Generate a real-time schedule consisting of a feasible processor assignment, service-level and start time for each task node of a given PTG having a stipulated end-to-end deadline, such that the total QoS acquired by the system is maxi- mized while ensuring that deadline, precedence and resource constraints are not violated on a fully-connected heterogeneous multiprocessor platform.