Scheduling Independent Tasks

Setup: We are given n tasks, numbered 1, 2, ..., n, with running times t1, t2, ..., tn respectively, and m processors. We would like to schedule all n task on the m processors so as to minimize the finish time of the last job.

We will see two heuristics methods for solving this problem.

List Schedule

A simple strategy is to assign the jobs sequentially, each job going to the processor that has the smallest load at that time.

e.g. Suppose we have 6 tasks with running times 10, 5, 4, 11, 3, 5, and 2 processors. Using to the list schedule heuristic, we get:

1	t1 = 10	t5 = 3	t6 = 5	
2	t2 = 5	t3 = 4	t4 = 11

Using list scheduling, we get 2 units of idle time on processor 1.

Note that the optimal schduling is

1	t1 = 10	t2 = 5	t3 = 4	
2	t4 = 11	t5 = 3	t6 = 5	

The optimal scheduling leaves no idle time on either processor, and finishes one time unit earlier. We look at performance by considering the ratio between the schedule finish time of the list schedule and the optimal schedule.

Let tLIST denote the length of the list schedule (where the length is the finish time of the last job).

Let tOPT denote the length of the optimum schedule.

Then,

Now, suppose we were given the tasks in a different order, say 10, 5, 5, 4, 3, 11. Using the list schedule heuristic, we now get

1	t1 = 10	t4 = 4	
2	t2 = 5	t3 = 5	t5 = 3	t6 = 11

Processor 1 now has 10 units of idle time, and the finish time of the last job is 24 units of time. For this particular sequence, the performance compared to the optimal is

We would like to know something about how well list schedule performs in general.

Theorem 1

For an independent task scheduling problem with m processors, the length tLIST of the schedule obtained by the list schedule heuristic satisfies

Proof

Let t be the running time of the last job to finish in the list schedule. Before time tLIST – t, all processors must be busy, otherwise the job would have been scheduled earlier. So, up until time tLIST – t, none of the processors were idle at any time. So,

(1)

Also, the optimum scheduling can never be better than the total time taken by all the tasks, divided by the number of processors available. That is,

Plugging into (1), we get

We also know that the length of any schedule, including the optimum, must be at least as long as the length of any task, so

Plugging into (2), we get that



This bound is actually a tight upper bound. Consider the case with m = 6 processors and 11 tasks with running times 5, 5, 5, 5, 5, 1, 1, 1, 1, 1, 6, given in that order.

Then list schedule will give us

1	5	6
2	5	
3	5	
4	5	
5	5	
6	1	1	1	1	1	

Clearly the optimum schedule has length 6, and so we get that

List Decreasing

We can note looking at examples above that we seem to get poorer results when we finish on very long jobs. In the last example, the fact that we kept 6 for last caused our solution to be rather suboptimal.

This observation leads to the list decreasing heuristic: given n tasks with running times t1, t2, ..., tn, we sort the tasks by decreasing runtime to get t1  t2  ...  tn, and then apply the list schedule heuristic as described above.

Lemma

Ifthen the list decreasing heuristic finds the optimum schedule, i.e.

Proof

Exercise.

Theorem 2

For an independent task scheduling problem with m processors, the length tLIST of the schedule obtained by the list schedule heuristic satisfies

Proof

First, we will assume that job n finishes last. We have two cases

By the lemma above, we know that

(3)

As shown in the proof of theorem 1, in equation (2), we have

where t is the last job to finish, in this case tn. Plugging in (3), we get

Note that if it is not the case that tn finsihed last, then we may remove it from the list without changing the finish time of the list schedule. We continue to remove jobs until the last job in the list does finish last, and then apply the same proof detailed above.



2005-11-25T21:52:24