90 01 03 013 - dtic · 2011-05-15 · 3 recipzenis catalog nubik 5. type of report a plow covered...

50
-1TNC'LAbiFiED., ,,i[ 4T I ON PAGE AD-A216 385 12. GOVI ACCESSID6 NO. 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002, Version 4.3, HP 9000 S 350 (host & target), *7 F£M1NG'bRG. REPOR! NUMBLR 8903 ".Ai .10038 7. AUINOR(s) S. CONTRACT 0R &RANT KIMER(s) AFNOR, Paris, France. 1. PERfORMING ORGANIZATIOh AND ADDRESS 10. PROGRA10 ELEMNT. PRCjf:7. TASK AREA & WORK UNIT NUMBERS AFNOR, Paris, France. 12. CONCTROLL1NG OFFICE NAME AND ADDRESS 12. REPOR1 DATE Adi. Joint P-oorLi Office United Sta-.es'Department of Defense IT WS u, IAu . Wt.shington, DC 2301-3081 14. 40101TORING AGtN;t NA4L & ADDC£ SS(if different from Conroling Office) 15. SECUR17? CLASS lofthJ epOra) UNCLASSIFIED AFNOR, Paris, France. 15s. DECLASSrVCATIO,/DObvhRADING N/A 15. LoIaTsi4b. 100i STATEMENIt (of this Report) Approved for public release; distribution unlimited. 17. DISTRIBJTION S7AYEMi,~ (Of the &bXT1&flenfere0,nBj ,20i dlefrentfrom Repon) UNCLASSIFIED nTIC 0 ELECTE 13. SUPPi[MEhIAR) NOTES 1S. KEYwORDS (Continue on reverse si" if necernr) and identify by block number)-" . -Ada 4rrogramming language, Ada Compile-rValidation Summary eport, Ada Compiler,-alidation Capability( ACVC). Validation Testing.iAda Validation Office, AVO, Ada Validat on Facility, AVF, ANSI/PbIL-STD- 1815A, Ada Joint Program Office, AJPO 20. A BS PAC I (Contfnue on reverse side if necessary and den t$ by block number) Alsys; AlsyCOMP_002, Version 4.3; AFNOR, France, HP 9000 S 350 under HP-UX, Version 6.2, (host & target). ACVC 1.10. 90 01 03 013 DD tuA, 1473 ID17OF oI 1 Nov 65 IS OBSOLE I JAN 73 S/N 0102-Li,-od-Bo UNCLASSIFIED S[CURI'h CLASSIFICATION Of THIS PAGE (whenDetEniered)

Upload: others

Post on 15-Aug-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

-1TNC'LAbiFiED., ,,i[

4T I ON PAGE

AD-A216 385 12. GOVI ACCESSID6 NO. 3 RECIPZENIS CATALOG NUbik

5. TYPE Of REPORT A PLOW COVERED

Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90AlsvCOMP 002, Version 4.3, HP 9000 S 350 (host & target), *7 F£M1NG'bRG. REPOR! NUMBLR8903 ".Ai .10038

7. AUINOR(s) S. CONTRACT 0R &RANT KIMER(s)

AFNOR, Paris, France.

1. PERfORMING ORGANIZATIOh AND ADDRESS 10. PROGRA10 ELEMNT. PRCjf:7. TASKAREA & WORK UNIT NUMBERS

AFNOR, Paris, France.

12. CONCTROLL1NG OFFICE NAME AND ADDRESS 12. REPOR1 DATEAdi. Joint P-oorLi OfficeUnited Sta-.es'Department of Defense IT WS u, IAu .Wt.shington, DC 2301-3081

14. 40101TORING AGtN;t NA4L & ADDC£ SS(if different from Conroling Office) 15. SECUR17? CLASS lofthJ epOra)UNCLASSIFIED

AFNOR, Paris, France. 15s. DECLASSrVCATIO,/DObvhRADINGN/A

15. LoIaTsi4b. 100i STATEMENIt (of this Report)

Approved for public release; distribution unlimited.

17. DISTRIBJTION S7AYEMi,~ (Of the &bXT1&flenfere0,nBj ,20i dlefrentfrom Repon)UNCLASSIFIED nTIC

0 ELECTE

13. SUPPi[MEhIAR) NOTES

1S. KEYwORDS (Continue on reverse si" if necernr) and identify by block number)-" .

-Ada 4rrogramming language, Ada Compile-rValidation Summary eport, AdaCompiler,-alidation Capability( ACVC). Validation Testing.iAdaValidation Office, AVO, Ada Validat on Facility, AVF, ANSI/PbIL-STD-1815A, Ada Joint Program Office, AJPO

20. A BS PAC I (Contfnue on reverse side if necessary and den t$ by block number)

Alsys; AlsyCOMP_002, Version 4.3; AFNOR, France, HP 9000 S 350 under HP-UX, Version 6.2,(host & target). ACVC 1.10.

90 01 03 013DD tuA, 1473 ID17OF oI 1 Nov 65 IS OBSOLE

I JAN 73 S/N 0102-Li,-od-Bo UNCLASSIFIEDS[CURI'h CLASSIFICATION Of THIS PAGE (whenDetEniered)

Page 2: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

AVF Control Number: AVF-VSR-AFNOR-89-03

Ada COMPILE.VALIDATION SUMMARY REPORT:

Certificate Number: 890314A1.10038Alsys

AlsyCOMP_002, Version 4.3 'o

HP 9000 S 350

Completion of On-Site Testing:14 March 1989 Accesion For

NTIS CR%&IDTIC TAB L]

Prepared By: .........AFNOR

Tour Europe By ..........Cedex 7 Dbt:.

F-92JR0 Paris !a DfenseA',,, tI td-ty C ,res

Dist .oAvijal

Prepared For: AIAda Joint Program Office

United States Department of DefenseWashington DC 20301-3081

Page 3: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

Ada Compiler Validation Summary Report:

Compiler Name: AlsyCOMPO02, Version 4.3

Certificate Number: 890314A1.10038

Host: HP 9000 S 350 under HP-UX, Version 6.2

Target: HP 9000 S 350 under HP-UX, Version 6.2

Testing Completed 14 March 1989 Using ACVC 1.10

This report has been reviewed and is approved.

AFNORFabrice Garnier de LabareyreTour EuropeCedex 7F-92080 Paris la Defense

4Ada Validation OrganizationDr. John F. KramerInstitute for Defense AnalysesAlexandria VA 22311

Ada Joint Program OfficeDr. John SolomondDirectorDepartment of DefenseWashington DC 20301

Page 4: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TABLE OF CONTENTS

CHAPTER 1 INTRODUCTION

1.1 PURPOSE OF THIS VALIDATION SUMMALRY REPORT ..... .......... 5

1.2 USE OF THIS VALIDATION SUMMARY REPORT ...... ............ 51.3 REFERENCES ............. .......................... 71.4 DEFINITION OF TERMS .......... ..................... 71.5 ACVC TEST CLASSES ........... ...................... 8

CHAPTER 2 CONFIGURATION INFORMATION

2.1 CONFIGURATION TESTED .......... .................... 102.2 IMPLEMENTATION CHARACTERISTICS ....... ............... i1

CHAPTER 3 TEST INFORMATION

3.1 TEST RESULTS ........... ........................ .163.2 SUMMARY OF TEST RESULTS BY CLASS ..... .............. .163.3 SUMMARY OF TEST RESULTS BY CHAPTER .... ............. .. 173.4 WITHDRAWN TESTS ......... ...................... .173.5 INAPPLICABLE TESTS ...................................... .. 173.6 TEST, PROCESSING, AND EVALUATION MODIFICATIONS ......... ... 213.7 ADDITIONAL TESTING INFORMATION ..... ............... .. 233.7.1 Prevalidation .......... ....................... .233.7.2 Test Me:n.od .......... ........................ .233.7.3 Test Site ........... ......................... .24

APPENDIX A DECLARATION OF CONFORMANCE

APPENDIX B TEST PARAMETERS

APPENDIX C WITHDRAWN TESTS

APPENDIX D APPENDIX F OF THE Ada STANDARD

Page 5: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

INTRODUCTION

CHAPTER 1

INTRODUCTION

This Validation Summary Report (VSR) 'describes the extent to which aspecific Ada compiler conforms to the Ada Standard, ANSI/MIL-STD-1815A. Thisreport explains all technical terms used within it and thoroughly reportsthe results of testing this compiler using the Ada Compiler ValidationCapability (ACVC). An Ada compiler must be implemented according to the AdaStandard, and any implementation-dependent features must conform to therequirements of the Ada Standard. The Ada Standard must be implemented inits entirety, and nothing can be implemented that is not in the Standard.

Even though all validated Ada compilers conform tc the Ada Standard, it mustbe understood that some differences do exist between implementations. TheAda Standard permits some implementation dependencies--for example, themaximum length of identifiers or the maximum values of integer types. Otherdifferences between compilers result from the characteristics of particularoperating systems, hardware, or implementation strategies. All thedependencies observed during the process of testing this compiler are givenin this report.

The information in this report is derived from the test results producedduring validation testing. The validation process includes submitting asuite of standardized tests, the ACVC, as inputs to an Ada compiler andevaluating the results. The purpose of validating is to ensure conformity ofthe compiler to the Ada Standard by testing that the compiler properlyimplements legal language constructs and that it identifies and rejectsillegal language constructs. The testing also identifies behavior that isimplementation-dependent but permitted by the Ada Standard. Six classe, oftests are used. These tests are designed to perform checks at compile time,at link time, and during execution.

Page 6: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

INTRODUCTIC::

1.1 PURPOSE OF THIS VALIDATION SUMMARY REPORT

This VSR documents the results of the validation testing performed on an Adacompiler. Testing was carried out for the following purposes:

To attempt to identify any language constructs supported by the

compiler that do not conform to the Ada Standard

To attempt to identify any language constructs not supported by thecompiler but required by the Ada Standard

To determine that the implementation-dependent behavior is allowedby the Ada Standard

Testing of this compiler was conducted by under the direction of the AVFaccording to procedures established by the Ada Joint Program Office andadministered by the Ada Validation Organization (AVO). On-site testing wascompleted 14 March 1989 at Alsys SA. in La Celle Saint Cloud, FRANCE.

1.2 USE OF THIS VALIDATION SUMMARY REPORT

Consistent with the national laws of the originating country, the AVO maymake full and free public disclosure of this report. in the United States,this is provided in accordance with the "Freedom of Information Act"(5U.S.C.#552). The results of this validation apply only to the computers,operating systems, and compiler versions identified in this report.

The organizations represented on the signature page of this report do notrepresent or warrant that all statements set forth in this report areaccurate and complete, or that the subject compiler has no nonconformitiesto the Ada Standard other than those presented. Copies of this report areavailable to the public from:

Ada Information ClearinghouseAda Joint Program OfficeOUSDREThe Pentagon, Rm 3D-139 (Fern Street)Washington DC 20301-3081

or from:

AFNORTour Europecedex 7F-92080 Paris la D~fense

Page 7: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

INTRODUCTION

Questions regarding this report or the validation test results shouldbe directed to the AVF listed above or to:

Ada Validation OrganizationInstitute for Defense Analyses1801 North Beauregard StreetAlexandria VA 22311

Page 8: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

INTRODUCTION

1.3 REFERENCES

1. Reference Manual for the Ada Programming Language, ANSI/MIL-STD-1815A, February 1983, and ISO 8652-1987.

2. Ada Compiler Validation Procedures and Guidelines Ada Joint ProgramOffice, I January 1987.

3. Ada Compile! Validation Capability implementers' Guide, SofTech,Inc., December 1986.

4. Ada Compiler Validation Capability User's Guide, December 1986

1.4 DEFINITION OF TERMS

ACVC The Ada Compiler Validation Capability. The set of Adaprograms that tests the conformity of an Ada compiler to theAda programming language.

Ada Commentary An Ada Commentary contains all information relevant to thepoint addressed by a' comment on the Ada Standard. Thesecomments are given a unique identification number having theform AI-ddddd.

Ada Standard ANSI/MIL-STD-1815A, February 1983 and ISO 8652-1987.

Applicant The agency requesting validation.

AVF The Ada Validation Facility. The AVF 4s responsible forconducting compiler validations according to procedurescontained in the Ada Compiler Validation Procedures andGuidelines.

AVO The Ada Validation Organization. The AVO has oversightauthority over all AVF practices for the purpose ofmaintaining a uniform process for validation of Adacompilers. The AVO provides administrative and technicalsupport for Ada validations to ensure consistent practices.

Compiler A processor for the Ada language. In the context of thisreport, a compiler is any language processor, includingcross-compilers, translators, and interpreters.

Failed test An ACVC test for which the compiler generates a result that

demonstrates nonconformity to the Ada Standard.

Host The computer on which the compiler resides.

Page 9: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

INTRODUCTION

Inapplicable test An ACVC test that uses features of the language thata compiler is not required to support or may legitimatelysupport in a way other than the one expected by the test.

Passed test An ACVC test for which a compiler generates the expected

result.

Target The computer for which a compiler generates code.

Test A program that checks a compiler's conformity regarding aparticular feature or a combination of features to the AdaStandard. In the context of this report, the term is used todesignate a single test, which may comprise one or morefiles.

Withdrawn test An ACVC test found to be incorrect and not used to checkconformity to the Ada Standard. A test may be incorrectbecause it has an invalid test objective, fails to meet itstest objective, or contains illegal or erroneous use of thelanguage.

1.5 ACVC TEST CLASSES

Conformity to the Ada Standard is measured using the ACVC. The ACVC containsboth legal and illegal Ada programs structured into six test classes: A, B,C, D, E, and L. The first letter of a test name identifies the class towhich it belongs. Class A, C, D, and E tests are executable, and specialprogram units are used to report *their results during execution. Class Btests are expected to produce compilation errors. Class L tests are expectedto produce compilation or link errors.

Class A tests check that legal Ada programs can be successfully compiled andexecuted. There are no explicit program components in a Class A test tocheck semantics. For example, a Class A test checks that reserved words ofanother language (other than those already reserved in the Ada language) arenot treated as reserved words by an Ada compiler. A Class A test is passedif no errors are detected at compile time and the program executes toproduce a PASSED message.

Class B tests check that a compiler detects illegal language usage. Class Btests are not executable. Each test in this class is compiled and theresulting compilation listing is examined to verify that every syntax orsemantic error in the test is detected. A Class B test is passed if everyillegal construct that it contains is detected by the compiler.

Class C tests check that legal Ada programs can be correctly compiled andexecuted. Each Class C test is self-checking and produces a PASSED, FAILED,or NOT APPLICABLE message indicating the result when it is executed.

Page 10: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

INTROD u§ ',

Class D tests check the compilation and execution capacities of a compiler.Since th're are no capacity requirements placed on a compiler by the AdaStandard for some paraimeters--for example, the number of identifierspermitted in a compilation or the number of units in a library--a compilermay refuse to compile a Class D test and still be a conforming compiler.Therefore, if a Class D test fails to compile because the capacity of thecompiler is exceeded, the test is classified as inapplicable. if a Class Dtest complies successfully, it is self-checking and produces a PASSED orFAILED message during execution.

Each Class E test is self-checking and produces a NOT APPLICABLE, PASSED, orFAILED message when it is compiled and executed. However, the Ada Standardpermits an implementation to reject programs containing some featuresaddressed by Class E tests during compilation. Therefore, a Class E test ispassed by a compiler if it is compiled successfully and executes to producea PASSED message, or if it is rejected by the compiler for an allowablereason.

Class L tests check that incomplete or illegal Ada programs involvingmultiple, separately compiled units are detected and not allowed to execute.Class L tests are compiled separately and execution is attempted. A Class Ltest passes if it is rejected at link time--that is, an attempt to executethe main program must generate an error message before any declarations inthe main program or any units referenced by the main program are elaborated.

Two library units, the package REPORT and the procedure CHECK_FILE, supportthe self-checking features of the executable tests. The package REPORTprovides the mechanism by which execatable tests report PASSED, FAILED, orNOT APPLICABLE results. It also provides a set of identity functions used todefeat some compiler optimizations allowed by the Ada Standard that wouldcircumvent a test objective. The procedure CHECKFILE is used to check thecontents of text files written by some of the Class C tests for chapter 14of the Ada Standard. The operation of REPORT and CHECKFILE is checked by aset of executable tests. These tests produce messages that are examined toverify that the units are operating correctly. If these units are notoperating correctly, then the validation is not attempted.

The text of the tests in the ACVC follow conventions that are intended toensure that the tests are reasonably portable without modification. Forexample, the tests make use of only the basic set of 55 characters, containlines with a maximum length of 72 characters, use small numeric values, andplace features that may not be supported by all implementations in separatetests. However, some tests contain values that require the test to becustomized according to implementation-specific values--for example, anillegal file name. A list of the values used for this validation is providedin Appendix C.

A compiler must correctly process each of the tests in the suite anddemonstrate conformity to the Ada Standard by either meeting the passcriteria given for the test or by showing that the test is inapplicable tothe implementation. The applicability of a test to an implementation isconsidered each time the implementation is validated. A test that isinapplicable for one validation is not necessarily inapplicable for asubsequent validation. Any test that was determined to contain an illegallanguage construct or an erroneous language construct is withdrawn from theACVC and, therefore, is not used in testing a compiler. The tests withdrawnat the time of this validation are given in Appendix D.

Page 11: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

CONFIGURATION INFORMATION

CHAPTER 2

CONFIGURATION INFORMATION

2.1 CONFIGURATION TESTED

The candidate compilation system for this validation was tested under thefollowing configuration:

Compiler: AlsyCOMP_002, Version 4.3

ACVC Version: 1.10

Certificate Number: 890314A1.10038

Host Computer:

Machine: HP 9000 S 350

Operating System: HP-UX, Version 6.2

Memory Size: 8 Mb

Configuration Information : MC68020 processorMC 68881 floating-point coprocessor

Target Computer:

Machine: HP 9000 S 350

Operating System: HP-UX, Version 6.2

Memory Size: 8 Mb

Configuration Information : MC68020 processorMC 68881 floating-point coprocessor

Communications Network: none

Page 12: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

CONFIGURATION INFORMATION

2.2 IMPLEMENTATION CHARACTERISTICS

One of the purposes of validating compilers is to determine the behavior ofa compiler in those areas of the Ada Standard that permit implementations todiffer. Class D and E tests specifically check for such implementationdifferences. However, tests in other classes also character:ze animplementation. The tests demonstrate the following characteristics:

a. Capacities.

(1) The compiler correctly processes a compilation containing 723variables in the same declarative part. (See test D29002K.)

(2) The compiler correctly processes tests containing loop statementsnested to 65 levels. (See tests D55A03A..H (8 tests).)

(3) The compiler correctly processes a test containing block statementsnested to 6: levels. (See test D56001B.)

(4) The compiler correctly processes tests containing recursiveprocedures separately compiled as subunits nested to 17 levels.(See tests D64005E..G (3 tests).)

b. Predefined types.

(1) This implementation supports the additional predefined types,SHORTINTEGER, LONG_INTEGER, LONG FLOAT in the package STANDARD.(See tests B86001T..Z (7 tests).)

c. Based literals.

(1) An implementation is allowed raise NUMERIC ERROR orCONSTRAINTERROR when a value exceeds SYSTEM.MAX_INT . Thisimplementation raises NUMERICERROR during execution. (See testE24201A.)

d. Expression evaluation.

The order in which expressions are evaluated and the time at whichconstraints are checked are not defined by the language. While theACVC tests do not specifically attempt to determine the order ofevaluation of expressions, test results indicate the following:

(1) Apparently no default initialization expressions for recordcomponents are evaluated before any value is checked to belong to acomponent's subtype. (See test C32117A.)

(2) Assignments for subtypes are performed with the same precision asthe base type. (See test C35712B.)

(3) This implementation uses no extra bits for extra precision. Thisimplementation uses all extra bits for extra range. (See testC35903A.)

Page 13: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

CONFIGURATION INFORMATION

(4) Apparently NUMERICERROR is raised when an integer literal operandin a comparison or membership test is outside the range of the basetype. (See test C45232A.)

(5) Apparently NUMERICERROR is raised when a Literal operand in afixed-point comparison or membership test is outside the range ofthe base type. (See test C45252A.)

(6) Apparently underflow is gradual. (See tests C45524A..Z.) (26 tests)

e. Rounding.

The method by which values are rounded in type conversions is notdefined by the language. While the ACVC tests do not specificallyattempt to determine the method of rounding, the test results indicatethe following:

(2) The method used for rounding to integer is apparently round toeven. (See tests C46012A..Z.) (26 tests)

(2) The method used for rounding to longest integer is apparently roundto even. (See tests C46012A..Z.) (26 tests)

(3) The method used for rounding to integer in stat:c universal realexpressions is apparently round to even. (See test C4AO14A.)

f. Array types.

An implementation is allowed to raise NUMERICERROR or CONSTRAINTERRORfor an ar.ay having a 'LENGTH that exceeds STANDARD.INTEGER'LAST and/orSYSTEM.MAXINT. For this implementation:

(1) Declaration of an array type or subtype declaration with more thanSYSTEM.MAXINT components raises NUMERICERROR (See testC36003A.)

(2) NUMERICERROR is raised when 'LENGTH is applied to an array typewith INTEGER'LAST + 2 components. (See test 36202A.)

(3) NUMERIC-ERROR is raised when an array type with SYSTEM.MAXINT + 2components is declared. (See test C36202B.)

(4) A packed BOOLEAN array having a 'LENGTH exceeding INTEGER'LASTraises no exception. (See test C52103X.).

(5) A packed two-dimensional BOOLEAN array with more than INTEGER'LASTcomponents raises CONSTRAINT-ERROR when the length of a dimensionis calculated and exceeds INTEGER'LAST. array objects are sliced.(See test C52104Y.)

(6) In assigning one-dimensional array types, the expression appears tobe evaluated in its entirety before CONSTRAINT-ERROR is raised whenchecking whether the expression's subtype is compatible with thetarget's subtype. (See test C52013A.)

Page 14: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

CONFIGURATION IN'-- C0!,tION

(7) In assigning two-dimensional array types, the expression does notappear to be evaluated in its entirety before CONSTRAINTERROR israised when checking whether the expression's subtype is compatiblewith the target's subtype. (See test C52013A.)

g. A null array with one dimension of length greater than INTEGER'LAST mayraise NUMERICERROR or CONSTRAINTERROR either when declared orassigned. Alternatively, an implementation may accept the declaration.However, lengths must match in array slice assignments. Thisimplementation raises no exception. (See test E52103Y.)

h. Discriminated types.

(1) In assigning record types with discriminants, the expressionappears to be evaluated in its entirety before CONSTRAINTERROR israised when checking whether the expression's subtype is compatiblewith the target's subtype. (See test C52013A.)

i. Aggregates.

(1) In the evaluation of a multi-dimensional aggregate, all choicesappear to be evaluated before checking against the index type. (Seetests C43207A and C43207B.)

(2) In the evaluation of an aggregate containing subaggregates, not allchoices are evaluated before being checked for identical bounds.(See test E43212B.)

(3) All choices are evaluated before CONSTRAINTERROR is raised if abound in a non-null range of a non-null aggregate does not belongto an index subtype. (See test E43211B.)

j. Pragmas.

(1) The pragma INLINE is supported for functions or procedures, but notfunctions called inside a package specification. (See testsLA3004A..B, EA3004C..D, and CA3004E..F.)

k. Generics.

(1) Generic specifications and bodies can be compiled in separatecompilations. (See tests CA1012A, CA2009C, CA2009F, BC3204C, andBC3205D.)

(2) Generic subprogram declarations and bodies can be compiled inseparate compilations. (See tests CA1O12A and CA2009F.)

(3) Generic library subprogram specifications and bodies can becompiled in separate compilations. (See test CAI012A.)

(4) Generic non-library package bodies as subunits can be compiled inseparate compilations. (See test CA2009C.)

Page 15: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

CONFIGURATION INFORMATION

c non-library subzroqra!- Joces ca:. - conrp:ie :n separatecO:az:.oi.s from teitr stuns. ,SCe ttst CA2009F.)

(C? Generic unit bodies anc z*Er su.Dun-s can be compiltce in separateco p 1at ions. (See zest CA30-iA.,

(7) Generic package declarations and Dodies can be compiled in separatecompilations. (See tests CA2009C, BC3204C, and BC3205D.)

(8) Generic -ibrary package specifications and bodies can be compiledin separate compilations. (See tests BC3204C and BC3205D.)

(9) Generic unit bodies and their subunits can be compiled in separa-ecompilations. (See test CA3011A.

Input and output.

(1) The package SEQUENTIAL_10 can be instantiated with unconstrainedarray types and record types with discriminants without defaults.(See tests AE2101C, EE220ID, and EE2201E.)

(2) The package DIRECT 10 can be instantiated with unconstrained arraytypes and record types with discriminants but CREATE will raiseUSEERROR. (See tests AE2101H, EE240iD, and EE240IG.)

(4) Modes IN FILE and OUTFILE are supported for SEQUENTIAL_IO. (Seetests CE2102D..E, CE2102N, and CE2102P.)

(5) Modes INFILE, OUT_FILE, and INOUTFILE are supported forDIRECTIO. (See tests CE2102F, CE2102I..J, CE2102R, CE2102T, andCE2102V.)

(6) Modes INFILE and OUTFILE are supported for text files. (See testsCE3102E and CE3102T..K.)

(7) RESET and DELETE operations are supported for SEQUENTIAL_IO. (Seetests CE2102G and CE2102X.)

(8) RESET and DELETE operations are supported for DIRECTIO. (Seetests CE2102K and CE2102Y.)

(9) RESET and DELETE operations are supported for text files. (Seetests CE3102F..G, CE3104C, CE3110A, and CE31i4A.)

(10) Overwriting to a sequential fi.e truncates to the last elementwritten. (See test CE2208B.)

(11) Temporary sequential files are given names and deleted when closed.(See test CE21O8A.)

(12) Temporary direct files are given names and deleted when closed.(See test CE2108C.)

Page 16: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

CONFIGURATION INFORMATION

(13) Temporary text files are given names and deleted when closed. (Seetest CE3112A.)

(14) More than one internal file can be associated with each externalflie for sequential files when reading or writing (See testsCE2I07A..E, CE2102L, CE2!IOB, and CE211ID.)

(15) More than one internal file can be associated with each externalfile for direct files when reading or writing (See testsCE2107F..I, CE2110D and CE2111H.)

(16) More than one internal file can be associated with each externalfile for text files when reading or writing. (See tests CE3111A..E,CE3114B, and CE3115A.)

Page 17: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMAT:ON

CHAPTER :5

TEST INFORMATION

3.1 TEST RESULTS

Version 1.10 of the ACVC comprises 3717 tests. When this compiler wastested, 43 tests had been withdrawn because of test errors. The AVFdetermined that 352 ttsts were inapplicable to this implementation.All inapplicable tests were processed during validation testingexcept for 201 executable tests that use floating-point precisionexceeding that supported by the implementation. Modifications to thecode, processing, or grading for 51 tests were required. (See section 3.6.)

The AVF concludes that the testing results demonstrate acceptableconformity to the Ada Standard.

3.2 SUMMARY OF TEST RESULTS BY CLASS

RESULT TEST CLASS TOTAL

A B C D E L____Passed 129 1132 1972 17 26 46 3322

Inapplicable 0 6 344 0 2 0 352

Withdrawn 1 2 34 C 6 0 43

TOTAL 130 1140 2350 17 34 46 3717

Page 18: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST IflF .'MATION

.3 UXAz*.* or -ES- R UTSpy H?!

RESULT CHAPTER TOTAL2 3 4 5 E 7 8 9 i0 I" 12 13 i4_____

Passed 198 577 555 248 172 99 161 332 137 36 252 257 296 3322

InappL 14 72 125 0 0 0 5 1 0 0 0 118 25 352

Wdrn 1 1 0 0 0 0 0 1 0 0 1 35 4 43

TOTAL 2i3 650 680 248 172 99 166 334 137 36 253 404 325 3717

3.4 WITHDRAWN TESTS

The following 43 tests were withdrawn from ACVC Version 1.10 at the time ofthis validation:

A39005G B97102E BC3009B CD2A62D CD2A63A CD2A63B CD2A63C CD2A63DCD2A66A CD2A66B CD2A66C CD2A66D CD2A73A CD2A73B CD2A73C CD2A73DCD2A76A CD2A76B CD2A76C CD2A76D CD2A81G CD2A83G CD2A84M CD2A84NCD2D11B CD2B15C CD5007B CD50110 CD7105A CD7203B CD7204B CD7205CCD7205D CE2107I CE3111C CE3301A CE341iB E28005C ED7004B ED7005CED7005D ED7006C ED7006D

See Appendix D for the reason that each of these tests was withdrawn.

3.5 INAPPLICABLE TESTS

Some tests do not apply to all compilers because they make use of featuresthat a compiler is not required by the Ada Standard to support. Others maydepend on the result of another test that is either inapplicable orwithdrawn. The applicability of a test to an implementation is consideredeach time a validation is attempted. A test that is inapplicable for onevalidation attempt is not necessarily inapplicable for a subsequent attempt.For this validation attempt, 352 tests were inapplicable for the reasonsindicated:

The following 201 tests are not applicable because they have floating-point type declarations requiring more digits than System.MaxDigits:

C24113L..Y (14 tests) C35705L..Y (14 tests)C35706L..Y (14 tests) C35707L..Y (14 tests)C35708L..Y (14 tests) C35802L. .Z (15 tests)C45241L..Y (14 tests) C45321L..Y (14 tests)C45421L..Y (:4 tests) C45521L. . (:5 tests)C45524L..Z (15 tests) C45621L..Z ('5 tests)C45641L..Y (14 tests) C-6012L..Z (15 tests)

Page 19: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMAT:ON

C357n2A an& B86001 are noz appl:ca1c 2 cause ts apienentationsuppor:s nr p-=ctf:ric. typE Sno-:_ F.oat.

* C4553T. .? (4 tzEsts; an i4553... i4 zeszs) are no- app:cabe becausEthe value of Syszer..Max_Mantzssa is less tnan 32.C8600.1F, is not applicable because recompilation of Package SYSTEM is

not allowed.

B86001X, C45231D, and CD710G are not applicable because thisimplementation does not support any predefined integer type with a nameother than Integer, LongInteger, or Short-Integer.

B86001Y is not applicable because this implementation supports nopredefined fixed-point type other than Duration.

B86001Z is not applicable because this implementation supports nopredefined floating-point type with a name other than Float, LongFloat,or ShortFloat.

B91001H is not applicable because address clause for entries is notsupported by this implementation.

CDI009C, CD2A41A..B, CD2A41E, CD2A42A..B, CD2A42E..F, CD2A42I..J are notapplicable because size clause on float is not supported by thisimplementation.

CDICO4B, CDIC04E, CD4051A..D are not applicable because representationclause on derived records or derived tasks is not supported by thisimplementation.

CD2A84B..I, CD2A84K. .L are not applicable because size clause on accesstype is not supported by this implementation.

CDiCO4A, CD2A2iC..D, CD2A22C..D, CD2A22G..H, CD2A31C..D,CD2A32C..D, CD2A32G..H, CD2A41C..D, CD2A42C..D, CD2A42G..H,CD2A5lC..D, CD2A52C..D, CD2A52G..H, CD2A53D, CD2A54D, CD2A54H arenot applicable because size clause for derived private type is notsupported by this implementation.

CD2A61A..D,F,H,I,J,K,L, CD2A62A..C, CD2A71A..D, CD2A72A..D, CD2A74A..D,CD2A75A..D are not applicable because of the way this implementationallocates storage space for one component, size specification clause foran array type or for a record type requires compression of the storagespace needed for all the components (without gaps).

CD4041A is not applicable because alignment "at mod 8" is not supportedby this implementation.

BD5006D is not applicable because address clause for packages is notsupported by this implementation.

CD5011B,D,F,H,L,N,R, CD5012C,D,G,H,L, CD5013B,D,F,H,L,N,R, CD5014U,W arenot applicable because address clause for a constant is not supported bythis inplementation.

Page 20: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMATION

C750:2v , CD5013S, CD5014S are not applicable ,ecause adress clause fora Ia k P-..'s n.0 -1suppI)or ts tc :y t'-- -.T I mp en t arzon

-72 0LD is E nap:-I: a - cus, -nlS -7o2.E7.) 1 oN support s cra:_n f:e :oe for EQUEiAL o.

CE2102E :s inapplicable because thzs imp-ementation supports create withoutfile mode for SEQUENTIAL_10.

CE2102F is inapplicable because this implementation supports create withinoutfile mode for LIRECTIO.

CE2102I is inapplicable because this implementation supports create withinfile mode for DIRECT_IO.

CE2102J is inapplicable because this implementation supports create withoutfile mode for DIRECT_10.

CE2102N is inapplicable because this implementation supports open within-file mode for SEQUENTIALIO.

CE21020 is inapplicable because this implementation supports RESET within-file mode for SEQUENTIALIO.

CE2102P is inapplicable because this implementation supports open without-file mode for SEQUENTIAL_10.

CE2102Q is inapplicable because this implementation supports RESET withoutfile mode for SEQUENTIALIO.

CE2!02R is inapplicable because this implementation supports open withinoutfile mode for DIRECTIO.

CE2102S is inapplicable because this implementation supports RESET withinoutfile mode for DIRECTIO.

CE2102T is inapplicable because this implementation supports open within-file mode for DIRECTIO.

CE2102U is inapplicable because this implementation supports RESET withinfile mode for DIRECT_10.

CE2102V is inapplicable because this implementation supports open withoutfile mode for DIRECTIO.

CE2102Y is inapplicable because this implementation supports RESET withoutfile mode for DIRECT_10.

EE2401D and EE2401G are not applicable because USEERROR is raised whenthe CREATE of an instantiation of DIRECT_10 with unconstrained type iscalled.

CE2401H is not applicable because create with inoutfile mode forunconstrained records with default discriminants is not supported bythis implementation.

CE3102E is inapplicable because this implementation supports create within_file mode for text files.

Page 21: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMATION

CE3102F is inapplicable becausi ths :.'Qerenzauon supporz rest:I o:text f-Its, fo o: f.LE, : _ f ie anc troM ou: _ file o i- fzlt ::od.

-C3IO0G is :npp~lcao.ti because :his impemaEnzazion supporf. .6, c'r, o

CE3102I is inapplicable because this implementation supports create withoutfile mode for text files.

CE3102J is inapplicable because this implementation supports open withinfile mode for text files.

CE3102K is inapplicable because this implementation supports open withoutfile mode for text files.

CE3202A requires the association of a name with the standard :nput andoutput files. This is not supported by the implementation and USEERRORis raised at execution. This behavior is accepted by the AVO pending aruling by the langage maintenance body.

Page 22: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INORMATION

3.6 TEST, PROCESSIG, AND EVALUATION MODIF:CATIOI S

S is eXDECtc that some tests w:-- require modifIcations of cooe,processing, or evaiuatio in orcer to compensate for iecizimateimplementation behavior. Modifications are made by the AVF in cases wherelegitimate implementation behavior prevents the successful completion of an(otherwise) applicable test. Examples of such modifications include: addinga length clause to alter the default size of a collection; splitting a ClassB test into subtests so that all errors are detected; and confirming thatmessages produced by an executable test demonstrate conforming behavior thatwasn't anticipated by the test (such as raising onE exception instead ofanother).

Modifications were required for 51 tests.

The test EA3004D when run as it is, the implementation fails to detect anerror on line 27 of test file EA3004D6M (line 115 of "cat -n ea3004d*").This is because the pragma INLINE has no effect when its object is within apackage specification. However, the results of running the test as it isdoes not confirm that the pragma had no effect, only that the package wasnot made obsolete. By re-ordering the compilations so that the twosubprograms are compiled after file D5 (the re-compilation of the "with"edpackage that makes the various earlier units obsolete), we create a testthat shows that indeed pragma INLINE has no effect when applied to asubprogram that is called within a package specification: the test thenexecutes and produces the expected NOT APPLICABLE result (as though INLINEwere not supported at all). The re-ordering of EA3004D test files is0-1-4-5-2-3-6.

The following 27 tests were split because syntax errors at one pointresulted in the compiler not detecting other errors in the test:B23004A B24007A B24009A B28003A B32202A B32202B B32202C B33001A B36307AB37004A B49003A B49005A B61012A B6200iB B74304B B74304C B74401F B7440IRB91004A B95032A B95069A B95069B BAIl01B2 BAllOIB4 BC2001D BC3009A BC3009CBD5005B

The following 21 tests were split in order to show that the compiler wasable to find the representation clause indicated by the comment--N/A =)ERROR :

CD2A61A CD2A61B CD2A61F CD2A611 CD2A61J CD2A62A CD2A62B CD2A71A CD2A72BCD2A72A CD2A72B CD2A75A CD2A75B CD2A84B CD2A84C CD2A84D CD2A84E CD2A84FCD2A84G CD2A84H CD2A84I

Modified versions were produced for the following 2 tests, in order to havethe test run to completion and fully exhibit the test behavior:

In test C87B62B, an explicit STORAGESIZE clause was added for theaccess type declared at line 68. This allows the test to executewithout raising STORAGEERROR and to meet its objective (testoverloading resolution in expression within length clause). The testthen produces the expected PASSED result.

Page 23: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMATION

In test CE3202A, the NAME (STANDARDINPUT) and NAME (STANDARDOUTPUT)calls at lines 25 and 29 were encapsulated in blocks with explicitexception handlers that produce a NOTAPPLICABLE result in theUSEERROR case, and a FAILED result in the OTHERS case. The test thenproduces the expected NOTAPPLICABLE result.CE3202A requires the association of a name with the standard input and

output files. This is not supported by the implementation and USEERRORis raised at execution. This behavior is accepted by the AVO pending aruling by the langage maintenance body.

BA2001E requires that duplicate names of subunits with a common ancestor bedetected and rejected at compile time. This implementation detects the errorat link time, and the AVO ruled that this behavior is acceptable.

Page 24: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMATION

3.7 ADDITIONAL TESTING INFORMATION

3.7.1 Prevalidation

Prior to validation, a set of test results for ACVC Version 2.10 produced bythe AlsyCOMP 002 was submitted to the AVF by the applicant for review.Analysis of these results demonstrated that the compiler successfully passedall applicable tests, and the compiler exhibited the expected behavior onall inapplicable tests.

3.7.2 Test Method

Testing of the AlsyCOMP_002 using ACVC Version 1.10 was conducted on-site bya validation team from the AVF. The configuration consisted of a HP 9000 S350 operating under HP-UX, Version 6.2.

A tape containing all tests was taken on-site by the validation team forprocessing. Tests that make use of implementation-specific values werecustomized by Alsys after loading of the tape.

The contents of the tape were not loaded di.-ectly onto the host computer.They were loaded on a VAX/VMS machine and transferred via a network to theHP 9000 S 350. This is the reason why prevalidation tests were used for thethe validation. Those tests were loaded by Alsys from a magnetic tapecontaining all tests provided by the AVF. Customization was done by Alsys.All the tests were checked at prevalidation time.

Integrity of the validation tests was made by checking that no modificationof the test occured after the time the prevalidation results weretransferred on cartridge tape for submission to the AVF. This check wasperformed by verifying that the date of creation (or last modification) ofthe test files was earlier than the prevalidation date. After validation wasperformed, 80 source tests were selected by the AVF and checked forintegrity.

The full set of tests was compiled, linked, and all executable tests wererun on the HP 9000 S 350. Results were printed from the host computer.

The compiler was tested using command scripts provided by Alsys and reviewedby the validation team. The compiler was tested using all default optionsettings except for the following:

OPTION / SWITCH EFFECT

FLOAT=MC68881 Floating point operations use the MC68881 arithmeticcoprocessor

CALLS=INLINED Allow inline insertion of code for subprograms and takepragma INLINE into account

REDUCTION=PARTIAL Perform some high level optimizations on checks andloops

Page 25: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST INFORMATION

EXPRESSION=PARTIAL Perform some low level optimizations on commonsubexpressions and register allocation

Tests were compiled, linked, and executed (as appropriate) using a singlecomputer. Test output, compilation listings, and job logs were captured oncartridge tape and archived at the AVF. The listings examined on-site by thevalidation team were also archived.

3.7.3 Test Site

Testing was conducted at Alsys, SA. in La Celle Saint Cloud, FRANCE and wascompleted on 14 March 1989.

Page 26: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

DECLJARATIONg~ CONFORM!ANCE

APPENDIX A

DECLARATION OF CONFORM~ANCE

Alsys has subm~itted the followingDeclaration of Conformance concerning the AlsyCOMP 002.

Page 27: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

DECLARATION OF CONFORMANCE

DECLARATION OF CONFORMANCE

Compiler Implementor: Alsys

Ada Validation Facility: AFNOR, Tour Europe Cedex 7,F-92080 Paris la Defense

Ada Compiler Validation Capability (ACVC) Version: 1.10

Base Configuration

Base Compiler Name: AlsyCOMP_002 Version 4.3

Host Architecture: HP 9000 S 350HOST OS and Version: HP-UX, Version 6.2

Target Architecture: HP 9000 S 350Target OS and Version: HP-UX, Version 6.2

Implementor's Declaration

I, the undersigned, representing Alsys, have implemented no deliberateextensions to the Ada Language Standard ANSI/MIL-STD-1815A in thecompiler(s) listed in this declaration. I declare that Alsys is the owner ofrecord of the Ada language compiler(s) listed above and, as such, isresponsible for maintaining said compiler(s) in conformance to ANSI/MIL-STD-1815A. All certificates and registrations for Ada language compiler(s)listed in this declaration shall be made only in the owner's corporate name.

- -Date: In MAI 1R9AlsysEtienne Morel, Managing Director

Page 28: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

DECLARATION OF CONFORMANCE

Owner's Declaration

I, the undersigned, representing Alsys, take full responsibility forimplementation and maintenance of the Ada compiler(s) listed above, andagree to the public disclosure of the final Validation Summary Report. Ifurther agree to continue to comply with the Ada trademark policy, asdefined by the Ada Joint Program Office. I declare that all of the Adalanguage compilers listed, and their host/target performance, are incompliance with the Ada Language Standard ANSI/MIL-STD-1815A.

Date: 3n Mi199AlsysEtienne Morel, Managing Director

Page 29: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST PARAMETERS

APPENDIX B

TEST PARAMETERS

Certain tests in the ACVC make use of implementation-dependent values, suchas the maximum length of an input line and invalid file names. A test thatmakes use of such values is identified by the extension .TST in its filename. Actual values to be substituted are represented by names that beginwith a dollar sign. A value must be substituted for each of these namesbefore the test is run. The values used for this validation are given below.

Name and Meaning Value

SACC_SIZE 32An integer literal whose valueis the number of bits sufficient

to hold any value of an accesstype.

SBIGIDI 'X234567890'&(24*'1234567890')&'12341'Identifier the size of themaximum input line lengthwith varying last character.

SBIG_ID2 'X234567890'&(24*'I234567890')&'12342'Identifier the size of themaximum input line lengthwith varying last character.

SBIGID3 'X234567890'&(ll*'1234567890')&'12345XX3XX12345'&(12*'1234567890')I

Identifier the size of themaximum input line lengthwith varying middle character.

$BIGID4 'X234567890'&(l1*'1234567890')&'12345XX4XX12345'&(12*'1234567890')'

Identifier the size of themaximum input line lengthwith varying middle character.

Page 30: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

,ST PARAMETERS

Name and Meaning Value

SBIGINT_LIT (252 * '0') & '298'An integer literal of value298 with enough leading zeroesso that it is the size of themaximum line length.

$BIG REALLIT (250 * '0') & '690.0'A universal real literal ofvalue 690.0 with enoughleading zeroes to be the sizeof the maximum line length.

SBIG_STRINGI '"'&'X234567890'&(ll*'1234567890')&."'A string literal which whencatenated with BIGSTRING2yields the image of BIGIDi.

SBIG_STRING2 '"'&(13*'1234567890')&'12341'&'"'A string literal which whencatenated to the end ofBIGSTRING1 yields the imageof BIGIDi.

SBLANKS (235 * '

A sequence of blanks twentycharacters less than the sizeof the maximum line length.

$COUNT LAST 2_147_483_647A universal integer literal whosevalue is TEXTIO.COUNT'LAST.

SDEFAULTMEMSIZE 2**32An integer literal whose valueis SYSTEM.MEMORYSIZE.

SDEFAULTSTOR UNIT 8An integer literal whose valueis SYSTEM.STORAGEUNIT.

SDEFAULT_SYSNAME UNIXThe value of the constantSYSTEM.SYSTEMNAME.

SDELTADOC 2#I.0#E-31A real literal whose value isSYSTEM.FINEDELTA.

Page 31: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST PARAMETERS

Name and Meaning Value

SFIELDLAST 255A urLversal integer literal whosevalue is TEXT_:C.FIELD'LAST.

SFIXED_NAME NOSUCHTYPEThe name of a predefinedfixed-point type other thanDURATION.

SFLOAT_NAXE NOSUCHTYPEThe name of a predefinedfloating-point type other thanFLOAT, SHORTFL3!T, orLONG_FLOAT.

$GREATERTHANDURATION 100_000.0A un:versal real literal thatlies jetween DURATION'BASE'LASTand DURATION'LAST or any valuein the range of DURATION.

SGREATERTHANDURATIONBASELAST 100_000_000.0A universal real literal that isgreater than DURATION'BASE'LAST.

SHIGH PRIORITY 127An integer literal whose valueis the upper bound of the rangefor the subtype SYSTEM.PRIORITY.

$ILLEGAL_EXTERNALFILE_NAMEI /'/*/flAn external file name specifyinga non existent directory

SILLEGALEXTERNAL_FILE_NAME2 /-/*/f2An external file name different

from $:LLEGALEXTERNALFILENAME

SINTEGER_FIRST -32768A universal integer literal*whose value is INTEGER'FIRST.

SINTEGERLAST 32767A universal integer literalwhose value is INTEGER'LAST.

$INTEGER_LAST_PLUS_I 32768A universal integer literalwhose value is INTEGER'LAST + 1.

Page 32: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST PARAMETERS

Name and Meaning Value------------------------------------------------------------------------

SLESSTHANDURATION -100_000.0A universal real literal thatlies between DURATION'BASE'FIRSTand DURATION'FIRST or any valuein the range of DURATION.

SLESSTHANDURATIONBASE_FIRST -100_000_000.0A universal real literal that isless than DURATION'BASE'FIRST.

SLOW_PRIORITY 1An integer literal whose valueis the lower bouad of the rangefor the subtype SYSTEM.PRIORITY.

$MANTISSA_DOC 31An integer literal whose valueis SYSTEM.MAXMANTISSA.

SMAXDIGITS 15Maximum digits supported forfloating-point types.

$MAXINLEN 255Maximum input line lengthpermitted by the implementation.

$MAXINT 2_147_483_647A universal integer literalwhose value is SYSTEM.MAXINT.

$MAXINT_PLUS_1 2_147_483_648A universal integer literalwhose value is SYSTEM.MAXINT+I.

SMAXLEN_INT_BASEDLITERAL '2:' & (250 * '0') & '11:'A universal integer basedliteral whose value is 2:11:with enough leading zeroes inthe mantissa to be MAXINLENlong.

SMAX.LEN_REAL_BASEDLITERAL '16:' & (248 * '0') & 'F.E:'A universal real based literalwhose value is 16: F.E: withenough leading zeroes in themantissa to be MAXIN_LEN long.

4

Page 33: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST PARAMETERS

Name and Meaning Value

SMAXSTRINGLITERAL ."&(25* '1234567890')&'123'& ...A string literal of sizeMAX IN LEN, including the quotecharacters.

SMININT -2147483648A universal integer literalwhose value is SYSTEM.MININT.

SMINTASKSIZE 32An integer literal whose valueis the number of bits requiredto hold a task object which hasno entries, no declarations, andNULL;" as the only statement inits body.

SNAME NOSUCHTYPEA name of a predefined numerictype other than FLOAT, INTEGER,SHORTFLOAT, SHORT_INTEGER,LONGFLOAT, or LONG-INTEGER.

SNAMELIST UNIXA list of enumeration literalsin the type SYSTEM.NAME,separated by commas.

$NEG_BASEDINT 16#FFFFFFFE#A based integer literal whosehighest order nonzero bit fallsin the sign bit position of therepresentation for SYSTEM.MAXINT.

SNEWMEMSIZE 2**32An integer literal whose valueis a permitted argument forpragma memorysize, other thanDEFAULT MEM SIZE. If there isno other value, then useDEFAULTMEMSIZE.

SNEWSTOR UNIT 8An integer literal whose valueis a permitted argument forpragma storage-unit, other thanDEFAULT STORUNIT. If there isno other permitted value, thenuse value of SYSTEM.STORAGEUNIT.

Page 34: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

TEST PARAMETW.;

Name and Meaning Value

SNEWSYSNAME UNIXA value of the type SYSTEM.NAME,other than SDEFAULTSYSNAME. Ifthere is only one value of thattype, then use that value.

STASK_SIZE 32An integer literal whose valueis the number of bits requiredto hold a task object which hasa single entry with one inoutparameter.

STICK 1.0A real literal whose value isSYSTEM.TICK.

Page 35: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

WITHDRAWN TESTS

APPENDIX C

WITHDRAWN TESTS

Some tests are withdrawn from the ACVC because they do not conform to theAda Standard. The following 43 tests had been withdrawn at the time ofvalidation testing for the reasons indicated. A reference of the form A!-ddddd is to an Ada Commentary.

E28005CThis test expects that the string "-- TOP OF PAGE. --63" of line 204 willappear at the top of the listing page due to a pragma PAGE in line 203; butline 203 contains text that follows the pragma, and it is this that mustappear at the top of the page.

A39005GThis test unreasonably expects a component clause to pack an array componentinto a minimum size (line 30).

B97102EThis test contains an unitended illegality: a select statement contains anull statement at the place of a selective wait alternative (line 31).

BC3009BThis test wrongly expects that circular instantiations will be detected inseveral compilation units even though none of the units is illegal with re-spect to the units it depends on; by AI-00256, the illegality need not bedetected until execution is attempted (line 95).

CD2A62DThis test wrongly requires that an array object's size be no greater than 10although its subtype's size was specified to be 40 (line 137).

CD2A63A..D, CD2A66A..D, CD2A73A..D, CD2A76A..D [16 tests]These testsr wrongly attempt to check the size of objects of a derived type(for which a 'SIZE length clause is given) by passing them to a derived sub-program (which implicitly converts them to the parent type (Ada standard3.4:14)). Additionally, they use the 'SIZE length clause and attribute,whose interpretation is considered problematic by the WG9 ARG.

CD2A81G, CD2A83G, CD2A84N & M, & CDS0110 [5 tests]These tests assume that dependent tasks will terminate while the main pro-gram executes a loop that simply tests for task termination; this is notthe case, and the main program may loop indefinitely (lines 74, 85, 86 & 96,86 & 96, and 58, resp.).

Page 36: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

WITHDRAWN TESTS

CD2Bl5C & CD7205CThese tests expect that a 'STORAGESIZE length clause provides precise con-trol over the number of designated objects in a collection; the Ada standard13.2:15 allows that such control must not be expected.

CD2DllBThis test gives a SMALL representation clause for a derived fixed-point type(at line 30) that defines a set of model numbers that are not necessarilyrepresented in the parent type; by Commentary AI-00099, all model numbers ofa derived fixed-point type must be representable values of the parent type.

CD5007BThis test wrongly expects an implicitly declared subprogram to be at thethe address that is specified for an unrelated subprogram (line 303).

ED7004B, ED7005C & D, ED7006C & D [5 tests]These tests check various aspects of the use of the three SYSTEM pragmas;the AVO withdraws these tests as being inappropriate for validation.

CD7105AThis test requires that successive calls to CALENDAR.CLOCK change by atleast SYSTEM.TICK; however, by Commentary AI-00201, it is only the expectedfrequency of change that must be at least SYSTEM.TICK--particular instancesof change may be less (line 29).

CD7203B, & CD7204BThese tests use the 'SIZE length clause and attribute, whose interpretationis considered problematic by the WG9 ARG.

CD7205DThis test checks an invalid test objective: it treats the specification ofstorage to be reserved for a task's activation as though it were like thespecification of storage for a collection.

CE2107IThis test requires that objects of two similar scalar types be distinguishedwhen read from a file--DATAERROR is expected to be raised by an attempt toread one object as of the other type. However, it is not clear exactly howthe Ada standard 14.2.4:4 is to be interpreted; thus, this test objective isnot considered valid. (line 90)

CE3111CThis test requires certain behavior, when two files are associated with thesame external file, that is not required by the Ada standard.

CE3301AThis test contains several calls to END OF LINE & ENDOFPAGE that have noparameter: these calls were intended to specify a file, not to refer toSTANDARDINPUT (lines 103, 107, 118, 132, & 136).

CE3411BThis test requires that a text file's column number be set to COUNT'LAST inorder to check that LAYOUT-ERROR is raised by a subsequent PUT operation.But the former operation will generally raise an exception due to a lack ofavailable disk space, and the test would thus encumber validation testing.

Page 37: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

APPL.)LX F OF THE Ada STANDARD

APPENDIX D

APPENDIX F OF THE Ada STANDARD

The only allowed implementation dependencies correspond to implementation-dependent pragmas, to certain machine-dependent conventions as mentioned inchapter 13 of the Ada Standard, and to certain allowed restrictions onrepresentation clauses. The implementation-dependent characteristics of theAlsyCOMP_002, Version 4.3, are described in the following sections, whichdiscuss topics in Appendix F of the Ada Standard. Implementation-specificportions of the package STANDARD are also included in this appendix.

package STANDARD is

type INTEGER is range -32_768 .. 32_767;

type SHORTINTEGER is range -128 .. 127;

type LONG-INTEGER is range -2147483648 .. 2_147_483_647;

type FLOAT is digits 6 range-2#1.1111111_11111_i 1_1111_111#E+127

2|i.iii1iiiiIlli1iii1iiii1iiiiE+127;

type LONG-FLOAT is digits 15 range-2#1. 11_11i_iiii 111_iii j1iiiIIii_111_1111_ 111_1111iiiEI023

type DURATION is delta 2#0.000_000_00000001# range --86_400.0 ..86_400.0;

end STANDARD;

Page 38: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

APPENDIX F

1 INTERFACING THE LANGUAGE ADA WITH OTHERLANGUAGESPrograms written in Ada can interface with external subprograms written in another

language, by use of the INTERFACE pragma. The format of the pragma is:

pragma INTERFACE ( languagename , Ada_subprogram_name );

where the language name can be any of

* Assembler

•C

* Fortran

* Pascal

It should be emphasized that in the discussion which follows the standard HP productsare being considered. Compiler products other than those provided by HP or Alsys maynot conform to the conventions given below.

The ,-da subprogramname is the name by which the subprogram is known in Ada. Forexample, to call a subprogram known as FASTFOURIER in Ada, written in C, theINTERFACE pragma is:

pragma INTERFACE ( C, FASTFOURIER);

To relate the name used in Ada with the name used in the original language, the AlsysAda compiler converts the latter name to lower case and truncates it to 32 significantcharacters.

To avoid naming conflict with routines of the Alsys Ada Executive, external routinenames should not begin with the letters alsy (whether in lower or upper case or acombination of both).

To allow the use of non-Ada naming conventions, such as special characters, or casesensitivity, an implementation-dependent pragma INTERFACENAME has beenintroduced:

pragma INTERFACE-NAME ( Adasubprogram name. name-string );

so that, for example,

pragma INTERFACE-NAME (FASTFOURIER, "fft");

AlsyCOMP Appendix F Version 4.1 1

Page 39: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

will associate the FASTFOURIER subprogram in Ada with the C subprogram fft.

In order to conform to the naming conventions of the UNIX Linker, an underscore isprepended to the name given by namestring, the result is then truncated to 255characters.

The pragma INTERFACE NAME may be used anywhere in an Ada program whereINTERFACE is allowed (see [13.9]). INTERFACENAME must occur after thecorresponding pragma INTERFACE and within the same declarative part.

2 IMPLEMENTATION-DEPENDENT PRAGMAS

Pragma INTERFACE

This pragma has been described in the previous section.

Pragma IMPROVE and Pragma PACK

These pragmas are discussed in sections 5.7 and 5.8 on representation clauses for arraysand records.

Note that packing of record types is done systematically by the compiler. The pragmapack will affect the mapping of each component onto storage. Each component will beallocated on the logical size of the subtype.

Example:

type R isrecord

Cl : BOOLEAN; C2: INTEGER range I .. 10;end record;

pragma PACK(R);-- the attribute R'SIZE returns 5

Pragma INDENT

This pragma is only used with the Alsys Reformauer; this tool offers the functionalitiesof a pretty-printer in an Ada environment.

The pragma is placed in the source file and interpreted by the Reformatter.

pragma INDENT(OFF)

causes the Reformatter not to modify the source lines after this pragma.

pragma INDENT(ON)

causes the Reformatter to resume its action after this pragma.

Pragmas not implemented

AlsyCOMP Appendix F Version 4.1 2

Page 40: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

The foi!owing pragmas are not implemented:

CONTROLLEDMEMORY SIZEOPTIMIZESTORAGE UNITSYSTEMNAME

3 IMPLEMENTATION-DEPENDENT ATTRIBUTES

In addition to the Representation Attributes of [13.7.2] and [13.7.3], there are fourattributes which are listed under F.5 below, for use in record representation clauses.

Limitations on the use of the attribute ADDRESS

The attribute ADDRESS is implemented for all prefixes that have meaningful addresses.The following entities do not have meaningful addresses and will therefore cause acompilation error if used as prefix to ADDRESS:

" A constant that is implemented as an immediate value i.e., aoes not have anyspace allocated for it.

" A package specification that is not a library unit.

" A package body that is not a library unit or a subunit.

4 PACKAGES SYSTEM AND STANDARD

This section contains information on two predefined library packages:

" a complete listing of the specification of the package SYSTEM

" a list of the implementation-dependent declarations in the packageSTANDARD.

package SYSTEM is

-- Standard Ada definitions

type NAME is (UNIX);SYSTEM NAME constant NAME :- UNIX;STORAGEUNIT • constant :8 ;MEMORYSIZE constant "= 2*32MININT constant :-(2*"31)MAX INT : constant " 2**31-1MAX DIGrIS • constant :1 15MAXMANTISSA : constant :a 31;FINE DELTA : constant :- 2*!.0*e-31TICK: constant = 1.0;

AlsyCOMP Appendix F Version 4.1 3

Page 41: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

type ADDRESS is private;

NULLADDRESS: constant ADDRESS;

subtype PRIORITY is INTEGER range .. 127;

-- Address arithmetic

function TOLONG INTEGER (LEFT: ADDRESS)return LONG INTEGER;

function TOADDRESS (LEFT: LONGINTEGER)return ADDRESS;

function "+" (LEFT: LONGINTEGER; RIGHT: ADDRESS)return ADDRESS;

function "+" (LEFT: ADDRESS; RIGHT: LONGINTEGER)return ADDRESS;

function "-" (LEFT: ADDRESS; RIGHT: ADDRESS)return LONGINTEGER;

function "-" (LEFT: ADDRESS; RIGHT: LONG INTEGER)return ADDRESS;

function "mod" (LEFT: ADDRESS; RIGHT: POSITIVE)return NATURAL;

function "<" (LEFT: ADDRESS; RIGHT: ADDRESS)return BOOLEAN;

function "<-" (LEFT: ADDRESS; RIGHT: ADDRESS)return BOOLEAN;

function ">" (LEFT: ADDRESS; RIGHT: ADDRESS)return BOOLEAN;

function ">-" (LEFT: ADDRESS; RIGHT : ADDRESS)return BOOLEAN;

function IS NULL (LEFT: ADDRESS)return BOOLEAN;

function WORDALIGNED (LEFT: ADDRESS)return BOOLEAN;

function ROUND (LEFT: ADDRESS)return ADDRESS;

-- Return the given address rounded to the next lower even value

procedure COPY (FROM: ADDRESS; TO: ADDRESS; SIZE : NATURAL);-- Copy SIZE storage units. The result is undefined if the two areas-- overlap.

AlsyCOMP Appendix F Version 4.1 4

Page 42: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

-- Direct mem.3ry access

generictype ELEMENT TYPE is private;

function FETCH (FROM: ADDRESS) return ELEMENT TYPE;-- Return the bit pattern stored at address FROM, as a value of the-- specified ELEMENT TYPE. This function is not implemented-- for unconstrained array types.

generictype ELEMENT TYPE is private;

procedure STORE (INTO: ADDRESS; OBJECT: ELEMENTTYPE);-- Store the bit pattern representing the value of OBJECT, at the-- address INTO. This function is not implemented for-- unconstrained array types.

private

-- private part of the system

end SYSTEM;

The package STANDARD

The following are the implementation-dependent parts of the package STANDARD:

type SHORT INTEGER is range -(2**7) .. (2**7 -1);type INTEGER is range -(2** 15) .. (2** 15 -1);type LONGINTEGER is range -(2'*31) .. (2"31 -1);

type FLOAT is digits 6 range-(2.0 - 2.0**(-23)) * 2.0*127+(2.0 - 2.0**(-23)) * 2.0*127;

type LONGFLOAT is digits 15 range-(2.0 - 2.0**(-51)) * 2.0"1023+(2.0 - 2.0"*(-51)) * 2.0"1023;

type DURATION is delta 2.0"*(-14) range -86_400.0 .. 86_400.0;

5 TYPE REPRESENTATION CLAUSES

The representation of an object is closely connected with its type. For this reason thissection addresses successively the representation of enumeration, integer, floating point,fixed point, access, task, array and record types. For each class of type therepresentation of the corresponding objects is described.

AlsyCOMP Appendix F Version 4.1 5

Page 43: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

Except in the case of array and record types, the description for each class of type isindependent of the others. To understand the representation of an array type it isnecessary to understand first the representation of its components. The same rule appliesto record types.

Apart from implementation defined pragmas, Ada provides three means to control thesize of objects:

" a (predefined) pragma PACK, when the object is an array, an arraycomponent, a record or a record component

* a record representation clause, when the object is a record or a ord

component

" a size specification, in any case.

For each class of types the effect of a size specification alone is described. Interferencebetween size specifications, packing and record representation clauses is described underarray and record types.

5.1 Enumeration Types

Size of the objects of an enumeration subtype

Provided its size is not constrained by a record component clause or a pragma PACK, anobject of an enumeration subtype has the same size as its subtype.

Alignment of an enumeration subtype

An enumeration subtype is byte aligned if the size of the subtype is less than or equal to8 bits, it is otherwise even byte aligned.

Address of an object of an enumeration subtype

Provided its alignment is not constrained by a record representation clause or a pragmaPACK, the address of an object of an enumeration subtype is even when its subtype iseven byte aligned.

5.2 Integer Types

Size of the objects of an integer subtype

Provided its size is not constrained by a record component clause or a pragma PACK, anobject of an integer subtype has the same size as its subtype.

AlsyCOMP Appendix F Version 4.1 6

Page 44: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

Alignment of an integer subtype

An integer subtype is byte aligned if the size of the subtype is less than or equal to 8bits, it is otherwise even byte aligned.

Address of an object of an integer subtype

Provided its alignment is not constrained by a record representation clause or a pragmaPACK, the address of an object of an integer subtype is even when its subtype is evenbyte aligned.

5.3 Floating Point Types

Size of the objects of a floating point subtype

An object of a floating point subtype has the same size as its subtype.

Alignment of a floating point subtype

A floating point subtype is always even byte aligned.

Address of an object of a floating point subtype

Provided its alignment is not constrained by a record representation clause or a pragmaPACK, the address of an object of a floating point subtype is always even, since itssubtype is even byte aligned.

5.4 Fixed Point Types

Size of the objects of a fixed point subtype

Provided its size is not constrained by a record component clause or a pragma PACK, anobject of a fixed point type has the same size as its subtype.

Alignment of a fixed point subtype

A fived point subtype is byte aligned if its size is less than or equal to 8 bits, and isotherwise even byte aligned.

Address of an object of a fixed point subtype

Provided its alignment is not constrained by a record representation clause or a pragmaPACK, the address of an object of a fixed point subtype is even when its subtype iseven byte aligned.

AlsyCOMP Appendix F Version 4.) 7

Page 45: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

5.5 Access Types

Size of an object of an access subtype

An object of an access subtype has the same size as its subtype, thus an object of anaccess subtype is always 32 bits long.

Alignment of an access subtype.

An access subtype is always even byte aligned.

Address of an object of an access subtype

Provided its alignment is not constrained by a record representation clause or a pragmaPACK, the address of an object of an access subtype is always even, since its subtype iseven byte aligned.

5.6 Task Types

Size of the objects of a task subtype

An object of a task subtype has the same size as its subtype. Thus an object of a tasksubtype is always 32 bits long.

Alignment of a task subtype

A task subtype is always even byte aligned.

Address of an object of a task subtype

Provided its alignment is not constrained by a record representation clause, the addressof an object of a task subtype is always even, since its subtype is even byte aligned.

5.7 Array Types

Size of the objects of an array subtype

The size of an object of an array subtype is always equal to the size of the subtype ofthe object.

Alignment of an array subtype

If no pragma PACK applies to an array subtype and no size specification applies to itscomponents, the array subtype is even byte aligned if the subtype of its components iseven byte aligned. Otherwise it is byte aligned.

AlsyCOMP Appendix F Version 4.1 8

Page 46: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

If a pragma PACK applies to an array subtype or if a size specification applies to itscomponents (so that there are no gaps), the alignment of the array subtype is as given inthe following table:

reLative dispiacement of components

even number odd number I not a whoLeof bytes of bytes number of bytes

even byte even byte byte bitComonentsubtype byte byte byte bit

atignmentbit bit bit bit

Address of an object of an array subtype

Provided its alignment is not constrained by a record representation clause, the addressof an object of an array subtype is even when its subtype is even byte aligned.

5.8 Record Types

Size of an object of a record subtype

An object of a constrained record subtype has the same size as its subtype.

An object of an unconstrained record subtype has the same size as its subtype if this sizeis less than or equal to 8 kb. If the *size of the subtype is greater than this, the object hasthe size necessary to store its current value; storage space is allocated and released as thediscriminants of the record change.

Alignment of a record subtype

When no record representation clause applies to its base type, a record subtype is evenbyte aligned if it contains a component whose subtype is even byte aligned. Otherwisethe record subtype is byte aligned.

When a record representation clause that does not contain an alignment clause applies toits base type, a record subtype is even byte aligned if it contains a component whosesubtype is even byte aligned and whose offset is a multiple of 16 bits. Otherwise therecord subtype is byte aligned.

When a record representation clause that contains an alignment clause applies to its basetype, a record subtype has an alignment that obeys the alignment clause An alignmentclause can specify that a record type is byte aligned or even byte aligned.

AIsyCOMP Appendix F Version 4.1 9

Page 47: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

Address of an object of a record subtype

Provided its alignment is not constrained by a representation clause, the address of anobject of a record subtype is even when its subtype is even byte aligned.

6 ADDRESS CLAUSES

6.1 Address Clauses for Objects

An address clause can be used to specify an address for an object as described in RM13.5. When such a clause applies to an object no storage is allocated for it in theprogram generated by the compiler. The program accesses the object using the addressspecified in the clause.

An address clause is not allowed for task objects, nor for unconstrained records whosesize is greater than 8 kb.

6.2 Address Clauses for Program Units

Address clauses for program units are not implemented in the current version of thecompiler.

6.3 Address Clauses for Entries

Address clauses for entries are not implemented in the current version of the compiler.

6.4 Address Clauses for Constants

Address clauses for constants are not implemented in the current version of thecompiler.

7 UNCHECKED CONVERSIONS

Unconstrained arrays are not allowed as target types. Unconstrained record types withoutdefaulted discriminants are not allowed as target types. Access to unconstrained arraysare not allowed as target or source types.

If the source and the target types are each scalar or access types, the sizes of the objects

of the source and target types must be equal.

If a composite type is used either as source type or as target type this restriction on thesize does not apply.

If the source and the target types are each of scalar or access type or if they are both ofcomposite type, the effect of the function is to return the operand.

AlsyCOMP Appendix F Version 4.) 10

Page 48: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

In other cases the effect of unchecked conversion can be considered as a copy:

" if an unchecked conversion is achieved of a scalar or access source type to acomposite target type, the result of the function is a copy of the sourceoperand: the result has the size of the source.

" if an unchecked conversion is achieved of a composite source type to a scalar

or access target t~pc, the result of the function is a copy of the sourceoperand: the result has the size of the target.

8 INPUT-OUTPUT CHARACTERISTICS

In this part of the Appendix the implementation-specific aspects of the input-outputsystem are described.

8.1 Introduction

In Ada, input-output operations (10) are considered to be performed on objects of acertain file type rather than being performed directly on external files. An external fileis anything external to the program that can produce a value to be read or receive avalue to be written. Values transferred for a given file must be all of one type.

Generally, in Ada documentation, the term file refers to an object of a certain file type,whereas a physical manifestation is known as an external file. An external file ischaracterized by

" Its NAME, which is a string defining a legal path name under the currentversion of the operating system.

" Its FORM, which gives implementation-dependent information on filecharacteristics.

Both the NAME and THE FORM appear explicitly as parameters of the Ada CREATEand OPEN procedures. Though a file is an object of a certain file type, ultimately theobject has to correspond to an external file. Both CREATE and OPEN associate aNAME of an external file (of a certain FORM) with a program file object.

Ada 10 operations are provided by means of standard packages [14].

SEQUENTIAL_O A generic package for sequential files of a single elementtype.

DIRECT_10 A generic package for direct (random) access files.

TEXT_O A generic package for human readable (text, ASCII) files.

IO_EXCEPTIONS A package which defines the exceptions needed by theabove three packages.

AisyCOMP Appendix F Version 4.1 ll

Page 49: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

The generic package LOW_LEVEL_10 is not implemented in this version.

The upper bound for index values in DIRECT_10 and for line, column and pagenumbers in TEXT_10 is given by

COUNT'LAST - 2**31 -1

The upper bound for field widths in TEXT 10 is given by

FIELD'LAST , 255

8.2 The FORM Parameter

The FORM parameter of both the CREATE and OPEN procedures in Ada specifies thecharacteristics of the external file involved.

The CREATE procedure establishes a new external file, of a given NAME and FORM,and associates it with a specified program file object. The external file is created (andthe file object set) with a specified (or default) file mode. If the external file alreadyexists, the file will be erased. The exception USEERROR is raised if the file mode isINFILE.

Examnle:

CREATE(F, OUT_FILE, "MYFILE",FORM ->"WORLD -> READ, OWNER => READWRITE");

The OPEN procedure associates an existing external file, of a given NAME and FORM,with a specified program file object. The procedure also sets the current file mode. Ifthere is an inadmissible change of mode, then the Ada exception USEERROR israised.

The FORM parameter is a string, formed from a list of attributes, with attributesseparated by commas (,). The string is not case sensitive (so that, for example, HEREand here are treated alike). (FORM attributes are distinct from Ada attributes.) Theattributes specify-

* File protection

" File sharing

" File structure

" Buffering

" Appending

" Blocking

" Terminal input

AlsyCOMP Appendix F Version 4.1 12

Page 50: 90 01 03 013 - DTIC · 2011-05-15 · 3 RECIPZENIS CATALOG NUbik 5. TYPE Of REPORT A PLOW COVERED Ada Compiler Validation Summary Report: Alsys, 1' March 89 - 1 Dec 90 AlsvCOMP 002,

The general form of each attribute is a keyword followed by => and then a qualifier.The arrow and qualifier may sometimes be omitted. The format for an attribute specifieris thus either of

KEYWORD

KEYWORD =.> QUALIFIER

AlsyCOMP Appendix F Version 4.1 13