CVS difference for ai05s/ai05-0171-1.txt

Differences between 1.1 and version 1.2
Log of other versions for file ai05s/ai05-0171-1.txt

--- ai05s/ai05-0171-1.txt	2009/10/23 03:41:05	1.1
+++ ai05s/ai05-0171-1.txt	2010/02/20 04:22:57	1.2
@@ -1,10 +1,11 @@
-!standard  D.13.1(4/2)                             09-10-22    AI05-0171-1/01
+!standard  D.13.1(4/2)                             10-02-18    AI05-0171-1/02
+!standard  D.16
 !class Amendment 09-10-22
 !status work item 09-10-22
 !status received 09-10-22
 !priority Medium
 !difficulty Easy
-!subject Ravenscar Profile for Multi-Processor Systems
+!subject Ravenscar Profile for Multiprocessor Systems
 
 !summary
 
@@ -31,12 +32,73 @@
 We propose to allow the implementation of the Ravenscar Profile on
 multi-processor systems following a fully partitioned approach.
 
+The first part of the proposal is a general package that will
+be used by Ravenscar.
+
 !wording
+
+Add a new clause:
+
+D.16 Multiprocessor Implementation
+
+This clause allows implementations on multiprocessor platforms to
+be configured.
+
+Syntax
+
+The form of a pragma CPU is as follows:
+
+pragma CPU (expression);
+
+
+Name Resolution Rules
+
+The expected type for the expression is Integer.
+
+A CPU pragma is allowed only immediately within a task_definition, or the
+declarative_part of a subprogram_body. At most one such pragma shall appear
+within a given construct.
+
+For a CPU pragma that appears in the declarative_part of a subprogram_body,
+the expression shall be static, and its value shall be in the range of
+System.Multiprocessors.CPU.
+
+
+Static Semantics
+
+The following language-defined library package exists
+
+package System.Multiprocessors is
+  type CPU_Range is range 0 .. <implementation-defined>
+  subtype CPU is CPU_Range range 1 .. CPU_Range'last;
+  function Number_Of_CPUs return CPU;
+end System.Multiprocessors;
+
+
+Dynamic Semantics
+
+A CPU pragma has no effect if it occurs in the declarative part of the
+subprogram_body of a subprogram other then the main subprogram.
+
+The CPU value determines the processor on which the task will
+activate and execute. A task without a pragma will execute on the same
+processor as its activating task. It is implementation defined where the
+environment task executes.
+
+A call of Number_Of_CPUs returns the number of processors available
+to the program.
+
+---
+
+
+Add to D.13.1(4/2) a new restriction:
+
+No_Dependence => System.Multiprocessors.Dispatching_Policies;
 
-Clause D.13.1 should be modified to add the following implementation
-advice.
+---
+Add after D.13.1(4/2):
 
-Implementation advice
+Implementation Advice
 
 On a multi-processor system, an implementation should support a fully
 partitioned approach, with each task allocated statically to a
@@ -47,14 +109,16 @@
 reaches a task dispatching point, it goes back to the ready queues of
 the same processor.
 
-Protected objects should be the only task synchronization
-mechanism. For inter-processor communication, an implementation should
-provide the necessary locking mechanism to achieve the required mutual
-exclusion among tasks executing on different processors.
 
 !discussion
 
-** TBD ** (Why is this model preferred??)
+Although there are many dispatching approaches that make use of
+task migration this significantly complicates the run-time
+and adds overheads. For Ravenscar and its focus on static properties
+it is in keeping to disallow migration. The scheduling problem for
+partitioned allocation is a combination of bin packing followed
+by single processor dispatching. These are known techniques and
+do not add complications to the Ravenscar model.
 
 !example
 

Questions? Ask the ACAA Technical Agent