Automated competitive analysis of realtime scheduling with graph games
 790 Downloads
Abstract
This paper is devoted to automatic competitive analysis of realtime scheduling algorithms for firmdeadline tasksets, where only completed tasks contribute some utility to the system. Given such a taskset \({\mathcal {T}}\), the competitive ratio of an online scheduling algorithm \({\mathcal {A}}\) for \({\mathcal {T}}\) is the worstcase utility ratio of \({\mathcal {A}}\) over the utility achieved by a clairvoyant algorithm. We leverage the theory of quantitative graph games to address the competitive analysis and competitive synthesis problems. For the competitive analysis case, given any taskset \({\mathcal {T}}\) and any finitememory online scheduling algorithm \({\mathcal {A}}\), we show that the competitive ratio of \({\mathcal {A}}\) in \({\mathcal {T}}\) can be computed in polynomial time in the size of the state space of \({\mathcal {A}}\). Our approach is flexible as it also provides ways to model meaningful constraints on the released task sequences that determine the competitive ratio. We provide an experimental study of many wellknown online scheduling algorithms, which demonstrates the feasibility of our competitive analysis approach that effectively replaces human ingenuity (required for finding worstcase scenarios) by computing power. For the competitive synthesis case, we are just given a taskset \({\mathcal {T}}\), and the goal is to automatically synthesize an optimal online scheduling algorithm \({\mathcal {A}}\), i.e., one that guarantees the largest competitive ratio possible for \({\mathcal {T}}\). We show how the competitive synthesis problem can be reduced to a twoplayer graph game with partial information, and establish that the computational complexity of solving this game is Npcomplete. The competitive synthesis problem is hence in Np in the size of the state space of the nondeterministic labeled transition system encoding the taskset. Overall, the proposed framework assists in the selection of suitable scheduling algorithms for a given taskset, which is in fact the most common situation in realtime systems design.
Keywords
Realtime scheduling Firmdeadline tasks Competitive analysis Quantitative graph games1 Introduction
We study the wellknown problem of scheduling a sequence of dynamically arriving realtime task instances with firm deadlines on a single processor, by using automatic solution techniques based on graphs and games. In firmdeadline scheduling, a task instance (a job) that is completed by its deadline contributes a positive utility value to the system; a job that does not meet its deadline does not harm, but does not add any utility. The goal of the scheduling algorithm is to maximize the cumulated utility. Firmdeadline tasks arise in various application domains, e.g., machine scheduling (Gupta and Palis 2001), multimedia and video streaming (Abeni and Buttazzo 1998), QoS management in boundeddelay data network switches (Englert and Westermann 2007) and even networksonchip (Lu and Jantsch 2007), and other systems that may suffer from overload (Koren and Shasha 1995).
Competitive analysis (Borodin and ElYaniv 1998) has been the primary tool for studying the performance of such scheduling algorithms (Baruah et al. 1992). It allows to compare the performance of an online algorithm \({\mathcal {A}}\), which processes a sequence of inputs without knowing the future, with what can be achieved by an optimal offline algorithm \({\mathcal {C}}\) that does know the future (a clairvoyant algorithm): the competitive factor gives the worstcase performance ratio of \({\mathcal {A}}\) vs. \({\mathcal {C}}\) over all possible scenarios.
In a seminal paper, Baruah et al. (1992) proved that no online scheduling algorithm for single processors can achieve a competitive factor better than 1 / 4 over a clairvoyant algorithm in all possible job sequences of all possible tasksets. The proof is based on constructing a specific job sequence, which takes into account the online algorithm’s actions and thereby forces any such algorithm to deliver a suboptimal cumulated utility. For the special case of zerolaxity tasksets of uniform valuedensity (where utilities equal execution times), they also provided the online algorithm TD1 with competitive factor 1 / 4, concluding that 1 / 4 is a tight bound for this family of tasksets. In Baruah et al. (1992), the 1 / 4 upper bound was also generalized, by showing that there exist tasksets with importance ratio k, defined as the ratio of the maximum over the minimum valuedensity in the taskset, in which no online scheduler can have competitive factor larger than \(\frac{1}{(1+\sqrt{k})^2}\). In subsequent work (Koren and Shasha 1995), the online scheduler \(D^{ over }\) was introduced, which provides the performance guarantee of \(\frac{1}{(1+\sqrt{k})^2}\) in any taskset with importance ratio k, showing that this bound is also tight.
1.1 Problems considered in this paper
 (1)
The competitive analysis question asks to compute the competitive ratio of a given online algorithm.
 (2)
The competitive synthesis question asks to construct an online algorithm with optimal competitive ratio.
1.2 Detailed contributions
Our contributions on each problem are as follows.
1.2.1 Competitive analysis

In Sect. 2, we formally define our realtime scheduling problem.

In Sect. 3, we provide a formalism for online and clairvoyant scheduling algorithms as labeled transitions systems. We also show how automata on infinite words can be used to express natural constraints on the set of released job sequences (such as sporadicity and workload constraints).

In Sects. 4.1 and 4.2, we define graph objectives on weighted multigraphs and provide algorithms for solving those objectives.

In Sect. 4.3, we present a formal reduction of the competitive analysis problem to solving a multiobjective graph problem. Section 4.4 describes both general and implementationspecific optimizations for the above reduction, which considerably reduce the size of the obtained graph and thus make our approach feasible in practice.

In Sect. 4.5, we present a comparative study of the competitive ratio of several existing firmdeadline realtime scheduling algorithms. Our results show that the competitive ratio of any algorithm varies highly when varying tasksets, which highlights the usefulness of an automated competitive analysis framework: after all, our framework allows to replace human ingenuity (required for finding worstcase scenarios) by computing power, as the application designer can analyze different scheduling algorithms for the specific taskset arising in some application and compare their competitive ratio.
1.2.2 Competitive synthesis

In Sect. 5.1, we consider a game model (a partialobservation game with memoryless strategies for Player 1 with meanpayoff and ratio objectives) that is suitable for the competitive synthesis of realtime scheduling algorithms. The meanpayoff (resp. ratio) objective allows to compute the cumulated utility (resp. competitive ratio) of the best online algorithm under the worstcase task sequence.

In Sect. 5.2, we establish that the relevant decision problems for the underlying game are Npcomplete in the size of the game graph.

In Sect. 5.3, we use the game of Sect. 5.1 to tackle two relevant synthesis problems for a given taskset \({\mathcal {T}}\): first, we show that constructing an online scheduling algorithm with optimal worstcase average utility for \({\mathcal {T}}\) is in Np \(\cap \) coNp in general, and polynomial in the size of the underlying game graph for reasonable choices of task utility values. Second, we show that constructing an online scheduling algorithm with optimal competitive ratio for \({\mathcal {T}}\) is in Np. Note that these complexities are with respect to the size of the constructed algorithm, represented explicitly as a labeled transition system. As a function of the input taskset \({\mathcal {T}}\) given in binary, all polynomial upper bounds become exponential upper bounds in the worst case.
1.3 Related work
Algorithmic game theory (Nisan et al. 2007) has been applied to classic scheduling problems since decades, primarily in economics and operations research, see e.g. (Koutsoupias 2011) for just one example of some more recent work. In the realtime systems context, mechanism design (Porter 2004) is an area where game theory is actually the method of choice: rather than determining the performance of a scheduling algorithm resp. finding an optimal one for some given taskset, i.e., for some given set of rules, which is our goal, the challenge in mechanism design is to define the rules that allow the system to to achieve certain goals, e.g., performance, in the presence of rational agents that strive for maximizing some local benefit.
However, game theory has also been applied to problems that are more closely related to the one studied in this paper. In particular, Sheikh et. al. (2011) considered the problem of nonpreemptively scheduling periodic hard realtime tasks (where all jobs must make their deadlines), and used an optimal strategy in the context of noncooperative games to optimally determine the initial offsets of all tasks in the periodic schedule. Altisen et al. (2002) used games for synthesizing controllers dedicated to meeting all deadlines in systems with shared resources. Bonifaci and MarchettiSpaccamela (2012) employed graph games for automatic feasibility analysis of sporadic realtime tasks in multiprocessor systems: given a set of sporadic tasks (where consecutive releases of jobs of the same task are separated at least by some sporadicity interval), the algorithms provided in Bonifaci and MarchettiSpaccamela (2012) allow to decide, in polynomial time, whether some given scheduling algorithm will meet all deadlines. A partialinformation game variant of their approach also allows to synthesize an optimal scheduling algorithm for a given taskset (albeit not in polynomial time).
A recent work (Lübbecke et al. 2016) studies the synthesis of schedulers where the task is to minimize the weighted sum of completion times of the released tasks. It is shown how the competitive ratio can be approximated in various online schemes, e.g. for parallel, related, and unrelated machines. We note that our online setting differs on the objective function that needs to be obtained (i.e., maximizing utility vs minimizing completion times).
Regarding firmdeadline task scheduling in general, starting out from (Baruah et al. 1992), classic realtime systems research has studied the competitive factor of both simple and extended realtime scheduling algorithms. The competitive analysis of simple algorithms has been extended in various ways later on: energy consumption (Aydin et al. 2004; Devadas et al. 2010) (including dynamic voltage scaling), imprecise computation tasks (having both a mandatory and an optional part and associated utilities) (Baruah and Hickey 1998), lower bounds on slack time (Baruah and Haritsa 1997), and fairness (Palis 2004). Note that dealing with these extensions involved considerable ingenuity and efforts w.r.t. identifying and analyzing appropriate worstcase scenarios, which do not necessarily carry over even to minor variants of the problem. Maximizing cumulated utility while satisfying multiple resource constraints is also the purpose of the QRAM (QoSbased Resource Allocation Model) (Rajkumar et al. 1997) approach.
Preliminary versions of this work have appeared in Chatterjee et al. (2014) (competitive analysis) and (Chatterjee et al. 2013) (competitive synthesis). The present paper unifies the two topics in a common framework, which we develop in more detail. Additionally, we have extended our experiments to also incorporate the wellknown scheduling algorithms TD1 (Baruah et al. 1992) and least laxity first (Leung 1989). Finally, we have extended our competitive synthesis approach to also cover constrained environments (imposing safety, liveness and limitaverage constraints for the generated job sequences).
2 Problem definition
We consider a finite set of tasks \({\mathcal {T}}=\{\tau _1,\dots ,\tau _N\}\), to be executed on a single processor. We assume a discrete notion of realtime \(t=k\varepsilon \), \(k\geqslant 1\), where \(\varepsilon >0\) is both the unit time and the smallest unit of preemption (called a slot). Since both task releases and scheduling activities occur at slot boundaries only, all timing values are specified as positive integers. Every task \(\tau _i\) releases countably many task instances (called jobs) \(J_{i,j}:=(\tau _i,j)\in {\mathcal {T}}\times \mathbb {N}^{+}\) (where \(\mathbb {N}^{+}\) is the set of positive integers) over time (i.e., \(J_{i,j}\) denotes that a job of task i is released at time j). All jobs, of all tasks, are independent of each other and can be preempted and resumed during execution without any overhead. Every task \(\tau _i\), for \(1\leqslant i \leqslant N\), is characterized by a 3tuple \(\tau _i=(C_i,D_i,V_i)\) consisting of its nonzero worstcase execution time \(C_i\in \mathbb {N}^{+}\) (slots), its nonzero relative deadline \(D_i\in \mathbb {N}^{+}\) (slots) and its nonzero utility value \(V_i \in \mathbb {N}^{+}\) (rational utility values \(V_1,\dots ,V_N\) can be mapped to integers by proper scaling). We denote with \(D_{\max }=\max _{1\leqslant i \leqslant N} D_i\) the maximum relative deadline in \({\mathcal {T}}\). Every job \(J_{i,j}\) needs the processor for \(C_i\) (not necessarily consecutive) slots exclusively to execute to completion. All tasks have firm deadlines: only a job \(J_{i,j}\) that completes within \(D_i\) slots, as measured from its release time, provides utility \(V_i\) to the system. A job that misses its deadline does not harm but provides zero utility. The goal of a realtime scheduling algorithm in this model is to maximize the cumulated utility, which is the sum of \(V_i\) times the number of jobs \(J_{i,j}\) that can be completed by their deadlines, in a sequence of job releases generated by the adversary.
2.1 Notation on sequences
Let X be a finite set. For an infinite sequence \(x=(x^\ell )_{\ell \geqslant 1}=(x^1,x^2, \ldots )\) of elements in X, we denote by \(x^{\ell }\) the element in the \(\ell \)th position of x, and denote by \(x(\ell )=(x^1,x^2,\ldots ,x^{\ell })\) the finite prefix of x up to position \(\ell \). We denote by \(X^\infty \) the set of all infinite sequences of elements from X. Given a function \(f: X\rightarrow \mathbb {Z}\) (where \(\mathbb {Z}\) is the set of integers) and a sequence \(x\in X^{\infty }\), we denote with \(f(x, k)=\sum _{\ell =1}^kf(x^{\ell })\) the sum of the images of the first k sequence elements under f.
2.2 Job sequences
The released jobs form a discrete sequence, where at each time point the adversary releases at most one new job from every task. Formally, the adversary generates an infinite job sequence \(\sigma =(\sigma ^{\ell })_{\ell \geqslant 1}\in \Sigma ^\infty \), where \(\Sigma =2^{{\mathcal {T}}}\). The release of one job of task \(\tau _i\) in time \(\ell \), for some \(\ell \in \mathbb {N}^{+}\), is denoted by having \(\tau _i\in \sigma ^{\ell }\). Then, a (single) new job \(J_{i,j}\) of task \(\tau _i\) is released at the beginning of slot \(\ell \): \(j=\ell \) denotes the release time of \(J_{i,j}\), which is also the earliest time that the job \(J_{i,j}\) can be executed, and \(d_{i,j}=j+D_i\) denotes its absolute deadline.
2.3 Admissible job sequences
 (\({\mathcal {S}}\))

Safety constraints, which are restrictions that have to hold in every finite prefix of an admissible job sequence; e.g., they can be used to enforce job release constraints such as periodicity or sporadicity, and to impose temporal workload restrictions.
 (\({\mathcal {L}}\))

Liveness restrictions, which assert infinite repetition of certain job releases in a job sequence; e.g., they can be used to force the adversary to release a certain task infinitely often.
 (\({\mathcal {W}}\))

Limitaverage constraints, which restrict the long run average behavior of a job sequence; e.g., they can be used to enforce that the average load in the job sequences does not exceed a threshold.
These three types of constraints will be made precise in the next section where we formally state the problem definition.
2.4 Schedule
 1.
\(\tau _i\in \sigma ^{\ell j}\) (the job has been released),
 2.
\(j < D_i\) (the job’s deadline has not passed),
 3.
\(\{k:k>0{ and}\pi ^{\ell k}=(\tau _i,j'){ and}k+j'=j\}<C_i\) (the job released in slot \(\ell j\) has not been completed).
2.5 Competitive ratio
Remark 1
Since, according to the definition of the competitive ratio \({\mathcal {CR}}_{{\mathcal {J}}}\) in Eq. (1), we focus on worstcase analysis, we do not consider randomized algorithms (such as Locke’s besteffort policy (Locke 1986)). Generally, for worstcase analysis, randomization can be handled by additional choices for the adversary. For the same reason, we do not consider scheduling algorithms that can use the unbounded history of job releases to predict the future (e.g., to capture correlations).
3 Modeling formalisms in our framework
In this section, we present the definitions of several types of labeled transition systems (LTSs). We use LTSs as the modeling formalism for online and clairvoyant scheduling algorithms, as well as for modeling optional constraints on the released job sequences.
3.1 Labeled Transition Systems
We will consider both online and offline scheduling algorithms that are formally modeled as labeled transition systems (LTSs): every deterministic finitestate online scheduling algorithm can be represented as a deterministic LTS, such that every input job sequence generates a unique run that determines the corresponding schedule. On the other hand, an offline algorithm can be represented as a nondeterministic LTS, which uses the nondeterminism to guess the appropriate job to schedule.
3.1.1 Labeled transitions systems (LTSs)
Formally, a labeled transition system (LTS) is a tuple \(L=(S, s_1, \Sigma , \Pi , \Delta )\), where S is a finite set of states, \(s_1\in S\) is the initial state, \(\Sigma \) is a finite set of input actions, \(\Pi \) is a finite set of output actions, and \(\Delta \subseteq S\times \Sigma \times S\times \Pi \) is the transition relation. Intuitively, \((s,x,s',y)\in \Delta \) if, given the current state s and input x, the LTS outputs y and makes a transition to state \(s'\). If the LTS is deterministic, then there is always a unique output and next state, i.e., \(\Delta \) is a function \(\Delta : S\times \Sigma \rightarrow S\times \Pi \). Given an input sequence \(\sigma \in \Sigma ^{\infty }\), a run of L on \(\sigma \) is a sequence \(\rho _{{\mathcal {A}}}=(p_{\ell },\sigma _{\ell }, q_{\ell }, \pi _{\ell })_{\ell \geqslant 1}\in \Delta ^{\infty }\) such that \(p_1=s_1\) and for all \(\ell \geqslant 2\), we have \(p_{\ell }=q_{\ell 1}\). For a deterministic LTS, for each input sequence, there is a unique run.
3.1.2 Deterministic LTS for an online algorithm
Most scheduling algorithms [such as EDF, FIFO, DOVER (Koren and Shasha 1995), TD1 (Baruah et al. 1992)] can be represented as a deterministic LTS. An illustration for EDF is given in the following example.
Example 1
Consider the taskset \({\mathcal {T}}=\{\tau _1, \tau _2\}\), with \(D_1=3\), \(D_2=2\) and \(C_1=C_2=2\). Figure 1 represents the EDF (Earliest Deadline First) scheduling policy as a deterministic LTS for \({\mathcal {T}}\). Each state is represented by a matrix M, such that M[i, j], \(1\leqslant i \leqslant N\), \(1\leqslant j \leqslant D_{\max }1\), denotes the remaining execution time of the job of task \(\tau _i\) released j slots ago. Every transition is labeled with a set \(T\in \Sigma \) of released tasks as well as with \((\tau _i, j)\in \Pi \), which denotes the unique job \(J_{i,\ell j}\) to be scheduled in the current slot \(\ell \). Released jobs with no chance of being scheduled are not included in the state space. For example, while being in the topmost state, the release of \(\tau _1\) makes the LTS take the transition to the leftmost state, where 1 unit of work is scheduled for the released task, and 1 unit remains, encoded by writing 1 in position (1, 1) of the matrix M. In the next round, a new release of \(\tau _2\) will take the LTS to the middle state, with 2 units of workload in position (1, 1). This is because the 2nd workload of the first job is scheduled (thus the first job is scheduled to completion), and the newly released job is not scheduled in the current slot. Thus all 2 units of workload of the currently released job remain.
All scheduling algorithms considered in this paper have been encoded similarly to EDF using the matrix M. Some more involved schedulers, such as DOVER, require some extra bits of information stored in the state.
3.1.3 The nondeterministic LTS
 1.
inserting all \(\tau _i\in T\) into column 1 of M,
 2.
decrementing the value at position M[i, j], and
 3.
shifting the contents of M by one column to the right, while initializing column 1 to all 0.
Remark 2
Note that the size of the above LTSs is the size of the state space of the corresponding scheduling algorithm. If the input consists of a succinct description of these algorithms [e.g., as a circuit (Galperin and Wigderson 1983)], then the size of the corresponding LTS is, in general, exponential in the size of the input. This statespace explosion is generally unavoidable (Clarke et al. 1999). In the complexity analysis of our algorithms, we consider all scheduling algorithms to be given in the explicit form of LTSs. When appropriate, we will state what the obtained results imply for the case where the input is succinct.
3.2 Admissible job sequences
 (\({\mathcal {S}}\))

Safety constraints are defined by a deterministic LTS \(L_{{\mathcal {S}}}=(S_{{\mathcal {S}}}, s_{{\mathcal {S}}}, \Sigma , \varnothing , \Delta _{{\mathcal {S}}})\), with a distinguished absorbing reject state \(s_{r}\in S_{{\mathcal {S}}}\). An absorbing state is a state that has outgoing transitions only to itself. Every job sequence \(\sigma \) defines a unique run \(\rho _{{\mathcal {S}}}^{\sigma }\) in \(L_{{\mathcal {S}}}\), such that either no transition to \(s_{r}\) appears in \(\rho _{{\mathcal {S}}}^{\sigma }\), or every such transition is followed solely by selftransitions to \(s_r\). A job sequence \(\sigma \) is admissible to \(L_{{\mathcal {S}}}\), if \(\rho _{{\mathcal {S}}}^{\sigma }\) does not contain a transition to \(s_r\). To obtain a safety LTS that does not restrict \({\mathcal {J}}\) at all, we simply use a trivial deterministic \(L_{{\mathcal {S}}}\) with no transition to \(s_r\). Safety constraints restrict the adversary to release job sequences, where every finite prefix satisfies some property (as they lead to the absorbing reject state \(s_r\) of \(L_{{\mathcal {S}}}\) otherwise). Some wellknown examples of safety constraints are (i) periodicity and/or sporadicity constraints, where there are fixed and/or a minimum time between the release of any two consecutive jobs of a given task, and (ii) absolute workload constraints (Golestani 1991; Cruz 1991), where the total workload released in the last k slots, for some fixed k, is not allowed to exceed a threshold \(\lambda \). For example, in the case of absolute workload constraints, \(L_{{\mathcal {S}}}\) simply encodes the workload in the last k slots in its state, and makes a transition to \(s_r\) whenever the workload exceeds \(\lambda \). Figure 2 shows an example of a constraint LTS for the taskset \({\mathcal {T}}=\{\tau _1, \tau _2\}\) with \(C_1=C_2=1\) that restricts the adversary to release at most 2 units of workload in the last 2 slots.
 (\({\varvec{{\mathcal {L}}}}\))

Liveness constraints are modeled as a deterministic LTS \(L_{{\mathcal {L}}}=(S_{{\mathcal {L}}}, s_{{\mathcal {L}}}, \Sigma , \varnothing , \Delta _{{\mathcal {L}}})\) with a distinguished accept state \(s_a\in S_{{\mathcal {L}}}\). A job sequence \(\sigma \) is admissible to the liveness LTS \(L_{{\mathcal {L}}}\) if \(\rho _{{\mathcal {L}}}^{\sigma }\) contains infinitely many transitions to \(s_a\). For the case where there are no liveness constraint in \({\mathcal {J}}\), we use a LTS \(L_{{\mathcal {L}}}\) consisting of state \(s_a\) only. Liveness constraints force the adversary to release job sequences that satisfy some property infinitely often. For example, they could be used to guarantee that the release of some particular task \(\tau _i\) does not eventually stall; the constraint is specified by a twostate LTS \(L_{{\mathcal {L}}}\) that visits \(s_a\) whenever the current job set includes \(\tau _i\). A liveness constraint can also be used to prohibit infinitely long periods of overload (Baruah et al. 1992), by choosing \(s_a\) as the idle state. Figure 3 shows an example of a constraint LTS for the taskset \({\mathcal {T}}=\{\tau _1, \tau _2\}\) that forces the adversary to release \(\tau _2\) infinitely often.
 (\({\varvec{{\mathcal {W}}}}\))

Limitaverage constraints are defined by a deterministic weighted LTS \(L_{{\mathcal {W}}}=(S_{{\mathcal {W}}}, s_{{\mathcal {W}}}, \Sigma , \varnothing , \Delta _{{\mathcal {W}}})\) equipped with a weight function \(w:\Delta _{{\mathcal {W}}}\rightarrow \mathbb {Z}^{d}\) that assigns a vector of weights to every transition \(\delta _{{\mathcal {W}}}\in \Delta _{{\mathcal {W}}}\). Given a threshold vector \(\vec {\lambda }\in \mathbb {Q}^{d}\), where \(\mathbb {Q}\) denotes the set of all rational numbers, a job sequence \(\sigma \) and the corresponding run \(\rho _{{\mathcal {W}}}^{\sigma }=(\delta _{{\mathcal {W}}}^\ell )_{\ell \geqslant 1}\) of \(L_{{\mathcal {W}}}\), the job sequence is admissible to \(L_{{\mathcal {W}}}\) if \(\liminf _{k\rightarrow \infty } \frac{1}{k}\cdot w(\rho _{{\mathcal {W}}}^\sigma ,k)\leqslant \vec {\lambda }\) with \(w(\rho _{{\mathcal {W}}}^\sigma ,k)=\sum _{i=1}^k w(\delta _{{\mathcal {W}}}^\ell )\). Consider a relaxed notion of workload constraints, where the adversary is restricted to generate job sequences whose average workload does not exceed a threshold \(\lambda \). Since this constraint still allows “busy” intervals where the workload temporarily exceeds \(\lambda \), it cannot be expressed as a safety constraint. To support such interesting average constraints of admissible job sequences, where the adversary is more relaxed than under absolute constraints, our framework explicitly supports limitaverage constraints. Therefore, it is possible to express the average workload assumptions commonly used in the analysis of aperiodic task scheduling in softrealtime systems (Abeni and Buttazzo 1998; Haritsa et al. 1990). Other interesting cases of limitaverage constraints include restricting the average sporadicity, and, in particular, average energy: ensuring that the limitaverage of the energy consumption is below a certain threshold is an important concern in modern realtime systems (Aydin et al. 2004). Figure 4 shows an example of a constraint LTS for the taskset \({\mathcal {T}}=\{\tau _1, \tau _2\}\) with \(C_1=C_2=1\), which can be used to restrict the average workload the adversary is allowed to release in the long run.
Remark 3
While, in general, such constraints are encoded as independent automata, it is often possible to encode certain constraints directly in the nondeterministic LTS of the clairvoyant scheduler instead. In particular, this is possible for restricting the limitaverage workload, generating finite intervals of overload, and releasing a particular job infinitely often.
3.2.1 Synchronous product of LTSs
 1.
\(S\subseteq S_1\times S_2\),
 2.
\(s=(s_1, s_2)\),
 3.
\(\Pi ' = \Pi \times \Pi \), and
 4.
\(\Delta \subseteq S\times \Sigma \times S\times \Pi '\) such that \(((q_1,q_2),T, (q'_1,q'_2), (P_1, P_2)) \in \Delta \) iff \((q_1, T, q'_1, P_1)\in \Delta _1\) and \((q_2, T, q'_2, P_2)\in \Delta _2\).
3.2.2 Overall approach for computing \({\mathcal {CR}}\)
 1.
Construct a nondeterministic LTS \(L_{{\mathcal {C}}}\) corresponding to the clairvoyant offline algorithm \({\mathcal {C}}\). Note that since \(L_{{\mathcal {C}}}\) is nondeterministic, for every admissible job sequence \(\sigma \), there are many possible runs in \(L_{{\mathcal {C}}}\), of course also including the runs with maximum cumulative utility.
 2.
Take the synchronous product LTS \(L_{{\mathcal {A}}} \times L_{{\mathcal {C}}} \times L_{{\mathcal {S}}}\times L_{{\mathcal {L}}}\times L_{{\mathcal {W}}}\). By doing so, a path in the product graph corresponds to identically labeled paths in the LTSs, and thus ensures that they agree on the same job sequence \(\sigma \). This product can be represented by a multiobjective graph (as introduced in Sect. 4.1).
 3.
Determine \({\mathcal {CR}}_{\mathcal {J}}({\mathcal {A}})\) by reducing the computation of the ratio given in Eq. (1) to solving a multiobjective problem on the product graph.
 4.
4 Competitive analysis of online scheduling algorithms
In this section, we address the competitive analysis problem: given a taskset, a LTS \(L_{{\mathcal {A}}}\) for the online scheduling algorithm, and optional constraint automata \(L_{{\mathcal {S}}}\), \(L_{{\mathcal {L}}}\), \(L_{{\mathcal {W}}}\) for the set of admissible job sequences \({\mathcal {J}}\), our algorithms compute the competitive ratio \({\mathcal {CR}}_{\mathcal {J}}({\mathcal {A}})\) of \({\mathcal {A}}\) in \({\mathcal {J}}\). Our presentation is organized as follows: in Sect. 4.1, we define qualitative and quantitative objectives on multigraphs. In Sect. 4.2, we provide algorithms for solving these graph objectives. In Sect. 4.3, we establish a formal reduction of computing the competitive ratio \({\mathcal {CR}}_{\mathcal {J}}({\mathcal {A}})\) of an online scheduling algorithm \({\mathcal {A}}\) to solving for graph objectives on a suitable multigraph. In Sect. 4.4, we describe several generic optimizations for this reduction that make the reduction practical. In Sect. 4.5, we provide the results of an automatic competitive analysis of a wide range of classic online scheduling algorithms, using a prototype implementation of our framework.
4.1 Graphs with multiple objectives
In this subsection, we define various objectives on graphs and outline the algorithms for solving them. We later show how the competitive analysis of online schedulers reduces to the solution algorithms of this section.
4.1.1 Multigraphs
A multigraph \(G=(V,E)\), hereinafter called simply a graph, consists of a finite set V of n nodes, and a finite set of m directed multiple edges \(E \subset V\times V\times \mathbb {N}^{+}\). For brevity, we will refer to an edge (u, v, i) as (u, v), when i is not relevant. We consider graphs in which for all \(u\in V\), we have \((u,v)\in E\) for some \(v\in V\), i.e., every node has at least one outgoing edge. An infinite path \(\rho \) of G is an infinite sequence of edges \(e^1, e^2,\dots \) such that, for all \(i\geqslant 1\) with \(e^i=(u^i, v^i)\), we have \(v^i=u^{i+1}\). Every such path \(\rho \) induces a sequence of nodes \((u^i)_{i\geqslant 1}\), which we will also call a path when the distinction is clear from the context, where \(\rho ^i\) refers to \(u^i\) instead of \(e^i\). Finally, we denote by \(\Omega \) the set of all paths of G.
4.1.2 Objectives
Given a graph G, an objective \(\Phi \) is a subset of \(\Omega \) that defines the desired set of paths. We will consider safety, liveness, meanpayoff (limitaverage), and ratio objectives, and their conjunction for multiple objectives.
Safety and liveness objectives We consider safety and liveness objectives, both defined with respect to some subset of nodes \(X, Y \subseteq V\). Given \(X\subseteq V\), the safety objective, defined as \(\mathsf {Safe}(X)=\{\rho \in \Omega :~\forall i\geqslant 1, \rho ^i\not \in X \}\), represents the set of all paths that never visit the set X. The liveness objective defined as \(\mathsf {Live}(Y)=\{\rho \in \Omega :~\forall j\exists i>j \text{ s.t. } \rho ^i\in Y\}\) represents the set of all paths that visit Y infinitely often. Meanpayoff and ratio objectives We consider the meanpayoff and ratio objectives, defined with respect to a weight function and a threshold. A weight function \(w: E\rightarrow \mathbb {Z}^{d}\) assigns to each edge of G a vector of \(d\) integers. A weight function naturally extends to paths, with \(w(\rho , k)=\sum _{i=1}^k w(\rho ^i)\).
Example 2
Consider the multigraph shown in Fig. 5, with a weight function of dimension \(d=2\). Note that there are two edges from node 3 to node 5 (represented as edges (3, 5, 1) and (3, 5, 2)). In the graph we have a weight function with dimension 2. Note that the two edges from node 3 to node 5 have incomparable weight vectors.
4.1.3 Decision problem
The decision problem we consider is as follows: given the graph G, an initial node \(s\in V\), and an objective \(\Phi \) (which can be a conjunction of several objectives), determine whether there exists a path \(\rho \) that starts from s and belongs to \(\Phi \), i.e., \(\rho \in \Phi \). For simplicity of presentation, we assume that every \(u\in V\) is reachable from s (unreachable nodes can be discarded by preprocessing G in \(\mathcal {O}(m)\) time). We first present algorithms for each of safety, liveness, meanpayoff, and ratio objectives separately, and then for their conjunction.
4.2 Algorithms for solving graphs with multiple objectives
We now describe the algorithms for solving the graph objectives introduced in the last subsection.
4.2.1 Algorithms for safety and liveness objectives
The algorithm for the objective \(\mathsf {Safe}(X)\) is straightforward. We first remove the set X of nodes and then perform an SCC (maximal strongly connected component) decomposition of G. Then, we perform a single graph traversal to identify the set of nodes \(V_X\) which can reach an SCC that contains at least one edge (i.e., it contains either a single node with a selfloop, or more than one nodes). Note that since we have removed the set X, we have that \(V_X\cap X=\varnothing \). In the end, we obtain a graph \(G=(V_X, E_X)\) such that \(E_X=E\cap (V_X\times V_X)\). Thus, the objective \(\mathsf {Safe}(X)\) is satisfied in the resulting graph, and the algorithm answers yes iff \(s \in V_X\). Using the algorithm of Tarjan (1972) for performing the SCC decomposition, this algorithm requires \(\mathcal {O}(m)\) time.
To solve for the objective \(\mathsf {Live}(Y)\), initially perform an SCC decomposition of G. We call an SCC \(V_{\text {SCC}}\) live, if (i) either \(V_{\text {SCC}}>1\), or \(V_{\text {SCC}}=\{u\}\) and \((u,u)\in E\); and (ii) \(V_{\text {SCC}}\cap Y \ne \varnothing \). Then \(\mathsf {Live}(Y)\) is satisfied in G iff there exists a live SCC \(V_{\text {SCC}}\) that is reachable from s. This is because every node u in \(V_{\text {SCC}}\) can reach every node in \(V_{\text {SCC}}\), and thus there is a path \(u\rightsquigarrow u\) in \(V_{\text {SCC}}\). Since \(V_{\text {SCC}}\) is a live SCC, the same holds for nodes \(u\in V_{\text {SCC}}\cap Y\). Then a witness path can be constructed which first reaches some node \(u\in V_{\text {SCC}}\cap Y\), and then keeps repeating the path \(u \rightsquigarrow u\). Using the algorithm of (Tarjan 1972) for performing the SCC decomposition, this algorithm also requires \(\mathcal {O}(m)\) time.
4.2.2 Algorithms for meanpayoff objectives

Single dimension In the case of a singledimensional weight function, a single weight is assigned to every edge, and the decision problem of the meanpayoff objective reduces to determining the mean weight of a minimumweight simple cycle in G, as the latter also determines the meanweight by infinite repetition. Using the algorithms of Karp (1978 and Madani (2002), this process requires \(\mathcal {O}(n\cdot m)\) time. When the objective is satisfied, the process also returns a simple cycle C, as a witness to the objective. From C, a path \(\rho \in \mathsf{MP}(w, \vec {\nu })\) is constructed by infinite repetitions of C.
 Multiple dimensions When \(d>1\), the meanpayoff objective reduces to determining the feasibility of a linear program (LP). For \(u\in V\), let \(\mathsf{IN}(u)\) be the set of incoming, and \(\mathsf{OUT}(u)\) the set of outgoing edges of u. As shown in Velner et al. (2015), G satisfies \(\mathsf{MP}(w, \vec {\nu })\) iff the following set of constraints on \(\vec {x}=(x_e)_{e\in E_{\text {SCC}}}\) with \(x_e \in \mathbb {Q}\) is satisfied simultaneously on some SCC \(V_{\text {SCC}}\) of G with induced edges \(E_{\text {SCC}}\subseteq E\).The quantities \(x_e\) are intuitively interpreted as “flows”. The first constraint specifies that the flow of each edge is nonnegative. The second constraint is a flowconservation constraint. The third constraint specifies that the objective is satisfied if we consider the relative contribution of the weight of each edge, according to the flow of the edge. The last constraint asks that the preceding constraints are satisfied by a nontrivial (positive) flow. Hence, when \(d>1\), the decision problem reduces to solving a LP, and the time complexity is polynomial (Khachiyan 1979).$$\begin{aligned}&x_e\geqslant 0&\&e\in E_{\text {SCC}}\nonumber \\&\sum _{e\in \mathsf{IN}(u)}{x_e} = \sum _{e\in \mathsf{OUT}(u)}{x_e}&\&u\in V_{\text {SCC}}\\&\sum _{e\in E_{\text {SCC}}} x_e\cdot w(e) \leqslant \vec {\nu } \nonumber \\&\sum _{e\in E_{\text {SCC}}}x_e\geqslant 1\nonumber \end{aligned}$$(2)
 1.
Construction of a multicycle from the feasible solution; and
 2.
Construction of an infinite witness path from the multicycle.
 (i)
find a pair \((e_i, m_i)=\arg \min _{(e_j, m_j)\in \mathcal {X}}m_j\),
 (ii)
form a cycle \(C_i\) that contains \(e_i\) and only edges that appear in \(\mathcal {X}\) (because of Eq. (2), this is always possible),
 (iii)
add the pair \((C_i, m_i)\) in the multicycle \(\mathcal {MC}\),
 (iv)
subtract \(m_i\) from all elements \((e_j,m_j)\) of \(\mathcal {X}\) such that the edge \(e_j\) appears in \(C_i\),
 (v)
remove from \(\mathcal {X}\) all \((e_j, 0)\) pairs, and repeat.
4.2.3 Algorithm for ratio objectives
We now consider ratio objectives, and present a reduction to meanpayoff objectives. Consider the weight functions \(w_1\), \(w_2\) and the threshold vector \(\vec {\nu }=\frac{\vec {p}}{\vec {q}}\) as the componentwise division of vectors \(\vec {p},\vec {q}\in \mathbb {N}^{d}\). We define a new weight function \(w: E\rightarrow \mathbb {Z}^{d}\) such that, for all \(e\in E\), we have \(w(e)=\vec {q}\cdot w_1(e)\vec {p}\cdot w_2(e)\) (where \(\cdot \) denotes componentwise multiplication). It is easy to verify that \(\mathsf{Ratio}(w_1, w_2, \vec {\nu })=\mathsf{MP}(w, \vec {0})\), and thus we solve the ratio objective by solving the new meanpayoff objective, as described above.
4.2.4 Algorithms for conjunctions of objectives
 1.
Initially compute \(G_X\) from G as in the case of a single safety objective.
 2.
Then, perform an SCC decomposition on \(G_X\).
 3.
For every live SCC \(V_{\text {SCC}}\) that is reachable from s, solve for the meanpayoff objective in \(V_{\text {SCC}}\). Return yes, if \(\mathsf{MP}(w,\vec {\nu })\) is satisfied in any such \(V_{\text {SCC}}\).
Theorem 1
 1.
\(\mathcal {O}(n\cdot m)\) time, if \(d=1\).
 2.
Polynomial time, if \(d>1\).
Example 3
Consider the graph in Fig. 5. Starting from node 1, the meanpayoffobjective \(\mathsf{MP}(w, \vec {0})\) is satisfied by the multicycle \(\mathcal {MC}=\{(C_1, 1), (C_2, 2)\}\), with \(C_1=[(1,2), (2,1)]\) and \(C_2=[(3,5), (5,3)]\). A solution to the corresponding LP is \(x_{(1,2)}=x_{(2,1)}=\frac{1}{3}\) and \(x_{(3,5)}=x_{(5,3)}=\frac{2}{3}\), and \(x_e=0\) for all other \(e\in E\). Procedure 1 then generates a witness path for the objective. The objective is also satisfied in conjunction with \(\mathsf {Safe}(\{4\})\) or \(\mathsf {Live}(\{4\})\). In the latter case, a witness path additionally traverses the edges (3, 4) and (4, 5) before transitioning from \(C_1\) to \(C_2\).
Example 4
Consider the same graph of Fig. 5, where now instead of a single weight function of two dimensions, we have two weight functions \(w_1, w_2: E\rightarrow \mathbb {Z}\), of a single dimension each. The first (resp. second) weight of each edge is with respect to the weight function \(w_1\) (resp. \(w_2\)). The ratio objective \(\mathsf{Ratio}(w_1, w_2, 4)\) is satisfied by traversing the cycle \(C=[(3,5), (5,3)]\) repeatedly.
4.3 Reduction of competitive analysis to graphs with multiple objectives
We present a formal reduction of the computation of the competitive ratio of an online scheduling algorithm with constraints on job sequences to the multiobjective graph problem. The input consists of the taskset, a deterministic LTS for the online algorithm, a nondeterministic LTS for the clairvoyant algorithm, and optional deterministic LTSs for the constraints. We first describe the process of computing the competitive ratio \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\), where \({\mathcal {J}}\) is a set of job sequences only subject to safety and liveness constraints. We later show how to handle limitaverage constraints.
4.3.1 Reduction for safety and liveness constraints
Given the deterministic and nondeterministic LTS \(L_{{\mathcal {A}}}\) and \(L_{{\mathcal {C}}}\) with reward functions \(r_{{\mathcal {A}}}\) and \(r_{{\mathcal {C}}}\), respectively, and optionally safety and liveness LTS \(L_{{\mathcal {S}}}\) and \(L_{{\mathcal {L}}}\), let \(L=L_{{\mathcal {A}}}\times L_{{\mathcal {C}}}\times L_{{\mathcal {S}}}\times L_{{\mathcal {L}}}\) be their synchronous product. Hence, L is a nondeterministic LTS \((S, s_1,\Sigma , \Pi ,\Delta )\), and every job sequence \(\sigma \) yields a set of runs R in L, such that each \(\rho \in R\) captures the joint behavior of \({\mathcal {A}}\) and \({\mathcal {C}}\) under \(\sigma \). Note that for each such \(\rho \) the behavior of \({\mathcal {A}}\) is unchanged, but the behavior of \({\mathcal {C}}\) generally varies due to its nondeterminism. Let \(G=(V,E)\) be the multigraph induced by L, that is, \(V=S\) and \((M,M', j)\in E\) for all \(1\leqslant j \leqslant i\) iff there are i transitions \((M, T, M', P)\in \Delta \). Let \(w_{{\mathcal {A}}}\) and \(w_{{\mathcal {C}}}\) be the weight functions that assign to each edge of G the reward that the respective algorithm obtains from the corresponding transition in L. Let X be the set of states in G whose \(L_{{\mathcal {S}}}\) component is \(s_r\), and Y the set of states in G whose \(L_{{\mathcal {L}}}\) component is \(s_a\). It follows that for all \(\nu \in \mathbb {Q}\), we have that \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\leqslant \nu \) iff the objective \(\Phi _{\nu }=\mathsf {Safe}(X)\cap \mathsf {Live}(Y)\cap \mathsf{Ratio}(w_{{\mathcal {A}}}, w_{{\mathcal {C}}}, \nu )\) is satisfied in G from the state \(s_1\). As the dimension in the ratio objective (that just takes care of the competitive ratio) is one, Case 1 of Theorem 1 applies, and we obtain the following:
Lemma 1
Given the product graph \(G=(V, E)\) of n nodes and m edges, a rational \(\nu \in \mathbb {Q}\), and a set of job sequences \({\mathcal {J}}\) admissible for safety and liveness LTSs, determining whether \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\leqslant \nu \) requires \(O(n\cdot m)\) time.
Since \(0\leqslant {\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}}) \leqslant 1\), the problem of determining the competitive ratio reduces to finding \(v=\sup \{\nu \in \mathbb {Q}:~\Phi _{\nu } \text { is satisfied in } G\}\). Because this value corresponds to the ratio of the corresponding rewards obtained in a simple cycle in G, it follows that v is the maximum of a finite set, and can be determined exactly by an adaptive binary search.
4.3.2 Reduction for limitaverage constraints
Finally, we turn our attention to additional limitaverage constraints and the LTS \(L_{{\mathcal {W}}}\). We follow a similar approach as above, but this time including \(L_{{\mathcal {W}}}\) in the synchronous product, i.e., \(L=L_{{\mathcal {A}}}\times L_{{\mathcal {C}}}\times L_{{\mathcal {S}}}\times L_{{\mathcal {L}}}\times L_{{\mathcal {W}}}\). Let \(w_{{\mathcal {A}}}\) and \(w_{{\mathcal {C}}}\) be weight functions that assign to each edge \(e\in E\) in the corresponding multigraph a vector of \(d+1\) weights as follows. In the first dimension, \(w_{{\mathcal {A}}}\) and \(w_{{\mathcal {C}}}\) are defined as before, assigning to each edge of G the corresponding rewards of \({\mathcal {A}}\) and \({\mathcal {C}}\). In the remaining \(d\) dimensions, \(w_{{\mathcal {C}}}\) is always 1, whereas \(w_{{\mathcal {A}}}\) equals the value of the weight function \(w\) of \(L_{{\mathcal {W}}}\) on the corresponding transition. Let \(\vec {\lambda }\) be the threshold vector of \(L_{{\mathcal {W}}}\). It follows that for all \(\nu \in \mathbb {Q}\), we have that \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\leqslant \nu \) iff the objective \(\Phi _{\nu }=\mathsf {Safe}(X)\cap \mathsf {Live}(Y)\cap \mathsf{Ratio}(w_{{\mathcal {A}}}, w_{{\mathcal {C}}}, (\nu , \vec {\lambda }))\) is satisfied in G from the state s that corresponds to the initial state of each LTS, where \((\nu ,\vec {\lambda })\) is a \(d+1\)dimension vector, with \(\nu \) in the first dimension, followed by the ddimension vector \(\vec {\lambda }\). As the dimension in the ratio objective is greater than one, Case 2 of Theorem 1 applies, and we obtain the following:
Lemma 2
Given the product graph \(G=(V, E)\) of n nodes and m edges, a rational \(\nu \in \mathbb {Q}\), and a set of job sequences \({\mathcal {J}}\) admissible for safety, liveness, and limit average LTSs, determining whether \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\leqslant \nu \) requires polynomial time.
Again, since \(0\leqslant {\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}}) \leqslant 1\), the competitive ratio is determined by an adaptive binary search. However, this time \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\) is not guaranteed to be realized by a simple cycle (the witness path in G is not necessarily periodic, see Algorithm 1), and is only approximated within some desired error threshold \(\varepsilon >0\).
4.3.3 Adaptive binary search
We employ an adaptive binary search for the competitive ratio in the interval [0, 1], which works as follows: the algorithm maintains an interval \([\ell , r]\) such that \(\ell \leqslant {\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\leqslant r\) at all times, and exploits the nature of the problem for refining the interval according to the following rules: first, if the current objective \(\nu \in [\ell , r]\) (typically, \(\nu =(\ell +r)/2\)) is satisfied in G, i.e., Lemma 1 answers “yes” and provides the current minimum cycle C as a witness, the value r is updated to the ratio \(\nu '\) of the online and offline rewards in C, which is typically less than \(\nu \). This allows to reduce the current interval for the next iteration from \([\ell ,r]\) to \([\ell , \nu ']\), with \(\nu '\leqslant \nu \), rather than \([\ell , \nu ]\) (as a simple binary search would do). Second, since \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\) corresponds to the ratio of rewards on a simple cycle in G, if the current objective \(\nu \in [\ell , r]\) is not satisfied in G, the algorithm assumes that \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})=r\) (i.e, the competitive ratio equals the right endpoint of the current interval), and tries \(\nu =r\) in the next iteration. Hence, as opposed to a naive binary search, the adaptive version has the advantages of (i) returning the exact value of \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\) (rather than an approximation), and (ii) being faster in practice.
Remark 4
Lemmas 1 and 2 give polynomial upper bounds for the complexity of determining the competitive ratio of an online scheduling algorithm \({\mathcal {A}}\) given as a LTS \(L_{{\mathcal {A}}}\). If, instead, \({\mathcal {A}}\) is given in some succinct form using a description which is polylogarithmic in the number of states [e.g., as a circuit (Galperin and Wigderson 1983)], then the corresponding upper bounds become exponential in the size of the description of \({\mathcal {A}}\).
4.4 Optimized reduction
In Sect. 4.3, we established a formal reduction from determining the competitive ratio of an online scheduling algorithm in a constrained adversarial environment to solving multiple objectives on graphs. In this section, we present several optimizations for this reduction that significantly reduce the size of the generated LTSs.
4.4.1 Clairvoyant LTS reduction
Recall the clairvoyant LTS \(L_{{\mathcal {C}}}\) with reward function \(r_{{\mathcal {C}}}\) from Sect. 3, which nondeterministically models a scheduler. For our optimization, we encode the offline algorithm as a nondeterministic LTS \(L_{{\mathcal {C}}}'=(S_{{\mathcal {C}}}', s_{{\mathcal {C}}}',\Sigma , \varnothing ,\Delta _{{\mathcal {C}}}')\) with reward function \(r_{{\mathcal {C}}}'\) that lacks the property of being a scheduler, as information about released and scheduled jobs is lost. However, it preserves the property that, given a job sequence \(\sigma \), there exists a run \(\rho _{{\mathcal {C}}}^{\sigma }\) in \(L_{{\mathcal {C}}}\) iff there exists a run \(\widehat{\rho }_{{\mathcal {C}}}^{\sigma }\) in \(L_{{\mathcal {C}}}'\) with \(V(\rho _{{\mathcal {A}}}^{\sigma },k)=V(\widehat{\rho }_{{\mathcal {A}}}^{\sigma },k)\) for all \(k\in \mathbb {N}^{+}\). That is, there is a bisimulation between \(L_{{\mathcal {C}}}\) and \(L_{{\mathcal {C}}}'\) that preserves rewards.
Intuitively, the clairvoyant algorithm need not partially schedule a job, i.e., it will either discard it immediately, or schedule it to completion. Hence, in every release of a set of tasks T, \(L_{{\mathcal {C}}}'\) nondeterministically chooses a subset \(T'\subseteq T\) to be scheduled, as well as allocates the future slots for their execution. Once these slots are allocated, \(L_{{\mathcal {C}}}'\) is not allowed to preempt those in favor of a subsequent job. For the reward, we use \(r_{{\mathcal {C}}}'=\sum _{\tau _i\in T'}V_i\).
The state space \(S_{{\mathcal {C}}}'\) of \(L_{{\mathcal {C}}}'\) consists of binary strings of length \(D_{\max }\). For a binary string \(B\in S_{{\mathcal {C}}}'\), we have \(B[i]=1\) iff the ith slot in the future is allocated to some released job, and \(s_{{\mathcal {C}}}'=\vec {\mathbf {0}}\). Informally, the transition relation \(\Delta _{{\mathcal {C}}}'\) is such that, given a current subset \(T\subseteq \Sigma \) of newly released jobs, there exists a transition \(\delta \) from B to \(B'\) only if \(B'\) can be obtained from B by nondeterministically choosing a subset \(T'\subseteq T\), and for each task \(\tau _i\in T'\) allocating nondeterministically \(C_i\) free slots in B.
By definition, \(S_{{\mathcal {C}}}'\leqslant 2^{D_{\max }}\). In laxityrestricted tasksets, however, we can obtain an even tighter bound: let \(L_{\max }=\max _{\tau _i\in {\mathcal {T}}}{(D_iC_i)}\) be the maximum laxity in \({\mathcal {T}}\), and \(I:S_{{\mathcal {C}}}'\rightarrow \{\bot ,1,\dots ,D_{\max }1\}^{L_{\max }+1}\) denote a function such that \(I(B)=(i_1,\dots , i_{L_{\max }+1})\) are the indexes of the first \(L_{\max }+1\) zeros in B. That is, \(i_j=k\) iff B[k] is the jth zero location in B, and \(i_j=\bot \) if there are less than j free slots in B.
Claim
The function I is bijective.
Proof
 1.
If \(i_{L_{\max }+1}=\bot \), there are less than \(L_{\max }+1\) empty slots in B, all uniquely determined by \((i_1,\dots ,i_{k})\), for some \(k\leqslant L_{\max }\).
 2.
If \(i_{L_{\max }+1}\ne \bot \), then all \(i_j\ne \bot \), and thus any job to the right of \(i_{L_{\max }+1}\) would have been stalled for more than \(L_{\max }\) positions. Hence, all slots to the right of \(i_{L_{\max }+1}\) are free in B, and B is also unique.
For \(x,k\in \mathbb {N}^{+}\), denote with \(\mathsf {Perm}(x,k)=x\cdot (x1) \dots (xk+1)\) the number of kpermutations on a set of size x. Claim 4.4.1 immediately implies the following Lemma 3:
Lemma 3
Let \({\mathcal {T}}\) be a taskset with maximum deadline \(D_{\max }\), and \(L_{\max }=\max _{\tau _i\in {\mathcal {T}}}{(D_iC_i)}\) be the maximum laxity. Then, \(S_{{\mathcal {C}}}'\leqslant \min (2^{D_{\max }}, \mathsf {Perm}(D_{\max },L_{\max }+1))\).
Hence, for zero and small laxity environments (Baruah et al. 1992), as they typically arise in highspeed network switches (Englert and Westermann 2007) and in NoCs (Lu and Jantsch 2007), \(S_{{\mathcal {C}}}'\) has polynomial size in \(D_{\max }\). This affects the parameter n in Lemmas 1 and 2.
4.4.2 Clairvoyant LTS generation
The intuition behind \(\mathsf {ClairvoyantSuccessor}\) is as follows: it is wellknown that the earliest deadline first (EDF) policy is optimal for scheduling job sequences where every released task can be completed (Dertouzos 1974). By construction, given a job sequence \(\sigma _1\), \(L_{{\mathcal {C}}}'\) nondeterministically chooses a job sequence \(\sigma _2\), such that for all \(\ell \), we have \(\sigma _2^{\ell }\subseteq \sigma _1^{\ell }\), and all jobs in \(\sigma _2\) are scheduled to completion by \(L_{{\mathcal {C}}}'\). Therefore, it suffices to consider a transition relation \(\Delta _{{\mathcal {C}}}'\) that allows at least all possible choices that admit a feasible EDF schedule on every possible \(\sigma _2\), for any generated job sequence \(\sigma _1\).
In more detail, \(\mathsf {ClairvoyantSuccessor}\) is called with a current state B, a subset of released tasks T and an index k, and returns the set \(\mathcal {B}\) of all possible successors of B that schedule a subset \(T'\subseteq T\), where every job of \(T'\) is executed later than k slots in the future. This is done by extracting from T the task \(\tau \) with the earliest deadline, and proceeding as follows: the set \(\mathcal {B}\) is obtained by constructing a state \(B'\) that considers all the possible ways to schedule \(\tau \) to the right of k (including the possibility of not scheduling \(\tau \) at all), and recursively finding all the ways to schedule \(T\setminus \{\tau \}\) in \(B'\), to the right of the rightmost slot allocated for task \(\tau \).
Finally, we exploit the following two observations to further reduce the state space of \(L_{{\mathcal {C}}}'\). First, we note that as long as there are some unfinished jobs in the state of \(L_{{\mathcal {C}}}'\) (i.e., at least one bit of B is one), the clairvoyant algorithm gains no benefit by not executing any job in the current slot. Hence, besides the zero state \(\vec {\mathbf {0}}\), every state B must have \(B[1]=1\). In most cases, this restriction reduces the state space by at least \(50\%\).
 1.
no job is scheduled in some round, while there is some already released job J which will be scheduled in the future, or
 2.
two jobs J and \(J'\) are such that each one preempts the other.
These two improvements were found to reduce the state space by a factor up to \(90\%\) in all examined cases (see Sect. 4.5 and Table 5). In fact, despite the nondeterminism, in all reported cases the generation of \(L_{{\mathcal {C}}}\) was done in less than a second.
4.4.3 Online LTS reduction
Typically, simple online scheduling algorithms do “lazy dropping” of unsuccessful jobs, where such a job is dropped only when its deadline passes. An obvious improvement for reducing the size of the state space of the LTS is to implement some early dropping: store only those jobs that could be scheduled, at least partially, under some sequence of future task releases. We do so by first creating the LTS naively, and then iterating through its states. For each state s and job \(J_{i,j}\) in s with relative deadline \(D_{i}\), we perform a depthlimited search originating in s for \(D_{i}\) steps, looking for a state \(s'\) reached by a transition that schedules \(J_{i,j}\). If no such state is found, we merge state s to \(s''\), where \(s''\) is identical to s without job \(J_{i,j}\).
4.5 Experimental results
We have implemented a prototype of our automated competitive ratio analysis framework, and applied it in a comparative case study.
Our implementation has been done in Python 2.7 and C, and uses the lp_solve (Berkelaar et al. 2004) package for linear programming solutions. All experiments were run on a standard desktop computer with a 3.2 GHz CPU and 4 GB of RAM running Debian Linux.
Varying tasksets without constraints The algorithm DOVER was proved in Koren and Shasha (1995) to have optimal competitive factor, i.e., optimal competitive ratio under the worstcase taskset. However, our experiments reveal that this performance guarantee is not universal, in the sense that DOVER is outperformed by other schedulers for specific tasksets. Interestingly, this observation applies to all online algorithms examined: as shown in Fig. 6, even without constraints on the adversary, there are tasksets in which every chosen scheduling algorithm outperforms all others, by achieving the highest competitive ratio for the particular taskset. This sensitivity of the optimally performing online algorithm on the given taskset makes our automated analysis framework a very interesting tool for the application designer.
The tasksets used to generate Fig. 6
A1 (\(k=6\))  A2 (\(k=5\))  A3 (\(k=4\))  A4 (\(k=3\))  A5 (\(k=2\))  A6 (\(k=4\))  A7 (\(k=5\))  

\(\tau _1\)  \(\tau _2\)  \(\tau _3\)  \(\tau _4\)  \(\tau _1\)  \(\tau _2\)  \(\tau _1\)  \(\tau _2\)  \(\tau _3\)  \(\tau _1\)  \(\tau _2\)  \(\tau _3\)  \(\tau _1\)  \(\tau _2\)  \(\tau _3\)  \(\tau _1\)  \(\tau _2\)  \(\tau _3\)  \(\tau _1\)  \(\tau _2\)  \(\tau _3\)  
\(C_i\)  1  4  1  3  2  2  2  1  1  1  2  1  2  1  1  2  6  1  1  2  1 
\(D_i\)  2  6  3  4  3  2  2  5  5  2  3  6  3  1  3  2  6  1  5  2  1 
\(V_i\)  3  2  3  3  5  1  1  2  2  3  2  1  9  6  3  1  10  2  5  4  1 
Columns show the mean workload restriction. The checkmarks indicate that the corresponding scheduler is optimal for that mean workload restriction, among the six schedulers we examined. We see that the optimal scheduler can vary as the restrictions are tighter, and in a nonmonotonic way. LLF, EDF, DSTAR and DOVER were not optimal in any case and hence not mentioned
1.5  1  0.8  0.6  0.4  0.3  0.1  0.078  0.05  

FIFO  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  
SP  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  
SRT  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  \(\checkmark \)  \(\checkmark \) 
Fixed taskset with varying constraints We also analyzed fixed tasksets under various constraints (such as sporadicity or workload restrictions) for admissible job sequences. Figure 7 shows some experimental results for workload safety constraints, which again reveal that, depending on particular workload constraints, we can have different optimal schedulers. The same was observed for limitaverage constraints: as Table 2 shows, the optimal scheduler can vary highly and nonmonotonically with stronger limitaverage workload restrictions. The tasksets for both experiments are shown in Table 3.
Competitive ratio of TD1
Taskset  \(\eta \)  Taskset  Comp. Ratio 

C1  2  \(\{1,1\}\)  1 
C2  3  \(\{1,2,3\}\)  1 / 2 
C3  3.1  \(\{1,3,7,13,19\}\)  7 / 25 
C4  3.2  \(\{1,3,7,13,20,23\}\)  1 / 4 
C5  3.3  \(\{1,3,7,14,24,33\}\)  1 / 4 
C6  3.4  \(\{1,3,7,14,24,34\}\)  1 / 4 
Scalability of our approach for tasksets of various sizes N and \(D_{\max }\). For each taskset, the size of the state space of the clairvoyant scheduler is shown, along with the mean size of the product LTS, and the mean and maximum time to solve one instance of the corresponding ratio objective
Taskset  N  \(D_{\max }\)  Size (nodes)  Time (s)  

Clairv.  Product  Mean  Max  
B01  2  7  19  823  0.04  0.05 
B02  2  8  26  1997  0.39  0.58 
B03  2  9  34  4918  10.02  15.21 
B04  3  7  19  1064  0.14  0.40 
B05  3  8  26  1653  0.66  2.05 
B06  3  9  34  7705  51.04  136.62 
B07  4  7  19  1711  2.13  6.34 
B08  4  8  26  3707  13.88  34.12 
B09  4  9  44  10,040  131.83  311.94 
B10  5  7  19  2195  5.73  16.42 
B11  5  8  32  9105  142.55  364.92 
B12  5  9  44  16,817  558.04  1342.59 
In Baruah et al. (1992), TD1 was shown to have competitive factor \(\frac{1}{4}\), and hence a competitive ratio that approaches \(\frac{1}{4}\) from above, as \(\eta \rightarrow 4\) in the above series of tasksets. Table 4 shows the competitive ratio of TD1 in our constructed series of tasksets. Each taskset is represented as a set \(\{C_i : 1 \leqslant i \leqslant n\}\), where each \(C_i\) is given by the above recurrence, rounded up to the next integer. We indeed see that the competitive ratio drops until it stabilizes to \(\frac{1}{4}\). Note that, thanks to our optimizations, the zerolaxity restriction allowed us to process tasksets where \(D_{\max }\) is much higher than for the tasksets reported in Table 5: the results of Table 4 were produced in less than a minute overall.
Running times Table 5 summarizes some key parameters of our various tasksets, and gives some statistical data on the observed running times in our respective experiments. Even though the considered tasksets are small, the very short running times of our prototype implementation reveal the principal feasibility of our approach. We believe that further applicationspecific optimizations, augmented by abstraction and symmetry reduction techniques, will allow to scale to larger applications.
5 Competitive synthesis of online scheduling algorithms

In Sect. 5.1, we introduce a suitable twoplayer partialinformation game with meanpayoff and ratio objectives. Player 1 will represent the online algorithm, whereas Player 2 will represent both the adversary (which chooses the job sequence) and the clairvoyant algorithm (which knows the job sequence in advance). We use a partialinformation setting to model that Player 1 is oblivious to the scheduling choices of Player 2, but Player 2 knows the scheduling choices of Player 1 for deciding which future jobs to release. The meanpayoff and ratio objectives model directly the worstcase utility and competitive ratio problems, respectively.

In Sect. 5.2, we establish that the relevant decision problems for our game are Npcomplete in the size of the game graph.

In Sect. 5.3, we study the decision problems relevant for two particular synthesis questions: in synthesis for worstcase average utility, the goal is to automatically construct an online scheduling algorithm with the largest possible worstcase average utility for a given taskset. In competitive synthesis, we construct an online scheduling algorithm with the largest possible competitive ratio for the given taskset. The complexity results for our graph game reveal that the former problem is in Np \(\cap \) coNp, whereas the latter is in Np. These complexities are wrt the size of the constructed algorithm, represented explicitly as a labeled transition system. As a function of the input taskset \({\mathcal {T}}\) given in binary, all polynomial upper bounds become exponential upper bounds in the worst case. The solution to the competitive synthesis . Hence the algorithm for obtaining the optimal scheduler comes in two steps. The first step reduces the problem to the relevant partialinformation game and is found in Theorem 5 of Sect. 5.3. The second step is solving the partialinformation game, and is found in Theorem 3 of Sect. 5.2.
5.1 Partialinformation meanpayoff and ratio games
We first introduce a twoplayer partialinformation game on graphs with meanpayoff and ratio objectives.
5.1.1 Notation on graph games
 State space

The set \(S\) is a finite set of states.
 Actions

\(\Sigma _i\) (\(i=1,2\)) is a finite set of actions for Player i.
 Transition function

Given the current state \(s \in S\), an action \(\alpha _1 \in \Sigma _1\) for Player 1, and an action \(\alpha _2 \in \Sigma _2\) for Player 2, the transition function \(\delta : S\times \Sigma _1 \times \Sigma _2 \rightarrow S\) gives the next (or successor) state \(s'=\delta (s,\alpha _1,\alpha _2)\). A shorter form to denote a transition is to write the tuple \((s, \alpha _2, \alpha _1, s')\); note that \(\alpha _2\) is listed before \(\alpha _1\) to stress that fact that Player 2 chooses its action before Player 1.
 Observations

The set \(\mathcal{{O}}_{S} \subseteq 2^{S}\) is a finite set of observations for Player 1 that partition the state space \(S\). This partition uniquely defines a function \(\mathsf {obs}_S: S\rightarrow \mathcal{{O}}_S\), which maps each state to its observation \(\mathsf {obs}_S(s)\) in a way that ensures \(s \in \mathsf {obs}_S(s)\) for all \(s \in S\). In other words, the observation partitions the state space according to equivalence classes. Similarly, \(\mathcal{{O}}_\Sigma \) is a finite set of observations for Player 1 that partitions the action set \(\Sigma _2\), and analogously defines the function \(\mathsf {obs}_\Sigma \). Intuitively, Player 1 will have partial observation, and can only obtain the current observation of the state (not the precise state but only the equivalence class the state belongs to) and current observation of the action of Player 2 (but not the precise action of Player 2) to make her choice of action.
5.1.2 Plays
In a game, in each turn, first Player 2 chooses an action, then Player 1 chooses an action, and given the current state and the joint actions, we obtain the next state according to the transition function \(\delta \).
A play in \(\mathscr {G}\) is an infinite sequence of states and actions \(\mathscr {P}=s^1\!,\alpha _2^1, \alpha _1^1\), \(s^2\!,\alpha _2^2, \alpha _1^2\), \(s^3\!, \alpha _2^3, \alpha _1^3\), \(s^4 \ldots \) such that, for all \(j \geqslant 1\), we have \(\delta (s^j,\alpha _1^j,\alpha _2^j)=s^{j+1}\). The prefix up to \(s^n\) of the play \(\mathscr {P}\) is denoted by \(\mathscr {P}(n)\) and corresponds to the starting state of the nth turn. The set of plays in \(\mathscr {G}\) is denoted by \(\mathscr {P}^{\infty }\), and the set of corresponding finite prefixes is denoted by \(\mathsf{Prefs}(\mathscr {P}^{\infty })\).
5.1.3 Strategies
A strategy for a player is a recipe that specifies how to extend finite prefixes of plays. We will consider memoryless deterministic strategies for Player 1 (where its next action depends only on the current state, but not on the entire history) and general historydependent deterministic strategies for Player 2. A strategy for Player 1 is a function \(\pi :\mathcal{{O}}_S \times \mathcal{{O}}_\Sigma \rightarrow \Sigma _1\) that, given the current observation of the state and the current observation on the action of Player 2, selects the next action. A strategy for Player 2 is a function \(\sigma :\mathsf{Prefs}(\mathscr {P}^{\infty }) \rightarrow \Sigma _2\) that, given the current prefix of the play, chooses an action. Observe that the strategies for Player 1 are both observationbased and memoryless; i.e., depend only on the current observations (rather than the whole history), whereas the strategies for Player 2 depend on the history. A memoryless strategy for Player 2 only depends on the last state of a prefix. We denote by \(\Pi _\mathscr {G}^M\), \(\Sigma _\mathscr {G}\), \(\Sigma _\mathscr {G}^M\) the set of all observationbased memoryless Player 1 strategies, the set of all Player 2 strategies, and the set of all memoryless Player 2 strategies, respectively. In sequel, when we write “strategy for Player 1”, we consider only observationbased memoryless strategies. Given a strategy \(\pi \) and a strategy \(\sigma \) for Player 1 and Player 2, and an initial state \(s^1\), we obtain a unique play \(\mathscr {P}(s^1,\pi ,\sigma )=s^1\!,\alpha _2^1, \alpha _1^1, s^2\!,\alpha _2^2, \alpha _1^2, s^3, \ldots \) such that, for all \(n \geqslant 1\), we have \(\sigma (\mathscr {P}(n))=\alpha _2^n\) and \(\pi (\mathsf {obs}_S(s^n), \mathsf {obs}_\Sigma (\alpha _2^n))=\alpha _1^n\).
5.1.4 Objectives
Recall that, for the graphs with multiple objectives from Sect. 4.1, an objective is a set of paths. Here we extend this notion to games: an objective of a game \(\mathscr {G}\) is a set of plays that satisfy some desired properties. For the sake of completeness, we present here the relevant definitions for mean payoff and ratio objectives with 1dimensional weight functions.
5.1.5 Decision problems
Remark 5
Note that the decision problems of the graph game problem are defined over the \(\sup _{\pi \in \Pi _\mathscr {G}^M}\), taking all possible memoryless strategies into account. This corresponds to all possible online scheduling strategies, whereas the multigraph problem arising in the competitive analysis problem considered in the previous sections explicitly used the fixed deterministic strategy for the online scheduler only.
5.1.6 Perfectinformation games
Games of completeobservation (or perfectinformation games) are a special case of partialobservation games where \(\mathcal{{O}}_S = \{ \{s\} \mid s \in S\}\) and \(\mathcal{{O}}_\Sigma = \{ \{\alpha _2\} \mid \alpha _2 \in \Sigma _2 \}\), i.e., every individual state and action is fully visible to Player 1, and thus she has perfect information. For perfectinformation games, for the sake of simplicity, we will omit the corresponding observation sets from the description of the game. The following theorem for perfectinformation games with meanpayoff objectives follows from the results of Ehrenfeucht and Mycielski (1979), Zwick and Paterson (1996), Brim et al. (2011), Karp (1978).
Theorem 2
 1.(Determinacy) We have$$\begin{aligned}&\sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{MP}(w,\mathscr {P}(s^1,\pi ,\sigma )) \\ \quad= & {} \inf _{\sigma \in \Sigma _\mathscr {G}} \sup _{\pi \in \Pi _\mathscr {G}^M} \mathsf{MP}(,w,\mathscr {P}(s^1,\pi ,\sigma )) \\ \quad= & {} \inf _{\sigma \in \Sigma _\mathscr {G}^M} \sup _{\pi \in \Pi _\mathscr {G}^M} \mathsf{MP}(w, \mathscr {P}(s^1,\pi ,\sigma )). \end{aligned}$$
 2.
Whether \(\sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{MP}(w,\mathscr {P}(s^1,\pi ,\sigma ))\geqslant \nu \) can be decided in Np \(\cap \) coNp, for a rational threshold \(\nu \).
 3.
The computation of the optimal value \(v^*=\sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{MP}(w, \mathscr {P}(s^1,\pi ,\sigma ))\) and an optimal memoryless strategy \(\pi ^{*}\in \Pi _\mathscr {G}^M\) such that \(v^*=\inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{MP}(w, \mathscr {P}(s^1,\pi ^{*},\sigma ))\) can be done in time \(O(n \cdot m\cdot W)\), where n is the number of states, m is the number of transitions, and W is the maximum value of all the rewards (i.e., the algorithm runs in pseudopolynomial time, and if the maximum value W of rewards is polynomial in the size of the game, then the algorithm is polynomial).
5.1.7 Sketch of the algorithm
The complexity of Item 3 of Theorem 2 is obtained in Brim et al. (2011). Here we outline a simple algorithm for solving the same problem in time \(O(n^4\cdot m \cdot \log (n/m) \cdot W)\), as found in Zwick and Paterson (1996). The algorithm operates in two steps. First, we compute for every node \(u\in S\) the maximum mean payoff v(u) that Player 1 can ensure in any play that starts from u. This is achieved by the standard valueiteration procedure executed for \(\varTheta (n^2\cdot W)\) iterations. Hence, the time required for this step is \(O(n^2\cdot m \cdot W)\). Note that at this point \(v(s^1)\) gives the mean payoff achieved by an optimal strategy \(\pi ^{*}\in \Pi _\mathscr {G}^M\), but not the strategy itself. Since an optimal memoryless strategy is guaranteed to exist, this strategy can be computed by a binary search on the actions of Player 1. Given a node \(u\in S\), we denote by \(\Sigma _1(u)\) the set of actions available to Player 1 on u. In the second step, we iteratively pick a node \(u\in S\) which has more than one available actions for Player 1, and a set \(X\subset \Sigma _1(u)\) which contains half of the actions of Player 1 on u. We let \(\mathscr {G}'\) be the modified game where the actions for Player 1 on node u is the set X, and recompute the value \(v'(u)\) in \(\mathscr {G}'\). If \(v'(u)=v(u)\), we repeat the process on \(\mathscr {G}'\). Otherwise, we construct a new game \(\mathscr {G}''\) which is identical to \(\mathscr {G}\), but such that the available actions for Player 1 on node u is the set \(\Sigma _1(u)\setminus X\). We repeat the process on \(\mathscr {G}''\).
5.2 Complexity results
In this section, we establish the complexity of the decision problems arising in partialobservation games with meanpayoff and ratio objectives. In particular, we will show that for partialobservation games with memoryless strategies for Player 1 all the decision problems are Npcomplete.
5.2.1 Transformation
We start with a simple transformation that will allow us to technically simplify our proof. In our definition of games, every action was available for the players in every state for simplicity. We will now consider restricted games where, in certain states, some actions are not allowed for a player. The transformation of such restricted games to games where all actions are allowed is as follows: we add two absorbing dummy states (with only a selfloop), one for Player 1 and the other for Player 2, and assign rewards in a way such that the objectives are violated for the respective player. For example, for meanpayoff objectives with threshold \(\nu >0\), we assign reward 0 for the only outgoing (selfloop) transition of the Player 1 dummy state, and a reward strictly greater than \(\nu \) for the selfloop of the Player 2 dummy state; in the case of ratioobjectives we assign the reward pairs similarly. Given a state s, if Player 1 plays an action that is not allowed at s, we go to the dummy Player 1 state; and if Player 2 plays an action that is not allowed, we go to the Player 2 dummy state. Obviously, this is a simple linear time transformation. Hence, for technical convenience, we can assume in the sequel that different states have different sets of available actions for the players. We first start with the hardness result.
Lemma 4
The decision problems for partialobservation games with meanpayoff objectives and ratio objectives, i.e., whether \( \sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{MP}(w,\mathscr {P}(s^1,\pi ,\sigma ))\geqslant \nu \) (respectively \( \sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{Ratio}(w_1,w_2,\mathscr {P}(s^1,\pi ,\sigma ))\geqslant \nu \)), are Nphard in the strong sense.
Proof
 State space

\(S=\{s_\mathsf{init}\} \cup \{s_{i,j} \mid 1 \leqslant i \leqslant m, 1 \leqslant j \leqslant 3\} \cup \{\mathsf {dead}\}\); i.e., there is an initial state \(s_\mathsf{init}\), a dead state \(\mathsf {dead}\), and there is a state \(s_{i,j}\) for every clause \(\mathfrak c_i\) and literal j of \(\mathfrak c_i\).
 Actions

The set of actions applicable for Player 1 is \(\{\mathsf{true}, \mathsf{false}, \bot \}\), the possible actions for Player 2 are \(\{1,2,\ldots ,m\} \cup \{\bot \}\).
 Transitions

In the initial state \(s_\mathsf{init}\), Player 1 has only one action \(\bot \) available, Player 2 has actions \(\{1,2,\ldots ,m\}\) available, and given action \(1 \leqslant i \leqslant m\), the next state is \(s_{i,1}\). In all other states, Player 2 has only one action \(\bot \) available. In states \(s_{i,j}\), Player 1 has two actions available, namely, \(\mathsf{true}\) and \(\mathsf{false}\). The transitions are as follows:

If the action of Player 1 is \(\mathsf{true}\) in \(s_{i,j}\), then (i) if the jth literal in \(\mathfrak c_i\) is \(x_k\), then we have a transition back to the initial state; and (ii) if the jth literal in \(\mathfrak c_i\) is \(\overline{x}_k\) (negation of \(x_k\)), then we have a transition to \(s_{i,j+1}\) if \(j\in \{1,2\}\), and if \(j=3\), we have a transition to \(\mathsf {dead}\).

If the action of Player 1 is \(\mathsf{false}\) in \(s_{i,j}\), then (i) if the jth literal in \(\mathfrak c_i\) is \(\overline{x}_k\) (negation of \(x_k\)), then we have a transition back to the initial state; and (ii) if the jth literal in \(\mathfrak c_i\) is \(x_k\), then we have a transition to \(s_{i,j+1}\) if \(j\in \{1,2\}\), and if \(j=3\), we have a transition to \(\mathsf {dead}\).
 Observations:

First, Player 1 does not observe the actions of Player 2 (i.e., Player 1 does not know which action is played by Player 2). The observation mapping for the state space for Player 1 is as follows: the set of observations is \(\{0,1,\ldots ,n\}\) and we have \(\mathsf {obs}_S(s_\mathsf{init})=\mathsf {obs}_S(\mathsf {dead})=0\) and \(\mathsf {obs}_S(s_{i,j})=k\) if the jth variable of \(\mathfrak c_i\) is either \(x_k\) or its negation \(\overline{x}_k\), i.e., the observation for Player 1 corresponds to the variables.
A pictorial description is shown in Fig 8. The intuition for the above construction is as follows: Player 2 chooses a clause from the initial state \(s_\mathsf{init}\), and an observationbased memoryless strategy for Player 1 corresponds to a nonconflicting assignment to the variables. Note that Player 1 strategies are observationbased memoryless; hence, for every observation (i.e., a variable), it chooses a unique action (i.e., an assignment) and thus nonconflicting assignments are ensured. We consider \(\mathscr {G}_{\Psi }\) with reward functions \(w,w_1,w_2\) as follows: \(w_2\) assigns reward 1 to all transitions; \(w\) and \(w_1\) assigns reward 1 to all transitions other than the selfloop at state \(\mathsf {dead}\), which is assigned reward 0. We ask the decision questions with \(\nu =1\). Observe that the answer to the decision problems for both meanpayoff and ratio objectives is “Yes” iff the state \(\mathsf {dead}\) can be avoided by Player 1 (because if \(\mathsf {dead}\) is reached, then the game stays in \(\mathsf {dead}\) forever, violating both the meanpayoff as well as the ratio objective). We now present the two directions of the proof.
Satisfiable implies \(\mathsf {dead}\) is not reached: we show that if \(\Psi \) is satisfiable, then Player 1 has an observationbased memoryless strategy \(\pi ^{*}\) to ensure that \(\mathsf {dead}\) is never reached. Consider a satisfying assignment A for \(\Psi \), then the strategy \(\pi ^{*}\) for Player 1 is as follows: given an observation k, if A assigns true to variable \(x_k\), then the strategy \(\pi ^{*}\) chooses action \(\mathsf{true}\) for observation k, otherwise it chooses action \(\mathsf{false}\). Since the assignment A satisfies all clauses, it follows that for every \(1\leqslant i \leqslant m\), there exists \(s_{i,j}\) such that the strategy \(\pi ^{*}\) for Player 1 ensures that the transition to \(s_\mathsf{init}\) is chosen. Hence the state \(\mathsf {dead}\) is never reached, and both the meanpayoff and ratio objectives are satisfied.
If \(\mathsf {dead}\) is not reached, then \(\Psi \) is satisfiable: consider an observationbased memoryless strategy \(\pi ^{*}\) for Player 1 that ensures that \(\mathsf {dead}\) is never reached. From the strategy \(\pi ^{*}\) we obtain an assignment A as follows: if for observation k, the strategy \(\pi ^{*}\) chooses \(\mathsf{true}\), then the assignment A chooses true for variable \(x_k\), otherwise it chooses false. Since \(\pi ^{*}\) ensures that \(\mathsf {dead}\) is not reached, it means for every \(1\leqslant i\leqslant m\), that there exists \(s_{i,j}\) such that the transition to \(s_\mathsf{init}\) is chosen (which ensures that \(\mathfrak c_i\) is satisfied by A). Thus since \(\pi ^{*}\) ensures \(\mathsf {dead}\) is not reached, the assignment A is a satisfying assignment for \(\Psi \).
Thus, it follows that the answers to the decision problems are “Yes” iff \(\Psi \) is satisfiable, and this establishes the Nphardness result. \(\square \)
5.2.2 The Np upper bounds
 Meanpayoff objectives

Once the memoryless strategy for Player 1 is fixed, the game problem reduces to a 1player game where there is only Player 2. The verification problem hence reduces to the path problem in directed graphs analyzed and shown to be solvable in polynomial time by Theorem 1 in Sect. 4.1.
 Ratio objectives

Again, once the memoryless strategy for Player 1 is fixed, the game problem reduces to a decision problem on directed graphs. The same reduction from ratio objectives to meanpayoff objectives introduced in Sect. 4.1 can be applied. Theorem 1 hence gives a polynomialtime verification algorithm for our ratio objectives.
We summarize the result in the following theorem.
Theorem 3
The decision problems for partialobservation games with meanpayoff objectives and ratio objectives, i.e., whether \(\sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{MP}(w,\mathscr {P}(s^1,\pi ,\sigma ))\geqslant \nu \) respectively \(\sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{Ratio}(w_1,w_2,\mathscr {P}(s^1,\pi ,\sigma ))\geqslant \nu \), are Npcomplete.
Remark 6
 1.
The reward functions \(w\), \(w_1\), \(w_2\) map to \(d\)dimensional vectors of rewards, and the decision problems are with respect to a threshold vector \(\vec {\nu }\).
 2.
Player 2 must also satisfy a conjunction of \(\mathsf {Safe}(X)\) and \(\mathsf {Live}(Y)\) objectives (see Sect. 4.1).
5.3 Reduction of competitive synthesis to a graph game
 1.In synthesis for the worstcase average utility, the goal is to construct an online scheduling algorithm that has the largest worstcase average utility possible. Recall the notation \(V(\rho _{{\mathcal {A}}}^\sigma ,k)\) for the cumulative utility in the first k time slots of an online scheduling algorithm \({\mathcal {A}}\) with schedule \(\rho _{{\mathcal {A}}}^{\sigma }\) under the released job sequence \(\sigma \). Formally, the task is to construct an online scheduling algorithm \({\mathcal {A}}\) such that, for any onlinescheduling algorithm \({\mathcal {A}}'\),where \({\mathcal {J}}\) is the set of admissible job sequences.$$\begin{aligned} \inf _{\sigma \in {\mathcal {J}}} \liminf _{k\rightarrow \infty } \frac{1}{k}V(\rho _{{\mathcal {A}}}^\sigma ,k) \geqslant \inf _{\sigma \in {\mathcal {J}}} \liminf _{k\rightarrow \infty } \frac{1}{k}V(\rho _{{\mathcal {A}}'}^\sigma ,k), \end{aligned}$$
 2.
In competitive synthesis, the task is to construct an online scheduling algorithm with the largest possible competitive ratio. That is, we are looking for an online algorithm \({\mathcal {A}}\) such that, for any online algorithm \({\mathcal {A}}'\), we have \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\geqslant {\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}}')\), where \({\mathcal {CR}}_{{\mathcal {J}}}({\mathcal {A}})\) is the competitive ratio of algorithm \({\mathcal {A}}\) under the set \({\mathcal {J}}\) of admissible job sequences (see Eq. (1) in Sect. 2 for the definition of \({\mathcal {CR}}_{{\mathcal {J}}}\)).
5.3.1 Synthesis for worstcase average utility
Given a taskset, we can compute the worstcase average utility that can be achieved by any online scheduling algorithm. For this, we construct a nondeterministic finitestate LTS \(L_{\mathscr {G}}=(S_{\mathscr {G}},s_{\mathscr {G}},\Sigma , \Pi ,\Delta _{\mathscr {G}})\) with an associated reward function \(r_{\mathscr {G}}\) that can simulate all possible online algorithms. Such an LTS has already been introduced in Sect. 3 for the clairvoyant algorithm. Note that the latter implements memoryless strategies, as all required history information is encoded in the state.
We can interpret such a nondeterministic LTS as a perfectinformation graph game \(\mathscr {G}=\langle S_{\mathscr {G}}, \Sigma _1, \Sigma _2, \delta \rangle \), where \(\Sigma _1\) (the actions of Player 1) correspond to the output actions \(\Pi \) in \(L_{\mathscr {G}}\), and \(\Sigma _2\) (the actions of Player 2) correspond to the input actions \(\Sigma \) in \(L_{\mathscr {G}}\). That is, Player 2 (the adversary) chooses the released tasks, while Player 1 chooses the actual transitions in \(\delta \) actually taken.
Theorem 4
 1.
Whether there exists an online algorithm with worstcase average utility at least \(\nu \) can be decided in Np \(\cap \) coNp in general; and if \(V_{\max }\) is bounded by the size of the nondeterministic LTS, then the decision problem can be solved in polynomial time.
 2.
An online algorithm with optimal worstcase average utility can be constructed in time \(O(S_{\mathscr {G}} \cdot m \cdot V_{\max })\), where \(S_{\mathscr {G}}\) (resp. m) is the number of states (resp. transitions) of the nondeterministic LTS \(L_{\mathscr {G}}\).
5.3.2 Competitive synthesis
Given a taskset and a rational \(\nu \in \mathbb {Q}\), the competitive synthesis problem asks to determine whether there exists an online scheduling algorithm that achieves a competitive ratio of at least \(\nu \), and to determine the optimal competitive ratio \(\nu ^*\). Recall the nondeterministic LTS \(L_{\mathscr {G}}=(S_{\mathscr {G}},s_{\mathscr {G}},\Sigma , \Pi ,\Delta _{\mathscr {G}})\) and reward function \(r_{\mathscr {G}}\) in the synthesis for the worstcase average utility. For solving the competitive synthesis problem, we construct a partialobservation game \(\mathscr {G}_{{\mathcal {CR}}}\) as follows: \(\mathscr {G}_{{\mathcal {CR}}}=\langle S_{\mathscr {G}}\times S_{\mathscr {G}}, \Sigma _1, \Sigma _2 \times \Sigma _1,\delta , \mathcal{{O}}_S,\mathcal{{O}}_{\Sigma } \rangle \), where \(\Sigma _1=\Pi \) and \(\Sigma _2=\Sigma \). Intuitively, we construct a product game with two components, where Player 1 only observes the first component (the online algorithm) and makes the choice of the transition \(\alpha _1 \in \Sigma _1\) there; Player 2 is in charge of choosing the input \(\alpha _2 \in \Sigma _2\) and also the transition \(\alpha _1' \in \Sigma _1\) in the second component (the clairvoyant algorithm). However, due to partial observation, Player 1 does not observe the choice of the transitions of the clairvoyant algorithm.
 (i)Transition function \(\delta : (S_{\mathscr {G}}\times S_{\mathscr {G}})\times \Sigma _1\times (\Sigma _2\times \Sigma _1) \rightarrow (S_{\mathscr {G}}\times S_{\mathscr {G}})\) with$$\begin{aligned} \delta ((s_1,s_2),\alpha _1,(\alpha _2,\alpha '_1))= (\delta (s_1,\alpha _1,\alpha _2), \delta (s_2,\alpha '_1,\alpha _2)). \end{aligned}$$
 (ii)
The observation for states for Player 1 maps every state to the first component, i.e., \(\mathsf {obs}_S((s_1,s_2))=s_1\), and the observation for actions for Player 1 maps every action \((\alpha _2,\alpha _1')\) of Player 2 to its first component \(\alpha _2\) as well (i.e., the input from Player 2), i.e., \(\mathsf {obs}_{\Sigma }((\alpha _2,\alpha '_1))=\alpha _2\).
It follows that an online algorithm with competitiveratio at least \(\nu \) exists iff \( \sup _{\pi \in \Pi _\mathscr {G}^M} \inf _{\sigma \in \Sigma _\mathscr {G}} \mathsf{Ratio}(w_1,w_2, \mathscr {P}(s^1,\pi ,\sigma ))\geqslant \nu \), where \(s^1=(s_{\mathscr {G}}, s_{\mathscr {G}})\) is the start state derived from the LTS \(L_{\mathscr {G}}\). By Theorem 3, the decision problem is in Np in the size of the game \(\mathscr {G}_{{\mathcal {CR}}}\). Since the strategy of Player 1 can directly be translated to an online scheduling algorithm, the solution of the synthesis problem follows from the witness strategy for Player 1. We hence obtain:
Theorem 5
For the class of scheduling problems defined in Sect. 2, the decision problem of whether there exists an online scheduler with a competitive ratio at least a rational number \(\nu \) is in Np in the size of the LTS constructed from the scheduling problem.
Finally, finding the optimal competitive ratio \(\nu ^*\) (and a scheduling algorithm ensuring it) is possible by searching for \(\sup \{\nu \in \mathbb {Q}: \text {the answer to the decision problem is yes}\}\).
5.3.3 Synthesis for worstcase utility ratio
Remark 8
(Complexity with respect to the taskset) Theorem 4 and Theorem 5 establish complexity upper bounds for the synthesis for worstcase utility, and competitive synthesis problems as a function of the size of the nondeterministic LTS \(L_{\mathscr {G}}\). In general, the size of \(L_{\mathscr {G}}\) is exponential in the bit representation of the taskset \({\mathcal {T}}\). Hence, if the input to our algorithms is the taskset \({\mathcal {T}}\), the polynomial upper bounds of Theorem 4 and Theorem 5 translate to exponential upper bounds in the size of \({\mathcal {T}}\).
Remark 9
(Memory of the synthesized scheduler) The memoryspace requirement of the synthesized scheduler is upperbounded by \(O(C_{\max }^{N\cdot (D_{\max }1)})\), where N is the number of tasks, \(D_{\max }\) the maximum task deadline and \(C_{\max }\) is the maximum execution time. This holds since the state of the online scheduler is an \(N\times (D_{\max }1)\) matrix, where each entry of the matrix denotes the remaining execution time of a job.
6 Conclusions
We presented a flexible framework for the automated competitive analysis and competitive synthesis of realtime scheduling algorithms for firmdeadline tasksets using graph games. For competitive analysis, scheduling algorithms are specified as (deterministic) labeled transition systems. The rich formalism of automata on infinite words is used to express optional safety, liveness and limitaverage constraints in the generation of admissible job sequences. Our prototype implementation uses an optimized reduction of the competitive analysis problem to the problem of solving certain multiobjectives in multigraphs. Our comparative experimental case study demonstrates that it allows to solve smallsized tasksets efficiently. Moreover, our results clearly highlight the importance of a fully automated approach, as there is neither a “universally” optimal algorithm for all tasksets (even in the absence of additional constraints) nor an optimal algorithm for different constraints in the same taskset. For competitive synthesis, we introduced a partial observation game with meanpayoff and ratio objectives. We determined the complexity of this game, and showed that it can be used to solve the competitive synthesis problem.
Future work will be devoted to adding additional constraints to the scheduling algorithms, like energy constraints. In order to scaleup to larger tasksets, we will also investigate advanced techniques for further reducing the size of the underlying (game) graphs. Finally, the core computational step in our framework is that of computing meanpayoff objectives in the underlying graphs. Developing faster algorithms for meanpayoff objectives for special graphs is an active area of research (Chatterjee et al. 2015; Chatterjee et al. 2014). Whether the structure of our graphs can be exploited to yield faster algorithms for our framework is an interesting future direction.
Notes
Acknowledgements
This work has been supported by the Austrian Science Foundation (FWF) under the NFN RiSE (S11405 and S11407), FWF Grant P23499N23, ERC Start Grant (279307: Graph Games), and Microsoft Faculty Fellows Award.
References
 Abeni L, Buttazzo G (1998) Integrating multimedia applications in hard realtime systems. In: Proceedings of the 19th IEEE realtime systems symposium, RTSS ’98, pp 4–13. https://doi.org/10.1109/REAL.1998.739726
 Altisen K, Gößler G, Sifakis J (2002) Scheduler modeling based on the controller synthesis paradigm. RealTime Syst. 23(1–2):55–84CrossRefzbMATHGoogle Scholar
 Aydin H, Melhem R, Mossé D, MejíaAlvarez P (2004) Poweraware scheduling for periodic realtime tasks. IEEE Trans Comput 53(5):584–600. https://doi.org/10.1109/TC.2004.1275298 CrossRefGoogle Scholar
 Baruah SK, Haritsa JR (1997) Scheduling for overload in realtime systems. IEEE Trans Comput 46:1034–1039. https://doi.org/10.1109/12.620484 MathSciNetCrossRefGoogle Scholar
 Baruah SK, Hickey ME (1998) Competitive online scheduling of imprecise computations. IEEE Trans Comput 47(9):1027–1032CrossRefGoogle Scholar
 Baruah S, Koren G, Mishra B, Raghunathan A, Rosier L, Shasha D (1991) Online scheduling in the presence of overload. In: Proceedings of the 32nd annual symposium on foundations of computer science, FOCS ’91, pp 100–110. https://doi.org/10.1109/SFCS.1991.185354
 Baruah S, Koren G, Mao D, Mishra B, Raghunathan A, Rosier L, Shasha D, Wang F (1992) On the competitiveness of online realtime task scheduling. RealTime Syst 4(2):125–144CrossRefzbMATHGoogle Scholar
 Berkelaar M, Eikland K, Notebaert P (2004) lpsolve: open source (mixedinteger) linear programming system. Version 5.0.0.0Google Scholar
 Bonifaci V, MarchettiSpaccamela A (2012) Feasibility analysis of sporadic realtime multiprocessor task systems. Algorithmica 63(4):763–780. https://doi.org/10.1007/s0045301195056
 Borodin A, ElYaniv R (1998) Online computation and competitive analysis. Cambridge University Press, CambridgezbMATHGoogle Scholar
 Brim L, Chaloupka J, Doyen L, Gentilini R, Raskin JF (2011) Faster algorithms for meanpayoff games. Form Methods Syst Des 38(2):97–118CrossRefzbMATHGoogle Scholar
 Chatterjee K, Kößler A, Schmid U (2013) Automated analysis of realtime scheduling using graph games. In: Proceedings of the 16th ACM international conference on hybrid systems: computation and control, HSCC ’13, pp 163–172. ACM, New YorkGoogle Scholar
 Chatterjee K, Henzinger M, Krinninger S, Nanongkai D (2014) Polynomialtime algorithms for energy games with special weight structures. Algorithmica 70(3):457–492MathSciNetCrossRefzbMATHGoogle Scholar
 Chatterjee K, Pavlogiannis A, Kößler A, Schmid U (2014) A framework for automated competitive analysis of online scheduling of firmdeadline tasks. In: RTSS ’14, pp 118–127Google Scholar
 Chatterjee K, IbsenJensen R, Pavlogiannis A (2015) Faster algorithms for quantitative verification in constant treewidth graphs. In: CAVGoogle Scholar
 Clarke EM Jr, Grumberg O, Peled DA (1999) Model checking. MIT Press, CambridgeGoogle Scholar
 Cruz RL (1991) A calculus for network delay. I. Network elements in isolation. IEEE Trans Inf Theory 37(1):114–131. https://doi.org/10.1109/18.61109 MathSciNetCrossRefzbMATHGoogle Scholar
 Dertouzos ML (1974) Control robotics: The procedural control of physical processes. In: IFIP Congress, pp 807–813Google Scholar
 Devadas V, Li F, Aydin H (2010) Competitive analysis of online realtime scheduling algorithms under hard energy constraint. RealTime Syst 46(1):88–120. https://doi.org/10.1007/s112410109100y CrossRefzbMATHGoogle Scholar
 Ehrenfeucht A, Mycielski J (1979) Positional strategies for mean payoff games. Int J Game Theory 8(2):109–113MathSciNetCrossRefzbMATHGoogle Scholar
 Englert M, Westermann M (2007) Considering suppressed packets improves buffer management in qos switches. In: Proceedings of the eighteenth annual ACMSIAM symposium on discrete algorithms, SODA 2007, New Orlean, January 7–9, 2007, pp 209–218. http://dl.acm.org/citation.cfm?id=1283383.1283406
 Galperin H, Wigderson A (1983) Succinct representations of graphs. Inf Control 56(3):183–198MathSciNetCrossRefzbMATHGoogle Scholar
 Golestani SJ (1991) A framing strategy for congestion management. IEEE J Sel Areas Commun 9(7):1064–1077. https://doi.org/10.1109/49.103553 CrossRefGoogle Scholar
 Gupta BD, Palis MA (2001) Online realtime preemptive scheduling of jobs with deadlines on multiple machines. J Sched 4(6):297–312. https://doi.org/10.1002/jos.85 MathSciNetCrossRefzbMATHGoogle Scholar
 Haritsa JR, Carey MJ, Livny M (1990) On being optimistic about realtime constraints. In: Proceedings of the 9th ACM SIGACTSIGMODSIGART symposium on principles of database systems, PODS ’90, pp 331–343. ACM, New York. https://doi.org/10.1145/298514.298585
 Karp RM (1972) Reducibility among combinatorial problems. In: Proceedings of the Complexity of computer computations. Springer USGoogle Scholar
 Karp RM (1978) A characterization of the minimum cycle mean in a digraph. Discret Math 23(3):309–311MathSciNetCrossRefzbMATHGoogle Scholar
 Khachiyan LG (1979) ) A polynomial algorithm in linear programming. Dokl Akad Nauk SSSR 244:1093–1096MathSciNetzbMATHGoogle Scholar
 Koren G, Shasha D (1995) \(\text{ D }^{{over}}\): an optimal online scheduling algorithm for overloaded uniprocessor realtime systems. SIAM J Comput 24(2):318–339. https://doi.org/10.1137/S0097539792236882 MathSciNetCrossRefzbMATHGoogle Scholar
 Koutsoupias E (2011) Scheduling without payments. In: Proceedings of the 4th international conference on algorithmic game theory, SAGT’11, pp 143–153. Springer, Berlin, HeidelbergGoogle Scholar
 Leung JT (1989) A new algorithm for scheduling periodic, realtime tasks. Algorithmica 4(1–4):209–219. https://doi.org/10.1007/BF01553887 MathSciNetCrossRefzbMATHGoogle Scholar
 Locke CD (1986) Besteffort decisionmaking for realtime scheduling. Ph.D. thesis, CMU, PittsburghGoogle Scholar
 Lu Z, Jantsch A (2007) Admitting and ejecting flits in wormholeswitched networks on chip. IET Comput Digit Tech 1(5):546–556. https://doi.org/10.1049/ietcdt:20050068
 Lübbecke E, Maurer O, Megow N, Wiese A (2016) A new approach to online scheduling: approximating the optimal competitive ratio. ACM Trans Algorithms 13(1):15:1–15:34Google Scholar
 Madani O (2002) Polynomial value iteration algorithms for deterministic MDPs. In: Proceedings of the 18th conference on uncertainty in artificial intelligence, UAI ’02, pp 311–318Google Scholar
 Martin DA (1975) Borel determinacy. Ann Math 102(2): 363–371 . http://www.jstor.org/stable/1971035
 Nisan N, Roughgarden T, Tardos E, Vazirani VV (2007) Algorithmic game theory. Cambridge University Press, New YorkCrossRefzbMATHGoogle Scholar
 Palis MA (2004) Competitive algorithms for finegrain realtime scheduling. In: Proceedings of the 25th IEEE realtime systems symposium, RTSS ’04, pp 129–138. IEEE Computer Society. http://doi.ieeecomputersociety.org/10.1109/REAL.2004.14
 Papadimitriou CH (1993) Computational complexity. AddisonWesley, ReadingzbMATHGoogle Scholar
 Porter R (2004) Mechanism design for online realtime scheduling. In: Proceedings of the 5th ACM conference on electronic commerce, EC ’04, pp 61–70. ACM, New York. https://doi.org/10.1145/988772.988783
 Rajkumar R, Lee C, Lehoczky J, Siewiorek D (1997) A resource allocation model for qos management. In: Proceedings of the 18th IEEE realtime systems symposium, RTSS ’97, pp 298 –307. https://doi.org/10.1109/REAL.1997.641291
 Shapley LS (1953) Stochastic games. Proc Natl Acad Sci USA 39(10):1095–1100. http://www.pnas.org/content/39/10/1095.short
 Sheikh AA, Brun O, Hladik PE, Prabhu BJ (2011) A bestresponse algorithm for multiprocessor periodic scheduling. In: Proceedings of the 2011 23rd euromicro conference on realtime systems, ECRTS ’11, pp 228–237. IEEE Computer Society, Washington. https://doi.org/10.1109/ECRTS.2011.29
 Tarjan R (1972) Depthfirst search and linear graph algorithms. SIAM J Comput 1(2):146160MathSciNetCrossRefGoogle Scholar
 Velner Y, Chatterjee K, Doyen L, Henzinger TA, Rabinovich A, Raskin JF (2015) The complexity of multimeanpayoff and multienergy games. Inf Comput 241(Suppl C):177–196. https://doi.org/10.1016/j.ic.2015.03.001
 Zwick U, Paterson M (1996) The complexity of mean payoff games on graphs. Theoret Comput Sci 158(12):343–359MathSciNetCrossRefzbMATHGoogle Scholar
Copyright information
Open AccessThis article is distributed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made.