Scheduler in SMP

Joel Sherrill joel.sherrill at
Fri Sep 28 19:42:23 UTC 2012

On 09/28/2012 02:28 PM, Matias Vara wrote:
> Hi everyone,
> I am playing with the samples of RTEMS for SMP. I am trying understand 
> the example in /smp01, this one creates one task per processor but I 
> cannot figure out how the task is set in a given processor. Are there 
> any parameter when the task is created?
This would be called task processor affinity and it is not currently
supported. It was left as a future enhancement.

The current smptests were not designed to show off smp but to
debug it and to get coverage.

The magic of assigning a task to a core is in the scheduler. It is
in cpukit/score/src/schedulersimplesmp*. It is logically intended to
be the same as the single core scheduler but place the top N
tasks onto the N cores. It takes into account priority, preemption,
FIFO per priority, and timeslicing just like the single core priority
scheduler does.
> Thanks in advance.
> -- 
> MV

Joel Sherrill, Ph.D.             Director of Research&   Development
joel.sherrill at        On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
     Support Available             (256) 722-9985

More information about the devel mailing list