Annotated Ada Reference ManualLegal Information
Contents   Index   References   Search   Previous   Next 

 D.2.3 Preemptive Dispatching

1/2
{AI95-00321-01} [This clause defines a preemptive task dispatching policy.] 

Static Semantics

2/2
{AI95-00355-01} The policy_identifier FIFO_Within_Priorities is a task dispatching policy.

Dynamic Semantics

3/2
{AI95-00321-01} When FIFO_Within_Priorities is in effect, modifications to the ready queues occur only as follows:
4/2
5/2
6/2
7/2
7.a/2
Ramification: If the delay does result in blocking, the task moves to the “delay queue”, not to the ready queue. 
8/2
{AI95-00321-01} {task dispatching point [partial]} {dispatching point [partial]} Each of the events specified above is a task dispatching point (see D.2.1).
9/2
{AI95-00321-01} A task dispatching point occurs for the currently running task of a processor whenever there is a nonempty ready queue for that processor with a higher priority than the priority of the running task. The currently running task is said to be preempted and it is added at the head of the ready queue for its active priority.{preempt (a running task)}

Implementation Requirements

10/2
 {AI95-00333-01} An implementation shall allow, for a single partition, both the task dispatching policy to be specified as FIFO_Within_Priorities and also the locking policy (see D.3) to be specified as Ceiling_Locking. 
10.a/2
Reason: This is the preferred combination of the FIFO_Within_Priorities policy with a locking policy, and we want that combination to be portable. 

Documentation Requirements

11/2
 {AI95-00321-01} {priority inversion} Priority inversion is the duration for which a task remains at the head of the highest priority nonempty ready queue while the processor executes a lower priority task. The implementation shall document:
12/2
12.a/2
Documentation Requirement: The maximum priority inversion a user task can experience from the implementation.
13/2
13.a/2
Documentation Requirement: The amount of time that a task can be preempted for processing on behalf of lower-priority tasks.
NOTES
14/2
17  {AI95-00321-01} If the active priority of a running task is lowered due to loss of inherited priority (as it is on completion of a protected operation) and there is a ready task of the same active priority that is not running, the running task continues to run (provided that there is no higher priority task).
15/2
18  {AI95-00321-01} Setting the base priority of a ready task causes the task to move to the tail of the queue for its active priority, regardless of whether the active priority of the task actually changes.

Wording Changes from Ada 95

15.a/2
{AI95-00321-01} This subclause is new; it mainly consists of text that was found in D.2.1 and D.2.2 in Ada 95. This was separated out so the definition of additional policies was easier.
15.b/2
{AI95-00333-01} We require that implementations allow this policy and Ceiling_Locking together.
15.c/2
{AI95-00355-01} We explicitly defined FIFO_Within_Priorities to be a task dispatching policy. 

Contents   Index   References   Search   Previous   Next 
Ada-Europe Sponsored by Ada-Europe