Tuesday, June 28, 2011

PARFAIT + I/O Latency study

Title: Supporting Real-time guest OS with Xen-ARM Mobile Virtual Machine

‘Draws attention’
Virtualization in mobile systems presents many advantages regarding reliability, security, and flexible user customizability, etc.

‘Unique characteristics of mobile virtualization’
Mobile virtualization has different requirements such as real-time support, small footprint, performance with limited hardware resources. In this work, we focus on supporting heterogeneous guest OSs support, which is a unique requirement in mobile systems virtualization. Those mobile devices requires real-time performance that only RTOS can guarantee as well as rich functionalities that GPOS is able to provide.

‘Introduce difficulties - Porting is nothing more than executing’
In general, it is difficult to support heterogeneous guest OSs over the same physical machine. It is definitely not sufficient for porting two guest OSs, and running within the single physical machine. That is because heterogeneous guest OSs presents different policies, that might conflict each other, and scheduling is one of most significant issues to be resolved. A real-time guest OS has its unique scheduling policy and task model so that all the tasks can meet their given deadlines. On the other hand, fairness and reasonable response time are two primary concerns for a general-purpose guest OS. Those scheduling policies can conflict. For example, a RT guest OS requires immediate task scheduling in order to meet the deadline of a task, that would break the fairness of task scheduling of the GP guest OS, or vice versa. Namely, the difficulty rises when two guest OSs contend for CPU with different conflicting policies.

‘It is the hypervisor that has to arbitrate scheduling in such an environment’
Hierarchical scheduling is an approach that most hypervisors use. In a hierarchical scheduling system, the hypervisor scheduler strictly partition the CPU utilization, and gives the CPU bandwidth to each guest OS. Since each guest OS runs with explicitly given CPU bandwidth, the scheduling policy of a guest OS doesn’t break the scheduling policy of another guest OS.

‘Difficulties are two-fold; what’s more needed for real-time guest OSs’
On one hand, hierarchical scheduling implements resource partition scheduling that strictly isolates performance among guest OSs. However, it is not sufficient to support a real-time guest OS since the requirements are multi-disciplinary rather than simple CPU bandwidth allocation. To address real-time support in a virtualization system, I/O latency issue has to be addressed as well as performance isolation. Since a real-time guest OS has requirements not only for periodic CPU-bound tasks, but also for unpredictable and aperiodic I/O tasks, static CPU bandwidth allocation is not sufficient to deal with I/O latency issues even though hierarchical scheduling is used.

‘KU-approach for real-time virtualization’
1. ‘PARFAIT is an effort to schedule heterogeneous guest OSs over a single physical machine’
Parfait is a scheduling framework that incorporates both real-time guest OSs and non-real-time guest OSs, at the same time. It allocates static amount of CPU bandwidth to real-time guest OSs, at first hand. Secondly, it fairly distributes the CPU bandwidth among the other GP guest OSs. It enables to isolate performance among RTOS and GPOS so that one of guest OSs doesn’t have negative performance impact to another. To incorporate deterministic scheduling theory into a practical system, we performed quantization analysis, and presents an algorithm that provides a scheduling parameter that guarantees schedulability of a virtual machine.

2. ‘To guarantee I/O latency, scheduling optimization has provided’
To guarantee I/O latency, scheduling algorithm has to be carefully optimized. We particularly focus on the Xen-ARM’s split driver in their paravirtualization architecture. It functionally isolates device drivers from user domains so that the potentially faulty device driver cannot compromise the entire system. Although it enhances the reliability of the entire system, it causes additional latency by frequent switching back and forth to the driver domain. With the original credit scheduling policy in Xen-ARM, it presents serious performance degradation. Increased I/O latency might lead to call drops/misses, which can be regarded a serious system defect in mobile systems. To deal with I/O latency, we prioritize the driver domain so that it cannot be scheduled out by another domain. On top of that, we take advantage of hardware specific architectural state. In addition to the hypervisor scheduler, we optimized the guest OS so that the driver domain’s physical interrupt handling cannot be discontinued by virtualized interrupt disable/enable routine.

No comments:

Post a Comment