Ada Reference Manual (Ada 2022) — Legal Information

# D.4.1 Admission Policies

1/5
This subclause specifies a mechanism for a user to choose an admission policy. It also defines one such policy. Other policies are implementation defined.

#### Syntax

2/5
The form of a pragma Admission_Policy is as follows:
3/5
pragma Admission_Policy (policy_identifier);

#### Legality Rules

4/5
The policy_identifier shall be either FIFO_Spinning or an implementation-defined identifier.

#### Post-Compilation Rules

5/5
An Admission_Policy pragma is a configuration pragma.

#### Dynamic Semantics

6/5
An admission policy governs the order in which competing tasks are evaluated for acquiring the execution resource associated with a protected object. The admission policy is specified by an Admission_Policy pragma.
7/5
One admission policy, FIFO_Spinning, is language defined. If FIFO_Spinning is in effect, and starting a protected action on a protected object involves busy-waiting, then calls are selected for acquiring the execution resource of the protected object in the order in which the busy-wait was initiated; otherwise the FIFO_Spinning policy has no effect. If no Admission_Policy pragma applies to any of the program units in the partition, the admission policy for that partition is implementation defined.

#### Implementation Permissions

8/5
Implementations are allowed to define other admission policies, but are not required to support specifying more than one admission policy per partition.

Ada 2005 and 2012 Editions sponsored in part by Ada-Europe