Monketoo's picture
Add files using upload-large-folder tool
89d0916 verified

• $s_1 = 1$ and $s_2 = 2$, (i.e., $s_{min} = 1, s_{max} = 2, \delta = 1$);

• $L = 3T/2$;

• $E = 5T$.

Clearly, the size of $\mathcal{I}_2$ is polynomial in the size of $\mathcal{I}_1$.

Suppose first that instance $\mathcal{I}1$ has a solution $I$. For all $i \in I$, $T_i$ is executed at speed 1, otherwise it is executed at speed 2. The execution time is then $\sum{i \in I} a_i + \sum_{i \notin I} a_i / 2 = \frac{3}{2} T = D$, and the energy consumption is $E = \sum_{i \in I} a_i + \sum_{i \notin I} a_i \times 2^2 = 5T = E$. Both bounds are respected, and therefore the execution speeds are a solution to $\mathcal{I}_2$.

Suppose now that $\mathcal{I}2$ has a solution. Since we consider the DISCRETE and INCREMENTAL models, each task run either at speed 1, or at speed 2. Let $I = {i | T_i$ is executed at speed 1$}$. Note that we have $\sum{i \notin I} a_i = 2T - \sum_{i \in I} a_i$.

The execution time is $D' = \sum_{i \in I} a_i + \sum_{i \notin I} a_i / 2 = T + (\sum_{i \in I} a_i) / 2$. Since the deadline is not exceeded, $D' \le D = 3T/2$, and therefore $\sum_{i \in I} a_i \le T$.

For the energy consumption of the solution of $\mathcal{I}2$, we have $E' = \sum{i \in I} a_i + \sum_{i \notin I} a_i \times 2^2 = 2T + 3 \sum_{i \notin I} a_i$. Since $E' \le E = 5T$, we obtain $3 \sum_{i \notin I} a_i \le 3T$, and hence $\sum_{i \notin I} a_i \le T$.

Since $\sum_{i \in I} a_i + \sum_{i \notin I} a_i = 2T$, we conclude that $\sum_{i \in I} a_i = \sum_{i \notin I} a_i = T$, and therefore $\mathcal{I}_1$ has a solution. This concludes the proof. $\square$

5.3. Approximation results

Here we explain, for the INCREMENTAL and DISCRETE models, how the solution to the NP-hard problem can be approximated. Note that, given an execution graph and a deadline, the optimal energy consumption with the CONTINUOUS model is always lower than that with the other models, which are more constrained.

Theorem 7. With the INCREMENTAL model, for any integer $K > 0$, the MINENERGY$(G, D)$ problem can be approximated within a factor $(1 + \frac{\delta}{s_{\min}})^2(1 + \frac{1}{K})^2$, in a time polynomial in the size of the instance and in $K$.

Proof. Consider an instance $\mathcal{I}{inc}$ of the problem with the INCREMENTAL model. The execution graph $G$ has $n$ tasks, $D$ is the deadline, $\delta$ is the minimum permissible speed increment, and $s{min}, s_{max}$ are the speed bounds. Moreover, let $K > 0$ be an integer, and let $E_{inc}$ be the optimal value of the energy consumption for this instance $\mathcal{I}_{inc}$.

We construct the following instance $\mathcal{I}{vdd}$ with the VDD-HOPPING model: the execution graph and the deadline are the same as in instance $\mathcal{I}{inc}$, and the speeds can take the values

{smin×(1+1K)i}0iN, \left\{ s_{\min} \times \left( 1 + \frac{1}{K} \right)^i \right\}_{0 \le i \le N},

where $N$ is such that $s_{max}$ is not exceeded: $N = \lfloor (\ln(s_{max}) - \ln(s_{min})) / \ln(1 + \frac{1}{K}) \rfloor$. As $N$ is asymptotically of order $O(K \ln(s_{max}))$, the number of possible speeds in $\mathcal{I}{vdd}$, and hence the size of $\mathcal{I}{vdd}$, is polynomial in the size of $\mathcal{I}_{inc}$ and $K$.

Next, we solve $\mathcal{I}_{vdd}$ in polynomial time thanks to Theorem 5. For each task $T_i$, let $s_i^{(vdd)}$ be the average speed of $T_i$ in this solution: if the execution time of the task in the solution