Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
wiki1201: SymmetricMultiProcessing (Version 1)

How does it work?#

Being a microkernel OS, most of the "operating system" in QNX is implemented in user processes. Even the process manager is implemented as a multithreaded process that uses the regular QNX message passing and thread support (the only difference is that is allowed to perform certain privileged operations not available to normal processes).

This means that many of the tricky issues for SMP operation (synchronisation, mutual exclusion etc.) are already dealt with by the POSIX pthread interfaces. Adding more cpus to the system simply gives the opportunity for more than one thread to run at a time.

The tricky parts of the SMP implementation are thus limited to the microkernel, memmgr and the startup support it uses to initialise the system and implement (board-specific) inter-processor communication. This adds a certain amount of complication and overhead that is really only needed when the system has multiple cpus, so as an optimisation, there are two different procnto variants:

  • procnto only implements support for a uniprocessor
  • procnto-smp implements support for one or more processors

The extra code for SMP operation is in:

  • VARIANT_smp conditional code
  • smp directories that contain code to override uniprocessor implementations:

The following sections delve into the details of: