Changeset b9990b8d in rtems

Timestamp:
10/27/21 06:48:47 (2 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
f767ef80
Parents:
6d20f0c5
git-author:
Sebastian Huber <sebastian.huber@…> (10/27/21 06:48:47)
git-committer:
Sebastian Huber <sebastian.huber@…> (11/23/21 10:00:28)
Message:

score: Fix SMP EDF priority group ordering

The SMP EDF scheduler supports one-to-one and one-to-all thread to
processor affinities. The one-to-one thread to processor affinity
introduces a constraint on the ordering of threads. The implementation
uses one ready queue for threads which have a one-to-all affinity and
one for each one-to-one affinity group. To order threads across the
ready queues, a generation number is used. However, the approach to
update the generation number each time a thread is inserted into a ready
queue was wrong. The generation number needs to be updated only in the
enqueue and enqueue scheduled operations where an insert priority is
available. The scheduled chain needs to take the generation number into
account.

An example scenario which shows the bug is this. Let T be a high
priority task affine to processor X. Let A be a lower priority task
affine to processor X. Let B be a lower priority task with no affinity
to a particular processor which executes on processor Y. Let B be in
the same priority group than A and after A. Let T set the affinity to
all processors. Now A (higher priority relative to B) should execute on
X and T (high priority) should execute on Y.

Close #4534.

(No files)

Note: See TracChangeset for help on using the changeset viewer.