With us today is Wind River CTO Tomas Evensen. Tomas is also vice president and general manager of the Wind River Tools product division.
Dr. Dobb's: Tomas, what's the biggest difference between Enterprise/IT Virtualized Environments (desktop) and Embedded Virtualization when developing software?
TE: When developing for an IT hypervisor, most developers will not see a difference at all when comparing developing for the native operating system. The environments and binaries are typically identical. The same is true for embedded developers working at a high level. To them the virtualized and non-virtualized systems look the same.
But for embedded developers that are doing lower level of development, doing I/O on specific devices and optimizing the whole system to run as fast as possible, there is a difference. In an embedded hypervisor there are many “knobs” to turn when it comes to configuration that affects performance. For example, an embedded systems developer need to make some decisions on which OS the I/O devices should be mapped to.
In the IT space, very few developers are involved with systems programming (devices, memory maps, etc.). That is done once. Every embedded system looks a bit different and to get the most performance out of a given device, more effort is involved at the systems level.
Dr. Dobb's: Is it easier for programmers to move from embedded to desktop, or from desktop to embedded?
TE: It is always dangerous to generalize, but it is typically much easier to move from embedded to desktop for a multitude of reasons:
- For the desktop you are developing for a full-fledged machine that has a very rich OS environment. Embedded systems are often much more scaled down for cost reasons.
- The desktop hardware (a PC or server) is very stable. Embedded programmers often develop for systems that are being designed and developed in parallel with the software.
- When debugging on a desktop, you run your code on the same machine as your dev tools (native development). This simplifies things a lot. For an embedded system, the host and the target systems are typically separate (cross developments), which introduces a lot of extra variables (flaky connections, limited resources, etc.)
- Embedded systems typically have a lot more hardware interaction directly from the application code. Specialized devices etc. Both to understand the hardware and to debug code that interacts with hardware is notoriously difficult.
- IT/desktop developers are on a constant path to higher abstraction levels (binary code -> assembly -> C -> Java/C# -> J2EE/.net ->...). Even though it takes time to learn the higher abstraction layers, they also simplify development a lot (hopefully). Since these kind of abstraction levels seem to add overhead that surpasses Moore’s law, most embedded systems are still programmed using fairly low-level languages (C/C++, Java in some specific verticals). Some people would argue that the jury is out when it comes to how much more efficient you become by using higher level abstractions, but this is a big difference. Even if you use C/C++ on your desktop, you typically have a much richer library environment to take care of common things.
In fact, many embedded developers start out with developing and testing their embedded software on the host (either using a simulator or using the host OS) and then port it over to the embedded platform when it is somewhat stable.
Dr. Dobb's: Are there differences between debugging multicore desktop systems and debugging multicore embedded platforms?
TE: Most of the differences are described above (limited, sometimes flaky hardware, cross debugging, interactions with hardware). One of the biggest hurdles I have seen for programmers making the transition to embedded development is that in order to be effective, you have to understand a lot more about the underlying system. Most good embedded developers look routinely at the generated assembly code to understand the behavior of the system. This is pretty rare for desktop programmers.
Dr. Dobb's: Where can readers go for more information on these topics?