[ieee 2007 2nd international conference on pervasive computing and applications - birmingham, uk...

6
A Heterogeneous Dynamic Critical Path and Duplication based Task Scheduling Algorithm for Pervasive Computing Dong Fang, Luo Junzhou School of Computer Science and Engineering, Southeast University, Nanjing, P.R. China tfdong, jluol @seu. edu. cn Abstract In order to utilize the different resource in pervasive environment effectively, task scheduling as the key part of the pervasive computing framework becomes significantly important. Nowadays, there are several proposed task scheduling algorithms which can be applied in the pervasive computing environment. But most of the existing algorithms are based on static task priority and singular predecessor duplication. And they can not schedule tasks effectively. Consequently, considering these drawbacks and combining the attribute of the pervasive computing, a task scheduling algorithm based on dynamic critical path and multi- task duplication (HDCPD) is presented The HDCPD algorithm is a list and duplication based scheduling algorithm that not only makes use of the dynamical critical path to computing the task priority effectively, but also consider the multi-level task to be duplicated The simulation results show that this algorithm significantly surpasses previous algorithms in SLR and Speedup Rate metrics. Keywords: Pervasive computing, task scheduling, DAG, heterogeneous, task duplication 1. Introduction The aim of pervasive computing is to provide transparent computing ability to users, make them employ resources and services of network at their wishes at anywhere and anytime [1]. In order to share the resources and the computing ability to users effectively, the task scheduling is a necessary part in pervasive computing environment. Therefore, task scheduling as the key part of the pervasive computing framework becomes significantly important. In order to take advantage of pervasive computing system, a job is usually partitioned into a set of communicating tasks. These tasks can be scheduled and executed on different resources respectively, which can be presented by a directed acyclic graph (DAG). The whole process of scheduling is to assign all tasks to different resources to gain the minimum completion time meanwhile the precedence constraint between tasks must be satisfied. Among the proposed DAG task scheduling algorithms, the task scheduling sequence can usually be obtained according to the static critical path of task DAG. But this static strategy can not reflect the actual situation accurately. Meanwhile, in the resource selection phase, most of duplication-based algorithms only consider duplicating one critical immediate predecessor or one level of immediate predecessor. In order to overcome these drawbacks, a task scheduling algorithm based on dynamic critical path and task duplication is presented. This algorithm makes use of dynamic critical path to get the task scheduling sequence. In the resource selection phase, the multi- immediate predecessors and multi-level predecessors are considered to be duplicated. Thus, this algorithm can reflect the dynamic situation of scheduling and achieve the better makespan. The simulation results show that this algorithm significantly surpasses traditional algorithms in SLR and Speedup Rate metrics. The remainder of this paper is organized as follows: Section 2 introduces related work about the proposed DAG task algorithms and analyzes their drawbacks. In section 3, we defined the scheduling problem and the related terminology. Section 4 explains heterogeneous dynamic critical path and task duplication based task scheduling algorithm. Section 5 presents a comparison study of our algorithm with the related work, which is based on randomly generated task graphs. The summary of the research and the direction of future work are given in Section 6. 2. Related work The DAG task scheduling problem is NP-Complete in pervasive computing environment. The task scheduling affects the whole performance of pervasive computing system significantly. Nowadays, around the issue of task scheduling, a lot of researches have been carried on and several scheduling algorithms were proposed in the literature [2-10]. According to the different strategies in these scheduling algorithms, these heuristics are classified into a variety of categories such as list-scheduling, clustering scheduling, duplication-based scheduling and random search methods. In the list-scheduling technique [2-9], the proper priorities are set to tasks and the task sequence of 1-4244-0971-3/07/$25.00 ©)2007 IEEE.

Upload: luo

Post on 11-Mar-2017

213 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: [IEEE 2007 2nd International Conference on Pervasive Computing and Applications - Birmingham, UK (2007.07.26-2007.07.27)] 2007 2nd International Conference on Pervasive Computing and

A Heterogeneous Dynamic Critical Path and Duplication based TaskScheduling Algorithm for Pervasive Computing

Dong Fang, Luo JunzhouSchool ofComputer Science and Engineering, Southeast University, Nanjing, P.R. China

tfdong, jluol@seu. edu. cn

Abstract

In order to utilize the different resource in pervasiveenvironment effectively, task scheduling as the key partof the pervasive computing framework becomessignificantly important. Nowadays, there are severalproposed task scheduling algorithms which can beapplied in the pervasive computing environment. Butmost of the existing algorithms are based on static taskpriority and singular predecessor duplication. And theycan not schedule tasks effectively. Consequently,considering these drawbacks and combining theattribute of the pervasive computing, a task schedulingalgorithm based on dynamic critical path and multi-task duplication (HDCPD) is presented The HDCPDalgorithm is a list and duplication based schedulingalgorithm that not only makes use of the dynamicalcritical path to computing the task priority effectively,but also consider the multi-level task to be duplicatedThe simulation results show that this algorithmsignificantly surpasses previous algorithms in SLR andSpeedup Rate metrics.

Keywords: Pervasive computing, task scheduling,DAG, heterogeneous, task duplication

1. Introduction

The aim of pervasive computing is to providetransparent computing ability to users, make thememploy resources and services of network at theirwishes at anywhere and anytime [1]. In order to sharethe resources and the computing ability to users

effectively, the task scheduling is a necessary part inpervasive computing environment. Therefore, taskscheduling as the key part of the pervasive computingframework becomes significantly important.

In order to take advantage of pervasive computingsystem, a job is usually partitioned into a set ofcommunicating tasks. These tasks can be scheduled andexecuted on different resources respectively, which can

be presented by a directed acyclic graph (DAG). Thewhole process of scheduling is to assign all tasks todifferent resources to gain the minimum completiontime meanwhile the precedence constraint betweentasks must be satisfied.

Among the proposed DAG task schedulingalgorithms, the task scheduling sequence can usually beobtained according to the static critical path of taskDAG. But this static strategy can not reflect the actualsituation accurately. Meanwhile, in the resource

selection phase, most of duplication-based algorithmsonly consider duplicating one critical immediatepredecessor or one level of immediate predecessor. Inorder to overcome these drawbacks, a task schedulingalgorithm based on dynamic critical path and taskduplication is presented. This algorithm makes use ofdynamic critical path to get the task schedulingsequence. In the resource selection phase, the multi-immediate predecessors and multi-level predecessorsare considered to be duplicated. Thus, this algorithmcan reflect the dynamic situation of scheduling andachieve the better makespan. The simulation resultsshow that this algorithm significantly surpasses

traditional algorithms in SLR and Speedup Rate metrics.The remainder of this paper is organized as follows:

Section 2 introduces related work about the proposedDAG task algorithms and analyzes their drawbacks. Insection 3, we defined the scheduling problem and therelated terminology. Section 4 explains heterogeneousdynamic critical path and task duplication based taskscheduling algorithm. Section 5 presents a comparisonstudy of our algorithm with the related work, which isbased on randomly generated task graphs. The summary

of the research and the direction of future work are

given in Section 6.

2. Related work

The DAG task scheduling problem is NP-Completein pervasive computing environment. The taskscheduling affects the whole performance of pervasivecomputing system significantly. Nowadays, around theissue of task scheduling, a lot of researches have beencarried on and several scheduling algorithms were

proposed in the literature [2-10].According to the different strategies in these

scheduling algorithms, these heuristics are classifiedinto a variety of categories such as list-scheduling,clustering scheduling, duplication-based scheduling andrandom search methods.

In the list-scheduling technique [2-9], the proper

priorities are set to tasks and the task sequence of

1-4244-0971-3/07/$25.00 ©)2007 IEEE.

Page 2: [IEEE 2007 2nd International Conference on Pervasive Computing and Applications - Birmingham, UK (2007.07.26-2007.07.27)] 2007 2nd International Conference on Pervasive Computing and

scheduling can be generated based on them. And themain idea of the duplication method is to use theresource's idle time to duplicate the tasks' predecessorswhich have been scheduled on any other resources. Andthen the communication cost can be reduced. Generally,list and duplication-based techniques are blendedtogether. The performance of this strategy outperformsother non-duplication algorithms, but meanwhile thetime complexity is increasing.

Nowadays, most ofDAG task scheduling algorithmsare mainly for homogeneous systems [4, 7, 10]. But inthe pervasive computing environment, resources areheterogeneous. Thus, the task scheduling algorithmsneed to aim at the heterogeneous environment. Recently,there are several scheduling algorithms based on theheterogeneous environment [2, 3, 5-6, 8-9], but theyalso have some problems:

1. Most ofheterogeneous scheduling algorithms onlytook into consideration the difference betweenresources. But in the pervasive computing environment,the link of communication is also heterogeneous.

2. In most algorithms, the priority of tasks arecalculated based on static DAG, it also means that thepriority value could not be changed during the taskscheduling process.

In HEFT [2] algorithm, the priorities of tasks arecalculated using the static DAG. And then use thegreedy strategy to schedule task onto the resourcewhich can accomplish the task in the minimum time.This algorithm didn't consider the dynamic change inscheduling process and the duplication of task. LDBS[6] is based on the list-duplication strategy. The readytasks are limited on the same topology level of DAG.The limitation is that not all ready tasks in the DAGcould be considered to be scheduled at one step. In theresource selection phase, more than one immediatepredecessor can be duplicated, but the multi-predecessors couldn't be duplicated, so the strategy isalso incomplete. DCPD [9] is the novel algorithm withbetter performance. It is also based on the list-duplication combination strategy. The differencebetween the time cost from entry node to the task andmaximum length from the task to the exit node isconsidered as the evaluating standard to fix the taskpriority dynamically. However, the tasks which can becompleted in shorter time could be scheduled earlier.Thus, the lower priority task would be scheduled firstly,so the completion time ofDAG could be delayed.

3. Scheduling problem formulation

A scheduling system model consists of the taskmodel, the resource model and the performance criteriafor scheduling.

3.1 Task model of pervasive computing

A job can be presented by a DAG. A task DAG can

of n tasks, R is the set of communication edges thatdefine a partial order or precedence constraints on V.v,Rvi E R means Vj can not be executed until vicompletes its execution. C is the set of data transferamount. C={ c(vi,vj) q(vj,vj) E RI, where c(vi,vj) presentsthe data transfer amount between vi and vj. A taskwithout any predecessor is called entry task and a taskwithout any successor is called exit node. Without lossof generality, we can assume that there is only one entrynode and one exit node in the DAG.

3.2 Resource model of pervasive computing

The pervasive computing environment can beassumed as a heterogeneous computing system whichconsists of m heterogeneous resources connected withthe communication links. It can be defined as M= (P, Q,B, L}, where P is the set ofm heterogeneous resources,

Q is the set of communication links. B which can bedefined as B = {b(pm,pn) q(p.,p11) E Q} is m*n matrix ofcommunication bandwidth between resources, whereb(pm,pn) presents the bandwidth between p, and pj. L isthe set of communication startup cost. Thus, the transfertime between vi and vj can be defined as formula 1:

Tc(i,j,m,n) = L + c(vi,vj) (1)

b(Pm,Pn)As the bandwidth of inner-bus is much larger than

the bandwidth of outer-bus, the value Tc(i,j,m,n) can beignored when vi and vj are scheduled on the same

resource.

3.3 The instruction of relative parameters

The parameters used in scheduling process are

defined as follows:Ready set: Under current scheduling situation, it

denotes the set of tasks whose all predecessors are

scheduled already.ETC(vi,p11): The execution time of task vi on

resource Pn. ETC(v1) is the mean execution time of vi.

EST(vi,pn)&EFT(vi,pn): They denote the earlieststart time and earliest finish time of vi on Pn. For theentry node, the value of EST(ventry, Pn) equals zero.

For the other tasks, the value of EST and EFT can

be calculated from entry node to exit node recursivelyusing formula 2 and formula 3:

EST(viXPn) =max{Pavij[n], max (FCT(v-) +Tc(j,i,p(v-),n))} (2)vjepred(v )

EFT(vi ,Pn1) = ETC(vi ,Pn1) + EST(vi,Pn) (3)

PavaiE[n] denotes the earliest available time of Pn

under the current situation. The inner max functionreturns the data ready time of task vi. pred(vi) presentsthe set of all immediate predecessors of task vi. p(vj)denotes the resource which vj is scheduled on.. After thetask was scheduled, EST and EFT are equal to FST(v,)(factual start time) and FCT(vi)(factual finish time).

be defined as a tuple G = (V, R, C), where V is the set

Page 3: [IEEE 2007 2nd International Conference on Pervasive Computing and Applications - Birmingham, UK (2007.07.26-2007.07.27)] 2007 2nd International Conference on Pervasive Computing and

DAT(vi,p,1,vj): It is defined as the time when vireceives the data from vj. The value can be calculatedby:

DAT(v,pPnX v ) = FCT(v ) + Tc(j,i,p(vj ),n) (4)The critical predecessor of vi, CP(vi): It denotes

immediate predecessor whose data arrive time is thelatest one of all immediate predecessor, defined as:

CP(vI) = VkS.t.Vk E pred(vi) and DAT(vi,Pn,Vk) (5)> Rl(DAT(vi vPn sVI ))

4. Task scheduling algorithm

HDCPD algorithm consists of two phases, the taskselection phase and resource selection phase. We willdefine some relative parameters firstly.

4.1 Graph attributes used by IIDCPD

There are two main phases of the list-schedulingalgorithm, task selection phase and resource selectionphase. In order to explain the task selection of ouralgorithm, two concepts are imported: the task remnantcomputation amount (RCA) and task completecomputation amount (CCA).

Definition 1: The task remnant computing amountRCA(vi) denotes the maximum length from vi to theexit node(include the execution time of vi). Thecomputation of RCA(vi) starts from the exit task andrecursively progresses by traversing the task graphupward. The recursions of RCA are presented informula 6-8:RCA(v1) = max {RCA(v ) + ETc(v1 ,vj) }+ EETC(v1)) (6)

VjE=SUCC(Vi )

ETc(vi ,v ) = Tc(i,j) (7)

EETC (vi )= E P(VI, Pn )x ETC (v.,Pn ) (8)

succ(vi) denotes the set of vi's successors. Theexpectation of data transfer cost ETc(vi,vj) can besubstituted by the mean transfer cost between two tasks.The expectation of task execution cost is equal to themean cost of execution when there is no selectionpreference between different resources. After the tasksare scheduled, the known part of RCA can besubstituted by the actual scheduling results.

In the RCA computing, the critical successor of viCS(vi) is introduced. It can be defined as the immediatesuccessor of vi which can lead the maximum value ofmax function in formula 6.

Definition 2: The complete computing amountCCA(vi) denotes the maximum length from the entrynode to vi (not include the execution time of vi). Thecomputation of CCA starts from the entry task andrecursively progresses by traversing the task graphdownward. As same as the definition 1, the recursionsofCCA are presented in formula 9.CCA(v¾) = max {CCA(v ) + ETc(vi ,vj) } + EETC(v ) (9)

vjepred(vi )

After tasks before vi are scheduled, the known partofCCA can be substituted by actual scheduling result.

4.2 Task selection phase

In the list-scheduling algorithms, the task prioritysetting is the key part of the whole scheduling process.One important attribute can be used to determine nodespriorities accurately is the critical path (CP) ofDAG.

The SL(schedule length) ofDAG can be potentiallydetermined by the CP of DAG. After all tasks arescheduled, the final SL is equal to the length of final CP.

However, the CP can change dynamically during thescheduling process. There are two main reasons:

1. When two tasks which have the data constraintare scheduled on the same resource, the communicationcost between them can be ignored.

2. Because of the heterogeneous attribute of thesystem, when the tasks are scheduled step by step, themathematical expectations of the data transfer and taskexecution time using to calculated the CP can besubstituted by the actual scheduling value.

If task priority setting is based on static CP, it mayresult in the deterioration of scheduling performance.To overcome this drawback, the heterogeneousdynamic critical path (HDCP) is introduced.

Definition 5: HDCP is the CP which considers theheterogeneous attribute of task and updates dynamically.It can reflect the latest situation of scheduling. HDCP,denotes the CP when i tasks have been scheduled.HDCPO denotes the static CP.

The detail of task selection strategy based ondynamic CP is as follows. At each scheduling step, thecurrent CP is calculated dynamically using latestscheduling information. The unscheduled task which islocated on the HDCP and has the smallest CCA valuecan be defined as Vdt and is selected to set with thehighest priority. If there are several unscheduledimmediate predecessors of vdt, the task with minimumvalue of CCA among the set of vdt's unscheduledimmediate predecessors of maximum sum of RCA andCCA is selected to be scheduled. Thus, the proper taskscheduling sequence can be obtained.

Theorem 1: Assumed that in the computation ofHDCP, the performance of estimating completion timeusing the mathematics expectation is steady to everytask's actual completion time. Then, the dynamic CPstrategy based on HDCP can outperform the static CPstrategy.

Proof: Assumed that vi and vj are two tasks locatedin the k-th ready set.

(1) If vi can be scheduled both according to dynamicCP and the static CP, SLdy is equal to SLst, thus theperformance oftwo strategy are the same.

(2) Ifvj is the unscheduled task which is located onthe HDCPklI and has the minimum value of CCA, vi isdefined as either the unscheduled task with minimumCCA in HDCPo or any unscheduled predecessors aheadof the task with minimum CCA in HDCPO. Thus,

Page 4: [IEEE 2007 2nd International Conference on Pervasive Computing and Applications - Birmingham, UK (2007.07.26-2007.07.27)] 2007 2nd International Conference on Pervasive Computing and

scheduling vi firstly may delay the scheduling of vj onthe HDCPk-l. In this situation, the scheduling length cannot be reduced. Thus, SLst = RCA(vi) + CCA(vi) >RCA(vj) + CCA(vj) = SLdy.

(3) If Vdt is the unscheduled task with minimumCCA in HDCPk1, and vj is vdt's predecessor whoseCCA is minimal in the set of predecessors withmaximal sum of RCA and CCA. And vi is defined thesame as(2). There are two situations. (a) If vi is theother unscheduled predecessor of Vdt, because ofRCA(vj) + CCA(vj) - RCA(vdt)> RCA(vi) + CCA(vi)- RCA(vdt), the Vdt can be considered as the fictitiousexit node. Thus, vj is the task with the minimal CCAwhich is located on the CP of DAG formed with allunscheduled tasks from entry node to Vdt. The problemmay convert to (2). (b) If vi is not the unscheduledpredecessor of Vdt, the scheduling time of Vdt can not bereduced, Thus SLst >SLdy. w

4.3 Resource selection and duplication phase

The resource selection phase of HDCPD is mainlybased on the task duplication and minimizing taskcompletion time strategy.

Most of the proposed task duplication basedalgorithms are only consider the duplication of singularpredecessor or the singular level of predecessors but donot consider the multi-level of predecessors. Thus, theycan not obtain the best result of duplication.

To overcome this drawback, more than oneimmediate predecessors and multi-level predecessorsare considered to be duplicated without increasing thecompletion time of certain task. However, if the multi-level predecessors are considered to be duplicatedfollowing the duplication of immediate predecessor ofvi, they may occupy the idle time slot so that the nextimmediate predecessor of vi can not be duplicated anymore. Thus, all immediate predecessors are consideredfirstly to be duplicated, then take turns to the multi-levelpredecessors.

The detail strategy of task duplication in this paperis: Assumed that vi is considered to be scheduled on Pnfirstly. According to the task duplication principle, thecritical predecessor of vi is duplicated on Pn. And then,the next duplication-task is chosen to be consideredafter updating all unscheduled predecessor of vi till allthe immediate predecessors are duplicated or thecondition of task duplication can not be satisfied. Then,only the critical predecessor can be considered to beduplicated when the level of the predecessor is largerthan one. Then the EFT(vi, Pn) can be calculated. Theminimum EFT of vi and corresponding resource can beobtained by traversing all resources. So the task will bescheduled on this resource.

Theorem 2: It is assumed that the strategy whichonly consider critical predecessor to be duplicated whenthe level of the predecessor is more than one can get theearliest finish time of the predecessor, and theduplication of immediate predecessors may not be

effected by the multi-predecessors. Then, the earliestfinish time of current scheduling task is optimal basedon our resource selection strategy.

Proof: DAG consists of two kinks of sub-structuresshown as Figure 1:

Figure 1. (a) joint task vi with k immediatepredecessors (b)fork task vi with k successors

Without loss of generality, the resource which thetask is assumed to be scheduled can be expressed by Pn.

(1) In the condition of Figure 1(b), vk has only oneimmediate predecessor vi. If vk is considered to bescheduled on Pn, vi and all of its critical multi-levelpredecessors will be duplicated on Pn following theduplication strategy, the earliest finish time of vk can becalculated and denoted as eft(pj,vk). After traversing allresource the minimum EFT value can be obtained aseftmm. Thus, there is not any other resource selectionsolution which can get the smaller completion time. Inother word, this strategy is optimal.

(2) In the condition of Figure 1(a), vi has kpredecessors. With out losing any generality, it assumesthat DAT(vi,p.,v1) > DAT(vi,pj,v2) > DAT(vi,pj,v3) > ...

> DAT(vi,pj,vk). It assumes that the number of allpossibly duplicated tasks is t ,where t predecessors mayinclude not only the immediate predecessors of vi butalso multi-level predecessors, the earliest computationtime of vi is EFTe(Vi,Pj) when the number of actuallyduplicated tasks is e. The predecessors must beconsidered to be duplicated following the descend orderof the data arriving time. (a). If O<e<k, it denotes thatall duplicated tasks are immediate predecessors of vi. Itcan deduct that:EFTe(vi,pj)=max{Pavai1j] e, DAT(vi,pj,ve 1)}+ETC(vi, pj).Then, problem can be transformed to prove formula 10:

EFT, (vi ,p ) < V(EFTs (vi ,p )) s E- (O, t) ( 10)Because e is the maximal number of duplicated tasks

based on the resource selection strategy, the formula 11and 12 can be deduced:

EFTe(vi,pj) < DAT(vi,pj,ve) + ETC(vi,p.) (11)EFTe+I(vi,Pj) > DAT(vi,pj,Ve+l) + ETC(vi,pj) (12)IfVs 1O<s<e, according to the duplication strategy

=> EFTe(vi,pj) < EFTs(vi,pj)And if Vs |e<s<t ,

> EFTe+i(vi,pj) = max{ Pavailb{]le, DAT(vi,pj,ve+2) }+ETC(vi,pj) > DAT(vi,pj, Ve+1) + ETC(vi,p.).El DAT(vi,pj,vj) >DAT(vi,pj,v2) > ... >DAT(vi,pj,Ve+l) >

DAT(vi,pj,Ve+2) >_.=> PavaibliI(e+l1) > DAT(vi,pj,ve+l)

VI) -- cl-o

vj

.Vi)

r',

Page 5: [IEEE 2007 2nd International Conference on Pervasive Computing and Applications - Birmingham, UK (2007.07.26-2007.07.27)] 2007 2nd International Conference on Pervasive Computing and

Pavaij{j] 1 < PavaiiU] 12 <.. < Pavai.i] e < PavaiU]Ue+±1 <

= EFTe+i(vi,pj) EFTe(vi,pj) > 0For the same reason,

EFTs(vi,pj) = max{Pavajjj]ls, DAT(vi,pj,vs+,)} +

ETC(vi,pj)> EFTs(vi,pj) > EFTe(vi,pj)l Vs le<s<t

(b)If k<e<t, it denotes that all immediatepredecessors are duplicated already. Assumed that thee-k multi-level predecessors are all the second levelpredecessors. Due to the duplication of all theimmediate predecessors of vi, the k tasks which are

located before vi on Pn are v1,v2,...,vk. In order to reducethe whole completion time, the completion time ofv1,v2,...,vk on Pn should be advanced in turn. Therefore,the critical predecessor of v1 is duplicated on Pn, and itmay lead to EFT1(vi,pj) < EFTk+l(vi,pj). And the restmay be deduced by analogy. According to theassumption, taking into consideration the multi-levelcritical predecessor of vi may lead to the minimumcompletion time of vi's critical predecessor. Thus, it candeduct that: EFTk+l(vi,pj)>EFTk+2(vi,pj)> . .. >EFTe(vi,pj).As well as EFTe(vi,pj)< EFT,+i(vi,pj)<..., thus it can

deduct that:EFTe(vi,pj) < V(EFT, (vi,pi )) s E (O, t)For the same reason, when the (e-k)-th predecessor

is located at the n-th level, the formula 10 is also true.The minimum value ofEFT can be obtained as eftm-m

by traversing all resources. And the result is optimal.

4.4 Detail of the HDCPD algorithm

The HDCPD scheduling algorithm is presented inFigure 2. Step 1 and 2 are the initialization of algorithm.According to the corresponding formula, all parameterscan be calculated by the depth first search algorithm.And the static CP of input DAG can be obtained by thedefinition. The time complexity of them is O(n*e),where e denotes the edge number of the DAG. The step3-13 will be repeated n times, where each iteration ofwhere loop is to complete the scheduling of certain task.At step 4, the selected task is fixed by dynamic CPstrategy. The time complexity of it is O(n*e+h), whereh is the height of DAG. At step 6, the earliest finishtime without task duplication can be obtained as

EFT(vdt,p.). The time complexity of it is O(n*e). Atstep 7, the earliest finish time with task duplication can

be obtained as EFTd(vdt,p11). The time complexity of it isO(n2*e). At step 8-10, if the smaller earliest finish timecan be obtained, the eft , and the corresponding Pdt are

fixed. At step 11, Vdt and its duplicated predecessors are

scheduled on the Pdt. At last, the parameters are updated,and the vdt is removed from the set of unscheduled tasks.Thus, the whole time complexity is O(n3*m*e).

Figure 2. HDCPD algorithm

5. Simulation results and discussion

In this section, in order to testify the performance ofHDCPD in schedule length and other evaluationcriterions, we present the comparative evaluation of our

algorithm and the algorithms in HC system presented inthe related work in section 2.

5.1 Metrics of performance comparison

The evaluation metrics of the simulation are definedas follows [2]:

Schedule Length Ratio (SLR). Since a large set oftask graphs with different properties is used, it isnecessary to normalize the schedule length. Thecomputation formula is defined by:

SLR = makespan (13)min E ETC(v1,p,)pEP ViE CPSWtiC

Speedup Rate (SUR). The SUR is defined as ratioof the sequential execution time obtained by allocatingall tasks to the resource which can complete all tasks inthe minimum completion time, to parallel executiontime of task scheduling. The computation formula isdefined by:

min E ETC(vi, pi)Speedup Rate = j ViEV

makespan(14)

5.2 Performance comparison and analysis

The performance of the four algorithms mentionedbefore were compared and analyzed. The first set ofsimulations compares the performance of SLR andSpeedup Rate in the situation that the value of CCR is1.0. Figure 3 shows that the more the size of DAG themore the average SLR of all algorithms is. However,the SLR of HDCPD is smaller than any otheralgorithms. Figure 4 shows that the more the size ofDAG the more the average Speedup Rate of allalgorithms is. And the Speedup Rate of HDCPDoutperforms other algorithms all the time.

HDCPD_ alotlihm(1. Accofiding to the inlput inoruation about the taskDAG, calcuilate corespouding EST,EFT.lRCA.,CCA ofall tasis2 Calcuilate the staric critical path of the tass DAG3 'where niot all tasks are schedLled do4. Calculate tle ltrrent dynamnic criticali path and

fiand out the dominant task vd lider onur tasnkselectioi1 stratem

5. For alIresovurcep in P6. Calculate the milInlumu coipletion time without

task duplication as EFT(dv iCalculate the n inimum conlpletion timne uncderru task d-i plication strategy as EFTd(. pnY

S. If(ain(EFT(xd p) EFTd(ydr Pi)) -efe

9. eft = gin(FT(vd p,) . EFTdx p.))10. t ;0 Pdt =1P½11. Allocate x7d' alid its duplication task on p12. Lpdate the readly set and otlier paraietel13. Remove v filn tle set of unschedu.led tasksVEid I d

Page 6: [IEEE 2007 2nd International Conference on Pervasive Computing and Applications - Birmingham, UK (2007.07.26-2007.07.27)] 2007 2nd International Conference on Pervasive Computing and

* HDCPD DCPD El LDBS HEFT DAGSi.

Figure 3. Average SLR with respect to DAG size

| 0 HDCPD DCPD 1:1 LDBS E HEFT DAG Size

Figure 4. Average speedup rate with respect toDAG size

| -HDCPD DCPD 0 LDBS HEFT CCR

Figure 5. Average SLR with respect to CCRThe second set of simulations compares the SLR

performance with respect to different CCR value in thecondition that the size of DAG is 200, and the scheduleresults are shown in Figure 5. It indicates that the morethe CCR value the more the average SLR of allalgorithms is meanwhile SLR ofHDCPD is the smallerthan any others..

We count the number of times that HDCPDalgorithm produced better, equal and worse schedulelength compared to every other algorithm in Figure 6.

DCPD HCNF LDBS HEFT coiiibiJili

Bete rHDC9XPX Ecal 69 30 13 <31%

Wore 2221, 1865 1495 157 21%

Figure 6. Comparison between HDCPD and otheralgorithms

6. Conclusion and future works

Effective task scheduling is important to achievehigh performance in pervasive computing system.Several proposed DAG based scheduling algorithms are

analyzed in this paper. According to their drawbacksand the attribute of pervasive computing environment,the task scheduling sequence can be obtained by usingdynamic critical path strategy. And in task duplication

part, not only the singular critical predecessor but alsothe multi-immediate predecessors and multi-levelpredecessors should be considered to be duplicated.This can lead to the complete duplication of the certaintask. The simulation results also indicate that ourpresented algorithm can outperform other algorithms atthe criterion of SLR and Speedup Rate. The futureworks will be focus on the services selection inpervasive computing environment.

Acknowledgement

This work is supported by National Natural ScienceFoundation of China under Grants No. 90412014 and90604004, and Jiangsu Provincial Key Laboratory ofNetwork and Information Security under Grants No.BM200320 1.

References

[1] M. Weiser. The computer of the 21st century[J]. ScientificAmerican, 1991, 265(3):66-75..[2] H. Topcuoglu, S. Hariri. Performance-Effective andLow-Complexity Task Scheduling for HeterogeneousComputing. IEEE Trans. Parallel and Distributed Systems,Vol. 13, No. 3, pp. 260-274, March, 2002.[3] E. Ilavarasan, P. Thambidurai. Performance Effective TaskScheduling Algorithm for Heterogeneous Computing System.Proceeding pf the 4th International Symposium on Paralleland Distributed Computing(ISPDC '05),2005.[4] S. Bansal, P. Kumar. An Improved Duplication Strategyfor Scheduling Precedence Constrained Graphs inMulti-processor Systems. IEEE Trans. Parallel andDistributed Systems, Vol. 14, No. 6, pp. 533-544, June, 2003.[5] S. Baskiyar, P. SaiRanga. Scheduling Directed A-cyclicTask Graphs On Heterogeneous Network of Workstations toMinimize Schedule Length. Proceeding of the 2003International Conference on Parallel Processing Workshops(ICPPW'03), 2003.[6] A. Dogan, F. Ozguner. LDBS: A Duplication BasedScheduling Algorithm for Heterogeneous Computing Systems.Proceeding of the International Conference on ParallelProcessing(ICPP'02), 2002.[7] Y.K. Kwok, I. Ahmad. Dynamic Critical-Path Scheduling:An Effective Technique for Allocating Task Graphs toMulti-processors. IEEE Trans. Parallel and DistributedSystems, Vol. 7, No. 5, pp. 506-521, May, 1996.[8] M. I. Daoud, N. Kharma. Efficient Compile-Time TaskScheduling for Heterogeneous Distributed ComputingSystems. Proceedings ofthe 12th International Conference onParallel and Distributed Systems(ICPADS'06), 2006.[9] C.H. Liu, C. F. Li. A dynamic Critical Path DuplicationTask Scheduling Algorithm for Distributed HeterogeneousComputing Systems. Proceedings of the 12th InternationalConference on Parallel and Distributed Systems(ICPADS'06),2006.[10] C.I. Park, T. Y. Choe. An Optimal Scheduling AlgorithmBased on Task Duplication. IEEE Trans. Parallel andDistributed Systems, Vol. 51, No. 4, pp. 444-448, April, 2002.