Skip to main content
Log in

Co-scheduling aperiodic real-time tasks with end-to-end firm and soft deadlines in two-stage systems

  • Published:
Real-Time Systems Aims and scope Submit manuscript

Abstract

This paper investigates scheduling methods for two-stage real-time systems (2S-RTSs) that execute aperiodic tasks with firm and soft end-to-end deadlines. 2S-RTSs are often used to capture task execution in reactive systems where the first stage is responsible for detecting and preprocessing irregularly occurring external events and the second stage for taking certain actions to react to the identified situations. Since aperiodic tasks have no regular arrival patterns, it is more appropriate for such 2S-RTS to adopt an online scheduler to make scheduling decisions according to the current system state. We prove that the 2S-RTS scheduling problem is NP-hard, and present a novel share-based heuristic scheduling algorithm, referred to as HS-2S-RTS, to accomplish efficient online scheduling. Different from traditional optimal schedulers that aim to ensure all hard and soft deadline constraints, the goal of HS-2S-RTS consists of ensuring all firm deadline constraints and maximizing the minimum processor share assigned to soft tasks. Since the processor resource assigned to soft tasks is optimized without affecting firm deadline constraints, the schedulability of both firm and soft tasks can be improved. To reduce the actual run-time overhead, we further propose a quasi-shared-based scheduling algorithm, referred to as qHS-2S-RTS, that can achieve equivalent scheduling performance to HS-2S-RTS. We also design a new admission control algorithm for HS-2S-RTS and qHS-2S-RTS, called HSAC-2S-RTS. Simulation results validate our theoretical analysis that qHS-2S-RTS and HS-2S-RTS are able to satisfy all feasible firm deadline constraints while improving the schedulability of soft tasks.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13
Fig. 14
Fig. 15
Fig. 16

Similar content being viewed by others

Notes

  1. The jobs having the same arrival time can be processed in random order by the admission controller introduced in Sect. 6.

  2. A multiset is a modification of the concept of a set that, unlike a set, allows for multiple instances for each of its elements.

  3. Our scheduling method can be easily extended to 2S-RTS employ other policy to assign priorities.

  4. A completed segment has zero delay.

  5. Lateness of a segment is defined as its completion time minus its absolute deadline. If a segment has a positive lateness, the corresponding job may miss its deadline.

  6. Load means incoming load in the rest of the paper whenever such use does not cause confusions.

  7. Given a firm job ratio, we can derive different firm job loads by varying the total incoming loads. Here, a firm job load is the part of an incoming load contributed by firm jobs. It approximately equals to the product of the total incoming load and the firm job ratio in our experiments.

  8. A soft job load is the part of an incoming load contributed by soft jobs. It equals to the difference between the total incoming load and the firm job load.

  9. We set the arrival interval between two successive jobs to the integer part of the randomly generated values.

References

  • Abdelzaher T, Thaker G, Lardieri P (2004a) A feasible region for meeting aperiodic end-to-end deadlines in resource pipelines. In: Proceedings of 24th international conference on distributed computing systems, Tokyo, Japan, pp 436–445. https://doi.org/10.1109/ICDCS.2004.1281610

  • Abdelzaher TF, Sharma V, Lu C (2004b) A utilization bound for aperiodic tasks and priority driven scheduling. IEEE Trans Comput 53(3):334–350. https://doi.org/10.1109/TC.2004.1261839

    Article  Google Scholar 

  • Brandenburg BB, Calandrino JM, Anderson JH (2008) On the scalability of real-time scheduling algorithms on multicore platforms: a case study. In: Proceedings of 29th real-time systems symposium (RTSS’08), IEEE computer society, Barcelona, pp 157–169. https://doi.org/10.1109/RTSS.2008.23.

  • Buttazzo G, Bini E, Wu Y (2010) Partitioning parallel applications on multiprocessor reservations. In Proceedings of 22nd Euromicro conference on real-time systems (ECRTS’10), IEEE computer society, Brussels, pp 24–33. https://doi.org/10.1109/ECRTS.2010.12

  • Cheng M, Tadikamalla PR, Shang J et al (2014) Bicriteria hierarchical optimization of two-machine flow shop scheduling problem with time-dependent deteriorating jobs. Eur J Oper Res 234(3):650–657

    Article  MathSciNet  Google Scholar 

  • Chetto H, Silly M, Bouchentouf T (1990) Dynamic scheduling of real-time tasks under precedence constraints. Real-Time Syst 2(3):181–194. https://doi.org/10.1007/BF00365326

    Article  Google Scholar 

  • Cortes LA, Eles P, Peng Z (2004) Quasi-static scheduling for real-time systems with hard and soft tasks. In: Proceedings of the design, automation and test in Europe conference and exhibition (DATE’04), IEEE computer society, pp 1530–1591

  • Detienne B, Sadykov R, Tanaka S et al (2016) The two-machine flowshop total completion time problem: Branch-and-bound algorithms based on network-flow formulation. Eur J Oper Res 252(3):750–760

    Article  MathSciNet  Google Scholar 

  • Ekberg P, Yi W (2012) Outstanding paper award: bounding and shaping the demand of mixed-criticality sporadic tasks. Real-time systems. In: Proceedings of 24th Euromicro conference on real-time systems (ECRTS’12), IEEE computer society, Pisa, pp 135–144. https://doi.org/10.1109/ECRTS.2012.24

  • Ertel W, Fessler J, Hochgeschwender N (2006) Flexible combination of vision, control and drive in autonomous mobile robots. In: Levi P, Schanz M, Lafrenz R, Avrutin V (eds) Autonome mobile systeme 2005 Informatik aktuell. Springer, Berlin, pp 245–251

    Chapter  Google Scholar 

  • Funk S, Levin G, Sadowski C et al (2011) DP-fair: a unifying theory for optimal hard real-time multiprocessor scheduling. Real-Time Syst 47(5):389–429. https://doi.org/10.1007/s11241-011-9130-0

    Article  MATH  Google Scholar 

  • Gonzalez T, Sahni S (1978) Flowshop and jobshop schedules: complexity and approximation. Oper Res 26(1):36–52. https://doi.org/10.1287/opre.26.1.36

    Article  MathSciNet  MATH  Google Scholar 

  • Hawkins W,Abdelzaher T (2005) Towards feasible region calculus: An end-to-end schedulability analysis of real-time multistage execution. In: Proceedings of 26th real-time systems symposium (RTSS’05), IEEE computer society, Miami, FL, pp 75–86. https://doi.org/10.1109/RTSS.2005.42

  • Holman P, Anderson JH (2005) Adapting Pfair scheduling for symmetric multiprocessors. J Embed Comput 1(4):543–564

    Google Scholar 

  • Hong S, Chantem T, Hu XS (2011) Meeting end-to-end deadlines through distributed local deadline assignments. In: Proceedings of 32nd real-time systems symposium (RTSS’11), IEEE computer society, Vienna, pp 183–192. https://doi.org/10.1109/RTSS.2011.24.

  • Hong S, Chantem T, Hu XS (2015) Local-deadline assignment for distributed real-time systems. IEEE Trans Comput 64(7):1983–1997. https://doi.org/10.1109/TC.2014.2349494

    Article  MathSciNet  MATH  Google Scholar 

  • Huang L, Hou IH, Sapatnekar S et al (2019) Improving QoS for global dual-criticality scheduling on multiprocessors. In: Proceedings of 25th international conference on embedded and real-time computing systems and applications (RTCSA’19), IEEE Computer Society, pp 1–11. https://doi.org/10.1109/RTCSA.2019.8864597

  • Jayachandran P, Abdelzaher T (2008a) Transforming distributed acyclic systems into equivalent uniprocessors under preemptive and non-preemptive scheduling. In Proceedings of 20th Euromicro conference on real-time systems (ECRTS’08), IEEE computer society, Prague, pp 233–242. https://doi.org/10.1109/ECRTS.2008.31

  • Jayachandran P, Abdelzaher T (2008b) Delay composition in preemptive and non-preemptive real-time pipelines. Real-Time Syst 40(3):290–320. https://doi.org/10.1007/s11241-008-9056-3

    Article  MATH  Google Scholar 

  • Johnson SM (1954) Optimal two- and three-stage production schedules with setup times included. Naval Res Logist Q 1(1):61–68. https://doi.org/10.1002/nav.3800010110

    Article  MATH  Google Scholar 

  • Karić M, Martinović G, Željko H (2010) Implementation and simulation results of multiple total bandwidth server mechanism. In: Proceedings of the 8th international symposium on intelligent systems and informatics, Szakal, pp 423–427. https://doi.org/10.1109/SISY.2010.5647358

  • Korf RE (1998) A complete anytime algorithm for number partitioning. Artif Intell 106(2):181–203. https://doi.org/10.1016/S0004-3702(98)00086-1

    Article  MathSciNet  MATH  Google Scholar 

  • Kuo TW, Lin KJ, Wang YC (2000) An open real-time environment for parallel and distributed systems. In: Proceedings of 20th international conference on distributed computing systems, Taipei, Taiwan, pp 206–213. https://doi.org/10.1109/ICDCS.2000.840931

  • Lano K (1995). Reactive system specification and refinement. In: Proceedings of 6th international joint conference CAAP/FASE theory and practice of software development (TAPSOFT'95), vol 915, pp 696–710

  • Lee J, Phan KM, Gu X et al (2014) MC-fluid: fluid model-based mixed-criticality scheduling on multiprocessors. In: Proceedings of 35th real-time systems symposium (RTSS’14), IEEE computer society, Rome, pp 41–52. https://doi.org/10.1109/RTSS.2014.32

  • Lee J, Chwa HS, Phan LX et al (2017) MC-ADAPT: adaptive task dropping in mixed-criticality scheduling. ACM Trans Embed Comput Syst 16(5):163. https://doi.org/10.1145/3126498

    Article  Google Scholar 

  • Leelaruji R, Vanfretti L, Ghandhari M, Söder L (2010) Coordination of protection and VSC-HVDC systems for mitigating cascading failure. In: 2010 international conference on power system technology (POWERCON), Hangzhou, pp 1–8. https://doi.org/10.1109/POWERCON.2010.5666604

  • Marijan S (2007) Proprietary embedded control electronics for TMK2200 ultra-low floor tramcar. J Control Meas Electron Comput Commun 48(3–4):99–112

    Google Scholar 

  • Nelissen G, Su H, Guo Y et al (2014) An optimal boundary fair scheduling. Real-Time Syst 50(4):456–508. https://doi.org/10.1007/s11241-014-9201-0

    Article  MATH  Google Scholar 

  • Niz DD, Lakshmanan K, Rajkumar R (2009) On the scheduling of mixed-criticality real-time task sets. In: Proceedings of 30th real-time systems symposium (RTSS’09), IEEE computer society, Washington, DC, pp 291–300. https://doi.org/10.1109/RTSS.2009.46

  • Niz DD, Andersson B, Kim H, Klein M, Phan LTX, Rajkumar R (2017) Mixed-criticality processing pipelines. In: Proceedings of the design, automation and test in europe conference and exhibition (DATE’17), Lausanne, pp 1372–1375, https://doi.org/10.23919/DATE.2017.7927206

  • Samii S, Eles P, Peng Z, Cervin A (2009) Quality-driven synthesis of embedded multi-mode control systems. In: Proceedings of 46th ACM/IEEE design automation conference, San Francisco, CA, pp 864–869. https://doi.org/10.1145/1629911.1630131

  • Saraswat PK, Pop P, Madsen J (2010) Task mapping and bandwidth reservation for mixed hard/soft fault-tolerant embedded systems. In: Proceedings of IEEE 19th real-time and embedded technology and applications symposium (RTAS), IEEE computer society, pp 89–98

  • Shiau YR, Tsai MS, Lee WC et al (2015) Two-agent two-machine flowshop scheduling with learning effects to minimize the total completion time. Comput Ind Eng 87:580–589

    Article  Google Scholar 

  • Singh A, Jeffay K (2007) Co-scheduling variable execution time requirement real-time tasks and non real-time tasks. In: Proceedings of 19th Euromicro conference on real-time systems (ECRTS’07), IEEE computer society, Pisa, pp 191–200. https://doi.org/10.1109/ECRTS.2007.87

  • Sun J (1997) Fixed-priority end-to-end scheduling in distributed real-time systems. University of Illinois, Urbana-Champaign

    Google Scholar 

  • Tan P, Jin H, Zhang M (2006) An open distributed real-time environment based on variable utilization server. In: first international multi-symposiums on computer and computational sciences (IMSCCS'06), Hanzhou, Zhejiang, pp 532–539. https://doi.org/10.1109/IMSCCS.2006.36

  • Tang HK, Ramanathan P, Compton K (2011) Combing hard periodic and soft aperiodic real-time task scheduling on heterogeneous compute resources. In: Proceedings of international conference on parallel processing, IEEE computer society, pp 753–762

  • Vestal S (2007) Preemptive scheduling of multi-criticality systems with varying degrees of execution time assurance. In: Proceedings of 28th real-time systems symposium (RTSS’07), IEEE computer society, Tucson, AZ, pp 239–243. https://doi.org/10.1109/RTSS.2007.47

  • Yan Z, Shu-Bo T, Lei L, Wei W (2004) Motion control system in a hybrid architecture for middle-size soccer robo. In: 8th control, automation, robotics and vision conference, ICARCV, vol 3, pp 2205–2210. https://doi.org/10.1109/ICARCV.2004.1469773

  • Yin J, Zhao W (2016) Fault diagnosis network design for vehicle on-board equipments of high-speed railway: a deep learning approach. Eng Appl Artif Intell 56:250–259

    Article  Google Scholar 

Download references

Funding

This work was supported by National Key Research and Development Program of China (2018YFB0904500), and National Natural Science Foundation of China (61902383).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Chang Leng.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Appendices

Appendices

1.1 Appendix A: Computing completion times of jobs

Assume \({\tau }_{r}\) is an active firm job and \({\tau }_{s}\) is an active soft job. Without loss of generality, we assume \({\tau }_{r,1}\) and \({\tau }_{s,1}\) are executed on the stage-1 processor \({P}_{x}\) while \({\tau }_{r,2}\) and \({\tau }_{s,2}\) are executed on the stage-2 processor \({P}_{y}\). If \({\tau }_{r,1}\) has not been completed, its completion time at time \(t\), denoted as \({f}_{s,1}(t)\), is computed by

$$ f_{s,1} \left( t \right) = t + \frac{{c_{s,1} \left( t \right)}}{{1 - u_{x} }} + \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{h,1} \in \Omega_{S} \left( {P_{x} ,t} \right)} \\ {Pr_{h} \le Pr_{s} ,h \ne s} \\ \end{array} }} \frac{{c_{h,1} \left( t \right)}}{{1 - u_{x} }} $$
(A.1)

Here, \({Pr}_{h}\) and \({Pr}_{s}\) are the priority of \({\tau }_{h,1}\) and \({\tau }_{s,1}\). Assume soft segment \({\tau }_{s,2}\) has been released at time instant t′. At time instant t′, the completion time of \({\tau }_{s,2}\), \( f_{{s,2}} (t^{\prime}) \) (equal to the completion time of soft job \({\tau }_{s}\), \( f_{s} (t^{\prime}) \)), is computed by

$$ f_{s} \left( {t^{\prime}} \right) = f_{s,2} \left( {t{^{\prime}}} \right) = t{^{\prime}} + c_{s,2} \left( {t{^{\prime}}} \right) + \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{h,2} \in \Omega \left( {P_{y} ,t} \right)} \\ {d_{h} \le d_{s} ,h \ne s} \\ \end{array} }} c_{h,2} \left( {t{^{\prime}}} \right) $$
(A.2)

Here, \(\Omega ({P}_{y},t)=\{{\tau }_{j,2}|{\tau }_{j}\in {\mathcal{T}}\left(t\right),Proc({\tau }_{j,2})= {P}_{y},{A}_{j,2}\ge t,\;{c}_{j,2}(t)>0\}\), i.e., the set of second segments (both firm and soft) that are active on \({P}_{y}\) at time \(t\).

At any time instant \(t\), if firm segment \({\tau }_{r,1}\) has not completed, we have

$$ f_{r,1} \left( t \right) = t + \frac{{c_{r,1} \left( t \right)}}{{u_{x} }} + \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{h,1} \in \Omega_{F} \left( {P_{x} ,t} \right)} \\ {Pr_{h} < Pr_{r} } \\ \end{array} }} \frac{{c_{h,1} \left( t \right)}}{{u_{x} }} $$
(A.3)

where \({Pr}_{h}\) and \({Pr}_{r}\) are the priority of \({\tau }_{h,1}\) and \({\tau }_{r,1}\). The completion time of \({\tau }_{r,2}\) (equal to the completion time of firm job \({\tau }_{r}\)) at time \(t\) is computed by

$$ f_{r} \left( t \right) = f_{r,2} \left( t \right) = f_{r,1} \left( t \right) + C_{r,2} + \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{h,2} \in \Omega_{F} \left( {P_{y} ,t} \right) \cup \omega_{S} \left( {P_{y} ,t} \right)} \\ {A_{h,2} < f_{r,2} } \\ {d_{h} \le d_{r} } \\ \end{array} }} c_{h,2} \left( {f_{r,1} \left( t \right)} \right) $$
(A.4)

where \({A}_{h,2}\) is the arrival time of \({\tau }_{h,2}\).

If \({\tau }_{r,1}\) has completed but \({\tau }_{r,2}\) has not completed at time \(t\), the completion time of \({\tau }_{r,2}\) (equal to the completion time of firm job \({\tau }_{r}\)) is computed by

$$f_{r} \left( t \right) = f_{r,2} \left( t \right) = t + c_{r,2} \left( t \right) + \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{h,2} \in \Omega_{F} \left( {P_{y} ,t} \right) \cup \omega_{S} \left( {P_{y} ,t} \right)} \\ {A_{h,2} < f_{r,2} } \\ {d_{h} \le d_{r} } \\ \end{array} }} c_{h,2} \left( t \right)$$
(A.5)

Equations (A.4) and (A.5) can be readily evaluated by the fix-point iteration approach.

1.2 Appendix B: Proofs of Lemmas and Theorems

Proof of Theorem 4.2

Note that \({\mathcal{T}}\left(t\right)=\{{\tau }_{1},{\tau }_{2},\ldots ,{\tau }_{N}\}\) is the active job set. If \({\tau }_{i}\) is a soft job, one can see from Algorithm 1 and 2 (Figs. 2 and 4) that \({\tau }_{i,1}\) has expected completion time as given in Eq. (4.1) regardless which algorithm is used for scheduling \({\mathcal{T}}\left(t\right)\). If \({\tau }_{i}\) is a firm job, we have \({f}_{i,1}^{HS}\ge {f}_{i,1}^{qHS}\), where \({f}_{i,1}^{HS}\) and \({f}_{i,1}^{qHS}\) are the completion time of \({\tau }_{i,1}(1\le i\le N)\) when \({\mathcal{T}}\left(t\right)\) is scheduled by HS-2S-RTS and qHS-2S-RTS, respectively. Therefore, we always have.

$$ f_{i,1}^{HS} \ge f_{i,1}^{qHS} $$
(B.1)

For any stage-2 processor \({P}_{y}\), let \(\Omega \left({P}_{y}\right)\) be the segments assigned to \({P}_{y}\). The work in (Hong et al. 2011) gives a necessary and sufficient condition for the schedulability of \(\Omega \left({P}_{y}\right)\):

All jobs in \(\Omega \left({P}_{y}\right)\) can meet their deadlines if and only if

$$ \begin{gathered} \mathop {\max }\limits_{{\tau_{i,2} \in \omega \left( {P_{y} } \right)}} \left\{ {d_{i} } \right\} - \mathop {\min }\limits_{{\tau_{i,2} \in \omega \left( {P_{y} } \right)}} \left\{ {R_{i,2} } \right\} \ge \mathop \sum \limits_{{\tau_{i,2} \in \omega \left( {P_{y} } \right)}} c_{i,2} \left( t \right), \hfill \\ \forall y,m + 1 \le y \le M,\omega \left( {P_{y} } \right) \subseteq \Omega \left( {P_{y} } \right) \hfill \\ \end{gathered} $$
(B.2)

where \({R}_{i,2}\) equals to the completion time of \({\tau }_{i,1}\). From Eq. (B.1), one can see that if Eq. (B.2) holds when \({\mathcal{T}}\left(t\right)\) is scheduled by HS-2S-RTS, Eq. (B.2) must hold when \({\mathcal{T}}\left(t\right)\) is scheduled by qHS-2S-RTS. Therefore, the theorem holds. ■

Proof of Lemma 5.1

We show the correctness of this lemma by proving that \({f}_{i,1}\le \tilde{f}_{{_{{i,1}} }}\) holds for each uncompleted \({\tau }_{i,1}\) at time \(t\).

Without loss of generality, assume that \({\tau }_{i,1}\in {\Omega }_{F}\left({P}_{x},t\right) (1\le x\le m)\). Note that \({\Omega }_{F}^{^{\prime}}\left({P}_{x},t,{\tau }_{i,1}\right)\) is empty if \({\tau }_{i,1}\) is completed, otherwise, \({\Omega }_{F}^{^{\prime}}\left({P}_{x},t,{\tau }_{i,1}\right)\) consists of all uncompleted segments in \({\Omega }_{F}\left({P}_{x},t\right)\) whose priorities are not lower than \({\tau }_{i,1}\). We have

$$ f_{i,1} = t + \frac{{\mathop \sum \nolimits_{{\tau_{j,1} \in \Omega_{F}^{^{\prime}} \left( {P_{x} ,t,\tau_{i,1} } \right)}} c_{j,1} \left( t \right)}}{{u_{x}^{B} \left( t \right)}} = t + \frac{{delay_{i} \left( t \right)}}{{u_{x}^{B} \left( t \right)}} $$
(B.3)

under the given share assignment \(<{u}_{1}^{B}(t),{u}_{2}^{B}(t),\ldots ,{u}_{m}^{B}(t)>\). From Eq. (5.6), we have

$$ 0 \le \frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1} - t}} \le u_{x}^{B} \left( t \right) $$
(B.4)

From Eqs. (B.3) and (B.4), we have \({f}_{i,1}\le t+\frac{{delay}_{i}\left(t\right)}{\left(\frac{{delay}_{i}\left(t\right)}{\tilde{f}_{{_{{i,1}} }}-t}\right)} =t+\tilde{f}_{{_{{i,1}} }}-t=\tilde{f}_{{_{{i,1}} }}\). Therefore, \({f}_{i,1}\le \tilde{f}_{{_{{i,1}} }}\) holds for each uncompleted firm job \({\tau }_{i,1}\) under the share assignment \(<{u}_{1}^{B}(t),{u}_{2}^{B}(t),\ldots ,{u}_{m}^{B}(t)>\). ■

Proof Theorem 5.2

According to Lemma 5.1, each \({\tau }_{i,1}\in {\Omega }_{F}\left({P}_{x},t\right)\) can be completed by \(\tilde{f}_{{_{{i,1}} }}\) under the share assignment \({u}_{x}^{B}(t)\). We show below that there exists at least one job in \({\Omega }_{F}\left({P}_{x},t\right)\) which would complete after its corresponding CTB, if \({P}_{x}\)’s firm job share is less than \({u}_{x}^{B}(t)\). Assume that \({\tau }_{j,1}\in {\Omega }_{F}\left({P}_{x},t\right)\) satisfies \(\frac{{delay}_{j}(t)}{ \tilde{f}_{{j,1}} -t}={u}_{x}^{B}(t)\). If \({P}_{x}\)’s firm job share is less than \({u}_{x}^{B}(t)\), we have \({f}_{j,1}>t+\frac{{delay}_{j}\left(t\right)}{{u}_{x}^{B}(t)}=t+\frac{{delay}_{j}\left(t\right)}{\left(\frac{{delay}_{j}\left(t\right)}{ \tilde{f}_{{j,1}} -t}\right)}= \tilde{f}_{{j,1}} \). Therefore, the theorem holds. ■

Proof of Lemma 5.2

We prove this lemma by showing that 2S-RTS risks firm deadline misses when \({f}_{j,1}={ub}_{j}+\varepsilon \), for any \(\varepsilon >0\). Assume \({\tau }_{k,1}\) is the job whose priority is just lower than \({\tau }_{j,1}\) on the same stage-1 processor as \({\tau }_{j,1}\). Since \({f}_{j,1}={ub}_{j}+\varepsilon = \tilde{f} _{k,1}^{OSA}-{C}_{k,1}\left(t\right)+\varepsilon \) and \({\tau }_{j,1}\) has higher priority than \({\tau }_{k,1}\), we have \({f}_{k,1}\ge {f}_{j,1}+{C}_{k,1}\left(t\right)= \tilde{f} _{k,1}^{OSA}+\varepsilon > \tilde{f} _{k,1}^{OSA}\). Thus, 2S-RTS risks firm deadline misses of firm jobs. ■

Proof of Lemma 5.3

We introduce the following theorem (Hong et al. 2011) to prove this lemma. That is, \(\mathcal{J}=\{{\varphi }_{k},{\varphi }_{k+1},\ldots ,{\varphi }_{j}\}\) is a set of uniprocessor job, where \({\varphi }_{i}(k\le i\le j)\) is a job associated with the following parameters: arrival time \({A}_{i}\), execution time \({C}_{i}\) and absolute deadline \({d}_{i}\). \(\mathcal{J}\) is schedulable by the EDF policy iff \(\forall {\varphi }_{i},{\varphi }_{g},{A}_{i}\le {d}_{g}\),

$$ d_{g} - A_{i} \ge \mathop \sum \limits_{{\begin{array}{*{20}c} {A_{h} \ge A_{i} } \\ {d_{h} \le d_{g} } \\ \end{array} }} C_{h} $$
(B.5)

where \((k\le g,h,i\le j)\).

Note that the value of \( \tilde{f}_{{j,1}} ^{OSA}\) only affects the schedulability of the jobs in \({{\mathcal{T}}^{\prime}}({P}_{y},t)\) among all jobs in \({{\mathcal{T}}^{\prime}}\). Thus, we can prove this lemma by showing that Eq. (B.5) holds for the mirror job set of \({\tau }_{j,1}\)iff it holds for \({{\mathcal{T}}^{\prime}}({P}_{y},t)\) given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\). Since \({A}_{i,2}={f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}\), based on the theorem in (Hong et al. 2011) abovementioned, \({{\mathcal{T}}^{\prime}}({P}_{y},t)\) is schedulable iff \(\forall g,h,i,k\le g,h,i\le j,{f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}\le {d}_{g}\),

$$ d_{g} - \tilde{f}_{i,1}^{OSA} \ge \mathop \sum \limits_{{\begin{array}{*{20}c} {\tilde{f}_{h,1}^{OSA} \ge \tilde{f}_{i,1}^{OSA} } \\ {d_{h} \le d_{g} } \\ \end{array} }} c_{h,2} \left( t \right) $$
(B.6)

where \(t\) is current considering time instant. Note that \({d}_{max}=max\{{d}_{i}|{\tau }_{i}\in {{\mathcal{T}}^{\prime}}({P}_{y},t)\}\), \({A}_{i}^{*}={d}_{max}-{d}_{i}\), \({C}_{i}^{*}={c}_{i,2}(t)\) and \({d}_{i}^{*}={d}_{max}-\tilde{f}_{{_{{i,1}} }}^{OSA}\). Equation (B.6) follows three conclusions: \(\forall g,h,i,k\le g,h,i\le j\), (i) \({d}_{g}-\tilde{f}_{{_{{i,1}} }}^{OSA}={d}_{i}^{*}-{A}_{g}^{*}\); (ii) \(\tilde{f}_{{_{{i,1}} }}^{OSA}\le {d}_{g}\)iff \({A}_{g}^{*}\le {d}_{i}^{*}\), and (iii) \( \tilde{f} _{h,1}^{OSA}\ge \tilde{f}_{{_{{i,1}} }}^{OSA}\), \({d}_{h}\le {d}_{g}\)iff \({d}_{h}^{*}\le {d}_{i}^{*}\), \({A}_{h}^{*}\ge {A}_{g}^{*}\). The following relationship can be deduced from the above three conclusions: \(\forall g,h,i,k\le g,h,i\le j\),

$$ d_{i}^{*} - A_{g}^{*} = d_{g} - \tilde{f}_{i,1}^{OSA} \ge \mathop \sum \limits_{{\begin{array}{*{20}c} {\tilde{f}_{h,1}^{OSA} \ge \tilde{f}_{i,1}^{OSA} } \\ {d_{h} \le d_{g} } \\ \end{array} }} c_{h,2} \left( t \right) = \mathop \sum \limits_{{\begin{array}{*{20}c} {A_{h}^{*} \ge A_{g}^{*} } \\ {d_{h}^{*} \le d_{i}^{*} } \\ \end{array} }} c_{h,2} \left( t \right) = \mathop \sum \limits_{{\begin{array}{*{20}c} {A_{h}^{*} \ge A_{g}^{*} } \\ {d_{h}^{*} \le d_{i}^{*} } \\ \end{array} }} C_{h}^{*} $$
(B.7)

One can see from Eqs. (B.6) and (B.7) that Eq. (B.5) holds for the mirror job set of \({\tau }_{j,1}\)iff it holds for \({{\mathcal{T}}^{\prime}}({P}_{y},t)\) given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\). Together with the theorem in (Hong et al. 2011) abovementioned, the lemma can be readily proved. ■

Before we prove other lemmas and theorems, we introduce the following two lemmas.

Lemma A.1

\({\mathcal{J}}_{bp}{(\tau }_{j,1})\)is schedulable.

Proof of Lemma A.1

Without loss of generality, assume that \({\mathcal{J}}_{bp}{(\tau }_{j,1})\) is the working job set and Get_CTB is being invoked to compute CTB for \({\varphi }_{bp\_i,1}(1\le i\le |{\mathcal{J}}^{^{\prime}}|)\). According to Lemma 5.3, we can prove the correctness of this lemma by showing the mirror job set of \({\varphi }_{bp\_i,1}\) is schedulable. Let \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_i,1})\) be the mirror job set of \({\varphi }_{bp\_i,1}\). We have \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_i,1})=\{{\varphi }_{bp\_i}^{*}| 1\le i\le |{\mathcal{J}}^{^{\prime}}|\}\), where \({\varphi }_{bp\_i}^{*}(1\le i\le |{\mathcal{J}}^{^{\prime}}|)\) is a job associated with the following parameters: \({A}_{bp\_i}^{*}=\mathit{max}\left\{{d}_{max}-{d}_{j},{d}_{max}-{d}_{index(i)}\right\}\), \({C}_{bp\_i}^{*}={c}_{index(i)}^{*}({d}_{max}-{d}_{j})\) and \({d}_{bp\_i}^{*}=\mathit{min}\left\{{t}_{2},{d}_{max}- \tilde{f} _{index(i),1}^{OSA}\right\}\).

Since the job set \(\{{\tau }_{i}|(1\le i\le j-1)\}\) is schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j-1)\), based on our Proof of Lemma 5.3, the job set \({\mathcal{J}}^{*}({\tau }_{j,1})-\{{\varphi }_{j}^{*}\}=\{{\varphi }_{k}^{*},{\varphi }_{k+1}^{*},\ldots ,{\varphi }_{j-1}^{*}\}\) is schedulable (details are omitted for brevity). Thus, \({\mathcal{J}}^{^{\prime}}\), a subset of \({\mathcal{J}}^{*}({\tau }_{j,1})-\{{\varphi }_{j}^{*}\}\), is schedulable. When \({\mathcal{J}}^{^{\prime}}\) is scheduled by the EDF policy, at time instant \({d}_{max}-{d}_{j}\), the parameters of each job \({\varphi }_{i}^{*}\) in \({\mathcal{J}}^{^{\prime}}\) are \({c}_{i}^{*}({d}_{max}-{d}_{j})={c}_{i,2}({d}_{max}-{d}_{j})\) and \({d}_{i}^{*}={d}_{max}-\tilde{f}_{{_{{i,1}} }}^{OSA}\). Note that each job in \({\mathcal{J}}^{^{\prime}}\) can be completed by \({t}_{2}\). Thus, \({\mathcal{J}}^{^{\prime}}\) is still schedulable if the deadline of each job \({\varphi }_{i}^{*}\) in \({\mathcal{J}}^{^{\prime}}\) is \({d}_{i}^{*}=min\{{t}_{2},{d}_{max}-\tilde{f}_{{_{{i,1}} }}^{OSA}\}\). Assume that \({P}_{1}\) is a processor that schedules \({\mathcal{J}}^{^{\prime}}\) by the EDF policy and \({P}_{2}\) is a processor that schedules the second segments of all jobs in \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_i,1})\) by the EDF policy. Observing that for \(i\)-th job of \({\mathcal{J}}^{^{\prime}}\), \({C}_{index(i)}^{*}({d}_{max}-{d}_{j})={C}_{bp\_i}^{*}\) and \({d}_{index(i)}^{*}={d}_{bp\_i}^{*}\) (\({d}_{index(i)}^{*}\) is modified to be \(min\{{t}_{2},{d}_{max}- \tilde{f} _{index(i),1}^{OSA}\}\)). It can readily see that \({P}_{1}\) and \({P}_{2}\) have the same processor state at time \({d}_{max}-{d}_{j}\) and the same job arrival pattern after time \({d}_{max}-{d}_{j}\). Thus, \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_i,1})\) is schedulable and the correctness of this lemma is proved. ■

Lemma A.2

If the conditions of Lemma 5.2 do not hold, the working job set \({{\mathcal{T}}^{\prime}}=\{{\tau }_{i}|1\le i\le j\}\) is schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\) and \( \tilde{f}_{{j,1}} ^{OSA}= \tilde{t} \), where \( \tilde{t} \) is the earliest idle time instant after \({d}_{max}-{t}_{2}\) when \({\mathcal{J}}_{bp}{(\tau }_{j,1})\) is scheduled by the EDF policy.

Proof of Lemma A.2

According to Lemma 5.3, we can prove the correctness of this lemma by showing the mirror job set of \({\tau }_{j,1}\), i.e., \({\mathcal{J}}^{*}{(\tau }_{j,1})=\{{\varphi }_{k}^{*},{\varphi }_{k+1}^{*},\ldots ,{\varphi }_{j}^{*}\}\), is schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\) and \( \tilde{f}_{{j,1}} ^{OSA}= \tilde{t} \). As we have described, \({\varphi }_{j}^{*}\) only affects the schedulability of the jobs arrives between \({t}_{1}\) and \({t}_{2}\) since the busy period where job \({\varphi }_{j}^{+}\) locates starts at time \({t}_{1}\) and ends at time \({t}_{2}\) when all jobs of the modified mirror job set of \({\tau }_{j,1}\) are scheduled by the EDF policy. Therefore, if all jobs in \({\mathcal{J}}^{^{\prime}}=\{{\varphi }_{k}^{*}|{\varphi }_{k}^{*}\in ({\mathcal{J}}^{*}{(\tau }_{j,1})-\{{\varphi }_{j}^{*}\}), {t}_{1}\le {A}_{k}^{*}\le {t}_{2}\}\) together with \({\varphi }_{j}^{*}\) can meet their deadlines, \({\mathcal{J}}^{*}{(\tau }_{j,1})\) is schedulable.

Let \({\varphi }_{bp\_j}\) be a firm job whose parameters are \({f}_{bp\_j,1}= \tilde{f} _{bp\_j}^{OSA}= \tilde{t} \), \({C}_{bp\_j,1}={c}_{j}^{*}({d}_{max}-{d}_{j})\) and \({d}_{bp\_j}={d}_{j}\). Assume that \({\mathcal{J}}_{bp}{(\tau }_{j,1})\cup \{{\varphi }_{bp\_j}\}\) is the working job set, then the mirror job set of \({\varphi }_{bp\_j}\) is \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_j})\cup \{{\varphi }_{bp\_j}^{*}\}\), where \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_j})=\{{\varphi }_{bp\_i}^{*}| 1\le i\le |{\mathcal{J}}^{^{\prime}}|\}\) and \({\varphi }_{bp\_j}^{*}\) is a job associated with the following parameters: \({A}_{bp\_j}^{*}={d}_{max}-{d}_{j}\), \({C}_{bp\_j}^{*}={c}_{j}^{*}({d}_{max}-{d}_{j})\) and \({d}_{bp\_j}^{*}=\mathit{min}\left\{{t}_{2},{d}_{max}- \tilde{t} \right\}\). Observing at time instant \({d}_{max}-{d}_{j}\), the parameters of the \(i\)-th job of set \({\mathcal{J}}^{^{\prime}}\) are \({C}_{index(i)}^{*}({d}_{max}-{d}_{j})={C}_{bp\_i}^{*}\) and \({d}_{index(i)}^{*}\ge {d}_{bp\_i}^{*}\). Note that \({\varphi }_{j}^{*}\) and \({\varphi }_{bp\_j}^{*}\) have the same parameter at \({d}_{max}-{d}_{j}\) except \({d}_{bp\_i}^{*}\le {d}_{j}^{*}\). Suppose we can prove that \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_j})\cup \{{\varphi }_{bp\_j}^{*}\}\) is schedulable. It follows that \({\mathcal{J}}^{^{\prime}}\) together with \({\varphi }_{j}^{*}\) is schedulable and the correctness of this lemma is proved.

Now we prove \({\mathcal{J}}_{bp}^{*}({\varphi }_{bp\_j})\cup \{{\varphi }_{bp\_j}^{*}\}\) is schedulable by showing that \({\mathcal{J}}_{bp}{(\tau }_{j,1})\cup \{{\varphi }_{bp\_j}\}\) is schedulable. Lemma A.1 has shown \({\mathcal{J}}_{bp}{(\tau }_{j,1})\) is schedulable. \({\varphi }_{bp\_j}\) has the latest absolute deadline among all jobs in \({\mathcal{J}}_{bp}\cup \{{\varphi }_{bp\_j}\}\). Without loss of generality, we assume that \({\varphi }_{bp\_j}\) has the lowest priority among all jobs in \({\mathcal{J}}_{bp}\cup \{{\varphi }_{bp\_j}\}\) by the EDF policy (ties can be broken arbitrarily if more than one jobs have the same absolute deadlines). Thus, no job in \({\mathcal{J}}_{bp}{(\tau }_{j,1})\) misses its deadline. If we further show that the total processor resource available for \({\varphi }_{bp\_j}\) during its arrival time \( \tilde{t} \) and its absolute deadline \({d}_{j}\) (during \([ \tilde{t} ,{d}_{j}]\)) is no less than its execution time \({c}_{j}^{*}({d}_{max}-{d}_{j})\). It follows that \({\varphi }_{bp\_j}\) can be completed by its absolute deadline \({d}_{j}\).

Suppose \({\mathcal{J}}^{^{\prime}}\cup \{{\varphi }_{j}^{*}\}\) is scheduled on a processor by the EDF policy. The processor is busy from \({t}_{1}\) to \({t}_{2}\). At time instant \({d}_{max}-{d}_{j}\), the total remaining execution time is \({t}_{2}-({d}_{max}-{d}_{j})\). Thus, we have

$${t}_{2}-({d}_{max}-{d}_{j})={c}_{j}^{*}({d}_{max}-{d}_{j})+\sum_{{\varphi }_{i}^{*}\in {\mathcal{J}}^{^{\prime}}}{c}_{i}^{*}({d}_{max}-{d}_{j})={c}_{j}^{*}({d}_{max}-{d}_{j})+\sum_{{\varphi }_{bp\_i}\in {\mathcal{J}}_{bp{(\tau }_{j,1})}}{C}_{bp\_i,1}$$

Therefore,

$$ c_{j}^{*} \left( {d_{max} - d_{j} } \right) = d_{j} - \left( {d_{max} - t_{2} } \right) - \mathop \sum \limits_{{\varphi_{bp\_i} \in {\mathcal{J}}_{{bp(\tau_{j,1} )}} }} C_{bp\_i,1} $$
(B.8)

Equation (B.8) implies that the total processor resource available for \({\varphi }_{bp\_j}\) during \([{d}_{max}-{t}_{2},{d}_{j}]\) equals to its execution time \({c}_{j}^{*}({d}_{max}-{d}_{j})\). Since the processor is busy during \([{d}_{max}-{t}_{2}, \tilde{t} ]\), the total processor resource available for \({\varphi }_{bp\_j}\) during \([ \tilde{t} ,{d}_{j}]\) equals to that during \([{d}_{max}-{t}_{2},{d}_{j}]\), i.e., its execution time \({c}_{j}^{*}({d}_{max}-{d}_{j})\). Therefore, \({\mathcal{J}}_{bp}\cup \{{\varphi }_{bp\_j}\}\) is schedulable. The lemma can be readily obtained. ■

Proof of Lemma 5.4

If the conditions of Lemma 5.2 do not hold, we have \( \tilde{t} <{ub}_{j}\) or \({\tau }_{j,1}\) is the lowest-priority uncompleted firm segment on \({P}_{x}\). Therefore, \({\tau }_{j,1}\) will not block other firm segment \({\tau }_{i,1}(1\le i\le j-1)\) such that \({f}_{i,1}>\tilde{f}_{{_{{i,1}} }}^{OSA}\). From Lemma A.2, we know \({{\mathcal{T}}^{\prime}}\) is schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\) and \( \tilde{f}_{{j,1}} ^{OSA}= \tilde{t} \). We prove this lemma by showing that the working job set \({{\mathcal{T}}^{\prime}}\) is not schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\) and \({f}_{j,1}> \tilde{t} \).

Assume that the second segments of all jobs in \({\mathcal{J}}_{bp}{(\tau }_{j,1})\cup \{{\varphi }_{bp\_j}\}\) (The parameters of \({\varphi }_{bp\_j}\) are given in the Proof of Lemma A.2) are scheduled on one processor by the EDF policy and the arrival time of \({\varphi }_{bp\_j}\) becomes \( \tilde{t} +\varepsilon \). As we have shown in our Proof of Lemma A.2, the total processor resource available for \({\varphi }_{bp\_j}\) during \([ \tilde{t} ,{d}_{j}]\) equals to its execution time. Note that \( \tilde{t} \) is the earliest idle time instant after \({d}_{max}-{t}_{2}\) when \({\mathcal{J}}_{bp}{(\tau }_{j,1})\) is scheduled by the EDF policy. All jobs in \({\mathcal{J}}_{bp}{(\tau }_{j,1})\cup \{{\varphi }_{bp\_j}\}\) arrived by \( \tilde{t} \) have been completed by \( \tilde{t} \). Thus, the processor is not always busy during \([ \tilde{t} , \tilde{t} +\varepsilon ]\), i.e., some available processor resources is not used by \({\varphi }_{bp\_j}\). \({\varphi }_{bp\_j}\) must miss its deadline. Thus, \({\mathcal{J}}_{bp}{(\tau }_{j,1})\cup \{{\varphi }_{bp\_j}\}\) is unschedulable if the arrival time of \({\varphi }_{bp\_j}\) is \( \tilde{t} +\varepsilon \).

Note that \({\varphi }_{j}^{*}\) is a job whose parameters are: \({A}_{j}^{*}={d}_{max}-{d}_{j}\), \({C}_{j}^{*}={c}_{j}^{*}({d}_{max}-{d}_{j})\) and \({d}_{j}^{*}={d}_{max}- \tilde{t} \). Therefore, \({\mathcal{J}}_{bp}^{*}{(\varphi }_{bp\_j})\cup \{{\varphi }_{j}^{*}\}\) is unschedulable if the absolute deadline of \({\varphi }_{j}^{*}\) is \({d}_{max}- \tilde{t} -\varepsilon \). Note that all jobs in \({\mathcal{J}}_{bp}^{*}{(\varphi }_{bp\_j})\cup \{{\varphi }_{j}^{*}\}\) can be completed by \({t}_{2}\). Thus, \({\mathcal{J}}_{bp}^{*}{(\varphi }_{bp\_j})\cup \{{\varphi }_{j}^{*}\}\) is still unschedulable if the deadline of each job \({\varphi }_{bp\_i}^{*}\) in \({\mathcal{J}}_{bp}^{*}{(\varphi }_{bp\_j})\), \({d}_{bp\_i}^{*}\), is set to \({d}_{max}- \tilde{f} _{index(i),1}^{OSA}\). When \({\mathcal{J}}^{^{\prime}}\cup \{{\varphi }_{j}^{*}\}\) is scheduled by the EDF policy, at time instant \({d}_{max}-{d}_{j}\), the parameters of each job \({\varphi }_{i}^{*}\) in \({\mathcal{J}}^{^{\prime}}\) are: \({C}_{i}^{*}({d}_{max}-{d}_{j})={c}_{i,2}({d}_{max}-{d}_{j})\) and \({d}_{i}^{*}={d}_{max}-\tilde{f}_{{_{{i,1}} }}^{OSA}\). Assume that \({P}_{1}\) is a processor that schedules \({\mathcal{J}}^{^{\prime}}\cup \{{\varphi }_{j}^{*}\}\) by the EDF policy and \({P}_{2}\) is a processor that schedules the second segments of all jobs in \({\mathcal{J}}_{bp}^{*}{(\varphi }_{bp\_j})\cup \{{\varphi }_{j}^{*}\}\) by the EDF policy. Observing at time instant \({d}_{max}-{d}_{j}\), the parameters of \(i\)-th job in \({\mathcal{J}}^{^{\prime}}\) satisfy: \({C}_{index(i)}^{*}({d}_{max}-{d}_{j})={C}_{bp\_i}^{*}\) and \({d}_{index(i)}^{*}={d}_{bp\_i}^{*}\) (\({d}_{bp\_i}^{*}\) is modified to be \({d}_{max}- \tilde{f} _{index(i),1}^{OSA}\)). It can readily see that \({P}_{1}\) and \({P}_{2}\) have the same processor state at time \({d}_{max}-{d}_{j}\) and the same job arrival pattern after time \({d}_{max}-{d}_{j}\). Thus, \({\mathcal{J}}^{^{\prime}}\cup \{{\varphi }_{j}^{*}\}\) is unschedulable, which means \({\mathcal{J}}^{*}{(\tau }_{j,1})\cup \{{\varphi }_{j}^{*}\}\) is unschedulable too. Together with Lemma 5.3, it follows \({{\mathcal{T}}^{\prime}}\) is unschedulable. The correctness of Lemma 5.4 is proved. ■

Proof of Lemma 5.5

We firstly prove that \({{\mathcal{T}}}_{F}\left(t\right)\) is schedulable if an active firm job \({\tau }_{j}\) as described in this lemma does not exist. Then, we prove that \({{\mathcal{T}}}_{F}\left(t\right)\) is not schedulable if such an active firm job exists.

From Algorithm 3 in Fig. 5, one can see that OSA returns a set of firm job share if there does not exist any active firm job \({\tau }_{j}\) such that \( \tilde{f}_{{j,1}} ^{OSA}<t\) or \({delay}_{j}/( \tilde{f}_{{j,1}} ^{OSA}-t)>1\). Lemmas 5.2 and 5.3 have proved that OSA always guarantees the working job set \({{\mathcal{T}}^{\prime}}=\{{\tau }_{i}|1\le i\le j\}\) is schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j)\). If there does not exist an active firm job \({\tau }_{j}\) such that \( \tilde{f}_{{j,1}} ^{OSA}<t\) or \({delay}_{j}/( \tilde{f}_{{j,1}} ^{OSA}-t)>1\), OSA exits its main loop (Algorithm 3 in Fig. 5, line 8–15) only if \({{\mathcal{T}}^{\prime}}={{\mathcal{T}}}_{F}\left(t\right)\). Thus, all active firm jobs are schedulable given that \({f}_{i,1}=\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le H)\). Using \(\tilde{f}_{{_{{i,1}} }}^{OSA}\) to substitute \({f}_{i,1}(1\le i\le H)\) in Eq. (5.6), firm jobs shares of all stage-1 processors are derived. From Lemma 5.1, \({f}_{i,1}\le \tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le H)\) is hold when HS-2S-RTS is employed. Therefore, \({{\mathcal{T}}}_{F}\left(t\right)\) is schedulable if there does not exist an active firm job \({\tau }_{j}\) such that \( \tilde{f}_{{j,1}} ^{OSA}<t\) or \({delay}_{j}/( \tilde{f}_{{j,1}} ^{OSA}-t)>1\).

If OSA finds that there exists an active firm job \({\tau }_{j}\) as described in this lemma, the following two cases arise depending on whether \({delay}_{j}/( \tilde{f}_{{j,1}} ^{OSA}-t)>1\) holds.

Case 1 \({delay}_{j}/( \tilde{f}_{{j,1}} ^{OSA}-t)>1\) holds. Note that \({{\mathcal{T}}}_{F}\left(t\right)=\{{\tau }_{1},{\tau }_{2},\ldots ,{\tau }_{H}\}\) is the active firm job set of the 2S-RTS. Without loss of generality, we assume OSA finds \({\tau }_{j}\) such that \({delay}_{j}/( \tilde{f}_{{j,1}} ^{OSA}-t)>1\). Assume \({\tau }_{j,1}\) is assigned to \({P}_{x}\) and the working job set is\({{\mathcal{T}}^{\prime}}=\{{\tau }_{1},{\tau }_{2},\ldots ,{\tau }_{j}\}\). Since OSA does not return after computing \(\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j-1)\) for \({\tau }_{i}\) in\({{\mathcal{T}}^{\prime}}\), we have

$$ \frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}} \le 1 < \frac{{delay_{j} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} - t}} $$
(B.9)

Assume that \( \tilde{f}_{{j,1}} ^{OSA}\) is set to the unique bound \({ub}_{j}\) (Algorithm 4, line 6,) (Fig. 6), i.e.,

$$ \tilde{f}_{j,1}^{OSA} = ub_{j} = \tilde{f}_{i,1}^{OSA} - c_{i,1} \left( t \right) $$
(B.10)

where \({\tau }_{i,1}\) is the job having priority just lower than \({\tau }_{j,1}\) on \({P}_{x}\). From Eq. (B.10), one can see the following relationship holds

$$ \frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}} = \frac{{delay_{j} \left( t \right) + C_{i,1} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} + C_{i,1} \left( t \right) - t}} > \frac{{delay_{j} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} - t}} > 1 $$
(B.11)

Since Eq. (B.11) contradicts Eqs. (B.9), (B.10) does not hold. Thus, in case 1, we have

$$ \tilde{f}_{j,1}^{OSA} = \tilde{t} $$
(B.12)

Furthermore, for any job \({\tau }_{i}\) in the working job set \({{\mathcal{T}}^{\prime}}\) except \({\tau }_{j}\), we have \({delay}_{i}(t)\ge {delay}_{j}(t)\). From Eq. (B.9), one can deduce that

$$ \tilde{f}_{i,1}^{OSA} \ge \tilde{f}_{j,1}^{OSA} = \tilde{t} $$
(B.13)

Let \({\mathcal{J}}^{*}({\tau }_{j,1})\) be the mirror job set of \({\tau }_{j,1}\) and \({\varphi }_{j}^{+}\) is a job associated with the following parameters: \({A}_{j}^{+}={d}_{max}-{d}_{j}\), \({C}_{j}^{+}={c}_{j}(t)\) and \({d}_{j}^{+}=+\infty \). The busy period where \({\varphi }_{j}^{+}\) locates starts at time \({t}_{1}\) and ends at time \({t}_{2}\) when all jobs in the modified mirror job set of \({\tau }_{j,1}\), \({\mathcal{J}}^{*}({\tau }_{j,1})\cup \{{\varphi }_{j}^{+}\}-\{{\varphi }_{j}^{*}\}\), is scheduled by the EDF policy. Let \({\mathcal{J}}_{c}\) be the set of all jobs in \({\mathcal{J}}^{*}({\tau }_{j,1})\) which arrives between \({t}_{1}\) and \({t}_{2}\) and \({{\mathcal{T}}}_{c}\) be the subset of \({{\mathcal{T}}^{\prime}}\) such that \( {{\mathcal{T}}}_{c} = \{ \tau _{i} |\tau _{i} \in {{\mathcal{T}}^{\prime}}~and~d_{{max}} - t_{2} \le d_{i} \le d_{{max}} - t_{1} \} \). Thus, we have

$$ t_{2} - t_{1} = \mathop \sum \limits_{{\varphi_{i}^{*} \in {\mathcal{J}}_{c} }} C_{i}^{*} $$
(B.14)

Note that \({\tau }_{i}\in {{\mathcal{T}}}_{c}\)iff \({\varphi }_{i}^{*}\in {\mathcal{J}}_{c}\). Furthermore, \({C}_{i}^{*}={c}_{i,2}(t)\). Thus,

$$ t_{2} - t_{1} = \mathop \sum \limits_{{\tau_{i} \in {{\mathcal{T}}}_{c} }} c_{i,2} \left( t \right) $$
(B.15)

Let \(Max\_d\) be the latest absolute deadline of all jobs in \({{\mathcal{T}}}_{c}\) i.e., \(Max\_d=max\{{d}_{i}|{\tau }_{i}\in {{\mathcal{T}}}_{c}\}\), and \(Min\_A\) be the earliest arrival time of the second segments of all jobs in \({{\mathcal{T}}}_{c}\), i.e., \(Min\_A=min\{{A}_{i,2}|{\tau }_{i}\in {{\mathcal{T}}}_{c}\}\). For any \({\tau }_{i}\in {{\mathcal{T}}}_{c}\), we have

$$ A_{i,2} \ge t + delay_{i} \left( t \right) \ge t + delay_{j} \left( t \right) $$
(B.16)

From Eqs. (B.9), (B.13) and (B.16), we have \({A}_{i,2}> \tilde{t} \). Thus, \(Min\_A> \tilde{t} \). Note that \( \tilde{t} \ge {d}_{max}-{t}_{2}\). We have

$$ Max\_d - Min\_A < d_{max} - t_{1} - \tilde{t} \le d_{max} - t_{1} - \left( {d_{max} - t_{2} } \right) = t_{2} - t_{1} = \mathop \sum \limits_{{\tau_{i} \in {{\mathcal{T}}}_{c} }} c_{i,2} \left( t \right) $$
(B.17)

Equation (B.17) shows that at least one active firm job in \({{\mathcal{T}}}_{c}\) cannot be completed by \(Max\_d\), i.e., misses its deadline. Thus, \({{\mathcal{T}}}_{F}\left(t\right)\) is not schedulable in this case.

Case 2 \( \tilde{f}_{{j,1}} ^{OSA}<t\) but \({delay}_{i}/(\tilde{f}_{{_{{i,1}} }}^{OSA}-t)\le 1\) holds for any job (including \({\tau }_{j}\)) in the working job set \({{\mathcal{T}}^{\prime}}\). Since OSA does not return after computing \(\tilde{f}_{{_{{i,1}} }}^{OSA}(1\le i\le j-1)\) for \({\tau }_{i}\) in \({{\mathcal{T}}^{\prime}}\), we have \(\tilde{f}_{{_{{i,1}} }}^{OSA}\ge t(1\le i\le j-1)\). Assume that \( \tilde{f}_{{j,1}} ^{OSA}\) is set to the unique bound \({ub}_{j}\) (Algorithm 4, line 6 in Fig. 6), i.e., Eq. (B.10) holds. We have \(\tilde{f}_{{_{{i,1}} }}^{OSA}-{c}_{i,1}\left(t\right)<t\). Thus,

$$ \frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}} \ge \frac{{c_{i,1} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}} > 1 $$
(B.18)

Since Eq. (B.18) contradicts \({delay}_{i}/(\tilde{f}_{{_{{i,1}} }}^{OSA}-t)\le 1(1\le i\le j)\), Eq. (B.10) does not hold. Thus, Eq. (B.12) still holds and then \( \tilde{t} <t\). Considering the job set \({{\mathcal{T}}}_{c}\) constructed in case 1, we have

$$ Max\_d - t < d_{max} - t_{1} - \tilde{t} \le d_{max} - t_{1} - \left( {d_{max} - t_{2} } \right) = t_{2} - t_{1} = \mathop \sum \limits_{{\tau_{i} \in {{\mathcal{T}}}_{c} }} c_{i,2} \left( t \right) $$
(B.19)

Equation (B.19) shows that at least one active firm job in \({{\mathcal{T}}}_{c}\) misses its deadline. Thus, \({{\mathcal{T}}}_{F}\left(t\right)\) is not schedulable in this case. Therefore, \({{\mathcal{T}}}_{F}\left(t\right)\) is not schedulable if OSA finds an active firm job \({\tau }_{j}\) as described in this lemma. ■

Proof of Lemma 5.6

We prove this lemma by showing that firm deadline misses will occur in the 2S-RTS if a share assignment approach which achieves lower maximum firm job share than OSA is employed.

At time \(t\), OSA is invoked to assign firm job shares for all stage-1 processors. Note that \({{\mathcal{T}}}_{F}\left(t\right)=\{{\tau }_{1},{\tau }_{2},\ldots ,{\tau }_{H}\}\) is the active firm job set of the 2S-RTS. Since OSA returns a share assignment, we have \(\tilde{f}_{{_{{i,1}} }}^{OSA}\ge t\) and \({delay}_{i}/(\tilde{f}_{{_{{i,1}} }}^{OSA}-t)\le 1\) holds for each job \({\tau }_{i}\) in \({{\mathcal{T}}}_{F}\left(t\right)\). Without loss of generality, we assume under OSA

$$ \frac{{delay_{j} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} - t}} = \mathop {\max }\limits_{1 \le i \le H} \left\{ {\frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}}} \right\} $$
(B.20)

i.e., \(\frac{{delay}_{j}(t)}{ \tilde{f}_{{j,1}} ^{OSA}-t}\) equals to the maximum firm job share under OSA. Below, we prove an important relationship serving as a basis of our proof, i.e., the following equation always holds for \({\tau }_{j}\)

$$ \tilde{f}_{j,1}^{OSA} = \tilde{t} = d_{max} - t_{2} $$
(B.21)

Assume \({\tau }_{j}\) is assigned to the stage-1 processor \({P}_{x}\) and the working set is \({{\mathcal{T}}^{\prime}}=\{{\tau }_{1},{\tau }_{2},\ldots ,{\tau }_{j}\}\). Assume that \( \tilde{f}_{{j,1}} ^{OSA}\) is set to the unique bound \({ub}_{j}\) (Algorithm 4, line 6) (Fig. 6), i.e., Eq. (B.10) holds. We have,

$$ \frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}} = \frac{{delay_{j} \left( t \right) + C_{i,1} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} + C_{i,1} \left( t \right) - t}} > \frac{{delay_{j} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} - t}} $$
(B.22)

where \({\tau }_{i,1}\) is the job having priority just lower than \({\tau }_{j,1}\) on \({P}_{x}\). Since Eq. (B.22) contradicts Eq. (B.20), Eq. (B.10) does not hold. Thus, we have \( \tilde{f}_{{j,1}} ^{OSA}= \tilde{t} \). We further assume that \( \tilde{t} \ne {d}_{max}-{t}_{2}\), i.e.,

$$ \tilde{t} > d_{max} - t_{2} $$
(B.23)

Note that there exists \({\varphi }_{bp\_i}\in {\mathcal{J}}_{bp}({\tau }_{j,1})\) such that \({f}_{bp\_i,1}\le {d}_{max}-{t}_{2}\) and \({f}_{bp\_i,1}=max\{{d}_{max}-{t}_{2}, \tilde{f}_{{_{{i,1}} }}^{OSA}\}\). Thus, there exists \({\tau }_{i}(i\ne j)\) in \({{\mathcal{T}}^{\prime}}\) such that

$$ \tilde{f}_{i,1}^{OSA} \le d_{max} - t_{2} $$
(B.24)

It can be deduced from Eqs. (B.12), (B.23) and (B.24) that

$$ \frac{{delay_{i} \left( t \right)}}{{\tilde{f}_{i,1}^{OSA} - t}} > \frac{{delay_{j} \left( t \right)}}{{\tilde{f}_{j,1}^{OSA} - t}} $$
(B.25)

Since Eq. (B.25) also contradicts Eq. (B.20), Eq. (B.23) does not hold. Thus, Eq. (B.21) always holds.

Assume \(\mathcal{A}\) is a share assignment approach which achieves lower maximum firm job share than OSA. Below, we prove that firm deadline misses will occur in the 2S-RTS if \(\mathcal{A}\) is employed by HS-2S-RTS.

From our Proof of Lemma 5.5, we know that Eqs. (B.14) and (B.15) hold. Let \(Max\_d\) be the latest absolute deadline of all jobs in \({{\mathcal{T}}}_{c}\) (defined in the Proof of Lemma 5.5), i.e., \(Max\_d=max\{{d}_{i}|{\tau }_{i}\in {{\mathcal{T}}}_{c}\}\). Since \(\mathcal{A}\) achieves lower maximum firm job share than OSA, one can deduce that \({u}_{x}^{\mathcal{A}}(t)=\frac{{delay}_{i}(t)}{{f}_{i,1}^{\mathcal{A}}-t}<\frac{{delay}_{j}(t)}{ \tilde{f}_{{j,1}} ^{OSA}-t}\) holds for each firm job \({\tau }_{i}\in {{\mathcal{T}}}_{c}\), where \({f}_{i,1}^{\mathcal{A}}\) is the completion time of \({\tau }_{i,1}\) under share assignment \(\mathcal{A}\) and \({u}_{x}^{\mathcal{A}}(t)\) is the firm job share on processor \({P}_{x}\) under \(\mathcal{A}\). From Eq. (B.21), we further have \(\frac{{delay}_{i}(t)}{{f}_{i,1}^{\mathcal{A}}-t}<\frac{{delay}_{j}(t)}{ \tilde{f}_{{j,1}} ^{OSA}-t}=\frac{{delay}_{j}(t)}{{d}_{max}-{t}_{2}-t}\). Note that \({delay}_{i}(t)>{delay}_{j}(t)\). Thus, the first segment of each job \({\tau }_{i}\) in \({{\mathcal{T}}}_{c}\) is completed later than \({d}_{max}-{t}_{2}\) under \(\mathcal{A}\), i.e., \(\forall {\tau }_{i}\in {{\mathcal{T}}}_{c},{f}_{i,1}^{\mathcal{A}}>{d}_{max}-{t}_{2}\). Let \(Min\_A\) be the earliest arrival time of the second segments of all jobs in \({{\mathcal{T}}}_{c}\), i.e., \(Min\_A=min\{{A}_{i,2}|{\tau }_{i}\in {{\mathcal{T}}}_{c}\}\) under share assignment \(\mathcal{A}\). Thus, \(Min\_A>{d}_{max}-{t}_{2}\). From Eq. (B.15), we have

$$ \begin{gathered} Max\_d - Min\_A < Max\_d - \left( {d_{max} - t_{2} } \right) \hfill \\ \le d_{max} - t_{1} - \left( {d_{max} - t_{2} } \right) = t_{2} - t_{1} = \mathop \sum \limits_{{\tau_{i} \in {{\mathcal{T}}}_{c} }} c_{i,2} \left( t \right) \hfill \\ \end{gathered} $$
(B.26)

Equation (B.26) shows that at least one active firm job in \({{\mathcal{T}}}_{c}\) cannot be completed by \(Max\_d\), i.e., misses its deadline, if HS-2S-RTS employs the share assignment approach \(\mathcal{A}\). Note that \({{\mathcal{T}}}_{c}\) is a subset of \({{\mathcal{T}}}_{F}\left(t\right)\). Thus, at least one firm job in \({{\mathcal{T}}}_{F}\left(t\right)\) will miss its deadline if HS-2S-RTS employs a share assignment approach which achieves lower maximum firm job share than OSA. This lemma can be obtained. ■

1.3 Appendix C: An example of mirror job set and busy period job set

We use an example to illustrate the mirror job set and the busy period job set constructed for computing completion time bound (CTB) in Sect. 5.2.2. We also show the relation between these two job sets and the CTB.

Consider the simplest 2S-RTS with only one processor in each stage, some soft jobs and two firm jobs are being executed in this system. Table 9 shows the parameters of the two firm jobs and the CTBs of \({\tau }_{1,1}\) and \({\tau }_{2,1}\) are artificially computed.

Table 9 Job set 4

Since \({\tau }_{1,1}\) has larger delay than \({\tau }_{2,1}\), OSA will first compute CTB for \({\tau }_{1,1}\). \({\mathcal{J}}^{*}({\tau }_{1,1})\) only contains \({\varphi }_{1}^{*}\). Figure 17a shows the schedule of \({\mathcal{J}}^{*}({\tau }_{1,1})\) and the schedule of \({\tau }_{1,2}\) assuming that \({A}_{1,2}= \tilde{f} _{1,1}^{OSA}=140\) under the EDF policy. OSA will then computes CTB for \({\tau }_{2,1}\) based on the computed \( \tilde{f} _{1,1}^{OSA}=140\). \({\mathcal{J}}^{*}({\tau }_{2,1})\) contains two jobs. Figure 17b shows the schedule of \({\mathcal{J}}^{*}({\tau }_{2,1})\) and the schedule of \({\tau }_{1,2}\), \({\tau }_{2,2}\) assuming that \({A}_{1,2}= \tilde{f} _{1,1}^{OSA}=140\),\({A}_{2,2}= \tilde{f} _{2,1}^{OSA}=125\) under the EDF policy. One can see from Fig. 17 that the mirror job set has close relationship with CTBs. The schedules in Fig. 17a, b are symmetrical and they can be transformed into each other by \(t=150-{t}^{^{\prime}}\). Due to the symmetry relationship, the CTB of \({\tau }_{j,1}\) can be calculated by computing the earliest completion time of corresponding job \({\varphi }_{j}^{*}\) in its mirror job set.

Fig. 17
figure 17

Mirror job set (job set 4, dmax = 150)

Figure 18 shows how CTBs are derived with the help of busy period job set. As shown in Fig. 18a, the busy period where job \({\varphi }_{1}^{+}\) locates is [0, 10]. Since \( {\mathcal{J}}_{{bp}} (\tau _{{1,1}} ) = \emptyset \), \( \tilde{f} _{1,1}^{OSA}\) is determined by \( \tilde{f} _{1,1}^{OSA}=150-10=140\). As shown in Fig. 18b, the busy period where job \({\varphi }_{2}^{+}\) locates is [0, 25]. \({\mathcal{J}}_{bp}({\tau }_{2,1})\) contains one job, \({\varphi }_{bp\_1}\), whose parameter is decided by the state of \({\varphi }_{1}^{*}\) at \({A}_{2}^{+}=5\) when the modified mirror job set of \({\tau }_{2,1}\) are scheduled by the EDF policy. Considering the symmetry relationship between schedules, \( \tilde{f} _{2,1}^{OSA}\) can be calculated by the earliest idle time when \({\mathcal{J}}_{bp}({\tau }_{2,1})\) is scheduled by the EDF policy during [125, 150], i.e., \( \tilde{f} _{2,1}^{OSA}=125\).

Fig. 18
figure 18

Busy period job set (job set 4, dmax = 150)

1.4 Appendix D: Implementation details of UMC

UMC is a utilization-based mixed-criticality scheduler built upon the same main ideas as MC-ADAPT(Lee et al. 2017). UMC and MC-ADAPT have many common features. First, UMC assigns a virtual relative deadline to each firm job at its arrival in the same manner as MC-ADAPT assigning virtual deadlines to the high-criticality tasks. Second, both of them are schedulers that adopt utilization-based admission control. Third, to minimize the number of the dropping jobs/tasks, UMC drops the soft job that can achieve the maximum utilization decrease while MC-ADAPT drops the active low-criticality task with the maximum utilization. Below, we present the key implementation details of UMC.

1.4.1 Virtual deadlines and synthetic utilization

Let \({\tau }_{j}\) be a two-stage job whose arrival time, execution time and relative deadline are \({A}_{j}\), \({C}_{j}\) and \({D}_{j}\), respectively. \({GL}_{j}\) represents the guarantee level of \({\tau }_{j}\), where \({GL}_{j}=firm\) if \({\tau }_{j}\) is a firm job, and \({GL}_{j}=soft\) if \({\tau }_{j}\) is a soft job. Without loss of generality, we assume that \({\tau }_{j,1}\) and \({\tau }_{j,2}\) should be executed on \({P}_{1}\) and \({P}_{2}\), respectively. If \({\tau }_{j}\) is a firm job, UMC assigns a virtual relative deadline to \({\tau }_{j,1}\), referred to as \({V}_{j,1}\). The virtual absolute deadline of \({\tau }_{j,1}\) can be computed by \({A}_{j}+{V}_{j,1}\). To evaluate the loads contributed by aperiodic jobs, UMC employs the concept of synthetic utilization (Abdelzaher et al. 2004b). For brevity, we will use utilization to mean synthetic utilization in this section whenever such use does not cause confusion.

Clearly, the utilization of each processor consists of two parts: the utilization of the firm jobs and the utilization of the soft jobs. Since firm and soft jobs have different guarantee requirement, their utilizations are computed differently. We use the example of computing the utilization on processor \({P}_{1}\) and \({P}_{2}\) to illustrate how UMC computes utilization.

Let \(\stackrel{-}{{\mathcal{T}}}\left({P}_{x},t\right)\) be the set of admitted jobs that are assigned to processor \({P}_{x}\). The utilization of the firm jobs on processor \({P}_{1}\) is determined by the admitted firm jobs on \({P}_{1}\) whose virtual absolute deadlines have not expired, i.e., \({A}_{j}+{V}_{j,1}\ge t\):

$$ U_{F1} \left( t \right) = \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{j} \in {\overline{{\mathcal{T}}}}\left( {P_{1} ,t} \right)} \\ {A_{j} + V_{j,1} \ge t} \\ {GL_{j} = firm} \\ \end{array} }} \frac{{C_{j,1} }}{{V_{j,1} }} $$
(D.1)

The utilization of the firm jobs on processor \({P}_{2}\) is determined by the admitted firm jobs on \({P}_{2}\) whose absolute deadlines have not expired, i.e., \({A}_{j}+{D}_{j}\ge t\):

$$ U_{F2} \left( t \right) = \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{j} \in {\overline{{\mathcal{T}}}}\left( {P_{2} ,t} \right)} \\ {A_{j} + D_{j} \ge t} \\ {GL_{j} = firm} \\ \end{array} }} \frac{{C_{j,2} }}{{D_{j} - V_{j,1} }} $$
(D.2)

The utilization of the soft jobs on processor \({P}_{1}\) is determined by the admitted soft jobs on \({P}_{1}\) whose absolute deadlines have not expired:

$$ U_{S1} \left( t \right) = \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{j} \in {\overline{{\mathcal{T}}}}\left( {P_{1} ,t} \right)} \\ {A_{j} + D_{j} \ge t} \\ {GL_{j} = soft} \\ \end{array} }} \frac{{C_{j,1} }}{{D_{j} }} $$
(D.3)

The utilization of the soft jobs on processor \({P}_{2}\) is determined by the admitted soft jobs on \({P}_{2}\) who has arrived on \({P}_{2}\) but whose absolute deadlines have not expired:

$$ U_{S2} \left( t \right) = \mathop \sum \limits_{{\begin{array}{*{20}c} {\tau_{j} \in {\overline{{\mathcal{T}}}}\left( {P_{2} ,t} \right)} \\ {A_{j,2} \le t} \\ {A_{j} + D_{j} \ge t} \\ {GL_{j} = soft} \\ \end{array} }} \frac{{C_{j,2} }}{{D_{j} }} $$
(D.4)

Based on the above utilization definitions, UMC adopts the same virtual deadline assignment as the MC-ADAPT scheduler. Specifically, if \({\tau }_{j}\) is a firm job, upon the arrival of \({\tau }_{j}\), the virtual relative deadline \({V}_{j,1}\) is determined by

$$ V_{j,1} = x*D_{j} $$
(D.5)

where

$$ x = \frac{{U_{F1} \left( {A_{j} } \right) + \left( {C_{j,1} /V_{j,1} } \right)}}{{1 - U_{S1} \left( {A_{j} } \right)}} $$
(D.6)

Clearly, \({V}_{j,1}\) is readily obtained by Eqs. (D.5) and (D.6).

1.4.2 Admission control

Similar to MC-ADAPT, UMC uses a utilization-based policy to admit jobs online. If \({\tau }_{j}\) is a firm job, UMC guarantees that the utilizations on processor \({P}_{1}\) and \({P}_{2}\) do not exceed 1 at the arrival of \({\tau }_{j}\) to ensure all firm deadline constraints. Specifically, \({\tau }_{j}\) is admitted if

$$ U_{F1} \left( {A_{j} } \right) + U_{S1} \left( {A_{j} } \right) + \frac{{C_{j,1} }}{{V_{j,1} }} \le 1 $$
(D.7)

and

$$ U_{F2} \left( {A_{j} } \right) + U_{S2} \left( {A_{j} } \right) + \frac{{C_{j,2} }}{{D_{j} - V_{j,1} }} \le 1 $$
(D.8)

Meanwhile, soft jobs are scheduled in a best effort way. If \({\tau }_{j}\) is a soft job, UMC admits \({\tau }_{j,1}\) if the utilizations on processor \({P}_{1}\) do not exceed 1 at the arrival of \({\tau }_{j,1}\), i.e.,

$$ U_{F1} \left( {A_{j} } \right) + U_{S1} \left( {A_{j} } \right) + \frac{{C_{j,1} }}{{D_{j} }} \le 1 $$
(D.9)

Similarly, UMC admits \({\tau }_{j,2}\) if the utilizations on processor \({P}_{2}\) do not exceed 1 at the arrival of \({\tau }_{j,2}\), i.e.,

$$ U_{F2} \left( {A_{j,2} } \right) + U_{S2} \left( {A_{j,2} } \right) + \frac{{C_{j,2} }}{{D_{j} }} \le 1 $$
(D.10)

1.4.3 Dropping strategy

The dropping strategy of UMC employs the same idea as that of MC-ADAPT. Specifically, if some soft jobs should be dropped from some specific processor, UMC always drops the soft job that can achieve the maximum utilization decrease among all the candidate soft jobs. When calculating the utilization decrease due to dropping a soft job, care must be taken. Specifically, the utilization decrease is determined by the remaining execution time of the dropped job. Assume that \({\tau }_{j}\) is a soft aperiodic job. At time \(t\), if \({P}_{1}\) drops the soft segment \({\tau }_{j,1}\), \({U}_{S1}\left(t\right)\) decreases by \({c}_{j,1}(t)/{D}_{j}\), where \({c}_{j,1}(t)\) is the remaining execution time of \({\tau }_{j,1}\). Similarly, if \({P}_{2}\) drops the soft segment \({\tau }_{j,2}\), \({U}_{S2}\left(t\right)\) decreases by \({c}_{j,2}(t)/{D}_{j}\), where \({c}_{j,2}(t)\) is the remaining execution time of \({\tau }_{j,2}\). Note that the remaining utilization of \({\tau }_{j,k} (k=1,2)\), i.e., \(({C}_{j,k}-{c}_{j,k}\left(t\right))/{D}_{j}\), will be removed from \({U}_{Sk}\left(t\right)\) at time \({D}_{j}\), i.e., the absolute deadline of \({\tau }_{j}\).

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Leng, C., Qiao, Y., Hu, X.S. et al. Co-scheduling aperiodic real-time tasks with end-to-end firm and soft deadlines in two-stage systems. Real-Time Syst 56, 391–451 (2020). https://doi.org/10.1007/s11241-020-09352-1

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11241-020-09352-1

Keywords

Navigation