
3 minute read
Embedded Multicore and OpenAMP
By Colin Walls, Siemens Embedded
Every embedded system is different. And so, as multicore designs become increasingly common, almost to the point of being mainstream, different hardware and software architectures are evolving.
From the software perspective, there are broadly two options: symmetric multiprocessing (SMP) and asymmetric multiprocessing (AMP).
Inside SMP
The objective of SMP is to increase available processing performance in a power-efficient manner, and it is very commonly found on desktop and laptop computers.
An SMP system can only be implemented on a homogeneous multicore platform (i.e., all the cores are identical). A single instance of an operating system (OS) runs across all the cores, and this OS needs to be a specific variant that supports SMP operations. Today, SMP is supported by Linux and a number of real-time OS products.
With SMP, tasks are distributed across the cores automatically. However, there may be an option to lock tasks to specific cores if that is required for a particular application.
AMP and Embedded Systems
For embedded applications, AMP provides more flexibility and is, hence, much more common. to be identical. Each OS may be selected according to the intended functionality of the core and does not need to be a special, “multicore-enabled” version.
Unlike SMP, AMP does not require all the cores to be identical – it may be implemented on a heterogeneous multicore platform – which is advantageous because most multicore SoC devices include a variety of core architectures as different core architectures may be suitable for different parts of the application.
However, there are two matters that need to be resolved in an AMP design: lifecycle management (boot sequence, etc.) and inter-core communications. These issues do not arise in an SMP system, as the OS has control over which tasks run where and when and inter-task communication uses the standard OS APIs because the tasks do not need to “know” they are running in a multicore context. In an AMP system, each OS is unaware of the existence of the others, so specific provisions must be made.
OpenAMP: A Multiprocessing Framework
The best way to configure an AMP system is to use some kind of multicore framework to address the control and communication requirements. OpenAMP1 is a standard that defines the architecture of such a framework; implementations of OpenAMP are available from a number of vendors.
MOORE’S LAW VERSUS PARALLELISM

FIGURE 1
OpenAMP provides an architectural framework for asymmetric multiprocessing in multicore embedded systems.
An instance of the framework runs on each core. Lifecycle management is provided by using the Remoteproc framework2 , where one core is designated as the “master”. Inter-core communication is managed using RPMsg3, which provides a channel-based, bi-directional communication link between cores.
An alternative to using a multicore framework is to deploy a hypervisor. This is a powerful option but is limited by its requirement that all CPUs are identical and, hence, it can only be used on a homogeneous multicore platform. However, in a complex multicore system, there may be groups of identical cores that can be managed using an SMP OS or a hypervisor, linked to the rest of the system using a multicore framework.
Colin Walls is currently an embedded software technologist at Siemens, and has more than 40 years’ experience in the electronics industry (largely involved with embedded software – very much a pioneer in this specialty). Colin has authored a great many technical articles and one of the first books on embedded software, Programming Dedicated Microprocessors (Macmillan Education, 1986). His most recent publication is Embedded Software: The Works (2nd edition; Newnes, 2012), which addresses a wide range of embedded software topics.
References:
1. The openamp project. Retrieved from www.openampproject.org. 2. Remote Processor Framework. Retrieved from www.kernel.org/doc/Documentation/remoteproc.txt. 3. Remote Processor Messaging (rpmsg) Framework. Retrieved from www.kernel.org/doc/Documentation/rpmsg.txt.
Making the Grade with Linux and Cybersecurity at the Intelligent Edge
Sponsored by Wind River Software developers use open source Linux because of its ease of access, flexibility, and leading-edge technologies. It also has one of the largest and most prolific communities, with vast amounts of resources. At the intelligent edge, where devices and systems have mission-critical functionality, Linux adoption has lagged behind other markets. But the momentum is shifting, and Linux has the potential to lead the way for a massive transformation of the embedded industry. Join Michael Mehlberg, vice president of marketing for Wind River® Security, for a fast-paced micro series covering the requirements needed for Linux to make the grade at the intelligent edge.
Watch the seven-part series at http://bit.ly/WindRiverMakingtheGrade.
