source: rtems/c/src/ada-tests/tmtests/tm20/tmtest.ads @ bf9ae83

4.104.114.84.95
Last change on this file since bf9ae83 was bf9ae83, checked in by Joel Sherrill <joel.sherrill@…>, on 06/02/97 at 20:32:11

modified copyright notice to be the same as RTEMS 4.0.0.

changed the CVS ID string to be a "development" version.

  • Property mode set to 100644
File size: 5.3 KB
Line 
1--
2--  TMTEST / SPECIFICATION
3--
4--  DESCRIPTION:
5--
6--  This package is the specification for Test 20 of the RTEMS
7--  Timing Test Suite.
8--
9--  DEPENDENCIES:
10--
11-- 
12--
13--  COPYRIGHT (c) 1989-1997.
14--  On-Line Applications Research Corporation (OAR).
15--  Copyright assigned to U.S. Government, 1994.
16--
17--  The license and distribution terms for this file may in
18--  the file LICENSE in this distribution or at
19--  http://www.OARcorp.com/rtems/license.html.
20--
21--  $Id$
22--
23
24with STUB_DRIVER;
25with TIME_TEST_SUPPORT;
26with TIMER_DRIVER;
27with RTEMS;
28
29package TMTEST is
30
31--
32--  These arrays contain the IDs and NAMEs of all RTEMS tasks created
33--  by this test.
34--
35
36   TASK_ID   : array ( RTEMS.UNSIGNED32 range 1 .. 3 ) of RTEMS.ID;
37   TASK_NAME : array ( RTEMS.UNSIGNED32 range 1 .. 3 ) of RTEMS.NAME;
38
39--
40--  These following are the ID and NAME of the RTEMS partition created
41--  by this test.
42--
43
44   PARTITION_ID   : RTEMS.ID;
45   PARTITION_NAME : RTEMS.NAME;
46
47--
48--  These following are the ID and NAME of the RTEMS region created
49--  by this test.
50--
51
52   REGION_ID   : RTEMS.ID;
53   REGION_NAME : RTEMS.NAME;
54
55--
56--  The following area defines a memory area to be used as the
57--  memory space for a partition.
58--
59
60   PARTITION_AREA : array ( RTEMS.UNSIGNED32 range 0 .. 2047 )
61      of RTEMS.UNSIGNED8;
62   for PARTITION_AREA'ALIGNMENT use RTEMS.STRUCTURE_ALIGNMENT;
63
64--
65--  The following area defines a memory area to be used as the
66--  memory space for a region.
67--
68
69   REGION_AREA : array ( RTEMS.UNSIGNED32 range 0 .. 2047 )
70      of RTEMS.UNSIGNED8;
71
72   for REGION_AREA'ALIGNMENT use RTEMS.STRUCTURE_ALIGNMENT;
73
74--
75--  The following are the buffers allocated from the region.
76--
77
78   BUFFER_ADDRESS_1 : RTEMS.ADDRESS;
79   BUFFER_ADDRESS_2 : RTEMS.ADDRESS;
80   BUFFER_ADDRESS_3 : RTEMS.ADDRESS;
81   BUFFER_ADDRESS_4 : RTEMS.ADDRESS;
82
83   BUFFER_ADDRESSES : array ( RTEMS.UNSIGNED32
84      range 0 .. TIME_TEST_SUPPORT.OPERATION_COUNT ) of RTEMS.ADDRESS;
85
86--
87--  The following variable is set to the execution time returned
88--  by the timer.
89--
90
91   END_TIME  : RTEMS.UNSIGNED32;
92
93--
94--  INIT
95--
96--  DESCRIPTION:
97--
98--  This RTEMS task initializes the application.
99--
100
101   procedure INIT (
102      ARGUMENT : in     RTEMS.TASK_ARGUMENT
103   );
104
105--
106--  TASK_1
107--
108--  DESCRIPTION:
109--
110--  This RTEMS task is responsible for measuring and reporting
111--  the following execution times:
112--
113--    + PARTITION_CREATE
114--    + REGION_CREATE
115--    + PARTITION_GET_BUFFER with a buffer available
116--    + PARTITION_GET_BUFFER with no buffers available
117--    + PARTITION_RETURN_BUFFER
118--    + PARTITION_DELETE
119--    + REGION_GET_SEGMENT with a segment available
120--    + REGION_GET_SEGMENT with the NO_WAIT option
121--    + REGION_RETURN_SEGMENT with no tasks waiting for memory
122--    + REGION_RETURN_SEGMENT preemptive
123--    + REGION_DELETE
124--    + IO_INITIALIZE
125--    + IO_OPEN
126--    + IO_CLOSE
127--    + IO_READ
128--    + IO_WRITE
129--    + IO_CONTROL
130--
131
132   procedure TASK_1 (
133      ARGUMENT : in     RTEMS.TASK_ARGUMENT
134   );
135
136--
137--  TASK_2
138--
139--  DESCRIPTION:
140--
141--  This RTEMS task is responsible for measuring and reporting
142--  the following execution times:
143--
144--    + blocking REGION_GET_SEGMENT
145--    + REGION_RETURN_SEGMENT which readies a task
146--
147
148   procedure TASK_2 (
149      ARGUMENT : in     RTEMS.TASK_ARGUMENT
150   );
151
152--
153--  This is the Driver Address Table for this test.
154--
155
156   DEVICE_DRIVERS : aliased RTEMS.DRIVER_ADDRESS_TABLE( 1 .. 1 ) :=
157   ( 1 =>
158      (
159        STUB_DRIVER.INITIALIZE'ACCESS,               -- Initialization
160        STUB_DRIVER.OPEN'ACCESS,                     -- Open
161        STUB_DRIVER.CLOSE'ACCESS,                    -- Close
162        STUB_DRIVER.READ'ACCESS,                     -- Read
163        STUB_DRIVER.WRITE'ACCESS,                    -- Write
164        STUB_DRIVER.CONTROL'ACCESS                   -- Control
165      )
166   );
167
168--
169--  This is the Initialization Tasks Table for this test.
170--
171
172   INITIALIZATION_TASKS : aliased RTEMS.INITIALIZATION_TASKS_TABLE( 1 .. 1 ) :=
173   (1=>
174     (
175       RTEMS.BUILD_NAME( 'U', 'I', '1', ' ' ),        -- task name
176       2048,                                          -- stack size
177       1,                                             -- priority
178       RTEMS.DEFAULT_ATTRIBUTES,                      -- attributes
179       TMTEST.INIT'ACCESS,                            -- entry point
180       RTEMS.NO_PREEMPT,                              -- initial mode
181       0                                              -- argument list
182     )
183   );
184
185--
186--  This is the Configuration Table for this test.
187--
188
189   CONFIGURATION : aliased RTEMS.CONFIGURATION_TABLE := (
190      RTEMS.NULL_ADDRESS,        -- will be replaced by BSP
191      256 * 1024,                -- executive RAM size
192      10,                        -- maximum # tasks
193      0,                         -- maximum # timers
194      0,                         -- maximum # semaphores
195      0,                         -- maximum # message queues
196      0,                         -- maximum # messages
197      1,                         -- maximum # partitions
198      1,                         -- maximum # regions
199      0,                         -- maximum # dp memory areas
200      0,                         -- maximum # periods
201      0,                         -- maximum # user extensions
202      RTEMS.MILLISECONDS_TO_MICROSECONDS(10), -- # us in a tick
203      0                          -- # ticks in a timeslice
204  );
205
206end TMTEST;
Note: See TracBrowser for help on using the repository browser.