OVER THE years, our machine control and HMI solution has evolved from proprietary processors, to using two separate PCs, to using Windows NT and XP with real-time extensions to achieve less than 50 ms scan rates.
Now that dual-core processors are available from AMD and Intel, does anyone think there could be task management performance advantages using a dual-core solution, which might lead to eliminating the third-party kernel? Has anyone tried it?
-- From February 2006 Control Design
Two Cores Better Than One
A dual-core system has the potential to improve performance and simplify your life. One approach is to use a real-time OS that can run on both cores. The OS can schedule tasks to run on either core seamlessly, allowing you to take advantage of both cores without rewriting your application. If the OS is real time, then your response times can be guaranteed by prioritizing the low-latency tasks. You can even bind certain tasks to one of the cores to ensure maximum performance. If you your applications are portable, then using an RTOS that supports POSIX-conformant interfaces might be a plus. If your applications are hopelessly dependent on Windows, then use an RTOS that can host Windows in a virtual machine, allowing you to run critical real-time tasks alongside Office and other non-real time tasks on the system.
Chris Smith, Marketing Vice President, Green Hills Software, Santa Barbara, CA
Windows Will Still Be Too Fair
Your question asks if Windows, when running on a dual-core platform, will stop being fair to processes, drivers and the kernel, and turn itself into a system that bases its allocation of processor resources on higher-priority control instructions.
From a software perspective, dual-core systems are no different than many of the dual-processor, symmetric multiprocessor platforms (SMP) that have been available for years. The key difference between older, multi-socket SMP platforms and newer, dual-core, single-socket SMP platforms is cost, size, power consumption, and availability. The original Windows NT kernel, on which todays Windows XP is based, was designed from the start to operate on SMP machines.
For Windows, a second (or third, or fourth, etc.) processor resource adds additional CPU cycles over which to spread the compute load. The Windows scheduler will attempt to maximize the use of CPU resources for a variety of applications in a general-purpose manner by spreading the load fairly between user processes and the kernel. Other than accommodating the execution of threads simultaneously, Windows task management, and its real-time determinism, on a dual-core platform (or any other SMP platform) is really no different than it is on a single-core platform.
A real-time kernel for Windows, such as our INtime RTOS, schedules unfairly because it schedules CPU resources to maximize timing of execution and CPU usage in favor of the real-time tasks in the system. Real-time kernels can use dual-core hardware to implement asymmetric multiprocessor platforms (AMP).
In the extreme case, the RTOS can dedicate all real-time tasks and the real-time kernel to one of the available CPU cores, leaving the remaining cores for Windows.
The issue that we see isnt that people will use the dual-core processor to eliminate the third-party RTOS (or the "real-time kernel" as you call it). Instead, we think people will go even further by integrating third-party real-time kernels and Windows. TenAsys has measured even better deterministic response alongside Windows (a 10 to 1 improvement) on dual-core platforms. This platform also provides more compute cycles to the real-time tasks, meaning that even more complex real-time control algorithms can be deployed. Dual-core processors mean that faster scan times can be implemented and higher quality controllers can be deployed on small single-board embedded platforms.
Paul Fischer, Senior Technical Marketing Engineer, TenAsys, Beaverton, OR
It Lifts and Separates
The new dualARM microcontroller from DualCore in Germany addresses this issue, and was an outgrowth of German university research. Avoiding any Windows involvement for runtime processes, this controller has been specifically designed to partition the time-critical tasks from the non-critical HMI functions. The technology supports many high-level functions for controlling and supervising real-time industrial conditions, such as tasks needing accurate time performance under all conditions, even when running in parallel with an OS. One of the two cores is used for real-time control and the second one handles infrastructure such as operator interaction and the required communication interfaces. The real-time operating system EUROS, which is popular in Europe, has been ported to this microcontroller. Datasheets can be found at www.dualcore.com.
Alan Lowne, President, Saelig Co., Pittsford, N.Y.
DUAL-CORE processors can offer several advantages to some industrial applications. For example, if you have programs/tasks for alarm management and separate programs/tasks for real-time trending, each program will have less effect on each other. When it comes to real-time extensions today, were achieving cycle times of 400 µsec, while running Windows on one processor. With a dual-core processor, you still will need the real-time extensions to guarantee the cycle time for the real time response.
John Roberts, Distribution Sales Manager, B&R Industrial Automation, Atlanta, GA
Check out our all-new, "The Best Of" The Answer to Your Problems, where we list all your published questions and answers.
Whats All This About FPGAs?
Send us your comments, suggestions, or solutions for this problem. Well include it in the June 2006 issue and post it on ControlDesign.com. Send visuals if youd likea sketch is fine. E-mail us at CDTheAnswer@putman.net. Please include your company, location and title in the response. Have a problem youd like to pose to the readers? Send it along, too.