# Priority Queues with Fractional Service for Tiered Delay QoS
## 7 Designing Fractional Service Buffer  
In the previous section, we showed that, given the values of \(K_{i}\) (_i.e._, thresholds for the queue length of each \(L_{i}\)) and \(m\), the delay limit and the probability for delay limit violation for each class could be determined. When designing a packet scheduler, however, a common objective is to set the buffer size for each delay class such that a pre-determined delay limit for that class can be achieved. In the following, we illustrate how to utilize our analytical results to achieve this design objective. We consider a case with \(M=4\), where each Class-\(i\) has a delay limit of \((i+1)D\). That is, the delay limit increases with \(i\) such that Class-0 has a delay limit of \(D\), Class-1 a delay limit of \(2D\), Class-2 a delay limit of \(3D\), and so on. For simplicity, we assume that the packet sizes are fixed and are equal for all classes and let \(X_{\max}\) denote the fixed packet size. By letting each \(\tau_{i}-\tau_{i-1}=D\) in Equations (9) and (10), each \(K_{i}\) can be expressed as:  
\[K_{0}=\frac{DC}{X_{\max}} \tag{13}\]  
\[K_{i}=\frac{\eta_{i}/(1+\eta_{i})DC}{X_{\max}}+K_{i-1},\ 1\leq i\leq M \tag{14}\]  
The above equations associate each \(K_{i}\) with the delay limits. However, \(K_{i}\)s and delay limits are meaningless without being accompanied by the probabilities of delay-limit violation (_i.e._, \(\delta_{i}\)), which can be determined given the packet-arrival statistics. For simplicity, let the packet inter-arrival time for each Buffer-\(i\) be exponentially distributed with a mean of \(1/\lambda\) (_i.e._, \(\lambda_{i}=\lambda\) for all \(0\leq i\leq M\)). We use a numeric example to illustrate the relationships between \(D\), \(K_{i}\), and \(\delta_{i}\), where the numeric values  
Figure 11: Delays for a system with \(M=4\) and \(m=1\). used in this example are summarized in Table 1. Note that \(D=50\dfrac{X_{\max}}{C}=7.5\times 10^{-4}\), which is equal to the time required for serving 50 packets of size \(X_{\max}=1500\). This results in \(K_{0}=50\). Additionally, note that \(\lambda\) is chosen such that the system has a normalized load of 1 (_i.e._, \(\rho_{M}=\dfrac{(M+1)\lambda X_{\max}}{C}=1\)). This means that \(\rho_{0}=\dfrac{\lambda X_{\max}}{C}=0.2\), \(\rho_{1}=\dfrac{2\lambda X_{\max}}{C}=0.4\), and so on. As such, Buffer-0 can store up to 50 Class-0 packets but only has \(\rho_{0}=0.2\) of traffic load. Clearly, Class-0 traffic has ample storage space for storing packets and will have a very small probability of delay limit violation, \(\delta_{0}\), regardless of the unit fraction, \(\eta_{1}=1/\mathrm{m}\), chosen for packet promotion from Buffer-1 to Buffer-0. This excessive storage space is shared with lower-priority classes, thus allowing these classes to enjoy low probabilities of delay limit violation as well. Table 1 illustrates the \(K_{i}\) required for achieving the delay limits when \(m=1\) and when \(m=2\). For \(m=1\), \(K_{i}-K_{i-1}\) decreases as \(i\) increases. In other words, the dedicated buffer space for Class-\(i\) packets under congestion (_i.e._, \(K_{i}-K_{i-1}\)) is small when Class-\(i\) has low priority. This is because as \(i\) increases, \(\eta_{i}\) decreases harmonically while the delay limit increases linearly. The linear increase on the delay limit requires that each Class-\(i\) packet be promoted in \(D\) seconds, for any Class-\(i\) with \(1\leqslant i\leqslant M\). However, the harmonic descent on \(\eta_{i}\) implies that a Class-\(i\) packet is promoted slower than that of a Class-(\(i\)\(-\)1) packet. That is, as the promotion rate of packets becomes slower when \(i\) increases, the limit on the time for a packet promotion remains unchanged. As a result, the dedicated buffer space for Class-\(i\) decreases as \(i\) increases. This phenomenon is even more apparent for \(m=2\), which results in a lower \(\eta_{i}\) for each Class-\(i\) when compared with the \(m=1\) case.