0% found this document useful (0 votes)
42 views8 pages

MIP Formulation For Robust Resource Allocation in Dynamic Real-Time Systems

Uploaded by

Junliang Chen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
42 views8 pages

MIP Formulation For Robust Resource Allocation in Dynamic Real-Time Systems

Uploaded by

Junliang Chen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

MIP Formulation for Robust Resource Allocation in

Dynamic Real-Time Systems

Sethavidh Gertphol and Viktor K. Prasanna


University of Southern California
Department of EE-Systems
Los Angeles, CA 90089-2562 USA
fgertphol, [email protected]

Abstract the task must be completed. Violating these real-time re-


quirements might cause catastrophic effects on the system.
Real-time systems usually operate in an environment that When the status of the environment changes causing
changes continuously. These changes cause the perfor- workloads of some tasks to increase, those tasks may vi-
mance of the system to vary during run time. An allocation olate their deadline and the current resource allocation be-
of resources in this environment must be robust. Using the comes invalid. In order to sustain the system in the current
amount of load variation that the allocation can accommo- status, dynamic re-allocation is often used to re-assign re-
date as a measure of robustness, we develop a mathematical sources to tasks. However, determining a new allocation
formulation for the problem of robust resource allocation. and performing re-allocation consumes time and resources.
Due to the complexity of the models used to represent the Since re-allocation is usually needed when tasks lack ade-
problem, the formulation is non-linear. We propose a lin- quate resources, an overhead is incurred when the system
earization technique based on variable substitution to re- can least afford. To avoid the cost of early re-allocation,
duce the mathematical formulation to a mixed integer pro- resource allocation techniques that consider workload vari-
gramming formulation, called SMIP. Compared with exist- ation during run time have been recently developed [1, 6, 7].
ing techniques, the search space of SMIP is not restricted. The allocation generated by these techniques will be robust
Thus, if a feasible allocation exists, SMIP will always pro- with respect to changes in the environment during run time.
duce an optimal allocation. Task allocation in real-time systems in order to meet certain
deadlines is known to be an NP-hard problem [8]. In [6],
Keywords: dynamic real-time systems, resource alloca- a mathematical programming formulation is developed to
tion, robust, mixed integer programming, linearization. represent the resource allocation problem. The formula-
tion is non-linear, but can be linearized into a mixed integer
1 Introduction programming (MIP) formulation by pre-selecting the num-
ber of tasks running on each machine. The quality of the
Recent developments in dynamic real-time systems such resulting resource allocation depends largely on these pre-
as embedded systems result in widespread deployment of selected numbers. If the pre-selected numbers match the
these systems in various application domains [3]. The op- number of tasks running on each machine in an optimal al-
erating environment, where dynamic real-time systems are location, the resulting allocation will also be optimal. On
deployed, is continuously changing. Changes in the envi- the other hand, if the numbers are selected poorly, such as
ronment often affect performance of these systems. For ex- where all tasks are allocated to the same machine, the mixed
ample, changes in the environment may cause an increase integer programming formulation may not have a feasible
in workload of some application tasks, resulting in degraded solution.
performance of those tasks. Another important characteris- In this paper, a method to linearize the mathematical for-
tic of these systems is the real-time requirements imposed mulation is proposed. This method is based on a technique
upon application tasks. The requirement is often expressed of variable substitution and constraint addition in [11]. Be-
in terms of task deadline, i.e., the amount of time in which cause this method does not rely on pre-selection of any
 This research was supported by the DARPA/ITO Quorum Program number, the resulting allocation is guaranteed to be optimal.
through the Office of Naval Research under Grant No. N00014-00-1-0599. The experimental results show that the substitution method

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
generates an allocation that is 1.25 times better than the al- non-linear equations are linearized. On the other hand,
location produced by the pre-selection technique. The exe- in this paper, variable substitution and constraint addition
cution time of the mixed integer programming formulation, technique derived from [11] is used to linearize the formu-
which is linearized by the substitution technique, is accept- lation instead.
able for the problem of initial resource allocation. Through-
out this paper, we use the words resource allocation and 3 Problem Definition
initial resource allocation interchangeably.
This paper is organized as follows. A brief discussion In this section, system and application models are briefly
about related work is presented in Section 2. Section 3 ex-
explain. For more detail discussion, please refer to [6].
plains the system and application models used in this pa-
per. A novel performance metric to evaluate a resource al-
3.1 System Model
location for its capability to accommodate changes in the
environment is also discussed. A formal mathematical for-
We consider a system consisting of s multitasking-
capable machines, represented by a set M
mulation of the resource allocation problem is described in
=
Section 4. The need for linearization and two linearization
techniques are explained in Section 5. Experiments and re-
fm1; : : : ; ms g. Each machine is connected to a net-
work switch via a full-duplex communication link. The
sults follow in Section 6. Finally, Section 7 gives conclusion
capacity of the communication links may be different.
and outlines future work.
Such a system (shown in Figure 1) consists of sensors,
actuators, and processing tasks. The sensors continuously
2 Related Work send information about the environment to the tasks. These
tasks process the data from the sensors and issue commands
Many algorithms and heuristics [9, 12, 13, 14] have been to the actuators.
developed to solve the problem of resource allocation in
dynamic real-time systems. Most of these resource allo- 3.2 Application Model
cation techniques do not consider the changing environ-
ment in which the system operates. Many heuristics allo- The set of processing tasks in real-time systems is mod-
cate resources such that the amount of workload is balanced eled using the asynchronous dataflow (ASDF) process net-
(evenly distributed) among all resources. These heuris- work [10]. Each task in the ASDF process network has as-
tics implicitly assume that future workload variation will sociated with it a firing rule, which determines when a task
be the same for all tasks or resources, which is an over- starts execution based on the availability of its inputs. How-
simplification. ever, the ASDF process network does not specify any real-
Recently, several resource allocation heuristics that ex- time requirements or parameters that can vary at run time.
plicitly consider workload variation during run time have We extend the ASDF process network to capture the varia-
been developed [1, 6, 7]. Heuristics presented in [1] are tions of run-time parameters as well as to associate real-time
based on a Greedy approach, while in [6] a mixed-integer- requirements with a task or a group of tasks.
programming-based (MIP-based) heuristic is used. Note
that the objective function in the mixed integer program- Run-time parameters
ming formulation in [6] is similar to an objective value Changes in the environment during run time are captured
called “system hazard” in [12]. The difference is that the in parameters called run-time parameters. In this paper,
MIP-based heuristic explicitly considers workload variation load level of a processing task is considered to be a parame-
in mathematical equations constituting the objective func- ter that changes during run time. For every processing node
tion, while the “system hazard” is calculated with no ex- that receives data, exactly one incoming edge is set to be a
plicit assumption about changing workload. primary edge (dark, solid edges in Figure 1). Let EP be the
Mixed integer programming is a subset of a well- set of all primary edges. The amount of data that a task re-
researched optimization technique called linear program- ceives from its primary edge can vary during run time. The
ming (LP). Linear programming has been used exten- load level of task ai , denoted as li , is a scalar value that
sively in various fields of research, such as Operation Re- represents the data that task ai receives through its primary
search [11], economics [4], and resource allocations [6, 13]. edge.
As the name suggests, variables in mathematical equations Let vector L denote the load level of all tasks, with Linit
constituting the objective function and constraints of LP denoting the initial load level. Data arriving from non-
must be in linear form. However, linear programming for- primary edges (gray, dashed edges in Figure 1) is used for
mulation of many problems contains non-linear equations. information updating (e.g., updating the internal database of
In [6], by pre-selecting the values of one set of variables, the task). This is considered to consume some CPU cycles

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
where the load levels on the primary edges determine the
performance of the system, in this study, the intercept is
sensors ASDF process network actuators assumed to be zero for each task. An estimated-time-to-
2 c(K)ommunicate-function matrix, etkf , gives a function for
1
3 X
each task-machine pair (ai , ml ) that maps li to an estimated
communication time for task ai from machine ml to the
A 4 network switch. The size of the etkf matrix is also jAj 
jMj. Similar to the etcf matrix, each entry in the etkf
5

6 8 Y
matrix is assumed to be a linear function of the load level
7
B
on the primary edge of a task, with a positive slope and an
intercept that equals zero.
9 10
11 Z
Worst-case resource sharing model
Given the current load level of a task, the task compu-
source node primary edge sensor and actuator tation and communication latencies can be calculated using
the etcf and etkf matrices. These latencies are called base
communication
sink node non-primary edge primary route
latencies, or the latencies of a task when resources are not
shared. When multiple tasks compete for the same resource,
Figure 1. An example sensor-actuator net- it is assumed that the resource is fairly shared among those
work tasks. Thus, the actual latencies — the latency of a task
when a resource is shared — is calculated as the base la-
independent of the load level of a task. A task starts exe- tency multiplied by the number of tasks competing for that
cution only after it receives data from its primary edge. In resource. This resource sharing model assumes a worst-
the ASDF terminology, the firing rule of a task can be stated case scenario where all tasks attempt to utilize the resource
as: a task fires (starts execution) only when data is received at the same time. Note that the actual latency of a task de-
from the primary edge. pends on both its load level, which can vary due to changes
in the environment, and on the current resource allocation.
Run-time parameter variation This model will be referred to as the worst-case resource
If we allow run-time parameters to vary independently of sharing model throughout the paper.
one another, there will be too many possibilities of the run-
time parameter variations. Thus, we assume that there is Real-time requirements
a run-time parameter, called , which governs the changes In this paper, two types of real-time requirements are
in the load level of all the tasks. During run time, the load considered. A task ai , where ai 2 A, may be associated
level of a task varies according to the changes in and its with a throughput requirement, T HREQi. That is, the out-
initial load level. Mathematically, li = (1 + )  liinit , for put data rate of task ai is required not to be slower than its
all ai 2 A. Note that when the system starts up, is equal throughput requirement, T HREQi . Also, a primary route
to zero, and the current load level of each task is equal to its rk from one sensor to one actuator may be associated with
initial load level. an end-to-end latency requirement, LREQk . That is, the
The changes in the load level of a task are reflected in the time between the sensor sending data out and the actuator
variation of its computation and communication latencies. receiving a message resulting from the processing of that
An estimated-time-to-compute-function matrix, etcf , gives data cannot exceed LREQk . Let LREQ and THREQ be
a computation latency function for each task-machine pair vectors that represent all latency and throughput require-
(ai , ml ) that maps li to an estimated computation time of ments, respectively. Also let R be a set of all primary routes.
ai on ml . The size of the etcf matrix is jAj  jMj. For
this study, each entry in the etcf matrix, etcfi;l , is assumed 3.3 Performance Metric for Robustness
to be a linear function of the load level on the primary edge
of task ai , with a positive slope, etcfi;l
a
, and non-negative To avoid early re-allocation, the resource allocation must
intercept, etcfi;l . The slope determines the rate at which
b
be robust with regard to changing conditions of the environ-
the estimated computation latency varies with respect to the ment. One way to measure the robustness of the system is
variation of the load level on the primary edge of the task to vary workload and determine the point at which the sys-
during run time. The intercept determines the CPU time tem violates real-time requirements. As discussed in Sec-
overhead for a task to process the data arriving from its non- tion 3.2, a run-time parameter governs the variations of
primary edges. Because we are interested in those cases all task workload. Thus, the amount that can vary can

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
be used as a performance metric for an allocation. When occurs twice, the actual communication latency takes into
varies, the load level of each task also varies, resulting account the communication link contention in both direc-
in the changes in the computation and communication time tion: from a switch to a machine, and from a machine to
of each task. However, the computation and communica- a switch. Note that the mathematical formulation for ini-
tion time of a task must conform with specified real-time tial resource allocation (Figure 2) is still valid even if other
requirements. Thus, the allowable variation of is lim- models are used to calculate the actual latency of tasks.
ited by real-time requirements. Let max be the maximum However, the formulation may not be reducible to an MIP
value of , under the condition that there is no deadline vi- formulation by using the linearization techniques presented
olation. max depends on real-time requirements and the in Section 5.
resource allocation of the system. Thus, we can use max pk , the actual end-to-end latency of a PR rk is
of an allocation as a performance metric. This specific per-
P
formance metric is called MAIL, Maximum Allowable In- p k = ai 2 k fc + k g
r i i
crease in Load level.
Given a task ai , its throughput requirement is satisfied
4 Mathematical Formulation when both its computation latency and communication la-
tencies do not exceed the reciprocal of its throughput re-
A mathematical formulation for the problem based on quirement. Mathematically,
our model is described in this section. An objective func-
1
tion is defined, which leads to an optimal MAIL value un- max (ci ; ki ) 
der some assumptions. However, the formulation contains T HREQ i

non-linear equations. By using a linearization heuristic, the


formulation is reduced to a mixed integer programming for- Given a primary route rk 2 R, its end-to-end latency
mulation. requirement is satisfied when the actual latency does not
Let X be a matrix that represents an allocation of tasks exceed its requirement. Mathematically,
onto machines such that
 p  LREQ
1 if ml is allocated to ai
k k

x i;l =
0 otherwise
4.2 Normalized Slackness
where ai 2 A and ml 2 M. A task can be allocated to
only one machine. Consequently, for any task ai , there is
Let nsci be the normalized computation slackness of
exactly one xi;l that is equal to 1 for all ml 2 M. Given an
task ai . It is calculated as:
allocation, let nl be the total
P number of tasks that execute
on machine ml , i.e., nl = ai 2A xi;l . c
nsc =1
i

1=T HREQi
i

4.1 Latencies and Requirements


Similarly, nski , the normalized communication slack-
The actual computation latency of task ai for the initial ness of a task ai is defined as:
load level, denoted ci , can be calculated as
k
X  nsk =1
i

1=T HREQi
i

ci = x i;l  etcf  l  n
a
i;l i l

ml 2 M
For a route rk 2 R, the normalized slackness is
Assume that communication of a task occurs twice for p
each computation: receiving data from the network, and nsr =1
k

sending results back after computation. The actual com-


k
LREQ k

munication latency of task ai , ki , is


Conceptually, the normalized slackness represents, as a per-
X 
k =2 x  etkf  l  n
a centage, the slack or available room for the latency of a task
i i;l i;l i l
or a route to increase, before the throughput and/or end-to-
ml 2 M
end latency requirement is violated. Note that an alloca-
Both the actual computation and communication laten- tion satisfies all performance requirements iff the normal-
cies are calculated based on the worst-case resource sharing ized slackness for all tasks and all primary routes is non-
model. In addition, by assuming that task communication negative.

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
1. Select nl , for all ml 2 M, by using a heuristic.
Given: M; A; E ; etcf; etkf; L ; R;
P
init
2. Solve the following mixed-integer-programming formu-
LREQ; T HREQ lation:
Find: X; c
to Given: M; A; E ; etcf; etkf; L ; R;
P
init

Maximize: c LREQ; T HREQ; N


Subject to: c  nsc i ; 8a i 2A Find: X; c
c  nsk 8a 2A to
i ; i
Maximize: c
c  nsr ; 8r 2R Subject to: c  nsr ; 8r 2R
X k k

8a 2A
k k
x =1
i;l ; i
c  nsc ; 8a 2A
2M i i

c  nsk 8a 2A
m
;
l

X i i

x =1
i;l ; 8a i 2A
Figure 2. Mathematical Formulation ml 2M
X
x =n
i;l l ; 8m 2 M l

4.3 Objective Function a


i 2A

Given an allocation, let Figure 3. MIP(*) Approach


c = minf min nsr ;
min
rk 2R k

min nsci ; product of two variables is replaced with one auxiliary vari-
ai 2A able, with additional constraints introduced. The following
min nski g two subsections describe both methods.
ai 2A
It was shown in [6] that the allocation that gives the high- Pre-selection
est value of cmin among all allocations will also result in the To linearize the formulation, the number of tasks allo-
highest value of max . Thus, we can use cmin as the ob- cated onto a machine is pre-selected using a linearization
jective function for maximization, instead of trying to find heuristic. The numbers are specified as a vector N , where
max directly.
nl is the pre-selected number of tasks on machine ml . An
The mathematical formulation of the resource allocation example of a heuristic used to select nl values in a heteroge-
problem is shown in Figure 2. The auxiliary variable c is neous system, called capability-based heuristic (CBH), can
a real number, while xi;l , an entry in X , is either 0 or 1. be found in [5]. This technique will be referred to as the
The objective is to maximize c, but c is limited by the first pre-selection technique throughout the paper.
three constraints corresponding to the normalized slackness The problem can now be formulated using mixed integer
of all tasks and primary routes. The last set of constraints programming, as shown in Figure 3. The main differences
enforces a task to be allocated to only one machine. Af- between Figure 2 and Figure 3 are: i) the N vector is given
ter solving the formulation, the auxiliary variable c will be as an input, and ii) additional constraints (the last set) are
equal to cmin . Furthermore, X will represent a resource al- introduced to force the actual number of tasks on each ma-
location that gives the highest value of cmin and thus the chine to be equal to the pre-selected number. The approach
highest value of max . is called MIP(*), where * is substituted by the name of the
heuristic used to pre-select the nl values. Thus, if CBH is
used to pre-select the nl values for the mixed integer pro-
5 Linearization Techniques gramming formulation (in step 1 of Figure 3), the entire
approach will be called MIP(CBH).
Direct mathematical formulation of the problem shown
in Figure 2 contains non-linear equations. Specifically, to Variable substitution
calculate nsci , nski , and nsrk , two variables
P xi;l and nl are In the pre-selection method, the search space of the lin-
multiplied together. Recall that nl = ai 2A xi;l . In [6], earized MIP formulation is limited to the allocations with
the mathematical formulation is linearized by pre-selecting the actual number of tasks on each machine equal to the pre-
nl value for each machine ml . In this P paper, the variable selected value. This limitation is mathematically described
xi;l is multiplied into the summation ai 2A xi;l . Then the as the last set of constraints shown in Figure 3. The qual-

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
ity of the resulting allocation depends largely on the pre- mance of our resource allocation techniques. Given an allo-
selected number of tasks allocated onto each machine. If cation, the simulator calculates the actual computation and
these pre-selected numbers are equal to the actual number of communication latencies of a task using the equations pre-
tasks on each machine of the optimal solution, MIP(CBH) sented in Section 4. If all real-time requirements are satis-
will also produce an optimal solution. On the other extreme, fied, the normalized slackness values of all tasks and pri-
if these pre-selected numbers are unreasonable (e.g., if all mary routes are calculated, which consequently determine
tasks are allocated to the same machine), it is very likely cmin . The max value for this allocation can then be calcu-
that MIP(CBH) cannot find a feasible allocation at all. lated using the equation max = 1 cmin cmin
.
By using the pre-selection method to linearize the MIP
formulation, the resulting allocation will not be a “globally”
optimal allocation. Feasible allocations with the numbers of 6.1 Problem Generation
tasks on each machine different than the pre-selected num-
bers will not be considered to be valid solutions, even if The etcf and etkf matrices were generated to capture
they provide better results (higher max values). In order the machine and task heterogeneities [2]. Specifically, each
to consider these allocations, other linearization techniques matrix was characterized by two parameters: machine het-
that do not restrict the number of tasks allocated to each ma- erogeneity and task heterogeneity. Both heterogeneities can
chine must be used. One way to linearize the formulation is be modeled as “Hi” or “Lo.” Gamma distributions were
by replacing the product of two variables with one auxiliary used to generate the matrices. Due to time limitation, the
variable, together with additional constraints. experiment was conducted only in Hi-Hi (high machine and
Mathematically, high task heterogeneity) environment. Each element in vec-
x i;l x c j;l
tor Linit is generated by sampling a uniform distribution of
values ranging from 10 to 100.
where x and x are binary (0-1) variables, i 6= j , and
i;l j;l For each task, the average values of its computation and
c is some constant, can be replaced with communication latencies over all machines were calculated
y c i;j;l
from the etcf and etkf matrices and the Linit vector. For
each PR, the sum and the maximum value of these average
where yi;j;l is also a binary variable, with additional con- values of all nodes along the route were calculated, denoted
straints as s and m, respectively. Let n  l be equal to jAj=jMj. The
y i;j;l x i;l 0 end-to-end latency requirement of the PR was then set to
s  n l  f . f is a specified factor that is used to adjust the
y i;j;l x j;l 0 tightness of the constraints. The throughput requirement
x +x
i;l j;l y i;j;l 1 of each task along the PR was set to be 1=(m  n  l  f ).
Due to space limitations, we emphasized only computation
Note that if i = j , then no substitution is needed. Also, intensive applications – the average communication latency
yi;j;l and yj;i;l represent the same product, and thus only for each task is around 1/100 of its average computation
one auxiliary variable is used. This technique is a special latency.
case of a technique shown in [11].
In mathematical formulation of the resource allocation
problem, two variables, xi;l and nl , are
P multiplied together. 6.2 Other Heuristics for Comparison
However, nl can be expanded into ai 2A xi;l . Thus, the
linearization technique described earlier can be used. In ef-
fect, jAj jAj2
2  jMj additional variables and 3  2  jMj
2 We also implemented two other approaches to solve the
resource allocation problem called Min-Min and Greedy.
additional constraints are introduced into the formulation. The Greedy heuristic maps tasks in a random order, and
This specific linearized MIP formulation is not restricted by each task is mapped onto the machine that gives the short-
any pre-selected numbers of tasks on each machine. Thus, est computation and communication latency based on the
solving the formulation will produce a “globally” optimal mapping information so far. The Min-Min heuristic ranks
allocation. This formulation will be referred to as SMIP tasks using their computation and communication laten-
throughout the paper. cies on the best machines, then allocates the tasks in or-
der. In both approaches, the computation and communica-
6 Experiments and Results tion latencies are calculated while considering multitasking
of tasks. max of the resulting allocations from these two
A simulator based on the mathematical formulation pre- approaches is compared with max of the allocations given
sented in Section 4 was developed to evaluate the perfor- by MIP(CBH) and SMIP.

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
MAIL value from various approaches in Hi-Hi machine-task Execution time of various approaches in Hi-Hi machine-
heterogeneity environment task heterogeneity environment
120 2500
eu
alv 100
la n) 2000
oti
tim
po rae 80
fo m SMIP s 1500
d Enumeration
un 60 MIP(CBH) n
%
sa eby Min-Min o
c
SMIP
e MIP(CBH)
(e d Greedy s 1000
ual nu 40
v fo
LI 20 500
AM
0 0
3 4 5 3 4 5
number of machines number of machines

Figure 4. The average MAIL value of alloca- Figure 5. Execution time of each approach
tions from each approach

the number of machines in the experiment increase, and is


provided as the baseline for comparison. SMIP’s execution
6.3 Experimental Procedure time also increase with the number of machines, but not
as quickly as enumeration’s. SMIP takes longer to execute
The experiment is divided into 3 sets, each with 40 prob- than enumeration in small problems (3 and 4 machines),
lem instances. A problem instance in each set is generated but when the problem becomes larger, the execution time
with 12 processing tasks (3 sources, 3 sinks, out-degree of enumeration increases rapidly, overtaking the time used
 2). The number of machines varies from 3 to 5 be- by SMIP. For example, to determine an allocation for a sys-
tween sets. The f (tightness of constraint) factor is set tem with 5 machines, SMIP takes 500 seconds on the av-
to be 1.5 for all problem instances. For each problem in- erage , compared with 1900 seconds used by enumeration.
stance, an optimal allocation that results in the highest max MIP(CBH) is very fast, using less than 1 seconds in all 3
value was found by enumerating all possible allocations. experiment sets (3, 4, and 5 machines).
Then, the problem is solved using 4 different approaches: From Figure 4, SMIP is obviously the best approach; it
SMIP, MIP(CBH), Greedy, and Min-Min. SMIP is a mixed- always provides allocations with the optimal MAIL value,
integer-programming-based approach, which is linearized and is 1.25 times better than allocations from MIP(CBH).
using the variable substitution technique. MIP(CBH) is also The execution time of SMIP is also acceptable for an initial
a mixed-integer-programming-based approach, but is lin- allocation problem. MIP(CBH) runs very fast and produces
earized by pre-selecting nl values using the CBH heuristic. relatively good results. It is a possible alternative approach
The MAIL value of the resulting allocation from each ap- when the size of the problem becomes huge or for run-time
proach is then compared with the optimal value found by resource re-allocation.
enumeration. In every problem instance, the execution time
of each approach including enumeration, is also recorded. 6.5 Discussion

6.4 Results MIP(CBH) can be regarded as a two-phase approach.


The first phase allocates resources on a machine-level ba-
Figure 4 shows the average MAIL value (as a percent- sis by using the CBH heuristic to pre-select the number of
age of the optimal value found by enumeration) of the al- tasks to be allocated onto each machine. The second phase
locations produced by each approach. As expected, SMIP utilizes the mixed integer programming optimization tech-
(MIP-based approach, using substitution technique for lin- nique to match tasks to machines to maximize cmin , given
earization) always produces an allocation with the optimal the pre-selected number from the first phase. From this re-
MAIL value. Allocations given by the MIP(CBH) approach spect, the actual allocation of resources is determined in the
has MAIL value around 80% of the optimal value on the av- first phase; the MIP formulation in the second phase is used
erage. Min-Min and Greedy generate allocations with the only to optimize the allocation. The resulting allocation
average MAIL value around 55% and 50% of the optimal will be optimal, only if the pre-selected numbers equal the
value, respectively. number of tasks on each machine of an optimal allocation.
Figure 5 shows the average execution time of enumer- However, it is possible that the pre-selected numbers will
ation, SMIP, and MIP(CBH) on a system with a 400MHz constrain the MIP formulation such that there is no feasi-
Ultrasparc-II processor and 1GB of main memory. The ex- ble allocation. We can show the following result. Detailed
ecution time of enumeration increases very rapidly when proof can be found in [5].

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.
Theorem 6.1 For all t  2, where t is the number of an engine control unit. In 35th Annual Conference on
tasks to be allocated, there are problem instances for which Design automation, pages 804–807, June 1998.
MIP(CBH) fails to find a resource allocation that satis-
fies all performance requirements, while SMIP succeeds (in [4] R. Dorfman, P. A. Samuelson, and R. M. Solow. Lin-
finding a feasible allocation). ear Programming and Economic Analysis. McGraw-
Hill, 1958.

7 Conclusion and Future Work [5] S. Gertphol and V. K. Prasanna. Robust resource allo-
cation techniques in dynamic real-time systems. Tech-
This paper developed a variable substitution technique nical report, Department of EE-Systems, University of
to linearize the mixed integer programming (MIP) formu- Southern California, 2003. in preparation.
lation for robust initial resource allocation in dynamic real- [6] S. Gertphol, Y. Yu, S. B. Gundala, V. K. Prasanna,
time systems. It was then compared with an existing lin- S. Ali, J.-K. Kim, A. A. Maciejewski, and H. J. Siegel.
earization technique based on pre-selection. Because the A mixed-integer-programming-based approach for re-
substitution technique does not restrict the search space of source allocation in dynamic real-time systems. Tech-
the MIP formulation, it guarantees to find an optimal allo- nical report, The University of Southern California,
cation. It will also find a feasible allocation, if one exists. 2002, in preparation.
The execution time of the MIP formulation linearized by
the substitution technique is also acceptable for the prob- [7] T. Hegazy and B. Ravindran. Using application ben-
lem of initial resource allocation. On the other hand, the efit for proactive resource allocation in asynchronous
pre-selection technique is fast but limits the search space of real-time distributed systems. IEEE Transactions on
an MIP formulation to allocations with the number of tasks Computers, 51(8):945 – 962, August 2002.
on each machine equal to the pre-selected numbers. Thus,
[8] O. H. Ibarra and C. E. Kim. Heuristic algorithms for
it may provide sub-optimal results and may fail to find ex-
scheduling independent tasks on nonidentical proces-
isting feasible allocations.
sors. Journal of the ACM, 24(2):280–289, Apr. 1977.
The short-coming of the pre-selection technique lies in
the heuristic used to pre-select the number of tasks on each [9] S. Kartik and C. Siva Ram Murthy. Task allocation
machine. The CBH heuristic does not consider real-time algorithms for maximizing reliability of distributed
requirements of the tasks, and thus may generate infeasi- computing systems. IEEE Transactions on Comput-
ble allocations. Heuristics that consider these requirements ers, 46(6):719 – 724, June 1997.
will be developed. Also, the importance of the pre-selected
number on the performance of the resulting allocation has [10] E. A. Lee and T. M. Parks. Dataflow process networks.
been shown in this research. Heuristics that pre-select the Proceedings of the IEEE, 83(5):773–801, May 1995.
optimal or close to optimal number of tasks on each ma- [11] G. L. Nemhauser, A. H. G. Rinnooy Kan, and M. J.
chine will also be considered. Todd, editors. Optimization: Handbooks in Opera-
tions Research and Management Science, volume 1.
References North-Holland, 1989.
[12] D.-T. Peng, K. G. Shin, and T. F. Abdelzaher. As-
[1] S. Ali, J.-K. Kim, H. J. Siegel, A. A. Maciejew- signment and scheduling of communicating periodic
ski, Y. Yu, S. B. Gundala, S. Gertphol, and V. K. tasks in distributed real-time systems. IEEE Transac-
Prasanna. Greedy heuristics for resource allocation in tions on Software Engineering, 23(12):745–758, Dec.
dynamic distributed real-time heterogeneous comput- 1997.
ing systems. In Proceeding of the International Con-
ference on Parallel and Distributed Processing Tech- [13] R. Rajkumar, C. Lee, J. Lehoczky, and D. Siewiorek.
niques and Applications, June 2002. Practical solutions for qos-based resource allocation
problems. In Proceedings of the IEEE Real-Time Sys-
[2] S. Ali, H. J. Siegel, M. Maheswaran, D. Hensgen, and tems Symposium, pages 296–306, December 1998.
S. Ali. Task execution time modeling for heteroge-
neous computing systems. In 9th Heterogeneous Com- [14] J. Santos, E. Ferro, J. Orozco, and R. Cayssials. A
puting Workshop, pages 185–199, May 2000. heuristic approach to the multitask-multiprocessor as-
signment problem using the empty-slots method and
[3] T. Cuatto, C. Passeronge, L. Lavagno, A. Jureska, rate monotonic scheduling. Journal of Real-Time Sys-
A. Damiano, C. Sansoe, and A.L. Sangiovanni- tems, 13(2):167–199, Sep. 1997.
Vincentelli. A case study in embedded system design:

0-7695-1926-1/03/$17.00 (C) 2003 IEEE


Proceedings of theAuthorized
International Parallel
licensed and Distributed
use limited Processing
to: UNIVERSITY Symposium
OF SYDNEY. (IPDPS’03)
Downloaded on April 05,2010 at 23:23:15 EDT from IEEE Xplore. Restrictions apply.

You might also like