Virtualization Brings Real Benefits

Intel® Virtualization Technology, or Intel® VT, enables the integration of two or more autonomous applications. Exploiting the company’s multi-core microprocessors, Intel VT offers industrial automation users the performance of multiple separate processors in a single chip. This multitasking brings some significant benefits.

By Control Engineering Contributing Writers July 1, 2007

Intelgs some significant benefits.

The advantages show up in lower overall power consumption, smaller hardware footprint and lower system costs. Intel VT also offers isolation between applications and enhanced fail over reliability, a result of virtualization and multiple cores. Finally, Intel VT makes it possible to deploy applications on a factory floor without impacting operations, an important plus.

Intel’s worldwide industrial automation segment market manager Ian Gilvarry notes the multiple benefits all derive from the new technology. “With a multi-core enabled design, you can realize a single hardware footprint that consumes less power,” he says. “Virtualization is an enabling technology. There’s a major cost savings here.”

Avoiding a Sticky Situation

To see how these benefits come about, take a common situation faced by industrial automation users. They need a GUI, a graphical user interface, for the operator and HMI. Some general purpose operating systems, such as Microsoft Windows*, come with a wealth of tools and libraries that make it easier for developers to customize the GUI. On the other hand, a general purpose OS (GPOS) may not be suitable to handle the real-time (RT) tasks at the heart of industrial automation. For that, users need a real-time OS (RTOS).

In meeting these somewhat contradictory requirements, users have traditionally opted to integrate two machines, one for real time control based on an RTOS and the other for operator interface based on a GPOS. That approach doubles both upfront and operating costs, as well as increasing the hardware space needed. Alternatively, they could go for a machine running multiple operating systems. This approach is complex to implement and has some limitations.

Platform solutions architect Edwin Verplanke cites a typical example of virtualization done without multi-core support. In that case, the RTOS must take control of interrupts, the asynchronous signals received when an external device, such as a motorized arm, needs attention. With software-only virtualization, the GPOS has to be manipulated at a basic level to ensure that interrupt and scheduling functions are handled by the appropriate OS with the right level of priority.

“If Windows* attempts to service it, the other kernel will take control. It will suspend Windows. But that is very, very complex,” says Verplanke. This approach is problematic, he continues, because most operating systems expect to have full hardware access.

With Intel VT, Intel provides hardware support for virtualization for developers to take advantage of the two or more processor cores present in multi-core chips. One core can host the RTOS while the other hosts a Windows or Linux* GPOS. This divide-and-conquer approach solves the two important problems critical to many automation applications: latency and jitter performance.

An unavoidable side effect of the software only solution is an increase in interrupt jitter or system latency. Tests, for instance, show that a largely idle 2.4 GHz Intele two systems are loaded, each running multiple Windows applications with disk and network access. Then the single-core system’s response balloons out to 17.7 microseconds. In contrast, the multi-core setup’s response time is 3.3 microseconds, the same for the unloaded case. This boundedreal-time performance occurs because one core is handling the GPOS demand while the other is hosting the RTOS.

Such low interrupt latencies enable bounded real-time application control loops to operate as quickly as every 50 microseconds, a much shorter cycle than is possible with software virtualization. The difference translates into a qualitative and quantitative enhancement of industrial control, points out Verplanke. “The faster you can regulate the flow of something or the faster you can react to a specific request, the better it is.”

Getting to the Root

Intel’s roadmap on virtualization technology is a phased approach to enable efficient and complete sharing of resources among several operating systems. The first generation of this technology, Intel VT for IA-32 Intelresponsible for scheduling. Applications, in contrast, sat at Ring 3. For virtualization in such a setting, a software only virtual machine monitor, a VMM or hypervisor, had to be sandwiched between the hardware and the OS, a complicated chore.

With Intel VT-x, guest operating systems can be loaded in non-root mode. In that case, the guest OS sits at Ring 0 of the non-root machine and does so without modification. As far as the OS and any applications running on it are concerned, the arrangement looks no different than is the case with a single core chip. The hypervisor, on the other hand, is in root mode and conceptually sits between the OS and the hardware. It handles communication between the guests by, for instance, creating a virtual device that one OS sets as a flag when it has information in a shared memory region for the other.

While all of the hardware could be virtualized, that is generally not done in an RT control application. Instead, for performance and reliability reasons a partial virtualization is typically done.

The GPOS will then have largely unfettered access to the hardware, with certain exceptions. “The real-time kernel will continue to take control over those devices it requires control over in order to guarantee bounded real-time performance,” says Verplanke.

Example of resources that might be exclusively controlled by an RTOS include a video capture system, a fieldbus interface or an Ethernet NIC for industrial I/O. User interface devices like a keyboard, mouse, or console are usually not time-critical and so could be virtualized by the hypervisor.

Virtualizing Interrupts

While Intel VT-x and dual cores are a reality in embedded applications today, the next step in the technology roadmap will add cores and virtualization capabilities. This year, Intel will debut a four core system, along with Intel VT for Directed I/O (Intel

With Intel VT-d, the focus shifts from virtualization of the processor to virtualization of I/O. Currently if a guest OS requires access to a particular piece of hardware, the hypervisor has to explicitly support this by offering mapping that connects the guest OS to the hardware in question. With Intel VT-d, that will no longer be needed as it will enable directly assigning I/O devices to a specific guest.

A direct memory access (DMA) remapping scheme, Intel VT-d will allow partitioning of resources without the overhead found in today’s virtualization schemes. In combination with the expansion from two cores to four, it allows for systems in which DSP, Real Time Control and Operator Interface functions can be consolidated into one multi-core setup. In that arrangement, one core can handle primary machine control, another can do high-performance data acquisition and digital filtering, while the rest support enterprise network access and the Human Machine Interface.

In summing up the situation, Gilvarry notes that Intel VT offers industrial automation applications more for less. For less power in a smaller space and at a lower cost, Intel VT enables increased performance, functionality and greater system uptime. He adds that being able to do two things at once helps both with initial development and later when the inevitable upgrade comes along for the application or the GPOS. “We have the ability to perform software migration without having to bring down the platform.”

Kontron is among the leading single board computer vendors in the world, with customers that span the industrial automation, military, telecom, medical and transportation markets. Most of the company’s customers like multi-core microprocessors because this relatively new technology can, given the right software, double the computing power available. Those looking at control applications, on the other hand, have a different focus.

“Industrial users really like multi-core solutions because of the virtualization technology. That’s almost– not completely – unique to industrial,” says pre-sales applications engineer David Pursley.

In a typical setup, the cores are treated as two computers, with one running an RTOS for a control application. The others handle the visualization, general communication, and other tasks of an industrial PC running a general purpose OS.

Pursley explains that most industrial automation users go through a similar solution progression. Most were very concerned about not loading down the RTOS in the old setup. Thus, they frequently have meager requirements of the new virtualization technology and expect few benefits from the core running the GPOS. However, they’re often pleasantly surprised.

He tells of a customer, for example, who wanted to have the RTOS on one core run a process while doing limited data analysis and historical tracking on the other. Once the system was running, the customer found that the data processing resulted in only a five percent or so utilization of the second core. Seeing that, they took an application that usually ran on a remote server and put it on the second core. That, too, didn’t use up much of the computing capability and so another function was added, and then another, until in the end the multi-core processor was functioning as an RTOS-based controller and at least one other complete GPOS platform.

Similar results have been realized in applications as diverse as remote-monitored power plants and factory floors. Of virtualization technology and industrial automation users, Pursley says, “In many cases, it doubles the value of the system.”

He adds that control applications may have an advantage in quickly getting full use out of multi-core products. Because the cores are treated as different machines, there’s no need to rewrite applications which are using single processing threads to take advantage of the chip’s capabilities. Applications can simply run on the new system and benefit from the processing power.

In computer terms, TenAsys is ancient, having debuted its first RTOS more than two decades ago. In addition to other real-time products, TenAsys today offers INtime* as a way to add deterministic, real-time capabilities to Microsoft Windows, the world’s most popular desktop OS.

Paul Fischer, a senior technical marketing engineer, is excited about Intel’s hardware support for virtualization for some bottom line reasons. “There are a couple different angles here but all go toward the same end goal of reducing cost and hardware content. Intel

Fischer notes that users have turned to INtime because they need both an RTOS and a GPOS, with tightly-coupled communication between the two. Virtualization has proven to be a significant benefit to the company’s customers.

For example, Phoenix Contact makes a software PLC, a programmable logic controller, that uses Windows for development and data monitoring and an RTOS for PLC control, with both running on the same chip. The Phoenix Contact product, Steeplechase VLC*, is considered among the fastest of its type available, with logic scan times as short as 200 microseconds. As a result of harnessing a GPOS with an RTOS, an automotive customer of Phoenix Contact reduced floor space for a new line by 40 percent, cut design and installation time by 12 weeks, and reached full production in a tenth the normal time.

A CNC machining system from ANCA uses Windows for 3D modeling and simulation while the RTOS provides multi-axis control, again doing both on a single hardware platform. The combination allows operators to run simulations on the CNC machine itself, saving time. An added bonus is that AutoCAD design data can be imported directly into the machine, another boost to productivity.

Intel VT will make the TenAsys real-time offerings even better and may help its customers reduce operating expenses in some new ways. For example, TenAsys chief technology officer Christopher Main notes that today a virtualized GUI that crashes can’t be restarted without rebooting the entire machine, which means stopping the RTOS controlled equipment and any production dependent on it. That constraint will be gone with Intel VT.

“Because we’ve got independently loaded guests when using Intel