OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [ada/] [acats/] [tests/] [cd/] [cd2c11d.tst] - Blame information for rev 294

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 294 jeremybenn
--CD2C11D.TST
2
 
3
--                             Grant of Unlimited Rights
4
--
5
--     Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
6
--     F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained
7
--     unlimited rights in the software and documentation contained herein.
8
--     Unlimited rights are defined in DFAR 252.227-7013(a)(19).  By making
9
--     this public release, the Government intends to confer upon all
10
--     recipients unlimited rights  equal to those held by the Government.
11
--     These rights include rights to use, duplicate, release or disclose the
12
--     released technical data and computer software in whole or in part, in
13
--     any manner and for any purpose whatsoever, and to have or permit others
14
--     to do so.
15
--
16
--                                    DISCLAIMER
17
--
18
--     ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
19
--     DISCLOSED ARE AS IS.  THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED
20
--     WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
21
--     SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
22
--     OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
23
--     PARTICULAR PURPOSE OF SAID MATERIAL.
24
--*
25
-- OBJECTIVE:
26
--     CHECK THAT THE EXPRESSION IN A TASK STORAGE SIZE CLAUSE NEED
27
--     NOT BE STATIC.
28
 
29
-- MACRO SUBSTITUTION:
30
--     $TASK_STORAGE_SIZE IS THE NUMBER OF STORAGE_UNITS REQUIRED FOR
31
--     THE ACTIVATION OF A TASK.
32
 
33
-- HISTORY
34
--     DHH 09/29/87 CREATED ORIGINAL TEST
35
--     PWB 05/11/89 CHANGED EXTENSION FROM '.DEP' TO '.TST'.
36
 
37
WITH SYSTEM; USE SYSTEM;
38
WITH REPORT; USE REPORT;
39
PROCEDURE CD2C11D IS
40
 
41
BEGIN
42
 
43
     TEST ("CD2C11D","THE EXPRESSION IN A TASK STORAGE SIZE CLAUSE " &
44
                     "NEED NOT BE STATIC");
45
 
46
     DECLARE
47
 
48
          STORAGE_SIZE : CONSTANT := $TASK_STORAGE_SIZE;
49
          PACKAGE PACK IS
50
               TASK TYPE CHECK_TYPE;
51
 
52
               FOR CHECK_TYPE'STORAGE_SIZE USE
53
                                      STORAGE_SIZE;
54
               TASK TYPE TTYPE IS
55
                    ENTRY ADD(J :IN INTEGER; K : IN OUT INTEGER);
56
               END TTYPE;
57
 
58
               FOR TTYPE'STORAGE_SIZE USE IDENT_INT(STORAGE_SIZE);
59
 
60
          END PACK;
61
 
62
          PACKAGE BODY PACK IS
63
 
64
               TASK BODY TTYPE IS
65
               BEGIN
66
                    ACCEPT ADD(J :IN INTEGER; K : IN OUT INTEGER);
67
               END TTYPE;
68
 
69
               TASK BODY CHECK_TYPE IS
70
               BEGIN
71
                    NULL;
72
               END CHECK_TYPE;
73
 
74
          BEGIN
75
 
76
               IF TTYPE'STORAGE_SIZE < IDENT_INT(STORAGE_SIZE) THEN
77
                    FAILED("STORAGE_SIZE SPECIFIED IS " &
78
                           "GREATER THAN MEMORY ALLOCATED");
79
               END IF;
80
 
81
          END PACK;
82
     BEGIN
83
          NULL;
84
     END;
85
 
86
     RESULT;
87
END CD2C11D;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.