ADA Volume 25 USER Number 4 December 2004

JOURNAL Contents Page Editorial Policy for Ada User Journal 176 Editorial 177 News 179 Conference Calendar 209 Forthcoming Events 216 Articles Benjamin M Brosgol “Real-Time ™ for Ada Programmers” 220 John Barnes “Rationale for Ada 2005: Introduction” 228 Ada-Europe 2004 Sponsors 246 Ada-Europe Associate Members (National Ada Organizations) Inside Back Cover

Ada User Journal Volumes 25, Number 4, December 2004 176 Editorial Policy for Ada User Journal

Publication Original Papers Commentaries Ada User Journal – The Journal for the Manuscripts should be submitted in We publish commentaries on Ada and international Ada Community – is accordance with the submission software engineering topics. These published by Ada-Europe. It appears guidelines (below). may represent the views either of four times a year, on the last days of individuals or of organisations. Such March, June, September and All original technical contributions are articles can be of any length – December. Copy date is the first of the submitted to refereeing by at least two inclusion is at the discretion of the month of publication. people. Names of referees will be kept Editor. confidential, but their comments will Opinions expressed within the Ada Aims be relayed to the authors at the discretion of the Editor. User Journal do not necessarily Ada User Journal aims to inform represent the views of the Editor, Ada- readers of developments in the Ada The first named author will receive a Europe or its directors. and its use, complimentary copy of the issue of the general Ada-related software Journal in which their paper appears. Announcements and Reports engineering issues and Ada-related We are happy to publicise and report activities in Europe and other parts of By submitting a manuscript, authors grant Ada-Europe an unlimited license on events that may be of interest to our the world. The language of the journal readers. is English. to publish (and, if appropriate, republish) it, if and when the article is Although the title of the Journal refers accepted for publication. We do not Reviews to the Ada language, any related topics require that authors assign copyright to Inclusion of any review in the Journal are welcome. In particular papers in the Journal. is at the discretion of the Editor. any of the areas related to reliable Unless the authors state explicitly A reviewer will be selected by the software technologies. otherwise, submission of an article is Editor to review any book or other taken to imply that it represents publication sent to us. We are also The Journal publishes the following prepared to print reviews submitted types of material: original, unpublished work, not under consideration for publication else- from elsewhere at the discretion of the • Refereed original articles on where. Editor. technical matters concerning Ada and related topics. News and Product Announcements Submission Guidelines Ada User Journal is one of the ways in All material for publication should be • News and miscellany of interest to which people find out what is going on sent to the Editor, preferably in the Ada community. in the Ada community. Since not all of electronic format. The Editor will only accept typed manuscripts by prior • Reprints of articles published our readers have access to resources arrangement. elsewhere that deserve a wider such as the World Wide Web and Prospective authors are encouraged to audience. Usenet, or have enough time to search through the information that can be contact the Editor by email to • Commentaries on matters relating found in those resources, we reprint or determine the best format for to Ada and software engineering. report on items that may be of interest submission. Contact details can be to them. found near the front of each edition. • Announcements and reports of Example papers conforming to conferences and workshops. Reprinted Articles formatting requirements as well as some word processor templates are • Reviews of publications in the While original material is our first available from the editor. There is no field of software engineering. priority, we are willing to reprint (with limitation on the length of papers, the permission of the copyright holder) though a paper longer than 10,000

• Announcements regarding material previously submitted words would be regarded as standards concerning Ada. elsewhere if it is appropriate to give it exceptional. a wider audience. This includes papers Further details on our approach to published in North America that are these are given below. not easily available in Europe. We have a reciprocal approach in granting permission for other publications to reprint papers originally published in Ada User Journal.

Volumes 25, Number 4, December 2004 Ada User Journal 177 Editorial The December issue of the Ada User Journal marks the end of the calendar year 2004 with two article contributions that symbolize the relay between the proceedings of the past year and the exciting highlights of the year to come, which promises to be extremely rich with Ada-related events. Both articles are authored by important and valued members of the Ada community. Ben Brosgol, the author of the first article, has kindly offered us an outline of the tutorial that he presented at Ada-Europe 2004. With this contribution, the Journal has provided substantial coverage of the main tutorials that use to complement the core programme of the Ada-Europe conference week. This coverage will continue for the future editions of the conference. The second article is a very precious gift that the Journal is proud to make to its readership at large: thanks to the support of Ada-Europe, starting with this issue, the Journal will be hosting a series of articles by John Barnes (a name that needs no introduction) that cover the preliminary version of the Ada 2005 Rationale. Yes, there will be an Ada 2005 Rationale after all, to accompany the publication of the 2005 amendment of the Ada programming language, and yes, the Rationale will be authored by John Barnes, a promise of very attractive, informative and witty read. We do hope that our readers will enjoy this contribution as much as we do. The readers will also notice that this issue is thicker than usual, which they should take as a token of the health of the Ada community and the wealth of its news and events, for which our News editor, Santiago Urueña, and his long-time precessor Dirk Craeynest offer comprehensive coverage as usual. A few words are in order to comment on the incident that caused the issue 25-3 of the Journal to come to you with a disappointing number of character and printing errors. As you may have heard from your local distributor, the incident occurred at a stage of the journal production that was beyond our control. We have taken immediate steps with the Printer to make sure that an error-free version of the very same issue be dispatched to you in a timely fashion and that mishaps of this kind do not occur again. We are hopeful that you will have received that correct version of AUJ 25-3 prior to receiving this one. In closing this editorial at last, I extend my best wishes for New Year to our whole readership, our fellow members of Ada- Europe, its Board and its sibling national organisation

Tullio Vardanega Padova December 2004 Email: [email protected]

Ada User Journal Volumes 25, Number 4, December 2004 179 News Santiago Urueña Technical University of Madrid. Email: [email protected] Eagle Tower represents one of the most by widening the scope of on-line expertise Contents prestigious office addresses in as well as expanding the wealth of Page Gloucestershire and is a well-known local teaching materials available to instructors Ada-related Organizations 179 landmark. Located in the heart of in Ada, wherever their faculty may be Ada-related Events 181 Cheltenham's fashionable Montpellier based." Louise Arkwright, Ada Academic Ada and Education 183 quarter, the tower is close to the renowned Program Manager, AdaCore." Ada-related Tools 184 shopping parade, the Promenade, and Ada-related Products 193 many of the town's finest bars and Praxis Critical Systems Ada and CORBA 196 restaurants. A photo of the tower can be Limited and High Integrity Ada and GNU/ 197 seen at Ada and Microsoft 197 http://www.artisansw.com/images/eagle.jpg. Systems Limited are References to Publications 199 The company's new address is: merging to create Praxis Ada Inside 199 High Integrity Systems Ada in Context 200 ARTiSAN Software Tools, Ltd Suite 701 Eagle Tower 11 October 2004 - Praxis Critical Systems Montpellier Drive Limited and High Integrity Systems Ada-related Cheltenham Limited are merging to create Praxis High Organizations Gloucestershire Integrity Systems, a company dedicated to GL50 1TA UK delivering the best in high integrity ARTiSAN Software Tools systems engineering. The companies will AdaCore Partners with trade as Praxis High Integrity Systems Relocates Corporate Praxis Critical Systems on a from 11th October 2004 and will formally Headquarters Joint Academic Initiative merge from 3rd January 2005. ARTiSAN Software Tools Relocates to The new company remains part of the Paris, France and London, UK - October 16,000 strong Altran Group, a recognised Eagle Tower, Tallest Office Building in 1, 2004 Cheltenham, to Accommodate Projected global leader in innovative engineering Growth As part of the Ada Academic Program, and technical partner to the Renault F1 AdaCore is pleased to announce a joint team. Praxis High Integrity Systems will Cheltenham, UK - July 1, 2004 - initiative with Praxis Critical Systems lead the service offering in High ARTiSAN Software Tools, a global Ltd. AdaCore's GNAT Academic Technology Engineering for Altran's US leader for UML-based, real-time systems Program (GAP) will be linked to the and Northern European business. Altran and software modeling tools, today Praxis Academic Support Programme - a expects to invest in further growth and announced that they have relocated their fully supported professional SPARK international development for the new corporate headquarters to Eagle Tower, toolset offered free-of-charge to company, already employing 120 one of Cheltenham's most exclusive university faculty members for teaching engineers and consultants known for the business addresses. and/or research. SPARK is a high- superlative quality of their contribution to "The move marks an exciting time in integrity subset of the Ada programming developing vital systems across business Artisan's history," noted Jeremy language. The SPARK Examiner checks and industry. Goulding, ARTiSAN's President and conformance of code against the rules of For more than 20 years, Praxis and HIS CEO. "We're profitable and had double SPARK, performs flow analysis and can have already successfully delivered digit quarter-to-quarter growth over the generate Verification-Conditions for full systems and engineering consultancy last 6 quarters and it was time that we formal proof of SPARK source code. In across the Aerospace and Defence, moved into a building that can conjunction with the SPADE Simplifier Automotive, Rail, Nuclear, accommodate our needs as this trend and the SPADE Proof Checker, Praxis Telecommunications and Finance sectors, continues. We're on one floor of the provides a suite of tools capable of aiding so the merged company will be a stronger Tower now, and with it having about the development, testing and verification force in these markets in future. 100,000 square feet of modern office of high integrity systems written in Combining proven domain knowledge space on 12 floors, there's plenty of room SPARKAda. and experience with new service offerings to meet the demands of our continued "The unique properties of the SPARK such as Security Engineering and growth." language and its support tools depend on Delivery Management means more "We've made a significant investment in a the solid foundations provided by the Ada opportunities for new and existing clients state of the art training facility, and will language so we are naturally delighted to to work with the new team. be growing in this area to support the support AdaCore's far-sighted Ada In a business environment where clients increasing customer demand for SysML, Academic Programme. The combination want dependable supply partners able to UML 2.0, and specific object oriented of the AdaCore and Praxis programmes offer leading-edge services and innovative tool supported ++ & Ada language provides a one stop resource offering the solutions, Praxis High Integrity Systems training. There is much confusion over very best in software engineering tools delivers. Our client-focussed approach is the UML 2.0 standard, and people are and teaching materials". Peter Amey, specifically aimed at understanding turning to ARTiSAN, as one of the Chief Technical Officer, Praxis Critical client's needs and challenges and adapting driving forces behind the standard, for Systems. our best-in-class principled engineering to their training." "Our joint initiative with Praxis reinforces meet those needs. Our goal is always to the commitment to Ada within Academia

Ada User Journal Volume 25, Number 4, December 2004 180 Ada-related Organizations deliver the right solution at the right DDC-I "SCOREs" plans to deliver an -based IDE quality - fit for purpose first time. targeted to developers of mission- and Experienced Italian safety-critical solutions. With 'lean' engineering processes Distributor understood by all our staff, Praxis HIS "The direction of the Eclipse Platform brings a team approach that makes rapid Phoenix, AZ - September 15, 2004 - In complements our strategy of delivering strides in building resilient solutions to response to increasing demand in Italian common platforms that enable embedded highly complex problems. And to prove it industrial markets, DDC-I today developers to mix tools and secure former has ultimate confidence in its abilities to announces the signing of experienced and future development through do so, Praxis HIS regularly arranges fixed real-time vendor ARTiSAN Software interoperable technologies," noted price and gainshare contracts with clients. Tools (Srl) as exclusive distributor of Jacques Brygier, vice president of Our mission is to be a successful and agile DDC-I tools in Italy, including the marketing at Aonix. "In the mission- and company founded on technical versatile SCORE (Safety Critical, Object- safety-critical market, our customers engineering excellence, capable of oriented, Real-time Embedded) integrated come from a number of industry sectors, creating and developing the best development environment. each carrying its own certification standards and specialized tools. Like engineering talent. The new organisation "Our relationship with ARTiSAN is structured to deliver this with a mix of Eclipse, we have focused on the represents an excellent opportunity for development of common platforms, Market Sector specialists and real-time software developers in Italy," Communities of Expertise (CoEx), particularly with our products based on explains DDC-I President and CEO Dr. our SmartKernel real-time executives including Software Engineering, Systems Ole N. Oest. "SCORE's participation in Engineering (including Requirements family, in which our tools - or the next the European Open Microprocessor vendors' - work seamlessly, enabling Engineering), Project/Operational Risk Initiative presents it as a compelling Management, Programme Delivery developers to focus on building choice for every budget-conscious Italian applications, not on integrating tools." Management, Safety Engineering, software developer." Security Engineering and Human Factors. "Aonix's support for Eclipse affirms the Each CoEx is hard at work delivering not Cheltenham, UK-based ARTiSAN - a benefits of a universal platform in just expertise into customer projects but global leader in UML-based real-time delivering mission- and safety-critical also Intellectual Property in the form of systems and software modeling tools - tools," noted Mike Milinkovich, Eclipse software products, training courses, tool appointed Carmelo Tommasi, an industry executive director. "We welcome Aonix templates and more. veteran with over 25 years of into Eclipse and look forward to multinational management experience at collaboration and future contributions as Introducing a new look for Mentor Graphics, Harris, Viewlogic and they extend the Eclipse Platform into their Telelogic, to distribute ARTiSAN offerings and industry segment." ACT Europe Software Tools products in Italy. Aonix already offers different levels of From: Cyrille Comar ARTiSAN Software Tools Srl serves Eclipse integration with its PERC and important customers in aerospace and Ameos products. In the near future, Aonix Date: Mon, November 15, 2004 6:33 pm telecom markets, thanks to Mr. will integrate its Ada 95-based To: [email protected] Tommasi's market awareness and first- development environment and the first Subject: Introducing a new look for ACT hand knowledge, recognizing increasing version of the SmartKernel product Europe customer demand for SysML, UML 2.0, family. The Eclipse-based IDE common and specific object-oriented tools We are pleased to introduce a new name - to all Aonix products is under supporting flexible development in C++ - AdaCore - and a new logo. This new development and a beta copy will be & Ada. name reflects our ongoing commitment to released in the second half of the year. Ada. AdaCore is dedicated to providing "Our current efforts are focused in About Eclipse quality software and services, and our aerospace, due to the mission-critical new look serves to convey the nature of the software development, and Eclipse has established an open-source professionalism synonymous with our on telecom, which has traditionally been eco-system of tools providers and GNAT Pro package. strong in Italy. Given the nature of the consumers by creating technology and an Italian industrial market, small and open universal platform for tools What does the new name mean for you? medium size companies also represent a integration. The open-source Eclipse This change does not affect the products fertile field for tool vendors offering community creates royalty-free or support we provide our customers. You flexible products like SCORE," Tommasi technology as a platform for tools can use the new report address, concludes. integration. Eclipse based tools give [email protected] to communicate developers freedom of choice in a multi- with our technical team. For sales Aonix Joins Eclipse to language, multi-platform, multi-vendor inquiries please send e-mail to Provide Customers a supported environment. Eclipse delivers a [email protected]. The corporate plug-in based framework that makes it website is at www.adacore.com, and the Common Platform easier to create, integrate and use software GNAT Tracker web server is available at tools, saving time and money. By www.adacore.com/gnattracker. Of course Product road map charts integration of collaborating and sharing core integration the old addresses will continue to work, Eclipse plug-ins technology, tool producers can so you can switch to the new scheme at San Diego, CA, Paris, France, June 10, concentrate on their areas of expertise and your convenience. 2004 the creation of new development technology. The Eclipse Platform is If you have any questions about the name Aonix, an independent global company written in the Java language, and comes change, please do not hesitate to contact delivering complete solutions for safety- with extensive plug-in construction [email protected]. and mission-critical applications, has toolkits and examples. It has already been joined Eclipse, a community committed to deployed on a range of development the implementation of an universal workstations including HP-UX, Solaris, platform for tools integration. In addition AIX, Linux, MAC OS X, QNX and to porting its Ada95, PERC and Ameos Windows based systems. Full details of tool suites to the Eclipse platform, Aonix the Eclipse community and white papers

Volume 25, Number 4, December 2004 Ada User Journal Ada-related Events 181 documenting the design of the Eclipse technology topics. Join us in I'm pleased to announce that to coordinate Platform are available at understanding how these topics mutually among potential speakers and attendants, www.eclipse.org. support the disciplined development and an AdaFosdem mailing list has been evolution of serious, high quality software created. Several relevant pre-list postings systems. have been included in the list's archives. Ada-related Events The following tutorial was added after the We hereby invite everyone interested in Advanced Program was published: an Ada event at FOSDEM 2005 to [The announcements reported below are a subscribe (*) to the AdaFosdem mailing selection of the many Ada-related events A#: Programming PDAs and .NET devices with Ada list in order to contribute ideas and organized by local groups. If you are or- suggestions. We recommend new ganizing such an event, feel free to inform This tutorial describes A#, an Ada environment for programming the subscribers to browse the archives for us as soon as possible. If you attended one September and to offer comments. please consider writing a short report for Windows .NET and .NET Compact the Journal. -- su] Frameworks. Attendees will learn how to To subscribe and to consult the list create Ada applications that take archives, use URL Nov 14-18 - SIGAda 2004 advantage of the rich set of libraries http://listserv.cc.kuleuven.ac.be/archives/a Conference available with the .NET Framework, and dafosdem.html also how to deploy Ada applications onto To post to the list (after subscribing), send From: Ricky E. Sward PDAs using the .NET Compact e-mail to Framework. [email protected] Date: 27 Aug 2004 07:57:58 -0700 For more information on the conference Looking forward to see much activity on Subject: SIGAda 2004 Conference schedule, registration options, and hotel the new list, Newsgroups: comp.lang.ada information visit the SIGAda 2004 web site at the following link. Ludovic Brenta, Ada at FOSDEM Conference Announcement - SIGAda coordinator, [email protected] 2004 http://www.acm.org/sigada/conf/sigada2004 Dirk Craeynest, Ada-Belgium & 14-18 November 2004, Atlanta, Georgia, AdaFosdem list owner, USA Oct 06-07 - Ada-Deutschland Tagung 2004 [email protected] Sponsored by ACM SIGAda (*) AdaFosdem is an open mailing list The SIGAda 2004 conference offers a Ada Germany Conference 2004: (anyone can subscribe), though top-quality technical program focused on Automotive Safety and Security subscriptions have to be confirmed by e- important strengths of the Ada "Security and Reliability for Automobile mail (to avoid spammers subscribing). programming language. Three days of Information Technology" The list is not moderated, though only technical papers, keynotes, and invited subscribers can post (again to reduce the presentations will report on how Ada is October 2004 - SofCheck Chairman and risk of spamming). We hope this setup achieving success in the challenging CTO, Tucker Taft, presented the keynote will be a good compromise between high realm of software engineering. We are lecture "Ada 2005 - Putting It All availability of the list and low spam risk. pleased to announce that three leaders in Together" to the Ada Germany Conference 2004 on Reliable Software [See also "Libre Software Meeting" in the software engineering community, Pam AUJ 25-3 (Sep 2004), p.117. --su] Thompson from Lockheed Martin Systems. Aeronautics, Watts Humphrey from the View the presentation in PDF format: Jun 20-24 - Ada-Europe Software Engineering Institute, and Stephen Cross from the Georgia Tech [http://www.sofcheck.com/news/adagerm 2005 Conference Research Institute, will provide keynote any2004rev3.pdf --su] addresses. We are also fortunate to have [See also the announcement (in German) From: Dirk Craeynest key members of the WG9 Ada Rapporteur of this conference in AUJ 25-2 (Jun Group (ARG) who will participate in a 3- 2004), p.85. --su] Date: 7 Oct 2004 22:06:48 +0200 hour panel on the significant Organization: Ada-Europe, c/o Dept. of improvements that WG9 has approved for Feb 26-27 - Ada event at Computer Science, K.U.Leuven inclusion in the Ada 2005 Amendment. FOSDEM 2005 Subject: 2nd CFP Conf. Reliable Software The Panel will be chaired by IBM Technologies, Ada-Europe 2005 Rational's Pascal Leroy, Chair of the Newsgroups: From: Dirk Craeynest comp.lang.ada,fr.comp.lang.ada WG9 ARG. Beyond the formal conference of selected Date: 5 Oct 2004 21:36:28 +0200 10th International Conference on Reliable papers and presentations, SIGAda 2004 Organization: Ada-Belgium, c/o Dept. of Software Technologies - Ada-Europe offers two days of outstanding tutorials Computer Science, K.U.Leuven 2005 led by some of the most respected Subject: AdaFosdem mailing list created for 20 - 24 June 2005, York, UK technical leaders in the industry. Ada event at FOSDEM 2005 Newsgroups: http://www.ada-europe.org/conference2005. SIGAda's tutorials and workshops provide html full- or half-days for those working the comp.lang.ada,fr.comp.lang.ada same issues to share with each other and Recently, there was a discussion on the Organized, on behalf of Ada-Europe, by leverage everyone's accomplishments; Ada-Belgium members' mailing list about the University of York, in cooperation workshop products are "delivered" to the the possibility of organizing an Ada event with ACM SIGAda (approval pending) community. The broad offerings of at FOSDEM 2005 in Brussels (Sat-Sun Ada-Europe organizes annual career-enhancing tutorials include basic 26-27 February 2005, www.fosdem.org). international conferences since the early Ada 95 introductions for software FOSDEM is the "Free and Open Source 80's. This is the 10th event in the engineers new to Ada, intermediate and Reliable Software Technologies series, advanced Ada topics for practitioners Software Developers' European Meeting" held annually in Brussels; the 4th edition previous ones being held at Montreux, striving to expand their Ada expertise, Switzerland ('96), London, UK ('97), and several language-independent attracted some 2000 participants earlier this year. Uppsala, Sweden ('98), Santander, Spain

Ada User Journal Volume 25, Number 4, December 2004 182 Ada-related Events

('99), Potsdam, Germany ('00), Leuven, Analysis, Verification, Validation, Ada User Journal using the relevant Belgium ('01), Vienna, Austria ('02), Testing of Software Systems format and style. Toulouse, France ('03), Palma de - Critical Systems: Real-Time, Awards Mallorca, Spain ('04). Distribution, Fault Tolerance, Information Ada-Europe will offer honorary awards General Information Technology, Safety, Security for the best paper and the best The 10th International Conference on - Mainstream and Emerging Applications: presentation, which will be presented Reliable Software Technologies (Ada- Multimedia and Communications, during the banquet and at the close of the Europe 2005) will take place in York, Manufacturing, Robotics, Avionics, conference respectively. UK. Following the usual style, the Space, Health Care, Transportation Call for Tutorials conference will span a full week, - Ada Language and Technology: Tutorials should address subjects that fall including a three-day technical program Programming Techniques, Object- and vendor exhibitions from Tuesday to within the thrust of the conference and Oriented Programming, Concurrent may be proposed as either half- or a full- Thursday, along with parallel workshops Programming, Bindings and Libraries, and tutorials on Monday and Friday. day events. Proposals should include a Evaluation & Comparative Assessments, title, an abstract, a description of the Schedule Critical Review of Language topic, a detailed outline of the 7 November 2004: Submission of Enhancements, Novel Support presentation, a description of the proposed contributions Technology presenter's lecturing expertise in general 17 January 2005: Notification to authors Call for Industrial Presentations and with the proposed topic in particular, the proposed duration (half day or full 7 March 2005: Camera-ready papers [Cf. the Forthcoming Events section in this AUJ issue, pages 221-222. – su] day), the intended level of the tutorial required (introductory, intermediate, or advanced), 20-24 June 2005: Conference Submissions the recommended audience experience and background, and a statement of the Topics Authors are invited to submit original contributions. Paper submissions shall be reasons for attending. Proposals should In the last decade the conference has in English, should be complete and should be submitted by e-mail to the Tutorial established itself as an international forum not exceed 20 double-spaced pages in Chair Iain Bate. The providers of full-day for providers and practitioners of, and length. Extended abstracts and outlines of tutorials will receive a complimentary researchers into, reliable software presentations that provide a sufficient conference registration as well as a fee for technologies. The conference insight into the intended contents of the every paying participant in excess of 5; presentations will illustrate current work contributions will also be considered. for half-day tutorials, these benefits will in the theory and practice of the design, Authors of accepted extended abstracts accordingly be halved. The Ada User development and maintenance of long- and/or presentations shall submit a Journal will offer space for the lived, high-quality software systems for a consolidated version of their contribution publication of summaries of the accepted variety of application domains. The to the Program Co-Chair Tullio tutorial in issues preceding and/or program will allow ample time for Vardanega for final acceptance, by following the conference. keynotes, Q&A sessions, panel *February 21, 2005*. Authors should Call for Workshops discussions and social events. Participants submit their work via the Web submission will include practitioners and researchers system accessible from the conference Workshops on themes within the from industry, academia and government Home page. The preferred format for conference scope may be arranged to organisations interested in furthering the submission is PDF. Postscript can also be discuss matters of immediate technical development of reliable software accepted, as long as it was generated interest as well as to foster action on technologies. To mark the completion of selecting the "optimize for portability" longer-term technical objectives. the technical work for the Ada language option in the used printer driver. Proposals may be submitted for half- or standard revision process, a special Submissions by other means and formats full-day workshops, to be scheduled on session will be devoted to the presentation will *not* be accepted. If you do not either ends of the main conference. and discussion of the prospects of the have easy access to the Internet, or you do Workshop proposals should be submitted revised language in the landscape of not have an appropriate Web browser, by e-mail to the Program Co-Chair Tullio mainstream language technologies. please contact the Program Co-Chair Vardanega. The workshop organiser shall also commit to preparing proceedings for For papers, tutorials, and workshop Tullio Vardanega, whose address details are on this call as well as on the timely publication in the Ada User proposals, the topics of interest include, Journal. but are not limited to: conference Home page. Exhibition - Methods and Techniques for Software Proceedings Development and Maintenance: The authors of accepted papers shall Commercial exhibitions will span the Requirements Engineering, Object- prepare their camera-ready submissions in three days of the main conference. Oriented Technologies, Formal Methods, full conformance with the LNCS style, Vendors and providers of software Re-engineering and Reverse Engineering, not exceeding 12 pages and strictly by products and services should contact the Reuse, Software Management Issues *March 7, 2005*. Authors should refer Exhibition Chair Rod Chapman as soon as possible for further information and for - Software Architectures: Patterns for to: http://www.springer.de/comp/lncs/authors allowing suitable planning of the Software Design and Composition, exhibition space and time. Frameworks, Architecture-Centered .html for format and style guidelines. Development, Component and Class Failure to comply will prevent the paper Libraries, Component-Based Design from appearing in the conference proceedings. The conference proceedings - Enabling Technology: CASE Tools, including all accepted papers will be Software Development Environments and published in the Lecture Notes in Project Browsers, Compilers, Debuggers Computer Science (LNCS) series by and Runtime Libraries Springer Verlag, which will be available - Software Quality: Quality Management at the start of the conference. All other and Assurance, Risk Analysis, Program accepted contributions will appear in the

Volume 25, Number 4, December 2004 Ada User Journal Ada and Education 183

Reduced Fees for Students Kermarrec Yvon, ENST Bretagne, France - In the Learning Center/ Free books and A small number of bursars are available Kienzle Jörg, McGill University, Canada references for another PDF file about the for students who will (co-)author and Kordon Fabrice, Université Pierre & Ravenscar tasking model. present papers at the conference. A Marie Curie, France - In the Ada Advocacy section for yet reduction of 25% will be made to the Leroy Pascal, IBM, France another pdf file entitled "Targeting conference fee. Contact the Conference LLamosi Albert, Universitat de les Illes Ada95/DSA for Distributed Simulation of Chair Alan Burns for details. Balears, Spain Multi Protocol Communication Lundqvist Kristina, MIT, USA Networks" Organizing Committee Mazzanti Franco, Istituto di Scienza e Conference Chair Tecnologie dell'Informazione, Italy Free Seminar about SPARK McCormick John, University of Northern Alan Burns, University of York, UK Iowa, USA [email protected] From: Joyce L. Tokar Miranda Javier, Universidad Las Palmas Program Co-Chairs de Gran Canaria, Spain Date: Fri, 27 Aug 2004 00:12:09 GMT Tullio Vardanega, University of Padua, Morere Pierre, Aonix, France Subject: FREE SEMINAR: SPARK: A Italy, [email protected] de la Puente Juan A., Universidad Safer Way to Program Politecnica de Madrid, Spain Newsgroups: comp.lang.ada Andy Wellings, University of York, UK, Pautet Laurent, ENST Paris, France [email protected] Plödereder Erhard, Universität Stuttgart, SPARK: A Safer Way to Program Tutorial Chair Germany Friday 1 Oct 2004 13:00-16:00 Romanovsky Alexander, University of Mustang Library Discussion Room Iain Bate, University of York, UK, Newcastle upon Tyne, UK 10101 N 90th St, Scottsdale, AZ 85258 [email protected] Rosen Jean-Pierre, Adalog, France Exhibition Chair Schonberg Edmond, New York There is an increasing need to produce software that is safe, secure, and reliable. Rod Chapman, Praxis Critical Systems, University & ACT, USA As systems become more complex and [email protected] Vardanega Tullio, Università di Padova, Italy safety and security issues gain ground in Publicity Co-Chairs Wellings Andy, University of York, UK the world of real-time applications, there Ian Broster, University of York, UK, Winkler Jürgen, Friedrich-Schiller- is a greater demand for tools and [email protected] Universität, Germany techniques that will enable the generation of robust software in a cost-effective and Dirk Craeynest, Aubay Belgium & timely manner. Much of the emphasis on K.U.Leuven, Belgium, Ada and Education the development of high integrity [email protected] software is placed on the testing cycle Local Administrator Real-Time Ada near the end of the development process. This methodology results in the need for a Sue Helliwell, University of York, UK, programming large amount of time at the end of the [email protected] From: Stephane Richard development process to test components Ada-Europe Conference Liaison as well as integrated systems. Laurent Pautet, ENST Paris, France, Date: Thu, 16 Sep 2004 11:29:08 GMT Yet, it is well known and documented that [email protected] Subject: Re: RTeal-time Ada Programming the best time to find errors is at the start of Program Committee Rules ? the development cycle when the problems Asplund Lars, Mälardalens Högskola, Newsgroups: comp.lang.ada are smaller and better understood. The Sweden Armand Puccetti wrote: cost of correcting errors that are Alonso Alejandro, Universidad discovered early in the software life cycle > Does someone know about some good is considerably less expensive than those Politecnica de Madrid, Spain guides with programming rules for real- Barnes Janet, Praxis Critical Systems, UK that are found during integration and test. time Ada? I'm looking for detailed rules The SPARK approach to developing Bernat Guillem, University of York, UK used for developing embedded systems Blieberger Johann, Technische software provides the tools and within large companies or national technology needed to construct correct Universität Wien, Austria authorities (FAA, DoD,...), that can Burgstaller Bernd, Technische Universität software from the start of the process. give concrete hints to RT programmers. This methodology reduces the cost of Wien, Austria Also, what reference text books on RT Burns Alan, University of York, UK development because the components are Ada programming are worthwile built correctly from the start leading to a Cederling Ulf, Vaxjo University, Sweden reading? Craeynest Dirk, Aubay Belgium & shorter integration and test cycle with K.U.Leuven, Belgium Here's one called "Real time scheduling fewer bugs discovered in this phase. Crespo Alfons, Universidad Politecnica theory and Ada." This free seminar will provide an de Valencia, Spain http://www.sei.cmu.edu/pub/documents/8 overview of the SPARK language and the Dencker Peter, Aonix GmbH, Germany 8.reports/pdf/tr33.88.pdf tools in the SPARK toolset that facilitate Devillers Raymond, Université Libre de And another called "Realtime Software the generation of safe and secure Bruxelles, Belgium Engineering in Ada: Observations and software. The course is suitable for senior González-Harbour Michael, Universidad Guidelines" software and systems engineers; the de Cantabria, Spain http://www.sei.cmu.edu/pub/documents/8 seminar does not presume prior Hately Andrew, Eurocontrol - CEATS 9.reports/pdf/tr22.89.pdf knowledge of SPARK. The seminar is Research Development Simulation also useful to software and systems Centre, Hungary I think they'll make to good night reading managers responsible for the development Hommel Günter, Technischen Univesität books for you :-). Might wanna pay a and integration of complex critical Berlin, Germany visit to my website too (ada world systems. The attendees should have an Kauer Stefan, EADS Dornier, Germany http://www.adaworld.com) understanding of the fundamentals of the Keller Hubert, Institut für Angewandte development of complex, critical real- Informatik time software applications.

Ada User Journal Volume 25, Number 4, December 2004 184 Ada-related Tools

If you would like to join us for a three- The old AdaPower site is accessible via Most packages have been entered in to the hour presentation by Dr. Joyce L Tokar, http://www.adapower.org during the new AdaPower.com site. Make sure yours please complete the registration form on transition. is there. our website and email it to From: David Botton If not, contact me and it will be in [email protected]. Date: Thu, 28 Oct 2004 02:27:05 -0400 instantly. See our website for other dates and Subject: AdaPower.com Links From: David Botton locations of the seminar Newsgroups: comp.lang.ada Date: Tue, 9 Nov 2004 00:24:16 -0500 www.pyrrhusoft.com. The AdaPower Links Page is complete Subject: The NEW AdaPower.com NOW Public SPARK Training in now. So.... COMPLETE Are you a Compiler Vendor, Tool Vendor Newsgroups: comp.lang.ada 2005 or Offering Training and Consulting? The entire contents of the old From: Rod Chapman Then you should be on the AdaPower.com has now been moved in to AdaPower.com Links page. the databases running the new AdaPower.com, links and code updated Date: 11 Nov 2004 07:42:30 -0800 http://www.adapower.com/links Subject: ANN: SPARK Training in 2005 when known and already a ton of new Newsgroups: comp.lang.ada Please check to see if you are listed. If stuff in. not, please e-mail to [email protected] I'm pleased to say that dates for public From the AdaPower.com home page: SPARK Training for 2005 are now From: David Botton Ada Programming Articles, Examples and available on www.sparkada.com Date: Thu, 28 Oct 2004 05:19:24 -0400 Packages on AdaPower as of Nov 8, Subject: AdaPower.com Call For Projects 2004: 433. So now there is a count :-) Note that there's a new, advanced "Black Newsgroups: comp.lang.ada Belt SPARK" course that concentrates on Help me break 500 this week! the use of the SPARK Proof Tools and the Do you have an active Ada project that other people can join and be a part of? I am looking for examples of Ada Proof-Directed design of SPARK programing. Be it simple basic code, programs. Public course dates for this There are many people that would love to advanced techniques or sample programs course will be announced soon. work with you on your Ada dreams. to demonstrate the use of Ada libraries, Public Ada 95 Courses The *new* AdaPower.com features a GUI programming with Ada, Web section called "Ada Projects You Can programming with Ada, etc. etc. From: Ed Colbert Join" where your Ada project can be Thanks! listed. Date: 12 Nov 2004 09:45:37 -0800 From: David Botton Subject: [Announcing] Public Ada 95 See http://www.adapower.com/projects Date: Fri, 5 Nov 2004 01:46:49 -0500 Courses 13-17 December 2004 in Contact me: [email protected] to have Subject: Ada FAQ Carlsbad CA your project listed! Please include Name, Newsgroups: comp.lang.ada Newsgroups: comp.lang.ada Description and URL AdaPower.com is almost done in the Absolute Software will be holding a From: David Botton transition to the new design and database public Ada 95 course during the week of Date: Fri, 29 Oct 2004 00:53:42 -0400 orientation and I've now picked up on an 13 [December] 2004 in Carlsbad, CA. Subject: AdaPower.com Home Pages old project, the Ada FAQ. As we all You can find a full description and Newsgroups: comp.lang.ada know, the old Ada FAQs have been registration form on our web-site, kindly locked up in (c)s and the author www.abssw.com. Click the Public Is your Ada home page listed on unresponsive to release them for many Courses button in the left margin. (We AdaPower.com? years. also offer courses on object-oriented Take a look AdaPower had an FAQ project for a little methods and other object-oriented http://www.adapower.com/index.php?Co languages.) while and the FAQs from that project are mmand=HomePages being imported in to the new Ada FAQ at: If there is anything you'd like to discuss, If not let me know! http://www.adapower.com/faq please call, write, or send me E-mail. From: David Botton If you have an Ada question and answer, Date: Fri, 29 Oct 2004 00:52:25 -0400 please forward it to [email protected] Ada-related Resources Subject: AdaPower.com RSS News Feeds If you maintain an FAQ for an Ada Newsgroups: comp.lang.ada related site or product, please send a link New AdaPower.com Did you know that the new to the above address so I can add it to the AdaPower.com has RSS News Feeds? list of "Other Ada Related FAQs" From: David Botton Date: Wed, 27 Oct 2004 19:06:14 -0400 You can subscribe to either the main news BTW - On November 7, AdaPower will Subject: New AdaPower.com feed at be 6 YEARS OLD! see Newsgroups: comp.lang.ada http://www.adapower.com/rss/index.xml http://www.adapower.com or the update feed for the last 20 updates I have begun work on a new version of made to the site at AdaPower.com powered by PHP and http://www.adapower.com/rss/latest/index Ada-related Tools MySQL using portal code that runs a .xml number of my personal sites. From: David Botton AdaCL 4.2.0 - Ada Class When complete, site updates can easily be Date: Fri, 29 Oct 2004 00:55:24 -0400 Library made from a control panel I wrote, etc. Subject: Source Code Example, Articles, etc. Etc. From: Martin Krischik More information to follow. You can Newsgroups: comp.lang.ada watch progress over the next few weeks Date: Thu, 26 Aug 2004 21:29:49 +0200 Do you have Ada Packages for Reuse that Subject: [Announcement] AdaCL 4.2.0 as things are put up, etc. at of course are not yet on AdaPower.com? http://www.adapower.com released. Newsgroups: comp.lang.ada

Volume 25, Number 4, December 2004 Ada User Journal Ada-related Tools 185

Notes: > Just for fun, I thought it would be There are some technical reasons why First Release with Björn Persson's interesting to do hobby like ada GNAT and GCC are unsuited to what I EAStrings and Orto. It's a Team now so programming on robots. From want to achieve. do use Tracker for bug reports. searching google, most I got was GNAT's library model is based on source references to using Ada for lego Changes: code files directly representing the mindstorms. That seems like fun, library; this model isn't always ideal. I EAStrings support for non Latin 1 strings. anyone have experience in this? want to provide a compiler that has the Here are some of the links for Lego more traditional model of a library being Orto Commandline parsing for non Latin Mindstorm: 1 commandlines. stored in a set of files which contain all 1) the necessary information (to generate Extension to XML/Ada Unicode support. http://www.faginfamily.net/barry/Papers/ executables) in a binary form. And yes I do submit them to libre as well AdaLetters.htm and one is already approved. 2) I want ECLAT to be able to target the AdaOS native executable format for the Abstract: http://www.usafa.af.mil/dfcs/bios/mcc_ht ml/adagide.html IA-32 (NEAI/IA-32), which is segmented. AdaCL provides library services for 3) GCC emits code which is suitable (only) scriptig in Ada: http://www.usafa.af.mil/dfcs/Ada_Mindst for a 'flat' memory model, and I think - A text search and replace library. orms_manual.htm adapting it to generate code that supports [4) the NEAI/IA-32 segmented architecture - a complete cgi binding. http://www.faginfamily.net/barry/Papers/I would be difficult. - execution of external programms TICSEWeb/using_ada.htm --su] [See also "ECLAT - Open Source Ada inclusive I/O redirection with Hope this wasn't off-base with this, but 2005 Compiler" in AUJ 25-3 (Sep 2004), Ada.Text_IO. Unlike GNAT.OS_Lib Ada all programmers like to play in p.120. --su] CL lets you wait on a given programming that isn't "work"? Plus, asynchronous process instead of just the fi robots are cool. Distributed compilation rst to end. Mr. Fagan has done a nice job with Ada - a garbage collector. Mindstorms. I hope it continues to From: Martin Dowie evolve. - booch components for indefinite Date: Fri, 29 Oct 2004 11:50:05 +0100 elements. You can get the AdaGide add-on for Ada Organization: BAE SYSTEMS - trace feature - very handy for CGI (no Mindstorms at: Subject: Re: Distributed compiles? debugger, no console output). ftp://ftp.usafa.af.mil/pub/dfcs/fagin/adami Newsgroups: comp.lang.ada - Control cdrecord and makeisofs. ndstorms-install.exe > A long shot, I know, but are there any distributed compilers for Ada? Our - some cvs tools. [See also same topic in AUJ 23-3 (Sep 2002), pp.127-128. --su] build process takes a couple of hours With Regards and it would nice if we could spread the Martin Krischik ECLAT Status load a bit... mailto://krischik@users..net Not quite what you're after but check out From: Nick Roberts the "-j" option for GNAT (under '6.2 http://www.ada.krischik.com switches for gnatmake'). On a twin Xeon Date: Thu, 07 Oct 2004 23:52:57 +0100 machine this should give you 4 Simple components 1.6 Subject: ECLAT [was: Ada memory compilations in parallel. management?] From: Dmitry A. Kazakov Newsgroups: comp.lang.ada From: Jeff Creem Date: Fri, 29 Oct 2004 11:05:58 GMT Luke A. Guest wrote: Date: Sat, 9 Oct 2004 20:02:47 +0200 Subject: Re: Distributed compiles? Subject: ANN: Simple components 1.6 >> http://sourceforge.net/projects/eclat Newsgroups: comp.lang.ada Newsgroups: comp.lang.ada > Erm, how far are you with this project I've never tried this but perhaps cook I have uploaded version 1.6. Nick? I've known about it for a while would be helpful and your page doesn't really have http://www.dmitry- http://www.vaxxine.com/pegasoft/homes/ anything on it (yet), how about an 5.html#5.2 kazakov.de/ada/components.htm update? Changes made are: From: Georg Bauhaus 1. Added set of GC objects: the child a few docs under the 'Docs' link. Date: Wed, 3 Nov 2004 13:22:09 package Object.Handle.Generic_Set; > Also, are you using GCC at all? That Subject: Re: Distributed compiles? 2. Erase operation was added to all would be interesting; it might spur Newsgroups: comp.lang.ada unbounded arrays; some competition with ACT ;-D If Not suggesting that you haven't already 3. Bug fix in Generic_Set. Now, binary you're not using GCC, maybe you done so, still, could you split the software operations should work correctly when should try using it to speed up into independent subsystems that are built both arguments are the same set. development. separately and then use some distributed I do want ECLAT to be (friendly :-) file system? Lego Mindstorms competition for GNAT/GCC, both in the From: Wes Groleau front and and the back end. I think this is From: Jerry Petrey a case where it makes sense to 'reinvent Date: Wed, 03 Nov 2004 19:48:10 -0500 the wheel'. If people who are new to Ada Subject: Re: Distributed compiles? Date: Wed, 29 Sep 2004 10:00:10 -0700 ask "Are there any free compilers?", I Newsgroups: comp.lang.ada Subject: Re: Ada and Robotics (for fun)? think it would sound a lot better to be able Newsgroups: comp.lang.ada to suggest two, rather than just one. (I With GNAT, you can specify gnatmake -j 5 and have five compiles running at once. Chris Humphries wrote: know there is ObjectAda, but it is really only a demo version.)

Ada User Journal Volume 25, Number 4, December 2004 186 Ada-related Tools

If you set it up (it's possible, check the I have already successfully ported (well [See also same topic in AUJ 24-4 (Dec docs) so that when it calls 'gcc' it actually copied and compiled :-) some applications 2003), p.204. --su] gets a script that runs the job on another on the iPAQ. It integrates even into the machine with the real gcc. Visual Studio .Net so you can debug the Infinite number sequences And, since gnatmake is written in Ada, Ada code as well on the emulated PDA. From: Georg Bauhaus complies with the distributed systems into the .IL files Date: Wed, 22 Sep 2004 21:15:54 +0000 annex, it shouldn't be too hard for There should be an official release soon UTC someone with some time on their hands to From: Pascal Obry Subject: [ANN] "functional" number modify gnatmake as follows: Date: 26 Oct 2004 19:40:38 +0200 sequence device -j n Subject: Re: PDA's Newsgroups: comp.lang.ada Newsgroups: comp.lang.ada where n is a positive number, just like A small programming device that has now Stephane Richard wrote: helped me make "infinite" sequences -j "host1 host2 host3 host4" > The good thing about a Symbian OS based on numbers in Ada is online at http://home.arcor.de/bauhaus/Ada/fada.txt farms out the compiles on all those hosts machine is that Ada can be compiled to (assumes mount points and paths are the Java bytecode and Symbian can/does It is modelled, in ML terms, after datatype same) run Java. chain = Link of (int (int -> chain)). Do you have a step-by-step doc to do Programming a PDA with that? I have a P900 and like to program it Ada and OpenGL Ada in Ada. The JGNAT is ok for me, but I have never installed a JVM into a From: Etienne Baudin Symbian device. I know that there is some Date: Sun, 17 Oct 2004 17:30:17 +0200 From: Stephane Richard Subject: Exemple d'application information on the Sony Ericsson Web site but this is far from being a step-by- Ada+Opengl Date: Tue, 26 Oct 2004 11:54:29 GMT Newsgroups: fr.comp.lang.ada Subject: Re: PDA's step approach! Newsgroups: comp.lang.ada From: Stephane Richard [Translation from French – su] I am offering code that implements a sort of > I'm looking for a PDA that I can Date: Tue, 26 Oct 2004 17:50:09 GMT rudimentary viewer for 3d objects. It is program. So I can basically put my own not really professional, but it shows that buttons and information on. Subject: Re: PDA's Newsgroups: comp.lang.ada one can put together nice toys with Ada. Any information on a PDA that does http://pfox.free.fr/AdaOpenGL- that, or specific software and PDA that Maybe this website can help. Exemple.tar.bz2 I can use, would be great. http://www.wirelessdevnet.com/channels/ pda/training/symbian2/ The software compiles on Linux as well As far as programmable PDAs goes, as on Windows (good live portability!). There's more than one model. I've found some programming language or another Fuzzy sets for Ada Do not hesitate to let me have your on pretty much all of Palm's series of comments and to report any compilation PDAs. I have a PSION REVO+ which I From: Dmitry A. Kazakov problems (cf. the relevant procedure happen to like alot because of it's layout within the distribution). and that one is programmable as well in Date: Sun, 17 Oct 2004 14:19:36 +0200 OPL (a somewhat BASIC like language) Subject: ANN: Fuzzy sets for Ada version Win_IO 2.0.1 C++ and Java and of course Assembler. 3.7 Newsgroups: comp.lang.ada From: Michael Gonzalez For palm: http://mobile.eric- poncet.com/palm/tutorial.html Fuzzy sets for Ada is distributed under terms of GMGPL. It provides Date: Wed, 13 Oct 2004 11:50:46 +0200 For PSION PDAs you can go to the implementations of: Organization: Universidad de Cantabria Symbian OS website Subject: Win_IO 2.0.1 is now available http://www.symbian.com/developer/ - Confidence factors with the operations Newsgroups: comp.lang.ada not, and, or, xor, +, *; The good think about a Symbian OS Version 2.0.1 of Win_IO is now available machine, is that Ada can be compiled to - Classical fuzzy sets with the set- in: http://www.ctr.unican.es/win_io/ Java bytecode and Symbian can/does run theoretic operations and the operations of the possibility theory; This version is developed with GtkAda Java. 2.2.X and is free software. It is the same From: Wes Groleau - Intuitionistic fuzzy sets with the as version 2.0 except that it corrects a bug operations on them; in the function used to read an image from Subject: Re: PDA's - Fuzzy logic based on the intuitionistic disk. Date: Tue, 26 Oct 2004 22:27:00 -0500 fuzzy sets and the possibility theory; Win_IO is a set of packages for graphical Newsgroups: comp.lang.ada - Fuzzy numbers both integer and input and output. It is designed specially Ada to J-code to Palm OS has also been floating-point ones with conventional for students or Ada users who do not want done. arithmetical operations; to spend their time learning a complex graphical user interface, but who are From: Rob Veenker - Linguistic variables and sets of linguistic "tired" of the old-fashioned text-oriented Date: Fri, 29 Oct 2004 09:12:38 +0200 variables with operations on them; input and output. Win_IO has the same Subject: Re: PDA's - String-oriented I/O is supported. goals as JEWL (John English Windows Newsgroups: comp.lang.ada The version 3.7 is based on the latest Library, Besides JGNAT, which works well on version of simple components. http://www.it.bton.ac.uk/staff/je/jewl/), most PDA's (the trick is to get a JVM :-) but is simpler (and less powerful) and is there now is MGNAT for PDA's as well. [http://www.dmitry- portable within UNIX, Linux and There will be a tutorial by Martin Carlisle kazakov.de/ada/fuzzy.htm --su] Windows platforms. JEWL is currently in the next SigAda conference in Atlanta. only provided for Windows.

Volume 25, Number 4, December 2004 Ada User Journal Ada-related Tools 187

See how you can code nice-looking community Ada Windows binding. I'd been away from this list for a long period windows for input & output in a really like to get started :). of time. minimal program: [...] As the list stands now, there is a clear For the community windows binding, I output: preference for GWindows. think it's best that we focus on Windows http://www.ctr.unican.es/win_io/ow_exa From: Frank Piron and only Windows (even though it sucks). mple.html Date: Thu, 07 Oct 2004 08:38:30 +0200 From: Ross Higson input : Subject: Re: A community Windows binding http://www.ctr.unican.es/win_io/iw_exam Newsgroups: comp.lang.ada Subject: Re: A community Windows binding ple.html Our position here at KonAd: Newsgroups: comp.lang.ada Win_IO is composed of the following 1) Every effort which leads to a broader [...] I wish there was a good platform modules: use of Ada should be supported. independent GUI toolset, and I support - Input_Windows: Provides a simple the goals of GtkAda in trying to fill this 2) Building a library or binding which for gap even though I personally find it a bit window with I/O capabilities for data of easy construction of production quality the types Integer, Float, and String. limited and more difficult to use than GUI interfaces on the windows operating GWindows. But I thought we were Several data can be displayed and/or system is an effort in the sense of 1). retrieved on the same window. talking here about a Windows specific 3) Last year we decided to extend binding, and I think GWindows is the - Output_Windows: Provides a simple GWindows because we had to decide right choice for that. It would also help window with Output capabilities for data something (otherwise no money) and promote the use of Ada on the Windows of the types Integer, Float, and String. GWindows was there: free, available, platform because it would be familiar Several data can be displayed on the same easy to use and to extend. territory to any Windows programmers window. who decided to try Ada. 4) Of course we will participate in every - Message_Windows: Provides a simple community effort concerning the further From: Stephen Leake window for displaying a short message. It development of GWindows. provides an OK button for closing the Date: 10 Oct 2004 14:05:57 -0400 window. From: Steve Subject: Re: A community Windows binding Date: Wed, 06 Oct 2004 14:04:04 GMT Newsgroups: comp.lang.ada - Menu_Windows: Provides a simple Subject: Re: A community Windows binding window with several buttons that enable Newsgroups: comp.lang.ada Given the response so far, it is clear there the user to select from a number of is much more support for using options.It is a generic package that must Georg Bauhaus wrote: GWindows as the base of a "community be instantiated with an enumeration type. > I think the point is Windows Windows binding" than CLAW. One button will be created for each value programming, not general GUI in this type. Also, it seems clear that SourceForge is programming. There are things that the platform to use. Using Gnu Arch is - Graphics_Windows: Provides a simple make OSs and GUIs look and feel appealing, but it requires that each window with drawing capabilities, different. In particluar, if your program developer open their machines to outside including the display of picture files. uses Windows specific features, how do access. I'd rather let SourceForge worry you define an interface that uses about the security implications of that. - Plot_Windows: Provides a simple Windows specific features on *BSD/X, window for drawing two-dimensional The other hosts suggested don't seem as say? well supported as SourceForge. graphs from sets of points. How would you define an interface that is capable of being ported to _both_ Before I actually create a SourceForge A community Windows Windows and 8 1/2 (the Plan 9 project, I'd like to get at least one other binding graphical interface)? developer to commit to being a sysadmin on the project. I don't think being From: Stephen Leake IMHO, sysadmin will take much time; it mostly The community Windows binding should consists of setting up accounts for Date: 05 Oct 2004 19:28:03 -0400 not get bogged down in building a system developers. When we get to doing Subject: A community Windows binding that is compatible with other OS or releases, there will be more work, but we Newsgroups: comp.lang.ada windowing systems. can deal with that then. [...] I'd like to step back from the "GWindows I am a strong advocate of Ada. Ada is the From: David Botton vs CLAW" debate and take stock. best general purpose programming Subject: Re: A community Windows binding David Botton has made several points in language I have met to date. I have met Date: Sun, 10 Oct 2004 20:39:31 -0400 favor of using GWindows as the starting several programming languages to date, Newsgroups: comp.lang.ada point for a community Ada binding. He and continue to meet them (C# being the Stephen Leake wrote: latest). has also pointed out the existence of a > Another minor issue is the name of the GWindows user/developer group on the I have come to the realization about project. We want to host GWindows GNAVI mailing list; perhaps those people making the most economic and logical code (no need to change the name of have not been represented in the choices: it doesn't matter. that package). discussions here. When OS/2 was a more stable and I recommend we use the original name of My personal interest is in establishing a uniform OS, the bulk of new development the GWindows/GNATCOM project, ie. community supported Free Software went to Windows and NT, which at the GNAVI Windows Ada binding. I can easily go time was comparatively unstable. OS/2 with either GWindows or CLAW as a was a better choice... it doesn't matter. > Also the Gnatcom code? I'm not clear if starting point. this is available anywhere other than Using Ada is the best choice for much of AdaPower, or if it needs a CVS project. I think the crucial issue is "how many the development done today. It doesn't developers will actually join the project?". matter, development is rarely done in CVS for GNATCOM and GWindows was Ada. I think that's why David Botton has actively maintained by ACT when they I have volunteered to be the first were supporting it for their customers. As sysadmin of a SourceForge project for a

Ada User Journal Volume 25, Number 4, December 2004 188 Ada-related Tools far as I know this is not officially the case Product Binding License/OSes/Install Technologies website any more. Support/Remarks (http://www.mckae.com/xia.html). > And possibly a version of ------Version: 0.10 AdaBindX C/Lesstif GPL* B,L d b Ada.Collections, until they become This current version of XIA is a limited- widely available from vendors. We IntroClaw C/Win32 GPL* W easy free f FullClaw C/Win32 prop W easy com f capability beta release. It implements the should start using that for any axes and the node tests, but does not yet collection needs in GWindows. Or we Glade GTK+ GPL B,L,? d a implement any predicate filtering. So an could just redistribute a .tar.gz of XPath query returns all the nodes meeting Matthew Heaney's current stuff. GtkAda C/GTK+ GPL* B,L,M, S,W d com the node test along the given axes. I think just linking / redistributing GWindows C/Win32 GPL* W Predicate processing will be incrementally Matthew Heaney's current stuff is ideal. JEWL Win32 free W easy added to XIA in subsequent releases, but RAPID c right now any additional node filtering Comparison of GUI libraries TASH Tcl/Tk GPL* B,W, must be done by the XML-enabled for Ada L e application itself. Windex Win32 GPL* W free As this is a beta release, reports of errors From: David Botton Win32 C/Win32 free W (either in operation or in the nodes Date: Sun, 3 Oct 2004 12:32:56 -0400 ------retrieved) would be appreciated. Please Subject: Re: GWindows and David Botton GPL* = GMGPL provide the XML document (or readable Newsgroups: comp.lang.ada (a) visual GUI builder and code generator fragment), the query that was submitted, [Discussing the development of a (gate) for GtkAda and a description of what was expected. (b) binding to Xlib, Xt, and Xm community Windows binding (see above Send bug reports and questions to xia- thread) --su] (motif/lesstif) (c) visual GUI builder [email protected] Stephen Leake wrote: (d) Debian package DOM and SAX parsing in > We should compare Windex, (e) Debian package no longer updated Gwindows, and Claw, and decide (f) visual GUI builder available Ada which one makes the best starting Binding: point. From: Steve Underlying programming language / Date: Tue, 09 Nov 2004 03:14:13 GMT I have a comparison between GWindows library. Subject: Re: DOM and SAX parsing in Ada and CLAW at: License: Newsgroups: comp.lang.ada http://www.adapower.com/gwindows/GW prop=proprietary indowsVsClaw.html Tim Roede wrote: OSes: > There is considerable interest in the Stephen, I would suggest looking at the B = BSD event models in GWindows in particular group I am working with to provide L = Linux XML parsing using both DOM and to see the major reason (in addition to M = MacOS doing what was needed to allow for SAX parsing. Does anyone have a S = Solaris name or a link to a suitable Ada library COM/.Net/ActiveX controls which may W = Windows be the chief reason in the end) why I (similar to xerces)? didn't build off of Windex which is very Install: XML/Ada easy = installs out of the box tightly bound to the Windows way of http://libre.act-europe.fr/xmlada/ doing things. Windex while in general a hard = requires a guru smaller library than GWindows does have Support: Includes a Unicode module, a SAX 2.0 some areas that it is better fleshed out in. free = dedicated volunteer structure e.g. a module, and a DOM 2.0 module. The code is released under the GMGPL. GWindows is also tuned toward the larger maillist (not CLA) project I was working on for a GNU com = commercial support Support is available for a fee from replacement. (GWindows + no = no support (but of course CLA AdaCore. In addition to the platforms GNATCOM + GNAVI IDE). So it is very continues to exist) listed at the Libre site, I have successfully easy to target for a GUI builder based on Append "/doc" if documentation exists used XML/Ada 1.0 with ObjectAda 7.2.2. its dispatching model combined with (free) From: David Botton inheritance. Threads in comp.lang.ada * Newsgroups: comp.lang.ada From: Marius Amado Alves Date: Mon, 8 Nov 2004 19:24:41 -0500 GTK Subject: Re: DOM and SAX parsing in Ada GWindows and David Botton Date: Wed, 06 Oct 2004 19:56:55 +0100 There are 2 XML libs listed here and I Subject: Re: GWindows and David Botton URLs * will be adding another shortly: Newsgroups: comp.lang.ada RAPID See: An update of our little table incorporating ftp://sunsite.informatik.rwth- http://www.adapower.com/index.php?Co the latest contributions. I have also put it aachen.de/pub/mirror/ftp.usafa.af.mil/pub/ mmand=Class&ClassID=AdaLibs in the Universal Casbah wiki at dfcs/carlisle/usafa/rapid/index.html See: The Ada Source Code treasury on http://www.liacc.up.pt/~maa / Casbah / XIA - XPath In Ada http://www.adapower.com for an example Miscellany / GUIs_ of using the Ada/XML DOM (more For_Ada or From: Marc A. Criley examples to follow) http://www.liacc.up.pt/~maa/cgi- Date: Sat, 06 Nov 2004 15:22:19 GMT bin/casbah/casbah.cgi?operation=view&p From: David Botton Subject: Announce: XIA (XPath In Ada) Date: Mon, 8 Nov 2004 19:56:59 -0500 agename=GUIs_For_Ada so that Newsgroups: comp.lang.ada contributions can go there directly. Subject: Re: DOM and SAX parsing in Ada A limited capability beta version of XIA, Newsgroups: comp.lang.ada GUI/Windows products for Ada a native implementation of XPath In Ada, comparison is now available on the Mckae (C) Guys de Cla

Volume 25, Number 4, December 2004 Ada User Journal 190 Ada-related Tools

There are so many XML and Web related Pgada /= Pg2. Nice to know Pg2 is being Detector. This version appears to correct tools for Ada that I broke them now in to used. Let me take the chance make a long the errors that occurred with Version 4.3 their own category, so please see overdue update on this. On 2001 I've under Windows 2000 and XP, but not http://www.adapower.com/reuse replaced Pg2 with Pgsql, for use in the under 9X, ME, and Linux. From: David Botton European project SolEuNet, which ended The Windows binary and source versions Date: Tue, 9 Nov 2004 08:25:32 -0500 2003. I now make Pgsql available, at are Version 4.4. The Linux binary version Subject: Re: DOM and SAX parsing in Ada http://www.liacc.up.pt/~maa/files. remains at Version 4.3, since there is no Newsgroups: comp.lang.ada There's no need to go rushing upgrading difference in appearance or behavior > AdaCL.GCI is missing on "Ada Web your existing Pg2 application to Pgsql. between the two versions under Linux. and XML" But if you're starting a new application, I Mine Detector is available from recommend Pgsql. Not any more. http://home.earthlink.net/~jrcarter010/min Pg2 was in my Adlib site which went det.html Ada Binding to Pipes down around that time. I'll try to set up a new shop soon with all the updated stuff War in Ada (the card game) From: Marc A. Criley as well as an historical copy of Adlib. From: John B. Matthews Date: Tue, 10 Aug 2004 07:58:58 -0500 From: Marius Amado Alves Subject: Re: SSH Sessions? Date: Thu, 23 Sep 2004 03:19:02 GMT Newsgroups: comp.lang.ada Newsgroups: comp.lang.ada Subject: Re: best ada integrated Subject: Re: Ada & Postgresql Adam Ruth wrote: development environment Date: Mon, 06 Sep 2004 12:36:09 +0100 > I'm doing this very thing myself, and Newsgroups: comp.lang.ada GNADE vs. Pgsql. I'm just using the command line version Phil wrote: of ssh. I execute it using the system Pgsql is a simple Ada binding to Postgres. > Hi, I have been out of the ada stuff for a call (the c library system (const char GNADE is a very big [1] Ada library while and are just about to embark on a *command) call). It's pretty encompassing various database systems project to simulate a blackjack card straightforward, since I don't need to do (Postgres, MySQL, etc.) and protocols game using Ada. much that's complicated, just execute a (ODBC). Pick the proper thing for your remote command line program as application. Use Pgsql when you simply [...] though it was being executed on my want to bind to Postgres and don't need You might also be interested in my local command line. ODBC. simulation of war (the card game) in Ada: Just want to reacquaint everyone about Now comparing oranges with oranges, i.e. . Binding to Pipes" GNADE, Gnu.Db.Postgres, vs. Pgsql. (http://www.adapower.com/reuse/pipes.ht As noted, Gnu.Db.Postgres has a leak in Documentation Tools for ml). You can issue a command and all the the connection area. But has controlled Ada Sources output is caught and easily read back in queries that automatically reclaim for post-processing. memory on finalization. Pgsql has no From: Alex R. Mosteo It's incredibly easy to use, effective and leaks per se, but in its current version the reliable, and I use it almost exclusively types are not controlled, so the user has to Date: Thu, 07 Oct 2004 12:40:55 +0200 whenever I need to issue commands from reclaim memory him self. Pick you Subject: Javadoc-like for Ada within an Ada program. Works great, poison. Newsgroups: comp.lang.ada highly, highly recommended. (Thanks However, I think the main difference is in I'm interested in some doc generation tool Jim!) the style of the Ada spec. Unfortunately à-la javadoc; i.e. that not only creates a I'm not able to look at Gnu.Db.Postgres listing like gnathtml but also capable of PGSQL - PostgreSQL right now [2], but from what I recall from extracting explanations from properly Minimal Binding my examination of the landscape some formatted comments in the specification. time ago, which has probably included I've heard good things about doxygen and From: "Alex R. Mosteo" Gnu.Db.Postgres, they are much longer I'm going to review it to see if it's suitable and harder to use than Pgsql. for Ada. Newsgroups: comp.lang.ada Subject: Ada & Postgresql [1] The RPM has 6M, but I don't know Any other options I should consider? what's in it. See note 2. Date: Fri, 03 Sep 2004 19:09:58 +0200 From: Stephane Richard Anyone doing the above? I've found three [2] The Sourceforge site seems to only bindings: provide RPM files. How do I read this in Date: Thu, 07 Oct 2004 11:46:16 GMT my Windows XP laptop? Also, when I Subject: Re: Javadoc-like for Ada Apq, Pgada, Gnade click the version number on the site Newsgroups: comp.lang.ada (hoping to browse the files), I get XML I suppose I could test the three, but has You might want to look at Ada Browse garbage. anyone already done that? I just need to which you can find here do fairly simple insertions. http://home.tiscalinet.ch/t_wolf/tw/ada95/ From: Marius Amado Alves Mine Detector Game 4.4 adabrowse/ From: PragmAda Software Engineering You might also want to look at AdaDoc Newsgroups: comp.lang.ada which you can find here. Subject: Re: Ada & Postgresql Date: Sun, 26 Sep 2004 18:40:31 GMT http://sourceforge.net/projects/adadoc/ Date: Sat, 04 Sep 2004 12:41:09 +0100 Subject: Ann: New release of Mine Detector From: Lionel Draghi >>Pgada for Windows > Is this the pg2-stuff from Mario Amado Newsgroups: comp.lang.ada Date: Tue, 12 Oct 2004 00:53:16 +0200 Alve? If so, I use this[0] ;) [0] PragmAda Software Engineering is proud Subject: Re: Javadoc-like for Ada http://adi.thur.de/?show=adabill to announce Version 4.4 of Mine Newsgroups: comp.lang.ada

Volume 25, Number 4, December 2004 Ada User Journal Ada-related Tools 191 http://www.naturaldocs.org/ does require This is an alpha release, and you can find SCHED_FIFO and SCHED_RR) with neither special tags in the code, nor ASIS. it at http://www.pushface.org/asis2xml/ different type of tasks (aperiodic, Building a doc from your sources, or periodic, task activated with a Poisson whatever file that can be displayed in a Cheddar - Real-Time process law, ...) browser is easy. Scheduling Simulator - Extract information from scheduling NaturalDocs is far from being as good as simulation. (buffer utilization factor, task gnathtml/AdaDoc/AdaBrowse to extract From: Frank Singhoff response times, task missed deadlines, procedure parameters and so on, but as number of pre-emption, ...) this is clearly one of the most Date: 8 Sep 2004 15:05:11 GMT Organization: Universite de Bretagne - Apply feasibility tests on tasks and uninteresting thing to put in a doc, I don't buffers (without scheduling simulation) : care. I can use Emacs or GPS for this kind Occidentale of navigation. Subject: ANN : New release of Cheddar : a + Compute task response time bounds. real time scheduling simulator + Apply processor utilization tests. On the other hand, NaturalDocs is very Newsgroups: comp.lang.ada good at extracting explanations from + Compute bound on buffer size (when comments, and this seems generally much The EA 2215 team is pleased to announce buffers are shared by periodic tasks) more interesting to me. a new release of Cheddar. - Shared resources support (scheduling Cheddar is a free real time scheduling Campaign to get full and blocking time analysis). Supported tool. Cheddar is designed for checking protocols: PIP, PCP. language support in Natural task temporal constraints and buffer sizes Docs of a real time application/system. It can - Tools to express and do also help you for quick prototyping of real simulations/feasibility tests with task precedence: From: Martin Dowie time schedulers. Finally, it can be used for educational purposes. + Schedule tasks according to task Date: Thu, 21 Oct 2004 12:50:04 +0100 Cheddar is developed and maintained by precedence Organization: BAE SYSTEMS the EA 2215 Team, University of Brest. + Compute Tindell end to end response Subject: Re: NaturalDocs - sponsor Ada Cheddar is composed of two independent time. support parts: an editor used to describe a real Newsgroups: comp.lang.ada + Apply Chetto and Blazewicz time application/system, and a algorithms. Martin Dowie wrote: framework. The editor allows you to describe systems composed of several - Tools to run scheduling simulation in > Put your $10 where your mouth is and the case of multiprocessors systems get Ada support at processors which own tasks, shared www.naturaldocs.org resources, buffers and which exchange - Do simulation when tasks are randomly http://www.naturaldocs.org/languages.h messages. The framework includes many activated. tml feasibility tests and simulation tools. - Can run scheduling simulation on user- Feasibility tests can be applied to check Actually, even if you don't want to pay, defined scheduler and task arrival that task response times are met and that patterns. you could consider voting for Ada support buffers have bounded size. When for free! feasibility tests can not be applied, the - Run user-defined analysis on scheduling [At this moment, Ada would be the studied application can be analyzed with simulation. second in the ranking for full support, scheduling and buffer simulations. - ... only behind C/C++ and before languages Cheddar provides a way to quickly define 2) Most of new features provided by like Java, PHP or Python --su] "user-defined schedulers" to model scheduling of ad-hoc applications/systems 1.3p3: ASIS2XML (ex : ARINC 653). - Fix many bugs of the previous release Cheddar is written in Ada. The graphical (see BUGS file) From: Simon Wright editor is made with GtkAda. Cheddar runs - Add a new user interface of the on Solaris, Linux and Win32 boxes and scheduling simulation service. With Date: 24 Oct 2004 08:05:42 +0100 should run on every GNAT/GtkAda 1.3p3, Cheddar provides two different Subject: ANN: ASIS2XML 20041024a supported platforms scheduling simulations: customized or un- Newsgroups: comp.lang.ada The current release is now 1.3p3. If you customized scheduling. ASIS2XML converts a unit's ASIS are a regular Cheddar's user, we strongly + Un-customized simulation draws time representation into XML, so as to make it advice you to switch to the 1.3p3 release line and computes worst case response easier to develop transformational tools due to the large amount of 1.3p2 bugs that time from simulation. This service is using (for example) XSLT. we fixed. called from the "Scheduling Simulation" As supplied, it relies on GNAT; the only Cheddar is distributed under the GNU pixmap. ASIS-for-GNAT feature it relies on is that GPL license. It's a free software, and you + Customized simulation draws time Data_Decomposition.Size has been are welcome to redistribute it under line and can compute many others extended to work for Subtype Indications; certain conditions; See the GNU General measures (eg. Worst/Best/Average cases and that only so that it can work out how Public License for details. Source code, of shared resource blocking and response many bytes a record component will binaries and documentations can be freely time from simulation). occupy when streamed (this part is in downloaded from http://beru.univ- progress) This service is called from the menu brest.fr/~singhoff/cheddar "Tools/Scheduling/Scheduling Not every ASIS feature is supported yet. 1) Summary of features: simulation" (F. Singhoff) There is no XML Schema as yet - Do scheduling simulations with classical - Add a way to display or export event (however, the output's structure follows real time schedulers (Rate Monotonic, tables produced by the scheduling that of ASIS as determined from the Ada Deadline Monotonic, Least Laxity First, simulator engine. Event tables are XML specs -- I'm not at all sure this is the Right Earliest Deadline First, POSIX queuing formatted. An event table is a set of data Thing for an XML representation). policies: SCHED_OTHERS,

Ada User Journal Volume 25, Number 4, December 2004 192 Ada-related Tools which stores a computed scheduling. (F. - Fixing a buggy service which should Date: Wed, 08 Sep 2004 17:29:12 GMT Singhoff) detects deadlock from simulation. Subject: About Visual Ada Developer - Add a way to import event tables - Completing available services on event (VAD). computed by other tools. This service tables. Newsgroups: comp.lang.ada allows you to run analysis on scheduling [See also same topic in AUJ 24-4 (Dec I've been trying to find the author of this produced by , object 2003), p.207. --su] project (in the subject line) to see what's request broker or any applications. (F. going on with the project. The link to the Singhoff). RTLGnat - GNAT Port for project doesn't work right now and I'd like - Add Partitioning tools for RT-Linux to know either where it is, or if it is still multiprocessor systems scheduled with actively developed somewhere. Anyone have any information on this? Rate Monotonic. Several partitioning From: Maurizio Ferracini strategies are provided (RM Best Fit, RM If the author of VAD, Leonid Dulman, Next Fit, RM First Fit, RMGT and Date: 19 Oct 2004 03:21:13 -0700 should happen to read this, please get in RMST) (M. Nivala) Subject: Re: Gnat and priority level touch with me either here or by email - Fix errors on utilization factor feasibility Newsgroups: comp.lang.ada (you should have my email address already :-). And let’s talk. tests. In the previous release, preemptive [Getting more than 32 priorities in EDF and RM tests were applied by error Windows2000 --su] From: Stephane Richard on other schedulers. (H. Martin, S. Bothorel) > You can't (at least easily). Not only the Date: Thu, 09 Sep 2004 12:00:42 GMT GNAT implementation uses just 32 Subject: For those that wondered about - Add user-defined event analyzers. User- priorities, but these are mapped to defined analyzer can be run on a given V.A.D. underlying windows priorities, which Newsgroups: comp.lang.ada scheduling to look for user specific are only 7, if I remember correctly (yes, properties. User-defined event analyzers there's overlapping). Big announcement, lots to read, but I are pieces of user code which scan and do think it's well worth it :-). I'm posting this analysis on event tables. (F. Singhoff) And with a Real-Time Linux version like from a request I got from Leonid himself RT-Linux? [...] - Add user-defined task arrival pattern. he can't post to comp.lang.ada for some This feature should allow us to easily From: Jerome Hugues Visual Ada Developer (VAD) bursty task activation; jitter constraint Date: Tue, 19 Oct 2004 11:50:15 Organization: ENST, France VAD is free software; you can activation, sporadic activation,...) (H. redistribute it and/or modify it under the Huopana, F. Singhoff) Subject: Re: Gnat and priority level Newsgroups: comp.lang.ada terms of the GNU General Public License - Add a simple message scheduling. as published by the Free Software Actually, message scheduling is limited Alex R. Mosteo wrote: Foundation; either version 2 of the with constant communication delay > mferracini wrote: License, or (at your option) any later messages and with sending tasks which Firstly, I think that GNAT doesn't version. VAD is distributed in the hope, send messages at the start of their target the RT capabilities of RT-Linux, that it will be useful, but WITHOUT activation. This service have to be so you'll really have regular non-RT ANY WARRANTY; without even the extended in the next release to be really linux threads. Unless someone has a implied warranty of usefull. (G. Oliva, F. Charlet) patch for it. MERCHANTABILITY or FITNESS - Add a sub-program To detect priority There exists one project on this subject: FOR A PARTICULAR PURPOSE. inversion from scheduling simulation (F. http://bernia.upv.es/rtportal/apps/rtl-gnat/ VAD 6.4 Common description. Singhoff) Note that I've never tried it, so I cannot 1. VAD ( Visual Ada Developer ) is a - Add a C interface to call the framework comment on which GNAT version it uses, Tcl/Tk oriented Ada-95(TCL) GUI from C programs. (F. Singhoff) ACATS results, etc builder portable to difference platforms, - Shared resource states are displayed on > Second, you can choose two threading such as Windows NT/9x, Unix(Linux), the time line. (E. Vilain) implementations with Gnat for Linux: Mac and OS/2. You may use it as IDE for any Ada-95 (C, C++, TCL) project. You 3) Work in progress: linux native threads, whose particularities I don't know but some may use it to build TCL script only. VAD During the next year, we plan to improve Linux expert could tell you (BTW, generated ada sources you may compile the tool with the following features: using the old 2.4 thread and build executable with GNAT in implementation, not the new 2.6 one). Windows and Unix(Linux) or Aonix - Update the user's guide according to the ObjectAda 7.2 in Windows. new 1.3p3 features fsu-threads (I think) which if I remember correctly are POSIX- 2. Used software - Improvement of the buffer analysis compliant or something-else-compliant GNAT 3.15p (3.4.0) Ada-95 compiler features with queuing theory analysis which native Linux's aren't. tools. ftp://cs.nyu.edu/pub/gnat Strict Annex D (real time) compliance. - Provide a way to import/export TCL/TK 8.3.5.1 See http://tcl.activestate.com/software/tcltk/ application specifications in AADL. http://gcc.gnu.org/onlinedocs/gnat_ugn_u - Improvement of message scheduling nw/Choosing-between-Native-and-FSU- TCL/TK 8.4.7.0 with: Threads-Libraries.html http://tcl.activestate.com/software/tcltk/ + Allowing message sending at any for more details TCL/TK 8.5.b2 time of a task capacity http://tcl.activestate.com/software/tcltk/ + Providing a way to user-defined About VAD - Visual Ada W A R N I N G ! VAD 6.4 has three message delay communication by Developer realization for tcl/tk8.3.5, tcl/tk 8.4.6 and specification of user-defined message tcl/tk 8.5x , you need to install and to scheduling (as user-defined scheduler) From: Stephane Richard check tcl/tk before using of VAD.

Volume 25, Number 4, December 2004 Ada User Journal Ada-related Products 193

[For a complete (and long) list of used OSX/ components and a description of the [...] Ada-related Products program files, see the original posting Well, several of the contributors, posting from Stephane Richard at comp.lang.ada in this thread, have been using Ada on AdaCore - Ada Answers --su] Mac since 1994. The present incarnation From: Ed Falis In WEB Browser you may run VAD for Mac OS X does indeed run with Date: Tue, 26 Oct 2004 21:28:01 GMT Tutorial from vad/tutorial/vadtutor.htm , as shown on Dr. Miller's site Subject: Ada Answers VAD 6.4 is available in above. The integration is excellent: edit, Newsgroups: comp.lang.ada http://www.websamba.com/GUIBUILDE compile, debug, step, trace, breakpoint, R profile - all from the GUI. I also use www.ada-answers.com launches! You may dowload sources gnatmake from the command line As the need for robust and reliable vad64scr.tar.bz2, vadhlp.tar.bz2, regularly. [...] software systems increases, Ada vadtutor.tar.bz2, continues to prove to be an excellent vadsmp.tar.bz2,vadaonix, adahlp.tar.bz2, Auto_Text_IO & SAL answer for many of today's most complex vadtcl.tar.bz2, programming challenges. "Ada Answers" From: Stephen Leake adastyle.tar.bz2,philosofers.tar.bz2,vadidl. is dedicated to keeping developers and tar.bz2 and binaries vad64win.tar.bz2 project managers informed about Ada and Date: 07 Aug 2004 12:22:56 -0400 (Windows 9x/NT) vad64lin.tar.bz2 (i386) showcasing the particular strengths and Subject: new SAL, Auto_Text_IO releases benefits of this extremely powerful Any questions, any ideas, any problems, Newsgroups: comp.lang.ada programming language. "Ada Answers" is any help Leonid SAL version 1.70 is released. part of AdaCore's ongoing commitment to Dulman([email protected]) promote the qualities of the Ada Auto_Text_IO 3.03 is released. [See also "VAD 6.2 - Visual Ada programming language. Developer" in AUJ 24-4 (Dec 2003), SAL is my Ada library; it has containers, Features of the new site include: pp.204-205. --su] spacecraft math, config files, other misc stuff. New in this release is a small - Real world examples of Ada in use, IDE for Ada on Mac OS X collection of GtkAda widgets, some of including a comprehensive list of which work :). More importantly, there is companies and organizations that are From: Stephane Richard a test harness for automating GUI tests. using Ada everyday. Also misc fixes in other SAL packages. - A growing collection of video Date: Sat, 30 Oct 2004 02:43:44 GMT Auto_Text_IO is an ASIS-based tool that interviews in which developers and Subject: Re: IDE for Ada on Mac OS X? generates Text_IO packages for types in managers speak about why they have Newsgroups: comp.lang.ada Ada packages; very useful for persistent chosen Ada. Christopher J. Henrich wrote: storage. New in this release are support - Technical features of the Ada > What integrated development for Standard.Duration, programming language are explained, environments that run on Mac OS X Standard.Character, misc other fixes. showing how they translate into bottom- 10.can handle Ada? Does such a thing For full information, and to download the line business benefits. exist? latest versions, see my web page - A section dedicated to the wide range of http://macada.org/ is probably the best http://www.toadmail.com/~ada_wizard/ up-to-date Ada materials and resources place to start your search. Not sure if [See also same topic in AUJ 25-3 (Sep available on the web. there's an IDE right there but there's one 2004), p.119. --su] AdaCore is always looking for interesting on the main picture so perhaps there they and innovative Ada stories. Please contact could help you find a Mac IDE. XAda - A Simple OS in Ada us with yours. We plan to produce videos From: James E. Hopper of some of the stories, but all contributors From: xavier whose story is published will receive a Date: Wed, 25 Aug 2004 13:46:35 +0200 Date: Sun, 31 Oct 2004 01:42:47 GMT stylish Ada Answers T-shirt! Subject: [annonce] XAda un os simple en Subject: Re: IDE for Ada on Mac OS X? Ada Newsgroups: comp.lang.ada AdaCore - GPS 2.1.0 Newsgroups: fr.comp.lang.ada In addition to Apple’s Xcode (which [Translated from French – su] AdaCore is pleased to announce the works very nicely with Ada) both immediate release of GPS 2.1.0 Codeforge and VisualSlickEdit works on I have started to adapt to Ada the series of OS X and supports Ada. Oh, and of articles on the Linux Magazine « Do it GPS, the GNAT Programming System, is course Ada mode in emacs is also yourself » and this has given rise to XAda an advanced IDE that streamlines your supported on OS X. (short for uniXAda). software development process - from the initial coding stage through testing, CodeForge XAda is a utility built for acquainting debugging/verification and maintenance. http://www.codeforge.com/products/ oneself with the internals of a kernel and Designed by programmers for for building them in Ada. This exercise VisualSlickEdit programmers, GPS is an IDE that offers has already provided [me] with contracts http://www.slickedit.com/purchase/pu_re the experience of designing software in a for a more substantial and longer-term gtrial.php. uniquely comfortable environment. project: “Lovelace” a UNIX written in From: John B. Matthews Ada, which natively provides the Ada The 2.1.0 version is a major release and runtime (among other initial objectives). features many improvements, notably: Date: Tue, 02 Nov 2004 14:38:44 GMT Should that be of your interest: - Improved customization, in particular: Subject: Re: IDE for Ada on Mac OS X? http://ipnnarval.in2p3.fr/~xavier/ Newsgroups: comp.lang.ada + Extended python support All sorts of contributions and comments Marius Amado Alves wrote: + Ability to define new project are most welcome. attributes > According to this you can use Xcode: http://pyrite.truman.edu/~millerj/Adaon

Ada User Journal Volume 25, Number 4, December 2004 194 Ada-related Products

+ New commands for accessing GPS such a wealth of third-party tools already restrictions on future work. Thousands of internals and manipulating integrated through a universal platform." lines of FORTRAN code, migrated to C, menus/toolbars AonixADT provides Ada-project can also generate substantial cost savings Emacs compatibility mode awareness, an Ada-language sensitive in reuse - with no shortage of experienced programmers. Why waste resources and New help menus editor, Ada-language compile and build capabilities, along with a complete Ada time discovering old tool limitations? C/C++ improvements debugger interface. ADT project Process improvements realized using awareness allows full library hierarchy modern development tools and languages + Better integrated multi-language consistently reach straight to the bottom build/link manipulation and Ada program units can be conveniently inserted or removed from line. + More powerful indentation Ada projects. The language-sensitive Positioning programs with five, ten and GPS is available on an ever-growing editor provides complete language twenty year lifecycles for the future also number of platforms including: awareness with syntax color coding and requires replacement of obsolete target Solaris SPARC template completion. Symbolic debugging hardware. While past custom solutions GNU/Linux x86 is integrated within the Ada-language were prohibitively expensive to develop Windows (NT, 2000, XP) sensitive editor. The build interface offers and unsuitable for mass production, Tru64 complete access to the Aonix ObjectAda today's COTS solutions frequently meet HP-UX compile and build capabilities. project requirements at a fraction of the IRIX This first release of AonixADT supports cost of in-house development. self-hosted development for the Windows Offering a full spectrum of consulting, Aonix - Eclipse-based Ada platform. Support for Solaris and Linux training and support services, individually IDE for Mission- and Safety- development and cross compilation for priced and shaped to help customers with key embedded platforms will be complex applications achieve project Critical Development announced subsequently. goals on-time and on-budget, DDC-I possesses broad knowledge and hands-on AonixADT opens Ada developers to a Shipping and Availability expertise in every part of the gamut of third-party tools AonixADT is available for free with application/development/certification and San Diego, CA, Paris, France, July 26, Aonix products. To purchase AonixADT migration process. 2004 stand-alone, the package is available at $995 per seat. DDC-I's Migration Assessment Package Aonix®, an independent global company begins with on-site migration needs delivering complete solutions for safety- DDC-I - Comprehensive assessment and and mission-critical applications, is application/data/infrastructure evaluation pleased to announce the Beta release of Migration Assessment culminating in a complete migration AonixADT - an Eclipse-based Integrated Packages assessment report. Once the assessment is Development Environment (IDE) for the complete, the customer can make an Ada language. Because Eclipse offers a A Valuable Resource for Migrating informed choice of how to move forward. common platform for which many Legacy Systems to Current Technology They can also choose to do the work companies have developed plug-ins, Phoenix, AZ - Aug 2, 2004 - Experienced themselves, or let DDC-I handle it for Aonix has extended the wealth of embedded system software development them. interoperable technologies and tool tools provider and safety-critical, real- flexibility available to Ada developers by time industry leader DDC-I today DDC-I - WEB based ensuring that AonixADT (Ada announced the availability of project- customer support: "Web Development Toolkit) builds on such a specific Migration Assessment Packages Pass" Atlas Support universal platform. for current programs facing the daunting In the mission- and safety-critical market, task of stewarding valuable legacy code Secure, Personalized Customer Service developers come from a number of into the future. Through a thorough Portal Provides Highly Targeted industry sectors, each carrying its own assessment of difficulty, cost and a Customer Information and Direct Access certification standards and specialized project timeline for migration to modern to Developer Knowledge tools. By delivering the power of the technology, DDC-I can design and standard Eclipse IDE with Ada implement a custom-tailored package for Phoenix, AZ - Aug 3, 2004 - Software programming language awareness, Aonix each program's needs. developers designing and maintaining provides developers with built-in support safety-critical embedded system software "Migrating legacy systems to current require powerful tools demanding for the project manager, editor, difference technology requires careful planning and capability, compile, debug, and command powerful support. Already providing a support. Whether the situation demands robust back-line for DDC-I's complete history. Developers can focus on building legacy system upgrades, application applications, not on integrating tools since range of programming tools, their flexible retargeting, rehosting or language Atlas Support package now provides AonixADT also retains a large set of migration, DDC-I brings over twenty existing plug-ins for third-party tools, personalized access for maintenance years of embedded system software customers via a password-protected web including support for source-code development experience to every project," configuration management. portal with a dramatically expanded list of explains David Mosley, DDC-I features. "Aonix is committed to providing the Engineering Manager and Product mission- and safety-critical developer Champion for the SCORE® IDE. "Web Pass is designed to extend the reach with an integrated, flexible tool chain," and responsiveness of the DDC-I support According to Mosley, development tools department, providing Atlas members a noted Greg Gicca, Director of Product on outdated hosts can be migrated to Marketing, Ada Products, "Notably, the technical database to solve problems and newer technology and can drastically a direct line to the right person in release of AonixADT celebrates two first- improve productivity and future time achievements - it's the first Eclipse- engineering as soon as they need one," flexibility. For example, SCORE® from explains David Mosley, DDC-I based Ada IDE and marks the first time DDC-I can instantly offer multi-language, that Ada developers have been offered Engineering Manager and SCORE® multi-target capability, placing fewer Product Champion.

Volume 25, Number 4, December 2004 Ada User Journal Ada-related Products 195

The expanded library of product-specific Improvements to TADS-1750A Run- SPARK Ada is a language specifically FAQ files, white papers and technical tips Time System include: more reliable designed to support the development of in the new Web Pass area are joined by handling of very rapid interrupt sequences software used in high integrity web-based issue submission and t racking from peripheral hardware; more reliable applications. As an annotated and and STR tracking features. Via Atlas, handling of critical timing delays in semantically rigorous subset of Ada, project leaders and pre-assigned staff gain multitasking configurations; and assured SPARK exploits the strengths of Ada direct access to DDC-I's lead product protection of critical code sections from while eliminating potential ambiguities. developers - "Product Champions" - interrupts under all memory model These properties, which include rigorous experienced engineers directly configurations. definition, simple semantics, security, responsible for fielding technical Version 6.1.1 also adds specific optional expressive power, verifiability and questions or product-specific problems. Ada 95 extensions to the Ada 83 bounded resource requirements, allow Already serving a "who's who" clientele compiler, and linker improvements for SPARK, in both its '83 and '95 variants, to distributed across the safety-critical, real- more reliable handling of memory meet all the requirements for software time embedded systems software allocation by application programs. Also, used in critical systems as well as industry, DDC-I's Atlas Support program effective with TADS v6.0, the AdaTrak facilitating exceptionally deep and offers flexible support options to suit the Profiler is no longer offered, though efficient forms of analysis. changing needs of customer programs AdaTrak support for previous TADS With this integration, Rhapsody users are throughout the lifecycle, from versions is naturally still available. now able to introduce and fully integrate development to maintenance. As a Pre-packaged and custom-built safety critical elements very early on into software development partner, DDC-I engineering services are designed to help their design process. Pre- and post- offers a full range of services designed to customers maximize program conditions can now be captured as part of help maximize productivity at any stage productivity at any stage in the a UML design, further augmented to of the development cycle. development cycle -- installation and reference proof functions that are tested Atlas Premium offers special attention training with full user documentation, through the SPARK Examiner. In effect, during critical stages of development, as basic hot-line support and additional high- designers can "think SPARK" while software architecture is established and level engineering services, full program simultaneously taking advantage of the prototyping takes place, when immediate consultation, and custom software benefits that UML Model-Driven customer support response can make or development to specialized requirements. Development (MDD) provide. break a project. Atlas Advantage suits Leveraging extensive experience, DDC-I Following are the key components of the customers past the critical project path, specializes in migration support services, integration between Rhapsody in Ada and often entering implementation, when particularly in the initial assessment the SPARK Examiner: timely service and regular version phase. Complete SPARK Profile: Rhapsody in upgrades are essential. Atlas Choice "Keeping TADS performance and support Ada provides the system modeller with a members custom-build a service package at the highest level demonstrates DDC-I's UML profile specific for SPARK. This combining options to best fit their commitment to their customers, while profile allows for an intuitive and highly maintenance and migration needs. ongoing market demand and Ada's visible method of modelling and advantages in code reliability, reusability, communicating any SPARK design. DDC-I - TADS 1750A readability, and portability continue to Rhapsody in Ada then fully generates the Solaris Development System prove the superiority of TADS for real- SPARK source code and complete Upgrade time embedded system developers in SPARK annotations including aerospace, avionics and defence - or any preconditions, post-conditions, and proof TADS Ada Development System for safety- critical application where failure is functions. Additionally, Rhapsody in Ada 1750A Processors not an option," Blum concludes. offers the flexibility and control of directly capturing the SPARK Phoenix, AZ - Aug, 31 2004 - DDC-I annotations, thus providing the end user today announces the availability of the I-Logix - UML Model- with an entry mechanism that best fits maintenance upgrade release of Driven Development Now their working style. Sun/Solaris® hosted TADS-1750A Ada Available For SPARK Ada Development System (v6.1.1) adding Applications Seamless integration: Rhapsody in Ada additional run-time, linker and compiler works seamlessly with SPARK Examiner improvements to the full complement of Rhapsody in Ada Now Offers Rules from Praxis Critical Systems. From upgrades integrated during the recent Based SPARK Ada Code Generation Rhapsody in Ada, the modeller can TADS rehost to PC/Windows® (v6.0). From UML Designs and Integration With invoke the Examiner to verify the conformance of the model with the "Responding to client needs by the SPARK Examiner. SPARK rules, perform data and flow consistently upgrading the tools our September 29, 2004 - Embedded systems analysis, and verify the proof contexts. clients' programs require for success is a and software solutions provider I-Logix SPARK Examiner results are displayed primary focus of DDC-I's 'Customer Care' and leading SPARK analysis tool within Rhapsody in Ada, and a double- philosophy," explains DDC-I Senior developer Praxis Critical Systems, click on an error or warning will bring the Software Engineer and TADS Product announced today a new capability to I- modeller to the appropriate portion of the Champion Harold "Bud" Blum. "A wide Logix' UML Model-Driven Development design, increasing workflow efficiency. range of programs depend on TADS for (MDD) product, Rhapsody that facilitates safety-critical embedded system the development of fully SPARK Fine-tuned control: Rhapsody in Ada development, alongside DDC-I's flexible compliant Ada applications. A joint allows the modeller to work incrementally customer support and engineering development effort between I-Logix and on any SPARK design. The modeller has services." Praxis Critical Systems now enables the full control over the model elements and the level of examination to be performed A mature software development solution, generation of SPARK Ada code directly by the Examiner. The design can begin TADS generates the most compact code from UML models. This capability is with no examination, and then have available via the highly optimizing especially valuable for safety critical and certain model elements examined for data compiler, selective linking, modular run- other high integrity applications, where flow, followed by a full information flow time systems and an unsurpassed toolset. SPARK Ada is the language of choice. analysis.

Ada User Journal Volume 25, Number 4, December 2004 196 Ada and CORBA

The user has the choice to examine each Systems, The Civil Aviation Authority, When the layout of data items change, model element individually, or a group of The Federal Aviation Administration and rescanning automatically picks up the model elements at once, or the entire National Air Traffic Services. The changes. model. This enables an incremental, Company's roots are in the application of DTraq requires GNAT 3.15p due to its iterative and flexible design process that sound engineering principles to the reliance on the Ada Semantic Interface is consistent with the recommended development of high-integrity software Specification (ASIS) and has been workflow for SPARK while being driven systems whether safety-, business- or validated on Red Hat 9 Linux. directly by the model. security-critical. Its unique tools and Source and executables are available on Customizable SPARK Source Code products have evolved from practical experience in the most effective the DTraq home page: Generation: Rhapsody in Ada offers a http://www.mckae.com/dtraq.html, along rules-based source code generator approaches to developing such systems. The Company has now diversified into with the comprehensive and up-to-date allowing the customer total control over user manual -- every aspect of the model-to-code several new markets including financial services, telecommunications, utilities and http://www.mckae.com/dtq_common/DTr transformation. From modifications of the aq.pdf. SPARK profile itself to changes in the automotive. For more information, please generated source and annotations, visit www.praxis-cs.co.uk. DTraq usage is described, and screenshots Rhapsody maintains a seamless About I-Logix: Founded in 1987, I-Logix provided, starting at integration for the system developer. is a leading provider of Model-Driven http://www.mckae.com/dtq_usage/tapping .html. "We are very pleased to see the Development (MDD) solutions for comprehensive capability offered by systems design through software Updates to DTraq 0.986 (versus 0.985): Rhapsody in Ada extended to support the development focused on real-time embedded applications. These solutions - Improved the handling of data tap SPARK language. The editable rules Suspension, particularly in situations feature provides for a well-integrated allow engineers to graphically model the behaviour and functionality of their where tapped data is being received UML environment where designers can sporadically. leverage the process benefits offered by embedded systems, analyze and validate SPARK Ada very early on in the the system, and automatically generate - Reevaluated the generation of development process," said Rod production quality code in a variety of informative messages to reduce text Chapman, SPARK Product Manager of languages. I-Logix also offers iNotion®, a clutter. Praxis Critical Systems. "Additionally, product lifecycle management portal the generated code can be easily and designed for software; coupling product Ada and CORBA iteratively analyzed through the SPARK development, quality assurance, Examiner. The result is a powerful marketing and the customer by providing Windows Support of integration of SPARK and UML, instant, controllable, web-based access to GLADE generating SPARK compliant code from development artifacts and product UML models that is readable, testable and management services 24/7 worldwide. From: Pascal Obry deployable. This combination of For more information, please visit our Date: 14 Sep 2004 22:43:27 +0200 individually leading technologies website www.ilogix.com. Subject: Re: GNAT and GLADE provides much more than the sum of its Newsgroups: comp.lang.ada parts." McKae Technologies - DTraq Tom Bolick wrote: "We are very excited about extending our > GNAT is cross platform, and seems to UML based design environment to the From: Marc A. Criley work fairly well on Windows, can SPARK Ada community," said Neeraj Date: Mon, 11 Oct 2004 08:03:03 -0500 GLADE work on windows? (We want Chandra, I-Logix Senior Vice President of Subject: ANN: DTraq 0.986 is available the option of running on one machine Marketing and Corporate Development. Newsgroups: comp.lang.ada in Windows or multiple machines in "Designers using SPARK Ada are now Linux). There will always be one able to leverage powerful capabilities McKae Technologies announces the release of version 0.986 of DTraq, an Ada machine in Windows for the User such as visual modelling with UML 2.0, Interface. visual execution and debugging, both on 95 data logging and review tool. host and target, and flexible, rules based DTraq is a data logging and playback Yes, GLADE works perfectly well on automatic application generation. This debugging tool providing near realtime Windows. Also it is possible to have new capability allows users to design data logging and analysis to aid partitions on different computers some on even larger systems at a reduced cost and debugging and validation. Captured, or GNU/Linux, some on Solaris and others higher quality. Combining the benefits of 'tapped' data from a program can be on Windows. All those partitions will be UML with Praxis Critical Systems' viewed live while the program is running able to talk to each others without trouble. excellent SPARK analysis tools lead to a or, since it is being logged to a file, > We'd like to test on one machine and significantly higher level of reliability, played back or printed out later for off- then scale up, does GLADE do this? (It safety and security as well." line review and analysis. looks like it does this very well.) For more information on any of the DTraq differs from other logging and Yes. company's embedded software products, playback tools in that no data layout maps > What do I need to use GLADE? please feel free to contact us. or byte interpretations or "data dumpers" About Praxis: Praxis Critical Systems has need to be manually created. Nor is the Well, GLADE obviously :) And GNAT of developed a global reputation in the fields application responsible for converting the course. of systems and requirements engineering, raw binary data to text form before software development, safety assurance, logging it. DTraq handles all conversion information security and risk management automatically by scanning the and works with some of the leading application's source code, identifying aerospace companies and other tapped data items, and extracting the organisations including; Boeing, information it needs to properly convert Lockheed Martin, BAE Systems, and display the logged items-simple ALSTOM Transport, Westinghouse Rail scalar items as well as arrays and records.

Volume 25, Number 4, December 2004 Ada User Journal Ada and Microsoft 197

From: Pascal Obry COM/COM+/DCOM/Active X binding Did you notice the following on the A# Date: 16 Sep 2004 20:50:06 +0200 has been updated to GNATCOM 1.4a. website? Subject: Re: GNAT and GLADE This release incorporates extensive "Negotiations are in progress with Newsgroups: comp.lang.ada support of directly embedding and Microsoft to include Ada in Visual Studio Tom Bolick wrote: controling ActiveX controls for .NET" GWindows based applications. > That all sounds great. So how do I get I personally would love to see this started with GLADE under windows? Thanks to GNATCOM, the Ada 95 happen. I think it would greatly increase Do I have to recompile it? COM/DCOM/COM+ Development the use of Ada. I'd also like to see the A# Framework and Tools open every facet of Yes, I think so. This is not trivial but it is project ported to *nix so that it could run the Windows platforms to Ada 95 on the Mono and Portable DotNet. I think not something very hard either. Download development. Never again will the cries GNAT 3.15p binary package and the this would fill a big void in using Ada for be heard, "but there are no bindings" on desktop applications. Namely, the lack of GLADE 3.15p sources from the Windows platform! http://libre.act-europe.fr/. application frameworks and support GWindows is being made available under libraries. Ada and GNU/Linux the GNAT modified GNU GPL used by From: Stephane Richard GNAT's runtime library making it A# for Mono availble for use in both GPL and Date: Fri, 10 Sep 2004 12:07:46 GMT proprietary applications. Subject: Re: Microsoft & Ada ??? From: David Botton For more information on GNATCOM, to Newsgroups: comp.lang.ada Date: Thu, 14 Oct 2004 20:01:12 -0400 view the on-line documentation, and to Yeah I noticed it (though quite recently) I Subject: A# for Mono / Linux download the product, please visit don't think it's been there that long. I Newsgroups: comp.lang.ada http://www.gnavi.org/gnatcom think you're right, if this was to happen, it Martin Carlisle has been able to confirm More information on GWindows can be would be a good boost for Ada. I think that the A# compiler (Martin's DotNet / found at http://www.gnavi.org/gwindows there's many other possibilities with GNAT compiler) will compile under Microsoft too that could play a big role Linux. Microsoft & Ada for Ada aside A# too :-)....so I think it's all good :-). (See: From: Stephane Richard From: Pascal Obry http://www.usafa.af.mil/dfcs/bios/mcc_ht Date: 12 Sep 2004 09:56:38 +0200 ml/a_sharp.html ) Date: Tue, 07 Sep 2004 01:03:23 GMT Subject: Re: Microsoft & Ada Subject: Re: Microsoft & Ada ??? It is possible to create A# applications Newsgroups: comp.lang.ada that run under Windows, Linux and Mac Newsgroups: comp.lang.ada Ludovic Brenta wrote: OS X using martins compiler be it on Stephen Thompson wrote: Windows, Linux, Mac OS X or whatever, > I would be happy if Microsoft provided > Couldn't help but notice that MS is a since on Linux and Mac OS X, Mono, the an Ada compiler, provided that this is platinum sponsor of SigAda 2004. GNU DotNET implementation is really an Ada compiler (as defined by As far as I know this is the first time available. the standard) and not a compiler for a this has happened. different language. If they call this The current version of Mono comes with What can we read into this ???. Gtk+.NET and therefore it is possible to different language "Ada" or "Microsoft write GUI applications that run on That is interesting, Visual Ada", we're in trouble. Windows and Linux using A#. A# For Ada and for Microsoft too I would Visual C++ is just this: a different automatically generates the Ada bindings say. I don't think they would sponsor if language, and C++ is far from being in needed from .NET / Mono components. It they didn't think there was something trouble... I would love to see Ada in the is possible to also use Windows.Forms on there for them, maybe, but I don't think so same level of troubles ! As I said earlier Windows which is also being ported to :-). Microsoft Visual Ada Anyone? ;-) Microsoft Visual Ada will be a good way Linux and Mac OS X for cross platform to introduce Ada in some projects... even GUI with native look and feel. But hey, if Microsoft is sponsoring, I think it's great for both worlds :-). if you stick to Ada not the Visual version He doesn't have ready access to Linux of it coming from Microsoft :) From: Stephane Richard machines to maintain the port of the A# From: Ben Brosgol compiler for Linux, but would be happy Date: Tue, 07 Sep 2004 02:39:03 GMT to work with some one interested in doing Date: Mon, 06 Sep 2004 23:39:37 so. Subject: Re: Microsoft & Ada ??? Newsgroups: comp.lang.ada Subject: Re: Microsoft & Ada ??? If you can, please contact him at Newsgroups: comp.lang.ada Frank J. Lhota wrote: [email protected] Rick Conn from Microsoft is the local > I recall that MS looked into developing arrangements chair for SIGAda 2004, and such a compiler, but decided not to go he has done an excellent job in getting his Ada and Microsoft forward with it. company's support for the conference Yep that's the way I remember it too. (and also in publicizing the event to local GNATCOM - companies and colleges). Microsoft's So then, either they're thinking of hitting platinum sponsorship is one example of COM/COM+/DCOM/Active the Ada market and/or (probably both :-) Rick's success, but alas it should not be X for Ada 95 See what they can do with that A# read as evidence of a sudden language project? From: David Botton transition within the company :-) Date: Sun, 24 Oct 2004 15:47:31 -0400 From: Jeff Subject: ANN: GNATCOM 1.4a Released Date: 10 Sep 2004 00:48:26 -0700 Newsgroups: comp.lang.ada Subject: Re: Microsoft & Ada ??? Newsgroups: comp.lang.ada GNATCOM, the Professional Open Source Ada 95

Ada User Journal Volume 25, Number 4, December 2004 Ada Inside 199

Great article of Jack Ganssle in To: 14D September 2004 Online News US References to Embedded Systems Programming" September 2004 pages 54-56 "Codifying DDC-I Online News. September 2004, Publications Good Software Design" Volume 5, Number 9 - Ada Article at ACM Queue exciting [http://www.ddci.com/news_vol5num9.sh thoroughly investigated tml] A monthly news update dedicated to DDC-I customers & registered From: Rom Moran compliment Date: Sun, 10 Oct 2004 17:51:02 GMT subscribers. Subject: ACM Queue Ada article http://www.embedded.com/showArticle.j Employee Experience Defines #1 in Newsgroups: comp.lang.ada html?articleID=26806185 Customer Care. Success a Direct Result "There's Still Some Life Left in Ada", From: Jeff Creem of Talented Staff and No-Nonsense Alexander Wolfe, ACM Queue Oct 2004 Date: Sat, 04 Sep 2004 14:00:30 GMT Customer Care Philosophy Subject: Embedded Systems Programming Maintenance Upgrade for TADS-1750A. IEEE Spectrum mentions Magazine - Ada Mention Adds Additional Run-time, Linker, and Ada Newsgroups: comp.lang.ada Compiler Improvements Embedded Systems Programming Thoughts from Thorkil - TADS Ada From: Marc A. Criley September 2004, page 56 in article Static Dumper. Helpful Tool Offers Info Date: Thu, 16 Sep 2004 08:11:36 -0500 "Codifying Good Software Design" About Variables, Constants, Packages, Subject: Crash proof software -- when it makes a very brief Ada mention: Tasks & Subprograms HAS to fly! Newsgroups: comp.lang.ada "Just as certain software technologies lead Self-Organizing Teams. An Innovative to better code (for instance, C code is Approach for Any Team Situation IEEE Spectrum Online has as their generally at least an order of magnitude From: jc weekly Feature Article "Crashproof buggier than code written in Ada), the Code", "Flying an experimental Date: Fri, 01 Oct 2004 12:53:53 -0700 technology of fireproofing was well (MST) supersonic aircraft requires rock-solid understood long before ordinances flight software ". To: 17D October 2004 Online News US required their use." It's an interesting article, with the Ada [...] Organization: DDC-I code getting a couple mentions. Subject: Real-Time Industry Updates - News http://www.spectrum.ieee.org/WEBONL DDC-I Online News from DDC-I Y/publicfeature/sep04/0904air.html DDC-I Online News. October 2004, [Extracts from the table of contents. See Volume 5, Number 10 - Ada at the Embedded elsewhere in this news section for selected [http://www.ddci.com/news_vol5num10.s Systems Conference items. -- su] html] A monthly news update dedicated From: jc to DDC-I customers & registered From: Jim Gurtner Date: Tue, 3 Aug 2004 17:22:34 -0700 subscribers. (MST) DDC-I "SCORE's" Experienced Italian Date: Thu, 16 Sep 2004 23:57:09 GMT Organization: DDC-I Distributor. DDC-I tools now available Subject: Embedded Keynote Speaker Subject: Real-Time Industry Updates - News through ARTiSAN Software Tools (Srl) Mentions Ada from DDC-I new Milan sales and service facility. Newsgroups: comp.lang.ada To: 7D August 2004 Online News US Migration Assessment ... A Big Hit: Is this an Ada put down? Enthusiastic response reveals many Dan Saks said in a keynote speech at DDC-I Online News, August 2004, customers looking into legacy upgrades. Volume 5, Number 8 - Embedded Systems Conference in Boston Thoughts from Thorkil - Exception on Tuesday (Sept. 14): [http://www.ddci.com/news_vol5num8.sh tml] A monthly news update dedicated to Handling (2): SCORE's approach to "In embedded programming, learning a DDC-I customers & registered exception handling less-popular language like Ada or Eiffel is subscribers. It's A Relationship, Not A Sale: As a critical not so much because it is a Migration Assessment Packages Now customer, we want someone who cares marketable skill but because it helps and will take action! programmers see what is possible with Available! An assessment of difficulty, more mainstream languages like C, C++ cost & timeline for migrating legacy or Java." systems to modern technology Ada Inside Full article at: Web Based Customer Support - Announcing the New & Improved. Atlas Indirect Information on Ada http://www.embedded.com/showArticle.j Web Pass. Personalized portal provides html?articleID=47208416 highly targeted customer info & direct Usage access to developer knowledge Mention of Ada at [Extracts from and translations of job-ads Thoughts from Thorkil: Exception and other postings illustrating Ada usage Embedded Systems Handling (1) around the world. -- su] Programming Magazine We're All in This Together: Practical, URL: http://www.adaic.com/jobs/ From: Peter Hermann down-to-earth ways to help us all work Date: September 15, 2004 at 18:00:00 and play well together Subject: Ada Software Engineer Date: Fri, 24 Sep 2004 16:45:01 +0000 From: jc Job Description: UTC Date: Wed, 1 Sep 2004 17:09:59 The job will include development of new, Subject: fire Organization: DDC-I and modification of existing, system Newsgroups: comp.lang.ada Subject: Real-Time Industry Updates - News from DDC-I software and support software components.

Ada User Journal Volume 25, Number 4, December 2004 200 Ada in Context

Software engineers will work through the > Hm. It could be - but just why you understand the advantages of each tool in entire software development life cycle should want to declare something as, different circumstances. from requirements analysis and through say, short, if it isn't necessary? If int or I personally like Smalltalk. I like, but am integration, test and delivery. long fit all your situations, just declare not proficient in Lisp. I have seen enough An object-oriented based, open everything as int or long. successful software in both languages to architecture with integrated COTS 1) In languages that support automatic have respect for both the developers and applications are applied in the type promotion, one is always at risk. the languages. At least one Smalltalk development of new system software. 2) Type casting needs to be more aficionado of my acquaintance is smart Opportunities exist in several domains disciplined in some of those languages. enough to understand that Smalltalk has its limitations for certain classes of from device drivers, network 3) When I declare a type, with a given communications, infrastructure, problems. I readily admit that Ada may bounds, it allows the compiler to check not always be the right solution. Of application development, tools, whether I any objects of that type, when simulations, and GUI. course, I continue to believe that there is used within my program, are likely to be no situation where I would deliberately Education: out of bounds (above or below the given choose C++, so I guess I am a bit Bachelors degree in Electrical range). For example, (in Ada) inflexible in that regard. That is, if I have Engineering, Computer Engineering, type T1 is range -473 .. 451; a choice of Ada versus C++, I would Computer Science, Mathematics, or type T2 is digits 7 almost always choose Ada. On the other related field and minimum 5 years of range -30_000.0 ... 100_000.0; hand, if there were choice between Ada software development experience strongly type Unsigned_Small_Integer is and Smalltalk, Ada and Eiffel, Smalltalk preferred. mod 256; and Lisp, Perl and Eiffel, etc., I would want to evaluate the context, the Required Skills: for Unsigned_Small_Integer'Size use 8; circumstances, the architecture, and many Software development experience in other considerations before making a several of the following areas is preferred: I could give many more examples decision. Does that not seem a sensible Ada, Ada-95, UNIX, C++, C, GUI some of which would illustrate the ability approach? design, UML, and Object Oriented to create types of quite sophisticated properties. From: Richard Riehle Methodology. Knowledge of, Solaris architecture and In type T1, I have defined a type with a Date: Thu, 19 Aug 2004 00:37:08 GMT near-real-time asynchronous operations is given upper and lower bounds. The Subject: Re: Static vs. Dynamic typing (big desirable for most positions. compiler can use this information. Also, advantage or not)---WAS: every Ada program sits on top of a small A minimum of 5 years of software c.programming: OOP and memory run-time executive. The RTE is tiny, but management engineering experience, is strongly it does its job well. When something preferred. Newsgroups: occurs that causes an object of type T1 to comp.programming,comp.object,comp.la Job offer is contingent upon obtaining go out of bounds (not common, but ng.smalltalk,comp.lang.ada acceptance by the customer for program possible), the RTE raises a constraint access. error. > > Please give us an example of a type definition that is difficult to catch and Active Top Secret clearance mandatory. In the case (contrived, I admit) of fix. Will consider applicants with previously Unsigned_Small_Integer, we have an held TS clearance. unsiged integer that can be represented in > I don't understand what you're asking eight bits. I use a representation clause him. Are you saying that you've never Salary: 70k - 85k (for ... use 8) to force the size of the seen a complicated model with a set of representation eight. I could just as easily types that was ever so slightly /off/ the force the size to 16 bits or 32 bits, and mark so that it was difficult to discover, Ada in Context then specified the alignment I want for and also laborious to fix? objects of that type. If I make an error, There are several parts to your question. Advantages of Strong the compiler immediately notifies me of Typing it. 1) Complicated model 2) Incorrect types ("ever so slightly From: Richard Riehle Granted, when writing programs for less /off/ the mark critical systems, these features can be 3) Difficult to discover Date: Fri, 20 Aug 2004 17:15:53 GMT overkill. For a large category of 4) Laborious to fix Subject: Re: Static vs. Dynamic typing (big embedded, real-time systems, particularly those targeted to bare-board My experience is primarily with Ada, so advantage or not)---WAS: these questions are not quite as relevant as c.programming: OOP environments), these features are a blessing. they might be in some other language. Newsgroups: Nevertheless, I will answer them. comp.programming,comp.object,comp.la As several people have noted, it is not (or ng.smalltalk,comp.lang.ada should not be) a debate about the virtues I have seen designs where the there were too many types defined. In particular, Cristiano Sadun wrote: of static typing over non-static typing. Rather the discussion should be about people sometimes design too many > Dave Harris wrote: when it is appropriate to use static typing floating point types. For example, > > I notice you mention, "different (if often is) and when it is appropriate, as package Real_Numbers is primitive types". I suspect a fair it often is, to use non-static typing. It type Real is digits 8 fraction of type errors in C/C++ are due should not be a debate about Smalltalk or range -2000.0 .. 2000.0; to mixing up the integers, int versus Lisp, at one extreme, versus Ada, at the type Degree is digits 6 short versus long versus bool versus other the other extreme. Instead, it should range 0.0 .. 360.0; char versus wchar_t versus unsigned. be the case that we all learn the tools of -- and many more such Sometimes it's useful to have that much our profession, understand when to use -- definitions control, but often it just gets in the way which tool, and not be so dogmatic about end Real_Numbers; and makes opportunity for mistakes. one tool over another, that we fail to

Volume 25, Number 4, December 2004 Ada User Journal Ada in Context 201

In the above example, it might be more I gather you believe it would have been This is also true independent of language. useful to derived Degree from Real, or easier to do this redesign in some other When writing multi-threaded code, you create an Ada subtype (I will not define language? What language, and why? need to be aware of thread issues. the difference here, but it is different) If I had done the same thing in Ada (and I > If you are lucky, your program will just from Real for Degree. When there are too have done similar redesigns (I call it crash; if you are unlucky, it will be a many variations on floating point, one "refactoring")), I would expect to "turn source of subtle, intermittent, often has to do too much type conversion the crank" to get all the types right. That's infuriatingly uncatchable bugs. elsewhere within the program. However, part of what static typing is for; the Theoretically, this should never happen Ada never lets you get this wrong. compiler lets you know where stuff has to unless both subprogram calls make As to incorrect types, this will most often be changed. But at each point, you need to reference to the same variable (or file). occur in composite types, especially make sure that nothing _else_ needs to be In practice, I think you'll find some record types. On might forget to include changed; often it does. implementations are less than perfect in a component of the type in the definition. So I don't see why you feel "turning the this area. Since record types, in Ada, are most crank" is a Bad Thing here. Hmm. If the Language Reference Manual frequently defined as "limited" types, they does not _explicitly_ state that a particular are not part of the public part of a Ada Compiler Differences function is safe for calling from multiple specification. This makes it quite easy to tasks, then you must assume it is not, and correct them without disturbing the From: Magnus provide your own layer of task protection integrity of the underlying specification. Date: 18 Oct 2004 05:47:47 -0700 for it. I suspect Nick has been violating As to being difficult to discover, I have Subject: Ada compiler differences this rule. Newsgroups: comp.lang.ada not seen this very often in programming > If you are not careful, you can run into with Ada. The language is designed so Could someone please point me to a list re-entrancy problems with your own the compiler will quickly highlight any of things that may be implementation subprograms, too. Since different inconsistencies. The compilation process dependent in different Ada compilers implementations can multitask in very is not based on textual information alone. and/or on different platforms? different ways, its often the case that a Each unit that depends on another unit potential re-entrancy problem doesn't requires the unit on which it depends is I know that things like 'Access and structures without [representation clauses] manifest itself until a program is successfully compiled first. The compiler ported. will not even begin to compile a unit may differ. But what else? unless its dependency relationships have Or rather: How can I write code that That is bad design, in any language. One been resolved. This lends itself to rapid really is platform (and compiler) of the reasons Ada defines tasking in the discovery of problems with type independent in Ada? language is to allow people to write definitions. portable multi-tasking code. From: Stephen Leake When we consider laborious to fix, I So the correct statement here is "If you rarely find that to be a problem. In fact, I Date: Tue, 19 Oct 2004 21:32:55 -0400 follow good multi-tasking design cannot think of the last time (in nearly 20 Subject: Re: Ada compiler differences principles, Ada lets you easily write years) where the problem with a type was Newsgroups: comp.lang.ada portable multi-tasking code". laborious to fix. Certainly, when I was a Nick Roberts wrote: > Aliasing: implementations are novice there were problems I could not sometimes allowed to choose whether easily resolve. With experience, I have > Generally, you cannot. to pass a parameter by value or by found that well-designed Ada does not This is a gross overstatement, and a reference (indirectly). If it so happens entertain me with the kind of mysterious horrible disservice to Ada. that a call to a subprogram effectively errors I sometimes encounter in other passes the same variable as two The real answer is: "Generally, for languages. different (formal) parameters, the applications that do not deal directly with subprogram has two different 'paths' to I realize that most readers do not benefit hardware or other target-dependent the variable, without knowing it. The from the Ada static compilation model. features, you can". Still, that model does have the appeal, to order in which updates to the variable those who do enjoy it, of making the type Part of the point of Ada is to allow users occur could change from one system a blessing rather than a nuisance. to write portable code! implementation to another, in this situation. This can be a source of some [...] > However, you generally /can/ write Ada programs that require very little really mysterious bugs, when porting. From: Stephen Leake changes to be ported. Typically, the True. Also easy to avoid, once you are best technique is to move everything aware of it. Hmm. There aught to be an Date: 19 Aug 2004 21:27:25 -0400 that might need to be changed during a ASIS based tool to check for this. Subject: Re: Static vs. Dynamic typing (big port into separate (library) packages, so > Order dependency: implementations are advantage or not)---WAS: that the places where changes are generally allowed to choose in what c.programming: OOP and memory required are isolated from the rest of order they evaluate the expressions management the code. Newsgroups: comp.lang.ada passed as (actual) parameters to a That is good advice in any language. subprogram call. If more than one of Thomas G. Marshall wrote: > There are lots of subtle gotchas, these expressions has a side-effect, and > [...] unfortunately, that you may need to the side-effects could interact in some Because it was done in Java, a statically watch out for. I can list a few. way, it possible that the order the typed language, there was a great deal Re-entrancy of pre-defined implementation chooses could affect of energy spent in just turning the crank subprograms: on some the behaviour of a program. This can be of making sure that the types shifted implementations, if two tasks make a source of subtle and nasty bugs when from prior strategy to the current one. I simultaneous calls to a subprogram in porting. hope I've been clear enough here. certain pre-defined library packages, While technically true, I don't recall one or both will not work correctly. anyone posting such a bug here. And I have never encountered such a bug.

Ada User Journal Volume 25, Number 4, December 2004 202 Ada in Context

Typical code just doesn't have this From: Nick Roberts Example: the port of the SPARK problem. Examiner (written in SPARK of course...) > The values of everything declared in the Date: Mon, 18 Oct 2004 20:55:15 +0100 from Solaris to Linux took...about 20 predefined package 'System' are all Subject: Re: Ada compiler differences minutes, most of which was spent implementation defined, as well as in Newsgroups: comp.lang.ada installing GNAT. The Examiner is about its children, and the subprograms will Luke A. Guest wrote: 70kloc, so hardly a trivial program. all work differently. There may be extra > Yeah, you'll need to define your own From: Rod Chapman imp-def declarations, and some types, but surely these are going to be declarations may be omitted or "derived" from the default types, i.e. Date: 22 Oct 2004 01:13:59 -0700 different to what the standard states. So Subject: Re: Ada compiler differences type Chutney is new Integer use of these packages needs care, from Newsgroups: comp.lang.ada range 1 .. 5; a portability perspective. It's best to Are you saying not to even do this? Larry Kilgallen wrote: avoid using anything here if you can. Yes. Normally it is better to simply put: > I suppose an _unknown_ True. implementation-defined feature is type Chutney is range 1..5; Another area of non-portability is GUI defined by the term "bug" :-) interfaces. Since the Ada standard does and allow the implementation to select the best base type. If you can find _any_ implementation- not define a GUI library, code you write dependent, implementation-defined, or using a GUI library is only as portable as From: Jeffrey Carter erroneous behaviour in SPARK (other that library. Date: Tue, 19 Oct 2004 02:11:45 GMT than the 2 I mentioned above), then please From: Mark H Johnson Subject: Re: Ada compiler differences report it to [email protected] Newsgroups: comp.lang.ada From: Stephen Leake Date: Mon, 18 Oct 2004 16:48:38 -0500 I rarely do this. What is the point of Subject: Re: Ada compiler differences specifying the representation (except at Date: Wed, 20 Oct 2004 09:05:50 -0400 Newsgroups: comp.lang.ada the edges of the application)? Why use 32 Subject: Re: Ada compiler differences I would start with chapter 13 of the Ada (or 64) bits for 5 values? Let the compiler Newsgroups: comp.lang.ada choose the best representation for the Reference Manual. Simple things like Simon Wright wrote: Integer'Size (e.g., 32) might not equal target. Natural'Size (e.g., 31) can trip you up in a From: Martin Dowie > Stephen Leake wrote: variety of different ways. I also had > > Hmm. If the Language Reference problems with some code assuming 'Size Date: Mon, 18 Oct 2004 21:03:36 Manual does not _explicitly_ state that of the object was the same as 'Size of the Subject: Re: Ada compiler differences a particular function is safe for calling corresponding type. Newsgroups: comp.lang.ada from multiple tasks, then you must I would also suggest a review of the Leave as many aspects of the underlying assume it is not, and provide your own Annotated ARM as well. The annotations representation to the compiler. It knows layer of task protection for it. I suspect are quite enlightening when trying to what the target is, so in this case it may Nick has been violating this rule. determine the possible implementation choose a 8-bit representation as opposed > What, even details of the language. [...] to say a 32-bit one. Perhaps the target has Generic_Elementary_Functions.Arctan To do that fully would require an faster instructions for 8-bit data items. ?! extensive list of issues and is often From: Jeffrey Carter Well, you have a point. Although, on a constrained by the types of platforms you Date: Wed, 20 Oct 2004 01:16:54 GMT system without floating point hardware, expect to run on. For a simple example, Subject: Re: Ada compiler differences this _could_ use a global cache of network order (for TCP/IP) is "big Newsgroups: comp.lang.ada previously computed results, which endian". If you are on a little endian _could_ be not task safe. machine, several values need to go Luke A. Guest wrote: through htonl, htons, and similar > Even if you use a use clause to specify > On the other hand, anyone who called functions to be converted. If you "know" how many bits you want it to take up Float_Random from two tasks *with you will always on a big endian machine (i.e. even in a record)? the same generator* would be entitled to expect truly random results. I think (same as network order), you might get The only reason to do that is because you away without them, but that isn't portable. you have to be prepared to use your need to map to something like hardware wits sometimes .. That particular issue has nothing to do where this is required, so it's a fairly rare with Ada; you have the same problem case (what I called the edges of software). It could also be argued that the LRM with C or other languages. Even then, there's no advantage to using a _should_ say more about what is guarranteed to be task safe. From: Jacob Sparre Andersen derived type. Indeed, using a derived type is giving contradictory information to the From: Randy Brukardt Date: 18 Oct 2004 16:01:50 +0200 compiler: "use the same representation as Organization: CRS4, Center for Adv. Integer" and "use only N bits". Date: Mon, 25 Oct 2004 19:28:57 -0500 Studies, Research and Development in From: Rod Chapman Subject: Re: Ada compiler differences Sardinia Newsgroups: comp.lang.ada Subject: Re: Ada compiler differences Date: 20 Oct 2004 01:02:48 -0700 This is wrong. As long as the tasks are not Newsgroups: comp.lang.ada Subject: Re: Ada compiler differences passing the same objects, the language One advice: Newsgroups: comp.lang.ada requires that multiple tasks can call predefined routines at the same time. See Don't depend on predefined types Write the code in SPARK, which has only 2 known implementation-defined features A(3). (That's the third paragraph of the (Integer, Float, Natural, etc.) where it introduction to Annex A.) makes more sense to declare a specific - the range of predefined base types type for your specific use. (which can be added by way of Any implementation that fails to do that annotations), and the finer details of for any predefined subprogram is (you'll probably get more) floating point (signed zeros, rounding incorrect. Of course, it is not unusual for mode etc.) implementations to be incorrect,

Volume 25, Number 4, December 2004 Ada User Journal Ada in Context 203 especially in this area; and that seemed to illustrated by Florist, which has a rather GNAT project files. The only places be Nick's original point. convoluted build process: where ./configure may be of help are for It will be very important that this property 1) It uses configure to generate a Makefile the installation target (--prefix), and is true for the containers, for instance. and a config.h finding any Ada libraries you depend on. 2) The Makefile compiles a number of C Ada and the GNU Build source files, and links them into an This problem is solved nicely in Debian System executable, named c-posix GNU/Linux. Each library has a GNAT 3) The Makefile executes c-posix, which project file in a well-known location From: Lutz Donnerhacke C file, c-posix-signals.c program just "withs" them as required. Date: Wed, 4 Aug 2004 02:05:12 4) The Makefile runs gnatprep, with the Subject: Re: GNAT and GNU build system configuration file, to generate several Ada Newsgroups: comp.lang.ada files Furthermore, on non-Debian systems, the 5) The Makefile compiles and links c- Tapio Kelloniemi wrote: GNU Ada Environment Specification[1] posix-signals.c says where library files should be > I'm planning to seriously develop free 6) Executes c-posix-signals, which creates installed. Here again, you would not need software packages in Ada. The problem posix_signals.ads a ./configure at all; just use -aI and -aO as I have is GNAT's fitness for GNU 7) Compiles all the Ada files necessary. program building standards. 8) Links the compiled files into a library You don't need that. Ada comes with See portable interface definition capabilities. http://buildd.debian.org/fetch.php?&pkg= Since Debian follows the GNAE, your libflorist-3.15p-1&ver=3.15p- GNAT project file can be portable > I would like to autoconfig my project without the need for ./configure. (not very bad, some M4 macros can be 3&arch=sparc&stamp=1069154570&file found in GtkAda). But I would like to =log&as=raw use automake (my projects are in Ada But the conclusion I draw from all this is: [1] http://cert.uni- and C, because almost every free do your very best to avoid such a stuttgart.de/projects/ada/gnae.php software library is written in C). complicated build process if possible! So, you could consider writing a The monkey argument is no argument for Unless you are interfacing to the ./configure script by hand, which would C. You do not need autoconfig for Ada. operating system, there is very little generate a minimal Makefile containing reason to use the autotools. GNAT and > If anyone has had any experience or only the value of --prefix. Something Florist together should provide you all the along the lines of: interest regarding this, please drop a portability you need (and yes, GNAT line. does use autoconf/automake, because PREFIX=/usr I prefer redefining the standard C-header GCC does). all: my_program my_program: in Ada. This is necessary, but nearly From: Stephen Leake gnatmake -Pmy_program.gpr impossible, because the C-library and install: my_program kernel-call interface generated depends on Date: 04 Aug 2004 18:06:19 -0400 cp my_program the C-compiler version and flags used Subject: Re: GNAT and GNU build system $(PREFIX)/bin when compiling the kernel and the libs. Newsgroups: comp.lang.ada That's why there is no generic way to If you need package-specific options (e.g. Sounds reasonable. Others have said "you --enable-gold-objects), then you can automatically determine the interface for don't need automake with Ada". That's Ada. In order to do it in a portable way extend the ./configure and generate almost true, but any _real_ project also something like: you have to study the interface deeply and has tests, documentation, and distribution redefine it in Ada yourself. Luckily the needs which are beyond Ada's scope. PREFIX=/usr ABI does not change this hard, but autoconf/automake help with those tasks, GOLD_OBJECTS=false depends on CPU and OS-version. and Ada needs to at least cooperate. all: my_program my_program: I'd recommend a libportable written in C, I'm using automake in an Ada project (a gnatmake -Pmy_program.gpr generated with autoconfigure and all GtkAda interface to a books database). It's -XGOLD_OBJECTS=$(GOLD_OBJECTS) those nifty workarounds about a missing not ready for prime time yet, but I'd be install: my_program interface definition. This libportable happy to exchange notes about autoconf cp my_program should convert the CPP-headers into C- use. headers, so that preprocessor definitions $(PREFIX)/bin become linkable. The Ada code will be From: Ludovic Brenta From: Tapio Kelloniemi constant and portable, because the value of the day for a system constant can be Date: Wed, 04 Aug 2004 22:34:25 +0200 Date: Thu, 05 Aug 2004 08:50:37 GMT linked. Subject: Re: GNAT and GNU build system Subject: Re: GNAT and GNU build system Newsgroups: comp.lang.ada From: Ludovic Brenta Newsgroups: comp.lang.ada Tapio Kelloniemi wrote: And I think that autotools should also Date: Wed, 04 Aug 2004 21:21:40 +0200 > I would really prefer typing: cooperate. FSF says that free software Subject: Re: GNAT and GNU build system ./configure --prefix=/usr --enable- packages in GNU system should Newsgroups: comp.lang.ada goldobj cooperate with others. Luckily GNAT is I also tend to think that autoconf and I understand your concern completely. part of GNU project and I think autotools automake are poor hacks meant to My concern, though, is the sheer writers could very well take a step circumvent the deficiencies of C; just like complexity of the ./configure script itself, towards Ada from the complete C make in fact. However, I see one and that of the Makefile it generates. centralism. (This C centralism is situation where it makes sense to use Most of that complexity is unnecessary unfortunately accepted by GNU projet them in Ada, and that is when you want to with Ada programs, and in fact really gets and very unfortunately even required by build a binding to a C library that has in the way. With Ada, you would the GNU coding standards.) platform-dependent parts. This is best normally want to take full advantage of

Ada User Journal Volume 25, Number 4, December 2004 204 Ada in Context

[...] There are still things that cannot be From: Ludovic Brenta Two option open: Your Ada has garbage solved with Ada, consider such a real time collection or you use programming need as memory mapped Date: Sun, 08 Aug 2004 16:45:15 +0200 Ada.Unchecked_Deallocation. IO, which is very non-portable. Subject: Re: GNAT and GNU build system AFAIK: Only Ada [platforms] targeting Configure could perhaps generate a Newsgroups: comp.lang.ada the JVM have garbage collection. Makefile, which runs automake with the The usual way to do configuration However for GNAT you can use the appropriate GNAT project file (assuming management in Ada in these situations is Boehm Collector which is part of the that GNAT is the only compiler to to have several bodies for a single spec, GCC. support). The project file used could be and choose one body when configuring. Mind you: A good collection class library choosed by configure (eg. if --enable- This can be done in several ways. The will free you from almost all memory maintainer-mode is specified, choose GNAT way is to symlink the file management. debug.gpr, instead super_optimise.gpr). containing the particular body to the From: Nick Roberts > This is true. So we need to start canonical name. For example, one body is "5msystem.ads" and it is symlinked to generating patches to auto* that take Date: Thu, 07 Oct 2004 18:24:21 +0100 advantage of Ada's simplicity. Not an "system.ads" before building. This however is done from the Makefile and Subject: Re: Ada memory management? easy task, but in the long run it is the Newsgroups: comp.lang.ada right solution. does not, per se, require a configure script. There are some Ada implementations Note that automaintainers are not allowed Another way is to have one target- where memory never leaks (unless a bug to accept our patches (if longer than few in the compiler or run time system causes lines), if writer doesn't sign a paper that dependent directory, and pass a variable to a GNAT project file to select which one, or the programmer causes it by poor he doesn't own the code (this is the FSF's unchecked or external programming). requirement). I really think that this target-dependent directory should be added to the Source_Dirs. Automatic deallocation combined with should be done in tight cooperation with comprehensive memory reclamation is the GNU developers, because they have A third way, used by GPS, is to write a called 'full garbage collection'. I think, in deep knowledge of their tools and we GNAT configuration file containing reality, there is no native code Ada have that of ours. configuration pragmas. The compiler- compiler which supports full garbage > Hmm. Maybe rewriting auto* in Ada specific pragma Souce_File_Name can collection. associate a body with the selected file. first would be easier; I'm not sure :). Personally, I regret this situation. The I think that using GNU tools is a good A fourth way could be to use gnatprep compiler vendors all say they don't idea not to couple efforts. Pure Ada (like Florist does). support full garbage collection because version would of course be easier, but in [...] I would probably be better to use a there is no demand, which is true mixed language projects, tools such as single project file, and pass variables on considering the paying Ada compiler autoscan, autoheader and others are also the command line (you can have a case market is almost entirely made up of the needed. statement in a project file). embedded, real-time, and safety-critical Things that I think should be done to As you can see, there is a lot you can do arenas. But the fact that the Ada language auto* are: to influence the build. Some of this has to is capable of protecting the programmer from the possibility of memory leaks used - Autoconf should be able to generate be done at configure time; some can be done from within the Makefile. to be, many years ago, one of the reasons gnatprep definition files, perhaps from cited for its superiority. The complete template like config.adp.in: I think that the general idea is to have a lack of support for full garbage collection -- Define this to true, if libfoo support minimal configure script that only does seems unfortunate to me. It is a proud should be included. what is strictly necessary, i.e. generates capability of many languages which have the Makefile. I do not like GNU since become far more popular than Ada. HAVE_libFOO := @LIBFOO_SUPPORT@ configure because it tries to be everything to all developers, and ends up in I am trying to build my own (open source, Better even could be that configure would GPL) Ada compiler, and I hope to be able generate this from scratch. unmaintainable and unnecessary complexity. to build in full garbage collection support, - Automake should be able to compile if only to prove that it can be done. But I Ada programs (in a way or another). If the Makefile can be written in a do not have recourse to huge resources, so portable way, then I would prefer not to don't hold your breath. - Automake should know how to install have a configure script at all (or a no-op Ada libraries (unfortunately installing .so configure script, to please people with http://sourceforge.net/projects/eclat and header is not enough.) pavlovian reflexes). I am a (moderate) fan of full garbage - Libtool (never used, don't know what collection, but I concede that it is not, in should be done to it) Memory Management in reality, as useful as you might think. One - Gettext and autopoint (gettext should be Ada could guess that 90% of 'desktop' Ada able to scan Ada sources for strings) programs would not benefit from the From: Martin Krischik availability of full garbage collection, for > Only if you have a pure Ada project. I one of the following reasons: the program find this unlikely; I like LaTeX or Date: Thu, 07 Oct 2004 14:06:41 +0200 does little or no dynamic memory Texinfo for documentation, and I want Subject: Re: Ada memory management? allocation; the program does not give any my makefiles to run test drivers. Newsgroups: comp.lang.ada (or much) opportunity for automatic You speak truly. Because almost every deallocation until (near) the end of > Since there is an allocator 'new' in Ada, program execution; more control over the library is written in C, C interfacing is I was wondering if there is a 'delete' required, as ugly and unwanted as it is. It management of (most) dynamically too. I've heard there is a special allocated variables is required; the is very often better to share than write technique called Storage Pool in Ada to giant size programs which introduce bugs, program must be written to be portable to write own memory managers, but what other Ada compilers (which do not or because somebody understood something is the default deallocator? incorrectly. may not support full garbage collection); the program only uses pre-written encapsulated 'containers' for dynamic data

Volume 25, Number 4, December 2004 Ada User Journal Ada in Context 205 storage, which all do their own memory Security holes are often buffer overflows, five minutes and a five-line Perl script management anyway. and as Jean-Pierre Rosen said, Ada would do the job? Many programs will only dynamically programs do not have buffer overflows. From: Randy Brukardt allocate variables of a fixed size (known Arithmetic overflows also occur, and Ada at compile time). By having a separate protects well against those too. Date: Tue, 7 Sep 2004 19:07:36 -0500 pool for each different size, the necessity From: Jean-Pierre Rosen Subject: Re: Advanced scripting languages for memory reclamation (moving things (was: Learning Ada83) around) is obviated; only automatic Subject: Re: Ada and malicious software Newsgroups: comp.lang.ada deallocation is useful. I do not know if Date: Thu, 23 Sep 2004 09:33:02 +0200 Because it would take a week to learn Perl any existing native code Ada compiler Organization: Adalog well enough to use it that way. And it is actually supports this technique (doing it Newsgroups: comp.lang.ada very rare that such a program is never automatically). It could be done manually, Warren W. Gay wrote: used again; my one experience with Perl by implementing one's own storage pool. > That should probably be tempered with showed it to be a write-only language (it Probably, full garbage collection would "not as susceptable" to buffer took me two weeks to successfully never be used for an embedded or real- overflows. If there was poor design modify the code that runs the CVS on the time program, because it is a big-memory and/or testing, then a production mode ada-auth.org site). And it is very rare that technique, and does not conform to strict program that is compiled with the I need to write a 100 line throwaway timing requirements. I'm not quite sure checks "off", is still vulnerable, program; most of my code has much more about safety-critical programs. although admitedly, much less likely. permanence than that. Summary: It doesn't make sense for me. YMMV. However, for the remaining 10% -- or Of course. You can write badly in Ada. whatever the figure really is -- of desktop But the difference is, you have to ask for From: Ken O. Burtch programs, full garbage collection would it! certainly be a useful facility, and I am Date: Wed, 08 Sep 2004 09:38:12 -0400 certain it is why many good programmers Scripting Languages and Subject: Re: Advanced scripting languages often choose languages such as Python, (was: Learning Ada83) Ruby, and various others which support it, Ada Newsgroups: comp.lang.ada in preference to a language which (in The documentation for the AdaScript practice) doesn't. From: Marius Amado Alves Business Shell Ada Movies on Date: Fri, 03 Sep 2004 17:42:07 +0100 (http://www.pegasoft.ca/bush.html) Subject: Re: Learning Ada83 contains several arguments against tools AdaPower.com Newsgroups: comp.lang.ada like Perl in favor of Ada-based scripting languages, including: From: David Botton > It would also be useful and practical to Date: Tue, 9 Nov 2004 00:43:18 -0500 learn one of the advanced scripting 1. Lower learning curve (a BUSH for loop Subject: Ada Movies on AdaPower.com languages like Perl or Python or is an Ada for loop) Newsgroups: comp.lang.ada Ruby.... 2. Lower overall cost for maintaining a script project over its lifetime Oldies but goodies :-) Wow, they're *advanced* scripting 3. Error messages that work for you, not languages now! And I thought real man Requires quick time. against you did all their scripting in Ada these days :-) 4. Better readability when debugging AdaPower Cinema, Now, less jestly, I find this a strange other people's scripts. http://www.adapower.com/index.php?Co advice in this list. If you want to go the 5. Sensible syntax shortcuts designed to mmand=Media Great Ball of Mud way why not just be typo-resistant. David Botton recommend PAM (PHP + Apache + 6. Better portability. MySQL) and get done with it? (Sorry, 7. Code reuse. Ada and Malicious Software every now and then I can't resist a good language battle.) When you look at the big picture, Perl projects increase costs and development From: Björn Persson From: Randy Brukardt time. As always, use the right tool for the job. But my experience with Perl Newsgroups: comp.lang.ada Date: Fri, 3 Sep 2004 18:47:58 -0500 development over the past 2 years has Subject: Ada and malicious software Subject: Re: Advanced scripting languages been negative. The idea of a 5 line Perl Date: Wed, 22 Sep 2004 09:21:42 GMT (was: Learning Ada83) script to replace 100 lines of Ada is a Tom wrote: Newsgroups: comp.lang.ada myth. > One question that I would like an That's funny, because if it's complicated Ken B. answer for is: Is Ada less susceptible to enough that I can't write a batch file to do Author of "Linux Shell Scripting with computer virii than C++ and Java on it, I'll generally write it in Ada. Bat has If Bash" the Windows XP operating system? and Goto, and that is enough for simple Now that is a question that would come tasks. Beyond that, I want to be able to fix up more often where I work. it and be able to insure that it works... Mantainability of Ada, C++ and Perl If you mean true viruses then I can't see From: Kevin Cline that there would be any difference. The From: Kevin Cline choice of programming language doesn't Date: 4 Sep 2004 20:28:16 -0700 Subject: Re: Advanced scripting languages affect a program's ability to modify the Date: 21 Sep 2004 17:21:38 -0700 code of another program. (On the other (was: Learning Ada83) Newsgroups: comp.lang.ada Subject: Ada Popularity: Comparison of hand, choice of operating system does.) Ada/Charles with C++ STL (and Perl) If you mean malicious code in general, Strong typing is handy, but it's not enough Newsgroups: comp.lang.ada then yes, Ada programs would be less to ensure that something works. Ada has it's strengths, but it's not the tool for every As promised in the Ada popularity thread, subjected to worms, cracking tools and I have taken one of the Charles examples other things that exploit security holes. job. Why would you spend an hour writing 50 or 100 lines of Ada code when and reimplemented it in C++. I used only

Ada User Journal Volume 25, Number 4, December 2004 206 Ada in Context the standard C++ language and libraries. Subject: Re: Ada Popularity: Comparison of and if they did, what they would use it The Ada/CHARLES main program body Ada/Charles with C++ STL (and Perl) for), no unit tests or any automated is 118 (non-blank) lines of code, plus an Newsgroups: comp.lang.ada framework for making sure the code does additional 40 lines of instantiations in I second this. And for a quick and dirty as designed (which brings me to my next eight other specification files, for a total comparison we have to figure out some one), no design documentation or even a of 158 lines and 9 files. The C++ (unique for all implementations) test suite, design process. implementation is 76 (non-blank) lines of so we can check the overall behaviour Many young/inexperienced programmers code in a single file. For grins, I also (not only performance). do not even see why this is important, as wrote the program in Perl. That took 14 their code works, and generally they are lines. From: James Alan Farrell Date: Wed, 22 Sep 2004 11:27:01 -0400 done with it then and there. In the real Summary: Subject: Re: Ada Popularity: Comparison of world, and in my job, most of the time is Ada/Charles 158 lines, 9 files Ada/Charles with C++ STL (and Perl) spend updating code. Good times are C++ 76 lines Newsgroups: comp.lang.ada when I get to design something new, most Perl 14 lines the time is spent doing grunt work. Does this prove that perl is the best You can compare the implementations at language? If so, perhaps we should all In a time when most programs are written http://www.geocities.com/kc0a/wordcoun switch our avionics projects over to perl. by having a 1-2 thought process of 1) I t.html Must be it will be easier to code and want my program to do this and 2) type- From: Björn Persson maintain, safer to fly, and run just as fast. type-run-repeat, such languages that allow you to do this easier are more popular, The things that make a language a "good" such as php and perl. Date: Wed, 22 Sep 2004 08:50:05 GMT language are many and complex, and are Subject: Re: Ada Popularity: Comparison of different in different circumstances. If I Granted, I do code perl for some of the Ada/Charles with C++ STL (and Perl) need a small utility that compares lines in legacy projects here (no I am not a web Newsgroups: comp.lang.ada different text files, I find perl much easier developer, heh), and if standards are in Neat. Now let's take three identical than Ada. On the other hand, if I have a place, perl code can be very readable and persons who haven't seen this program very large project that must always understandable. Coding standards are before, give them one version each, and perform "correctly", I've not found a nice, yet seem to be rarely used. see how long it takes them to understand language that can beat Ada. [...] it. But then I've never used Eiffel. From: Kevin Cline In other words: What matters is how easy From: Chris Humphries the program is to read and maintain. The Date: 27 Sep 2004 14:31:07 -0700 line count is interesting only to the extent Date: Mon, 27 Sep 2004 09:22:06 -0400 Subject: Re: Ada Popularity: Comparison of that it affects the readability. Subject: Re: Ada Popularity: Comparison of Ada/Charles with C++ STL (and Perl) From: Benjamin Ketcham Ada/Charles with C++ STL (and Perl) Newsgroups: comp.lang.ada Newsgroups: comp.lang.ada Bad programmers didn't come from open Date: Wed, 22 Sep 2004 13:38:33 -0000 Kevin Cline wrote: source. There have always been bad Subject: Re: Ada Popularity: Comparison of programmers, and there always will be. Ada/Charles with C++ STL (and Perl) > Again, the original question was "Why Just as it is with music and writing and Newsgroups: comp.lang.ada isn't Ada more popular?" film and art, 90% of all programming The answer I am giving is that most sucks. Well, the line count affects readability programmers don't have such an rather profoundly, in this example! Not overriding concern for safety that they [...] On a good project, design is a being an expert in any of the languages are willing to write twice as much code continuous process. Unfortunately, most concerned, I can take a more objective to get the additional safety. programs reach the point where any view of readability perhaps; and I can say change is so risky that developers spend that if I had to figure out and maintain any [...] all their time trying to figure out how to of these programs, the one that easily fits Thanks, and good answer. Since then squeeze in a new feature without breaking in entirety on an 80x24 screen wins my asking that question, I have learned a lot the existing features. approval. I.e., this might not scale to more about Ada. John Barnes' book, From: Brian May larger projects: I'm not at all sure I'd "Programming in Ada 95, 2nd Edition" rather read a 1400-line Perl program than helped tremendously. A very good book. Date: Tue, 28 Sep 2004 09:51:48 +1000 a 7600-line C++ program or a 15800-line It is now nice to understand just what Ada Subject: Re: Ada Popularity: Comparison of Ada program. Actually, "none of the is, and not just another programming Ada/Charles with C++ STL (and Perl) above" sounds most appealing. language, but more an attempting at Newsgroups: comp.lang.ada progressing software engineering. OTOH, it does not appear that the three I know of commercial programs that are programs actually implement the same I also think I understand why Ada is not developed (designed, implemented, and spec. E.g., error messages are different more popular. Though I am very thankful tested) very badly just as I know of open (and missing in the Perl version), and if for open source, and feel very strongly source projects that appear to be handled I'm not mistaken the Perl version reads about about it, something bad has grown very well. input from stdin, the other two take a file out of it: bad programmers and programs. argument -- or is while(<>) in Perl Most open source projects seem to have Commercial projects can be put under smart/twisted enough to read from a no formal software development process. pressure to cut corners, e.g. because filename in argv[] if present, else stdin? I There is more an attitude of "shut up and management sees a formal software certainly recall that it has extensively hack", which typically goes by whatever development process as an academic overloaded behaviour. Anyway, this is not they get features to do from, which may exercise that is a complete waste of time even a vaguely fair test until all three be from whatever they want, if there is a "in the real world"(TM), despite protests actually have the same behaviour in TODO list, then you are lucky. There is from programmers. The same detail. usually no goals or anything actually management see software development as a tedious and unreliable process, and don't From: Cesar Rabak defined, no use cases (I would put money on most do not even know what one is, make the connection that the lack of a Date: Wed, 22 Sep 2004 12:16:22 -0300 proper development process could be

Volume 25, Number 4, December 2004 Ada User Journal Ada in Context 207 leading to the difficulties. They often give He's not referring to the same limitation, Ada's case for the third axis of solutions (that may be inadequate) rather and he's right. optimization, "easier for the programmer then requirements, turning the task of to modify" (which is subjective), can be programming into a guessing game. Artistically creative strongly made as well. With its design Open source developers aren't under these expression has no role in goal of readability, fully object-oriented pressures, and have more scope for doing software design capabilities, and the strong typing that the right thing. makes it easier to modify software _correctly_, again Ada shines. (This isn't to imply that all open source From: Marc A. Criley projects are developed correctly; some are Date: Mon, 19 Jul 2004 13:46:58 -0500 After you get past the knee-jerk reaction bad too; this doesn't imply all commercial Subject: Artistically creative expression has to Heer's conclusion (which I'll admit to), projects are developed badly either). no role in software design sit back and really think about software, Newsgroups: comp.lang.ada its function, and how to achieve From: jayessay _correctness_ and _efficiency_ in design (Okay, now that I have your attention... :-) Date: 23 Sep 2004 15:30:11 -0400 and programming. Software development Subject: Re: Ada Popularity: Comparison of In spectating the "SCO vs Linux" lawsuit starts to become less about creative Ada/Charles with C++ STL (and Perl) (www.groklaw.net), a lot of documents of expression, and more like a quest, trying Newsgroups: comp.lang.ada various types get posted. One of the to find the elegant implementation of [...] Ole-Hjalmar Kristensen: recent references was a paper titled, "The functionality. Refactoring, anyone? case against Copyright Protection of Non- From: Alexander E. Kopilovich > Kevin Cline wrote: literal Elements of Computer Software" http://tinyurl.com/3tjqj, by Christopher >> But large projects in Ada or C++ or Date: Tue, 20 Jul 2004 05:45:33 Heer of the University of Toronto. Java or C# might be small or medium- Subject: Re: Artistically creative expression sized projects in a higher-level The paper analyzes something called the has no role in software design language. "Abstration-Filtration-Comparison test Newsgroups: comp.lang.ada (AFC test), which is a court created > Maybe. It depends on how large the It seems that the author of that paper means for attempting to determine project is, and how good you are to knows far too little about art and copyright infringement of software where create reusable artistically created expressions. Perhaps no _literal_ copying was involved, or components/abstractions within the he thinks that art is overwhelmingly not perhaps was obscured. project, and how good a fit your functional, but decorative... and that true problem is to the facilites provided by One of the interesting conclusions of this artists never worry about restrictions and the "higher-level" language. paper is this: consequences, being driven by mystical This is key. The robustness, "Since the design of computer software is revelations. maintainability, evolvability, and forever driven by its intended I'd like to recall here an interesting (and "correctness" of a program is directly and functionality and efficiency concerns, the not rare) kind of art - propaganda art, closely related to how close its expression room for artistically creative expression which from time to time thrives both in is to the language of the problem domain. never arises. [...] It is more appropriate to literature and in movies (especially in war In the case of Lisp, this is where the "Lisp consider the software objects of a or tension times). There are plenty of is a programmable programming computer program as analogous to the examples of true art of this kind - and language" comes in. You can always gears, pulleys, and levers of a mechanical certainly the ultimate purposes of those create a (possibly hierarchical set of) invention, as by its very nature, the design things were and are functionality and domain specific language that directly of computer software is intended to efficiency. optimize functionality by making a supports the most natural, clean, and Another well-known generic example is program run faster, use less memory, or direct means of expressing the definitions architecture - one may recall that so be easier for the programmer to modify." and process within the domain. People beloved by many in software world often talk of "hoisting the language up to Since programming in Ada has been "design patterns" were largely originated the level of the domain". sneered at as requiring that a programmer from the Christpher Alexander's work on It used to be (and I suppose in many "lose their programming freedom" and architectural patterns - and then read the places still is the case) that people thought likened to "programming in a first book in that series - "Timeless Way this sort of thing could be done with straitjacket", this article argues that those of Building" by Christopher Alexander - components and component libraries. But are in fact proper characteristics in the and see the roles of functionality and this is an error. No library (no matter how development of correctly functioning, effectiveness in that art. optimized software! good it is - and most are very poor) will Then, the author of that paper holds ever have the level of expressiveness as Software is pure function; there are inputs awfully narrow view for computer even a decent (let alone good) domain (data and time), transformations, and then software. It seems that he recognizes very specific language. outputs; although the software's design specific-purpose software only - because >> If you have a project that must always and implementation may be formulated in he spoke about functionality as about a perform "correctly", then you better a specific way that promotes one or more compact and well-defined thing, which prove it correct. Strong typing can of Heer's three functionality optimization does not need such artisitic features as help, but is not absolutely necessary to axes. Arguably then, for the first two fine balancing between contradictory that effort. axes, more speed and less memory, there criteria. He surely did not ask himself: For the rest of us, the most important should be an optimal design and an what is the functionality for a text editor thing is to get tested code done quickly. optimal implementation. of MS Word kind, and how it differs - not I don't know about you, but I can write Add in the overriding requirement that the in general, but in all important details - and test 14 lines of code a whole lot software must be _correct_, and Ada from the functionality of a text editor of, faster than I can write and test 80 or shines--its definition supports establishing say, Emacs kind. 160. and verifying programming correctness-- So I think that the quoted paper does not > I usually find that my ability to create and subsets with supporting tools like deserve further reading -; programs is limited by my thought SPARK (www.sparkada.com) even take process, not my typing speed :-) that a serious step further.

Ada User Journal Volume 25, Number 4, December 2004 209 Conference Calendar This is a list of European and large, worldwide events that may be of interest to the Ada community. Further information on items marked ♦ is available in the Forthcoming Events section of the Journal. Items in larger font denote events with specific Ada focus. Items marked with ☺denote events with close relation to Ada. The information in this section is extracted from the on-line Conference announcements for the international Ada community at: http://www.cs.kuleuven.ac.be/~dirk/ada-belgium/events/list.html on the Ada-Belgium Web site. These pages contain full announcements, calls for papers, calls for participation, programmes, URLs, etc. and are updated regularly.

2005

January 03-06 Software Technology Track of the 38th Hawaii International Conference on System Sciences (HICSS-38), Big Island of Hawaii, USA. Includes mini-tracks on: Distributed Object and Component-based Software Systems; Strategic Software Engineering; Adaptive and Evolvable Software Systems: Techniques, Tools, and Applications; etc. January 12-14 32nd Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL'2005), Long Beach, CA, USA. Topics include: fundamental principles and important innovations in the design, definition, analysis, transformation, implementation and verification of programming languages, programming systems, and programming abstractions.

January 21 1st International Workshop on Abstract Interpretation of Object-oriented Languages (AIOOL'2005), Paris, France. Topics include: Abstract Domains for the analysis of Object- oriented Languages, Semantics of Object-oriented Languages, Static Analysis of Object-oriented Languages, Verification, etc ☺ February 26-27 Free and Open Source Software Developers' European Meeting (FOSDEM'2005), Brussels, Belgium. Topics include: events on Ada and Open Source (tentative) March 07-10 17th Software Engineering Process Group Conference (SEPG'2005), Seattle, Washington. Topics include: building quality products on cost and on schedule, establishing and maintaining continuous improvement efforts, etc.

March 09-11 11th International Conference on Languages and Models with Objects (LMO'2005), Bern, Switzerland. Topics include: object-oriented programming, components and distributed objects, object engineering, etc. March 13-17 20th ACM Symposium on Applied Computing (SAC'2005), Santa Fe, New Mexico, USA. Includes tracks on: Embedded Systems (topics include: RTOS for embedded systems, Hardware/software support for real-time applications, Compilation strategies for performance enhancement vs. footprint control, Program parallelization for embedded systems, Case studies, etc.); Programming Languages (topics include: Compiling Techniques, Language Design and Implementation, Practical Experiences with Programming Languages, Program Analysis and Verification, etc.); Software Engineering (topics include: Software Reuse and Component-Based Development, Software Reliability and Software Fault Tolerance, Reengineering, Reverse Engineering and Software Maintenance, Real-Time Embedded Systems, etc.), etc. March 14-18 4th International Conference on Aspect-Oriented Software Development (AOSD'2005), Chicago, Illinois, USA March 21-23 9th IEEE European Conference on Software Maintenance and Reengineering (CSMR'2005), Manchester, UK. Theme: "Maintaining for Integration". Topics include: Evolution, maintenance and reengineering; Experience reports (successes and failures); Migration, wrapping and interfacing legacy systems; Reverse engineering of embedded systems; etc. April 02-08 Conference on Design, Analysis, and Simulation of Distributed Systems (DASD'2005), San Diego, California, USA. Theme: "Making simulation and analysis successful through novel distributed system design, methodologies, and management". Topics include: Distributed Systems, Design and implementation approaches for complex systems using Petri nets, Distributed real-time

Ada User Journal Volume 25, Number 4, December 2004 210 Conference Calendar

systems, Formal concepts and methods for validation and testing, High level architecture in distributed systems, etc. April 02-10 European Joint Conferences on Theory and Practice of Software (ETAPS'2005), Edinburgh, Scotland, United Kingdom. Event includes: conferences from 4-8 April, 2005, satellite events on 2-3 and 9-10 April, 2005 April 02-03 3rd Workshop on Quantitative Aspects of Programming Languages (QAPL'2005). Topics include: the design of probabilistic and real-time languages; of semantical models for such languages; the discussion of methodologies for the analysis of probabilistic and timing properties (e.g. security, safety, schedulability); applications to safety-critical systems; etc. April 02-10 8th International Conference on Fundamental Approaches to Software Engineering (FASE'2005). Topics include: Systematic approaches towards evolution management in large scale systems, continuous software engineering, and improvement and adaptation of legacy systems to altered requirements; Rigorous approaches to the design, testing, and maintenance of reactive, mobile, and distributed software systems; Integration of formal concepts and current best practices in industrial software development; Experience reports on best practices with development tools, software development kits, ...; etc. April 03 4th International Workshop on Compiler Optimization Meets Compiler Verification (COCV'2005). Topics include: optimizing and verifying compilation, and related fields such as translation validation, certifying and credible compilation, but also programming language design and programming language semantics. April 03 5th Workshop on Language Descriptions, Tools and Applications (LDTA'2005). Topics include: Program analysis, transformation, and generation; Formal analysis of language properties; Automatic generation of language processing tools.

April 04-08 14th International Conference on Compiler Construction (CC'2005). CC is undergoing an expansion. Traditionally, CC has focused on compiler construction; CC now seeks to become a conference for research on a broader spectrum of programming tools, from refactoring editors to checkers to compilers to virtual machines to debuggers. Topics include: compilation techniques, incl. program representation and analysis, code generation and code optimization; run-time techniques, incl. memory management; compilation techniques for embedded code; compilers for parallel and distributed computing; compilation techniques for security and safety; design of novel language constructs and their implementation; software tools, incl. debuggers, profilers, code verifiers; etc. April 07-09 International Symposium on Trustworthy Global Computing (TGC'2005). Topics include: language-based security, reliability and business integrity, language concepts and abstraction mechanisms, type checkers, software principles to support debugging and verification, etc. Deadline for submissions: January 14, 2005 (papers) ☺ April 04-08 International Parallel and Distributed Processing Symposium (IPDPS'2005), Denver, Colorado, USA. Topics include: Applications of parallel and distributed computing; Parallel and distributed software, including parallel programming languages and compilers, operating systems, middleware, libraries, programming environments and tools; etc. ☺April 04 10th International Workshop on High-Level Parallel Programming Models and Supportive Environments (HIPS'2005). Topics include: Concepts and languages for parallel and Grid programming (Component programming models, Refactoring of existing applications into components, Language and platform interoperability, Concurrent object-oriented programming, Extensions to traditional programming models, ...); Supportive techniques and runtime

Volume 25, Number 4, December 2004 Ada User Journal Conference Calendar 211

environments (Compiler techniques, ...); Tools for high-level parallel programming; etc. April 04 3rd International Workshop on Parallel and Distributed Systems: Testing and Debugging (PADTAD'2005). Topics include: optimizing and verifying compilation, and related fields such as translation validation, certifying and credible compilation, but also programming language design and programming language semantics. ☺ April 05-08 2nd Jahrestagung Fachbereich "Sicherheit - Schutz und Zuverlässigkeit" (2nd Annual Conference on Safety and Security), Regensburg, Germany. Event includes: special session "Informationssicherheit im Automobil", workshop "Privacy Respecting Incident Management", etc. Contributions welcome in English or in German. Topics include (in German): Vertrauenswürdige Softwarekomponenten; Zuverlässigkeit und Fehlertoleranz in Hardware- und Softwaresystemen; Formale Techniken, Modellierung, Spezifikation und Verifikation; Betriebssicherheit unter extremen Bedingungen; Standards und Normung; Sicherheitsevaluation und -zertifizierung; Kosten von Sicherheit; etc. April 06-08 Software & Systems Quality Conferences (SQS'2005), Düsseldorf, Germany. Event includes: ICSTEST International Conference on Software Testing, SQM, a congress focussing on Software Quality Management, and CSVHC Conference on Software Validation for Health Care. April 10-13 The Conference for Software Practice Advancement (SPA'2005), Wyboston, Bedfordshire, England. Topics include: Languages; Distributed, component-based development; Pervasive or embedded systems; Patterns and pattern languages; Comparative experience (what we have learned or can learn from other disciplines); Lessons learned/experience reports; etc. April 11-13 12th Annual European Concurrent Engineering Conference (ECEC'2005), Toulouse, France. Topics include: engineering of embedded systems, specification languages, distributed computing environments, practical solutions, pitfalls and success stories, case studies, pilot projects and experiments, etc. Deadline for submissions: January 20, 2005 (final)

April 11-13 9th International Conference on Empirical Assessment in Software Engineering (EASE'2005), Keele University, UK. Topics include: Evaluation of products, components and services; Process and tool evaluation; Quality assessment; Software experiments, case studies and observational studies; etc. April 27-29 5th International SPICE Conference on Software Process Improvement and Capability dEtermination (SPICE'2005), Klagenfurt, Austria. May 02-06 International Conference on Practical Software Quality and Testing (PSQT'2005 West), Las Vegas, Nevada, USA. Deadline for submissions: January 14, 2005 (papers, presentations)

☺ May 15-21 27th International Conference on Software Engineering (ICSE'2005), St Louis, Missouri, USA. Topics include: Software architectures and design; Software components and reuse; Software security; Software safety and reliability; Reverse engineering and software maintenance; Software economics; Empirical software engineering and metrics; Distribution and parallelism; Software tools and development environments; Programming languages; Object-oriented techniques; Embedded and real-time software; etc. May 14-15 8th International SIGSOFT Symposium on Component-Based Software Engineering (CBSE'2005). Topics include: Static analysis and execution monitoring of system properties; Components for real-time, secure, safety critical and/or embedded systems; etc. Deadline for submissions: January 7, 2005 May 15-16 13th IEEE International Workshop on Program Comprehension (IWPC'2005). Topics include: Comprehension during large scale maintenance, reengineering, and evolution of existing systems; Reverse engineering for the purpose of program comprehension; etc. Deadline for submissions: January 21, 2005 (technical papers), February 4, 2005 (working sessions, tool demonstrations)

Ada User Journal Volume 25, Number 4, December 2004 212 Conference Calendar

☺May 17 Workshop on Architecting Dependable Systems (WADS'2005). Topics include: all topics related to software architectures for dependable systems. Deadline for submissions: January 21, 2005 May 17 3rd Workshop on Software Quality (WoSQ'2005). Topics include: Software Product Evaluation and Certification; Tradeoffs in Quality during software development; Software Quality Education; Methods and Tools for Quality Assurance; Software Quality at different stages of the development lifecycle; Building quality into software products; Testing, Inspections, Walkthroughs and Reviews; etc. Deadline for submissions: February 21, 2005 (extended abstracts, position papers) May 22-25 5th International Conference on Computational Science (ICCS'2005), Atlanta, USA. Theme: "Advancing Science through Computation". Topics include: Parallel and Distributed Computing, etc. May 23-25 9th Brazilian Symposium on Programming Languages (SBLP'2005), Recife, PE, Brazil. Topics include: programming language design and implementation, formal semantics of programming languages, theoretical foundations of programming languages and teaching programming languages, etc. Deadline for submissions: February 28, 2005 May 27-June 01 3rd International Software Development Conference (SWDC'2005), Reykjavik, Iceland. Topics include: Project success and failure analysis; Software project risk management; Software process improvement; etc. Deadline for submissions: February 21, 2005 ☺ May 30-June 02 DAta Systems In Aerospace (DASIA'2005), Edinburgh, Scotland, UK.

June 06-09 5th International Conference on Application of Concurrency to System Design (ACSD'2005), St Malo, France. Topics include: Correct-by-construction design methods and integration of verification techniques with the design process; etc. Deadline for submissions: February 4, 2005 (tool demonstrations) June 06-10 25th International Conference on Distributed Computing Systems (ICDCS'2005), Columbus, Ohio, USA. Sponsored by The IEEE Computer Society Technical Committee on Distributed Processing. Topics include: Fault Tolerance & Dependability, Middleware, Real-time & Embedded Systems, Security, Formal Verification, etc. June 13-17 17th Conference on Advanced Information Systems Engineering (CAiSE'2005), Porto, Portugal. Topics include: Model and Software Reusability, Distributed and Open Architectures, Languages for IS, etc. Deadline for submissions: February 26, 2005 (posters), February 28, 2005 (Doctoral Consortium Papers)

☺ June 14-17 34th International Conference on Parallel Processing (ICPP'2005), Oslo, Norway. Topics include: Compilers and Languages, Programming Methodologies, Tools, Parallel Embedded Systems, etc. Deadline for submissions: January 3, 2005 June 15-17 7th IFIP International Conference on Formal Methods for Open Object-based Distributed Systems (FMOODS'2005), Athens, Greece. In conjunction with DAIS'2005 (Distributed Applications and Interoperable Systems). Topics include: Formal techniques for specification, design or analysis; Verification, testing and validation; Component-based design; Type systems for programming languages; Formal models for security; Applications and experience, carefully described; etc. Deadline for submissions: January 14, 2005 (abstracts), January 21, 2005 (full papers) June 15-17 5th IFIP WG 6.1 International Conference on Distributed Applications and Interoperable Systems (DAIS'2005), Athens, Greece. Deadline for submissions: February 1, 2005 (full papers), February 15, 2005 (work-in-progress papers). June 16-20 10th IEEE International Conference on the Engineering of Complex Computer Systems (ICECCS'2005), Shanghai, China. Topics include: Tools, environments, and languages for complex systems; Formal methods for developing complex systems; Software and system development processes for complex systems; Software review, inspection, and testing; Formal proof and model checking; Human factors and collaborative aspects; Interoperability and

Volume 25, Number 4, December 2004 Ada User Journal Conference Calendar 213

standardization; Systems and software safety and security; Industrial automation, embedded and/or real time systems; etc. June 18-23 6th International Conference on eXtreme Programming and Agile Processes in Software Engineering (XP'2005), Sheffield, UK. Topics include: Case studies, experiments and practioner's reports; Scalability issues; Refactoring and continuous integration; Use of SW development tools and environments; etc. Deadline for submissions: January 16, 2005 (papers), March 1, 2005 (tutorials, workshops, panels and activities, PhD Symposium, posters) ♦ June 20-24 10th International Conference on Reliable Software Technologies - Ada- Europe'2005, York, UK. Sponsored by Ada-Europe, in cooperation with ACM SIGAda (approval pending). Deadline for submissions: January 10, 2005 (industrial presentations) June 27-29 10th Annual Conference on Innovation and Technology in Computer Science Education (ITiCSE'2005), Monte de Caparica, Portugal. Deadline for submissions: February 14, 2005 (tips & techniques summaries, posters, demos), April 18, 2005 (working group membership application) June 27-30 2005 International Multiconference in Computer Science and Computer Engineering (IMCSE'2005), Las Vegas, Nevada, USA. Deadline for submissions: February 16, 2005 (papers) ☺June 27-30 International Conference on Programming Languages and Compilers (PLC'2005). Deadline for submissions: February 16, 2005 (papers) June 27-30 International Conference on Software Engineering Research and Practice (SERP'2005). Topics include: Formal methods in software engineering, Software engineering and high assurance systems, Software maintenance, Component-based software engineering, Quality-based software engineering, Real-time software engineering, Critical systems, Verification and validation, Software testing, Quality management, Object-oriented software engineering, Case studies, etc. Deadline for submissions: February 26, 2005 July 06-10 17th International Conference on Computer-Aided Verification (CAV'2005), Edinburgh, Scotland, UK. Topics include: Algorithms and tools for verifying models and implementations, Program analysis and software verification, Applications and case studies, Verification in industrial practice, etc. Deadline for paper submissions: January 21, 2005

July 11-15 32nd International Colloquium on Automata, Languages and Programming (ICALP'2005), Lisbon, Portugal. Topics include: Parallel and Distributed Computing; Principles of Programming Languages; Formal Methods; Program Analysis and Transformation; Specifications, Verifications and Secure Programming; etc. Affiliated Workshops on July 9-10 and 16-17, 2005. Deadline for submissions: February 13, 2005 (extended abstracts) July 11-15 1st International Conference on Open Source Systems (OSS'2005), Genova, Italy. Topics include: Introduction of OSS in companies and Public Administrations, Empirical analysis of OSS, Case studies and experiments, etc. Deadline for submissions: January 15, 2005 (extended abstracts), January 31, 2005 (tutorials, workshops, panels, demos), March 1, 2005 (abstracts for Open Educational Symposium, research plans for PhD symposium) July 17-20 24rd Annual ACM SIGACT-SIGOPS Symposium on Principles of Distributed Computing (PODC'2005), Las Vegas, Nevada, USA. Topics include: all areas of distributed systems. Deadline for submissions: February 7, 2005 July 18-22 13th International Symposium of Formal Methods Europe (FM'2005), Newcastle upon Tyne, UK. Topics include: introducing formal methods in industrial practice (technical, organizational, social, psychological aspects); reports on practical use and case studies (reporting positive or negative experiences); tool support and software engineering; environments for formal methods; etc. Deadline for submissions: January 24, 2005 (papers), March 07, 2005 (workshops, tutorials), May 09, 2005 (tools exhibition, demonstrations) July 25-28 29th Annual International Computer Software and Applications Conference (COMPSAC'2005), Edinburgh, Scotland, UK. Theme: "High Assurance Software Systems" Topics include: Dependable service provision, Trustworthy software, Software safety, Software

Ada User Journal Volume 25, Number 4, December 2004 214 Conference Calendar

fault tolerance, High performance software, Component-based software, Design patterns, Software certification, Software standards, Software engineering education, Embedded systems, Middleware systems, Automotive telematics, etc. Deadline for submissions: February 15, 2005 (regular and workshop papers), March 21, 2005 (fast abstract submissions) ☺ July 25-29 19th European Conference on Object-Oriented Programming (ECOOP'2005), Glasgow, Scotland, UK. Topics include: Concurrent, real-time and parallel systems; Design patterns; Distributed systems; Frameworks and software architectures; Language design and implementation; Programming environments; Adaptability; Formal methods; Software evolution; etc. Deadline for submissions: March 18, 2005 (PhD workshop submissions), May 6, 2005 (demos, posters, exhibitions) August 29-September 02 13th IEEE International Requirements Engineering Conference (RE'2005), Paris, France. Deadline for submissions: February 7, 2005 (abstracts), February 14, 2005 (papers), March 11, 2005 (workshops, tutorials, panels), April 28, 2005 (doctoral symposium, posters, research demonstrations) ☺ August 30-Sept. 02 11th International Conference on Parallel and Distributed Computing (Euro-Par'2005), Lisboa, Portugal. Topics include: Support Tools and Environments; Scheduling and Load Balancing; Compilers for High Performance; Distributed Systems and Algorithms; Parallel Programming: Models, Methods, and Languages; etc. Deadline for submissions: January 31, 2005 (full papers) August 30 – Sept. 03 31st EUROMICRO Conference on Software Engineering and Advanced Applications (EUROMICRO'2005), Lisboa, Portugal. Topics include: Component-Based Software Engineering, Software Process and Product Improvement, Component Models for Dependable Systems, Value- based Software Engineering, etc. Deadline for submissions: March 1, 2005 (papers) ☺ September 13-16 International Conference on Parallel Computing 2005 (ParCo2005), Malaga, Spain. Topics include: applications; software engineering methodologies, methods and tools for developing and maintaining parallel software, incl. parallel programming models and paradigms, development environments, languages, compiling and run-time tools; etc. Deadline for submissions: January 31, 2005 (abstracts, mini-symposia proposals), July 31, 2005 (draft full papers)

September 19-22 11th International Software Metrics Symposium (Metrics'2005), Como, Italy. Topics include: Effort and cost estimation; Defect rate and reliability prediction; Quality Assurance; Empirical studies of global software development projects, open source software projects, agile development projects; etc. Deadline for submissions: February 23, 2005 (abstracts), March 15, 2005 (technical papers), April 1, 2005 (workshops, dissertation forum), May 30, 2005 (industry track) September 19-23 9th International IEEE Enterprise Distributed Object Computing Conference (EDOC'2005), Enschede, The Netherlands. Deadline for submissions: March 4, 2005 (abstracts), March 18, 2005 (papers, workshops) September 25-30 21st IEEE International Conference on Software Maintenance (ICSM'2005), Budapest, Hungary. Topics include: issues related to maintaining, modifying, enhancing, and testing operational systems, and designing, building, testing, and evolving maintainable systems. Deadline for submissions: March 21, 2005 (research papers), April 30, 2005 (industrial applications, panels, tool demonstrations, dissertation forum, tutorials) October 02-07 8th International Conference on Model Driven Engineering Languages and Systems (MoDELS'2005), Montego Bay, Jamaica. Formerly the UML series of conferences. Topics include: Model-driven development methodologies, approaches, and languages; Empirical studies of modeling and model-driven development; Tool support for any aspect of model-driven development or model use; Semantics of modeling languages; etc. Deadline for submissions: March 21, 2005 (experience and scientific abstracts), April 4, 2005 (experience and scientific full papers), May 6, 2005 (workshops), June 6, 2005 (tutorials), TBA (doctoral symposium, tools and exhibits, posters and demos) ♦ November 13-17 2005 ACM SIGAda Annual International Conference (SIGAda'2005), Atlanta, Georgia, USA. December 10 Birthday of Lady Ada Lovelace, born in 1815. Happy Programmers' Day!

Volume 25, Number 4, December 2004 Ada User Journal 220 Real-Time Java™ for Ada Programmers Benjamin M Brosgol AdaCore, 79 Tobey Road, Belmont, MA 02478, USA; email: [email protected]

Abstract Dibble [3] and Wellings [4]. Additional information can be found at the website www.rtj.org. This full-day tutorial was an in-depth introduction to the Real-Time Specification for Java (“RTSJ”), a The J-Consortium published an alternative approach for class library (and JVM constraints) designed to add real-time Java in Fall 2000, the “Core Extensions” real-time behaviour and predictability to the Java document (Nilsen [5]). Despite a number of innovative platform. The RTSJ comprises several kinds of aspects (such as features that help predict Worst Case features: a scheduling framework and base scheduler, Execution Time) the Core Extensions have not yet been memory management not subject to Garbage implemented. Collection, synchronization / priority inversion The tutorial focused on the RTSJ rather than the Core control, asynchronous event handling, asynchronous Extensions, since the RTSJ has much higher likelihood of transfer of control, time-related classes, and low-level being implemented and used in practice. features. Several implementations are in progress, and work is underway on designing a subset that is 2 Java and Real-Time Programming appropriate for safety-critical applications. In order to support real-time development, a programming Keywords: real-time, Java, priority inversion, language needs to meet requirements in several areas: concurrency, garbage collection, asynchrony. • Appropriate reliability-oriented facilities, such as 1 Background and Introduction strong typing and encapsulation. During the late 1990s Java’s growing popularity as an • A concurrency mechanism with an adequate range of alternative to C++ led to several workshops, organized by priorities, well-defined scheduling semantics, the National Institute for Standards and Technology (NIST) safe/efficient mutual exclusion that allows in the US, to assess the Java platform’s viability for real- management of priority inversion, and support for time applications. These culminated in a January 1999 common idioms such as periodic activities. meeting in San Diego hosted by Aonix and attended by • Predictability of time and space utilization, particularly representatives of Sun Microsystems, hardware vendors, in the area of memory management. Predictability RTOS suppliers, researchers, and users. Two obvious also applies more generally to program execution: major technical problems were noted: the unpredictability language semantics should be deterministic and should caused by automatic garbage collection, and the lack of avoid implementation dependence. deterministic scheduling for threads. It was felt that these were solvable issues. A set of requirements was formulated • Asynchronous event handling and also timeouts / by NIST [1], and almost immediately two parallel efforts thread abort (“asynchronous transfer of control”). got underway to design a compliant specification: one • Adequate functionality for clocks / timers and low- under the auspices of Sun Microsystems’ Java Community level support. Process (JCP), and the other by a group known as the J- Consortium (who had some issues with the JCP licensing Performance is also a goal, although “real time” is not the terms). same as “real fast”. Indeed, there is sometimes a trade-off between predictability and performance or throughput. An The Sun-sanctioned effort was a Java Specification interesting contrast between the RTSJ and the Core Request, JSR-001, that came to be known as the Real-Time Extensions is that the latter strove explicitly to attain run- Specification for Java (“RTSJ”). This has gone through time efficiency comparable to traditional real-time several iterations: a pre-release in June 2000 led by Greg approaches. Bollella (then at IBM); an initial JCP-approved version in November 2001 let by Peter Haggar (IBM); and a JCP- Although Java meets many of the general reliability- approved maintenance release in August 2004 led by Peter oriented criteria and has deterministic semantics for its Dibble (Timesys). As required by JCP rules, the sequential features, it has some obvious deficiencies. In the specification is accompanied by a Reference concurrency area, the priority range (10 values) is too Implementation and Technology Compatibility Kit, both narrow, and these values do not necessarily map to distinct from Timesys. The RTSJ has been the subject of an initial priorities on the underlying native operating system. The reference book by Bollella et. al. [2], and textbooks by scheduling semantics are (intentionally) loose; indeed, the

Volume 25, Number 4, December 2004 Ada User Journal B M Brosgol 221

Java Language Specification [6] states that there is no and thus do not incur GC latency except in specialized “guarantee that the highest priority thread will always be circumstances described below. running, and thread priorities cannot be used to reliably Java’s asynchrony issues are addressed through two main implement mutual exclusion”. Priority may or may not be features. First, the RTSJ allows the definition of used in the selection of which thread to run when a lock is asynchronous events and asynchronous event handlers – released, or which thread in a wait set to make ready when these are basically a high-level mechanism for handling a notify occurs. Unbounded priority inversion may occur. hardware interrupts or software “signals”. Secondly, the Another major deficiency, which some may feel is a fatal RTSJ extends the effect of Thread.interrupt to apply not flaw, is Java’s need for garbage collection. Despite the only to blocked threads, but also to real-time threads and advances in “real-time GC”, this topic remains a research asynchronous event handlers whether blocked or not. area and is not in mainstream use. Thus any attempt to The RTSJ supports absolute and relative high-resolution adapt Java to meet real-time requirements must address the time, as well as one-shot and periodic timers. It also issue of predictable memory management. provides several classes for low-level programming. “Peek Asynchrony support in Java is weak. There is no special and poke” facilities for integral and floating-point data are mechanism for asynchronous event handling; the available for “raw memory”, and “physical memory” may programmer needs to realize such handlers as regular be defined with particular characteristics (such as flash threads, with the resulting loose semantics for scheduling. memory) and used for general object allocation. Asynchronous transfer of control was simply not well thought out in the original Java specification. The main 4 Scheduling methods for realizing this behaviour – stop() and destroy() The RTSJ combines a priority-oriented scheduling – have been deprecated because of their dangers, and in any algorithm (the base scheduler) with an extensible event destroy() has never been implemented. scheduling framework, support for on-line admission control and feasibility analysis, and a unified treatment of The other functional requirements noted above – support real-time threads and asynchronous event handers. A real- for time and timers, and access to low-level hardware time thread is an instance of the RTSJ’s RealtimeThread features – are also insufficient or absent. class. Asynchronous event handlers will be described All of these issues presented challenges in the design of the below. RTSJ. The base scheduler adds deterministic semantics (FIFO 3 RTSJ Overview within priority) to the rules for choosing which ready thread to run, which wait set member to awaken after a notify(), The contents of this section are based on Brosgol & and which “stalled” thread to unblock when a lock is Wellings [7]. released. The RTSJ provides a flexible scheduling framework based The extensible scheduling framework allows implementers on the Schedulable interface and the Thread subclass to provide additional schedulers such as Earliest Deadline RealtimeThread that implements this interface. The latter First or Round Robin. class overrides various methods with versions that add real- time functionality, and supplies new methods for operations Real-time threads and asynchronous event handlers are such as periodic scheduling. The Schedulable interface is termed schedulable objects. Constructors allow the introduced because certain schedulable entities (in establishment of various sorts of “parameters”, including particular, handlers for asynchronous events) might not be scheduling parameters (priority), release parameters (cost, implemented as threads. deadline, cost overrun handler, and deadline miss handler), and memory parameters (control over GC pacing). Support The RTSJ mandates a default POSIX-compliant preemptive for cost overrun detection is optional, given the priority-based scheduler that supports at least 28 distinct implementation difficulty on some platforms. priority levels, and that enforces Priority Inheritance to manage priority inversions. The implementation can The RealtimeThread class is an extension of provide other schedulers (e.g., Earliest Deadline First) and java.lang.Thread that implements the Schedulable priority inversion control policies (e.g., Priority Ceiling interface, itself an extension of Runnable. Besides the run() Emulation). method, there are a number of methods related to feasibility analysis. To deal with Garbage Collection issues, the RTSJ provides various memory areas that are not subject to Garbage Here is an example of a periodic real-time thread: Collection: “immortal memory”, which persists for the public class MyPeriodic extends RealtimeThread{ duration of the application; and “scoped memory”, which is public MyPeriodic( int priority, a generalization of the run-time stack. Restrictions on int periodMillis, assignment prevent dangling references. The RTSJ also int costMillis, provides a NoHeapRealtimeThread class; instances never int deadlineMillis ){ super( new PriorityParameters( priority ), reference the heap, may preempt the Garbage Collector at // SchedulingParameters any time (even when the heap is in an inconsistent state), new PeriodicParameters(

Ada User Journal Volume 25, Number 4, December 2004 222 Real-Time Java™ for Ada Programmers

// ReleaseParameters even when the GC is not at a “safe” interruption point (i.e., null, // 1st release is at start new RelativeTime( periodMillis, 0 ), when the heap is in an inconsistent state). Such real-time new RelativeTime( costMillis, 0 ), threads, instances of the NoHeapRealtimeThread class, may new RelativeTime( deadlineMillis, 0 ), only reference immortal and scoped memory areas. null, // No cost overrun handler ) null) // No deadline miss handler The rules for scoped memory are somewhat subtle, and the ); workaround to the assignment restrictions typically } involves heavy use of immortal memory. public void run(){ while (true) { The following example shows one use of scoped memory. … // Work done during each release The constructor for m creates a scoped area of size 100K RealtimeThread.waitForNextPeriod(); // Block till next release bytes. At each iteration of the loop, the area is used for } allocating objects that are created during execution of } r.run(). At the end of each iteration each object in the area MyPeriodic mp = new MyPeriodic( 30, 100, 20, 100 ); is finalized, and the area is emptied. // priority == 30, period ==100, cost ==20, // deadline == 100 void foo(){ LTMemory m = new LTMemory( 100000, 100000 ); mp.start(); // Triggers initial release for mp Runnable r = new Runnable(){ The arguments to the constructor for MyPeriodic establish public void run(){...} }; the priority, period, cost and deadline. These are in turn while ( someCondition() ){ passed to one of the superclass constructors via m.enter(r); corresponding parameters objects. The behaviour of the } } periodic real-time thread is captured in the run() method, which illustrates the RTSJ style for realizing periodicity: 6 Synchronization invoking the waitForNextPeriod method. The implementa- The RTSJ provides a general model for synchronization tion will arrange the next release automatically. control (to manage priority inversions), and specific 5 Memory Management semantics that apply to the base scheduler. The RTSJ defines a general concept of a memory area, Every object has a monitor control policy, assigned either which is a region used for object allocation. The Java heap implicitly or explicitly. The default (implicit) policy is is one such memory area, represented by a singleton class. Priority Inheritance (“PI”), but this can be changed at Another memory area is immortal memory, also system startup. (More specifically, the RTSJ defines an represented by a singleton class; objects in this area are abstract class MonitorControlPolicy and a singleton subclass never reclaimed or relocated. PriorityInheritance.) If an object governed by priority inheritance is locked by a thread t1, and another thread t2 Supplementing the heap and immortal areas are scoped attempts to lock the object, then t1’s active priority will be memory areas that are constructed under program control. increased to that of t2. This is applied recursively if t1 is As suggested by the terminology, a scoped area has a stalled waiting for an object that is currently locked by limited lifetime: it is reset (and all contained objects some other thread t3: the priority of t3 will be raised to that finalized) when it is no longer referenced by the program. of t2. Usage restrictions allow this to be implemented with a reference counting scheme – one count per area, not one The RTSJ also defines a MonitorControlPolicy subclass per allocated object. Consistent with the Java language PriorityCeilingEmulation (“PCE”) corresponding to the principles, there is no explicit free operation. Assignments “highest lockers” / priority ceiling emulation policy. An are restricted to prevent dangling references: a reference to object governed by an instance of this class has a ceiling an object in a scoped area is not allowed to be assigned to a that needs to be set (by the programmer) at least as high as field in an object that resides in the heap, in immortal the highest active priority of any thread that could lock the memory, or in an outer scope. This rule is enforced by a object. When a thread attempts to lock an object governed run-time check but could be optimized out by a clever by such a policy a check is made to ensure that the thread’s compiler. priority does not exceed the object’s ceiling. If this condition is met then either the thread’s active priority is A memory area can be used for a single object allocation, boosted to the ceiling and the thread acquires the lock (if but more typically it is “entered” and then used for all the object is unlocked) or the thread is queued (if the object object allocations during the “closure” of a method is locked). If the ceiling check fails, an exception is invocation (i.e., by the method itself or other methods and thrown. constructors directly or indirectly invoked). A memory area can also be passed to a constructor for a schedulable The combination of Priority Inheritance and PCE results in object, in which case it is used during the closure of the some subtle interactions. For example, while a thread t1 is schedulable object’s run() method. holding locks on a PCE-governed object obj1 and a PI- governed object obj2, a high priority thread t2 may attempt The user can construct real-time threads that never access to lock obj2. This would ordinarily result in t1’s inheriting the heap and that thus can pre-empt the Garbage Collector t2’s priority. However, if t2’s priority exceeds obj1’s

Volume 25, Number 4, December 2004 Ada User Journal B M Brosgol 223 ceiling, then the priority inheritance would cause t1 to have attempt to synchronize on an object then the no-heap thread a ceiling violation. Since throwing an exception in t1 may incur GC-induced latency. (This can arise if the heap- would be asynchronous, the rules instead require the using thread holds a lock on an object that the no-heap exception to be thrown in t2. realtime thread attempts to synchronize on, since the heap- using thread may cause the GC to run.) The PriorityCeilingEmulation policy is optional, since the RTSJ authors felt that it was not as widely supported as In order to help applications avoid this problem, the RTSJ priority inheritance in practice. supplies two “wait-free queue” classes. The WaitFreeWriteQueue is typically used by one writer (a no- Unlike an Ada task executing a protected operation, a heap realtime thread) and any number of readers (heap- thread is allowed to block when in synchronized code, and using threads). The write() operation is non-blocking and thus the “no-lock” optimization for Ada’s protected objects non-synchronized; read() is a blocking, synchronized does not apply in the RTSJ. An implementation can operation. The WaitFreeReadQueue is analogous. provide a lock-free version of PriorityCeilingEmulation as an Communication between a no-heap realtime thread and a optimization, but there are a number of subtleties that will heap-using thread can use these queues and thus avoid the make this optimization difficult. need to synchronize on the same object. When a thread suffers a loss of inherited priority it goes to the ready queue for its new active priority; the RTSJ 7 Asynchrony recommends that it be placed at the head, but this is not a The RTSJ offers two types of asynchrony features: requirement. asynchronous event handling, and asynchronous transfer of control. An object’s monitor control policy can be changed dynamically; it may be governed by priority inheritance at 7.1 Asynchronous Events and their Handlers one point, and priority ceiling emulation at other times. It A real-time program often has to cope with events that are can also be governed by PCE policies with different triggered asynchronously, either from hardware interrupts ceilings at different times. or from software threads. The RTSJ uses the standard Java class Position{ “listener” pattern to model this situation, but extended for private double x, y; applicability to real-time systems. Position(double x, double y, int ceiling){ this.x=x; this.y=y; One part of the model is the AsyncEvent class, which has MonitorControl.setMonitorControl( methods that allow event handlers to be registered, and also this, a method – fire() – that reflects the occurrence of the event. PriorityCeilingEmulation.instance(ceiling)); } The other part of the model is the AsyncEventHandler class. synchronized void setXY(double x, double y){ This class has constructors similar to RealtimeThread: thus this.x=x; this.y=y; asynchronous event handlers (“AEH”s) have scheduling } synchronized double[] getXY() { parameters, release parameters, etc. The class has a method return new double[2]{x, y}; – handleAsyncEvent() – that will need to be overridden on } subclassing to supply the necessary logic for event } handling. AsyncEventHandler also has a run() method, but class Sensor extends RealtimeThread{ this contains logic supplied by the implementation and is Sensor(Position p, int priority){...} ... not overridden. } In a simple scenario, when an event e is fired, all AEHs class Reporter extends RealtimeThread{ registered to handle e are released and are then scheduled Reporter(Position p, int priority){...} ... based on their parameters. When an AEH is executed, its } run() method is invoked, which in turn invokes the class Test{ handleAsyncEvent() method. public static void main(String[] args){ Position p = new Position(0.0, 0.0, 16); In a more complicated situation, an event may be “bursty”: Sensor s = new Sensor(p, 15); when fired, it may already have an AEH running, having Reporter r = new Reporter(p, 10); been scheduled in response to a previous occurrence. In s.start(); r.start(); ... this situation there is not another scheduling of the handler. } Instead, the implementation needs to keep track of the } number of pending event firings via a “fire count”; the In this example, each Position instance is governed by PCE handler will invoke handleAsyncEvent() repeatedly as long and is given a ceiling a construction time. The main as the fire count is non-zero. Methods are available that method creates Sensor and Reporter real-time threads at allow the handler to reset the fire count, since in some priority 15 and 10 respectively, and a Position object situations the iterated invocation of handleAsyncEvent() (shared by the two real-time threads) at ceiling 16. might not be desirable. Communication between a no-heap realtime thread and a An AEH needs a thread of control to execute its run() and heap-using thread raises an interesting issue. If they handleAsyncEvent() methods. The RTSJ allows the user to

Ada User Journal Volume 25, Number 4, December 2004 224 Real-Time Java™ for Ada Programmers specify that an AEH is bound to a dedicated thread: this is includes AIE on its throws clause, but that is not within accomplished by the user subclassing BoundAsync- ATC-deferred code. Synchronized statements and methods, EventHandler. Otherwise an AEH may share a thread with and also methods and constructors that lack a throws AIE other AEHs. clause, are ATC-deferred. Further, an AI method or constructor will be ATC deferred if invoked from a regular Here is an example of asynchronous event handling: (i.e., non real-time) thread. class Handler extends AsyncEventHandler{ public void handleAsyncEvent(){ An ATC request always involves, either explicitly or System.out.println("Event handled"); implicitly, a target real-time thread t and an AIE instance } aie. For example, the method call t.interrupt() posts an ATC class Example{ request to t, but the AIE instance (the system-wide AsyncEvent e = new AsyncEvent(); Handler h = new Handler(); “generic” AIE) is implicit. Because of the special rules for e.addHandler(h); AIE exception propagation, t.interrupt() would typically be e.fire(); used as a way to terminate t. It has an effect not simply } when t is blocked (which are regular Thread semantics) but When event e is fired, handler h is released. Its scheduling also when t is executing AI code. Here’s an example of and release parameters (here the defaults are implied) how to express a real-time thread’s logic so that it may be determine when it runs, at which point it simply displays a terminated asynchronously by another thread: string. class AbortableVictim extends RealtimeThread{ private void body() throws AIE{ 7.2 Asynchronous Transfer of Control ... // abortable here Asynchronous Transfer of Control (“ATC”) is a transfer of } public void run(){ control within a thread, triggered not by the thread itself but ... // not abortable here rather from some external source such as another thread or try{ an interrupt handler. It is a controversial feature. On the body(); // abortable here one hand it is difficult to define, complicated to implement } catch( AIE e ){ (especially so if efficiency is important) and hard to use ... // response to abort correctly; the possibility of ATC makes program testing } and analysis complex. Nevertheless, there are several finally{ ... // unconditional pre-shutdown actions common situations in practice for which ATC works better } (i.e. has lower latency) than polling. These include timing } out on a computation, and terminating a thread (e.g. as part } of a mode change). If another thread has a reference to an AbortableVictim v, The ATC design in the RTSJ was based on several design then the method call v.interrupt() will cause an ATC in v if v principles, including the following: is executing the body() method, since body() has a “throws AIE” clause. • No syntactic extension. Any functionality had to be realized by method calls versus new statements. Posting an ATC request to a real-time thread t basically involves throwing an AIE instance asynchronously at t, but • Non-interruptibility as the default. Code that is subject to several restrictions and special rules: susceptible to asynchronous interruption must explicitly indicate its permission. • The throwing of the exception is deferred until t is executing AI code. This avoids the problem of ATC • Deferral in critical sections. Code that must execute to from synchronized code, which could leave an object completion (specifically, synchronized code) is not inconsistent. susceptible to ATC. • Handling an exception thrown as a result of ATC does The ATC approach in the RTSJ combines low-level not automatically prevent the exception from “building blocks” with some higher level mechanisms. At propagating. This rule prevents a real-time thread its foundation are several main elements: from defeating a termination ATC by handling the • The complementary concepts of asynchronously- exception. interruptible (“AI”) and ATC deferred code • An ATC request posted to a real-time thread has no • A class AsynchronouslyInterruptedException (“AIE”), effect if performed too early (before the target thread a subclass of InterruptedException has initiated an interruptible method invocation associated with the request) or too late (after such an • A generalization of Thread.interrupt() in regular Java invocation has completed. This rule prevents an when applied to a real-time thread. asynchronous exception from being thrown in code not • A controlled form of asynchronous exception throwing prepared to handle it. The only code that is asynchronously interruptible is that The last rule is captured in the Interruptible interface and the contained textually within a method or constructor that doInterruptible and fire methods of AIE. The basic style is as follows:

Volume 25, Number 4, December 2004 Ada User Journal B M Brosgol 225

• The target thread invokes aie.doInterruptible(i) where i lack floating-point arithmetic.) Neither allows the setting is an instance of Interruptible. The effect is to invoke or retrieval of references, since that would obviously defeat i.run() synchronously Java’s strong typing and interfere with Garbage Collection. • The relevant methods to implement in i are run(), Physical memory is part of the memory area mechanism which should have a “throws AIE” clause, and and allows the user to specify immortal or scoped areas that interruptAction. have distinguished characteristics (e.g., flash memory or memory-mapped I/O). It can be used for object allocations • The run() method is the interruptible logic, and in the same way as other memory areas. interruptAction is to be invoked when run receives an ATC 10 Real-Time Java in Practice • Another thread needs to invoke aie.fire() to post the This section highlights some current implementations and ATC request to the target thread other RTSJ-related developments. The RTSJ supplies an AIE subclass, Timed, which • Reference Implementation automates the firing of the AIE and serves as a basis for the The Reference Implementation (“RI”) is part of the JSR RTSJ idiom for expressing a timeout. “product” required by Sun’s Java Community Process. The The ATC rules are complicated and sometimes current RI had previously been marketed by Timesys as counterintuitive. For example, although it might seem that their commercial jTime offering. URL: www.timesys.com finally clauses should be ATC-deferred (analogous to • jRate (Java Real-Time Extension) Finalize being abort-deferred in Ada), this would cause problems, since finally clauses are not manifest in the This effort at Washington University at St. Louis (US) is an bytecodes of the classfile. One of the constraints on the extension of the GNU GCJ front-end and run-time library, RTSJ was that the spec should not force compilers to be to support the RTSJ. changed; requiring special handling for finally clauses URL: www.cs.wustl.edu/~corsaro/jRate would violate this condition. Thus an ATC is possible from • OVM (OpenVM) a finally clause in an AI method, which complicates the style for arranging non-interruptible cleanup. This is an open-source framework for language run-time 8 Time and Timers systems, with emphasis on an RTSJ-compliant JVM. Participants are Purdue, State Univ. of New York in The RTSJ supplies an abstract HighResolutionTime class, Oswego, and Univ. of Maryland (US); and DL Tech with non-abstract subclasses for AbsoluteTime and (Australia). It is sponsored by DARPA (US). URL: RelativeTime. These classes support time measured in www.ovmj.org milliseconds and nanoseconds, relative to some clock (by • Jamaica VM default a monotonically non-decreasing real-time clock). Various methods allow converting between absolute and This is a commercial implementation of the RTSJ by aicas, relative time, and perfoming relevant arithmetic operations using F. Siebert’s Garbage Collection algorithm [8]. URL: (e.g., adding millis and nanos to an absolute or relative time www.aicas.com value). The RTSJ also supplies a RationalTime class, as a • HIDOORS Project (High-Integrity Distributed Object- subclass of RelativeTime. This class was intended to allow Oriented Realtime Systems.) expressing frequency requirements (e.g., 17 times per second) but has been deprecated because of several Partially funded by the European Commision, this anomalies that it caused. consortium comprises organizations in Germany (FZI, R.O.S.E. Informatik, aicas, EADS), Sweden (Linköpings The RTSJ defines an abstract class Timer as a subclass of Univ.), France (Aonix), and Portugal (Skysoft). Their goal AsyncEvent,. It also provides OneShotTimer and Periodic- as stated on their website is to provide “the full function- Timer as subclasses of Timer. The AsyncEventHandler ality of the modern programming language Java for the mechanism may be used to realize the event handling logic. development of distributed, realtime and safety critical 9 Low-Level Features systems and to provide a powerful environment of tools that support modeling, analysis, and proof of correctness of Two basic mechanisms are provided for dealing with low- systems developed in Java”. URL: www.hidoors.org level issues: “raw” memory, and “physical” memory. • HIJA Project (High-Integrity Java) The RTSJ supplies two classes for raw memory: RawMemoryAccess and RawMemoryFloatAccess. The This consortium comprises The Open Group, aicas, Aonix, former contains methods that allow the setting and retrieval Bellstream, Fiat Research Centre (CRF), FZI, Thales- of integral values (byte, char, int, long) from specified Avionics, Telecom Italia, Trialog, Universität Karlsruhe, addresses. The latter contains all of these methods plus Universidad Politécnica de Madrid (DIT-UPM), and ones to set and retrieve floating point values (float, double). University of York. According to their website, “the main (The reason for the two classes is that some technical objective of HIJA is to demonstrate that Java implementations of the RTSJ might be on platforms that

Ada User Journal Volume 25, Number 4, December 2004 226 Real-Time Java™ for Ada Programmers technology can form an appropriate Architecturally The potential for the RTSJ in the traditional hard real-time Neutral, high-integrity Real-Time System.” domain seems more questionable. That community’s URL: www.hija.info dominant language (and culture) is currently C, with some Ada and also other languages. They generally remain • The Open Group unconvinced of the purported benefits of OOP, and the Under the auspices of The Open Group’s Real-Time and dynamic flexibility inherent in Java is treated with Embedded Systems Forum, work got underway in mid- suspicion in systems for which static analyzability is 2003 to investigate a safety-critical Java profile that would important. be based on the RTSJ and developed under the Java Regardless of the extent of its eventual usage, the RTSJ has Community Process. This effort is in progress, although as been a formidable technical accomplishment, illustrating of late 2004 an official JSR has not yet been initiated. some interesting technology cross fertilization. A number URL: www.opengroup.org of ideas from Ada influenced the RTSJ (perhaps not too 11 Conclusions surprising, since the RTSJ design group included several members of the Ada real-time community). And in the Although “real-time Java” may sound like a contradiction, other direction, some aspects of the RTSJ may influence the RTSJ has attempted to address the deficiencies of future directions for the Ada language. Experience with the regular Java in a technical credible manner. The RTSJ will likely determine the extent of that effect. combination of a priority-based default scheduler and user- assignable monitor control policies provide deterministic Acronyms Used in This Article scheduling semantics and avoid unbounded priority AEH Asynchronous Event Handler inversions. Scoped and immortal memory areas do not AI Asynchronously Interruptible suffer garbage collection, and no-heap realtime threads AIE AsynchronouslyInterruptedException need not incur GC latency. A general scheduling ATC Asynchronous Transfer of Control framework provides extensibility and also supports on-line GC Garbage Collector feasibility analysis. The unifying concept of a schedulable JCP Java Community Process object allows both real-time threads and asynchronous JSR Java Specification Request event handlers to be analyzed consistently. And a facility JVM Java Virtual Machine for asynchronous transfer of control solves regular Java’s PCE PriorityCeiling Emulation ATC anomalies by borrowing the Ada concept of an abort- PI Priority Inheritance deferred operation; the resulting mechanism deals with RI Reference Implementation common cases such as timeouts and thread termination. RTOS Real-Time Operating System All this is achieved within the Java framework (no new RTSJ Real-Time Specification for Java syntax) and within the Java design philosophy (no explicit memory freeing). References On the other hand, the RTSJ is not yet a proven technology. [1] www.nist.gov/rt-java It is forward-thinking and ambitious, but some features

(such as the memory area-related run-time assignment [2] G. Bollella, J.Gosling, B. Brosgol, P. Dibble, S. Furr, checks) will require compiler optimizations in order to D. Hardin, M. Turnbull (2000); The Real-Time avoid performance degradation. There are a number of Specification for Java; Addison-Wesley. “rough edges” – inconsistencies or other minor errors that [3] P. Dibble (2002), Introduction to the Real-Time Java are almost inevitable when a spec is finalized before it has Platform, Prentice-Hall. been implemented. Moreover, parts of the spec are rather complex – most notably the scoped memory area [4] A. Wellings (2004), Concurrent and Real-Time semantics, and also the ATC facility. This will complicate Programming in Java, John Wiley & Sons. the implementation and present a learning barrier to [5] K. Nilsen (2000); Real-Time Core Extensions for the potential users. One of the biggest advantages to Java is Java Platform; J-Consortium. that developers can largely ignore memory management [6] J. Gosling, B. Joy, G. Steele, G. Bracha (2000); The issues, but that does not hold true for the RTSJ. If careful nd attention is not paid to how memory areas are used, the Java Language Specification (2 ed.); Addison program could incur a storage leakage or an assignment Wesley. error. [7] B. Brosgol and A. Wellings (2003); “A Comparison of These issues notwithstanding, the RTSJ is receiving the Asynchronous Transfer of Control Facilities in Ada attention from the real-time community, and several and the Real-Time Specification for Java”, Proc. Ada projects are either evaluating it or committing to its usage. Europe 2003; Springer. It will most likely succeed in areas where there is already a [8] F. Siebert (2002): Hard Realtime Garbage Collection commitment to Java for other reasons; for example, an in Modern Object Oriented Programming Languages; enterprise project that has real-time components / aicas Books. requirements.

Volume 25, Number 4, December 2004 Ada User Journal 228 Rationale for Ada 2005: Introduction John Barnes John Barnes Informatics, 11 Albert Road, Caversham, Reading RG4 7AN, UK; Tel: +44 118 947 4125; email: [email protected]

Abstract by Pascal Leroy. The editor, who at the end of the day actually writes the words of the standard, is the This is the first of a number of papers describing the indefatigable Randy (fingers) Brukardt. rationale for Ada 2005. In due course it is anticipated that the papers will be combined (after appropriate Suggestions for the revised standard have come from a reformatting and editing) into a single volume for number of sources such as individuals on the ARG, formal publication. national bodies on WG9, users via email discussions on Ada-Comment and so on. This first paper covers the background to the development of Ada 2005 and gives a brief overview At the time of writing (November 2004), the revision of the main changes from Ada 95. Later papers will process is not quite finished. However, the details of all then look at the changes in more detail. individual changes are now clear. Nevertheless, integration of the changes needs to be done and maybe a few tweaks Keywords: rationale, Ada 2005. will be necessary before the final standard emerges in late 1 Revision process 2005 or early 2006. Readers will recall that the development of Ada 95 from 2 Scope of revision Ada 83 was an extensive process funded by the USDoD. The changes from Ada 83 to Ada 95 were large. They Formal requirements were established after comprehensive included several major new items such as surveys of user needs and competitive proposals were then submitted resulting in the selection of Intermetrics as the ▪ polymorphism through tagged types, class-wide types developer under the devoted leadership of Tucker Taft. The and dispatching, whole technical development process was then ▪ the hierarchical library system including public and comprehensively monitored by a distinct body of private child packages, Distinguished Reviewers. Of course, the process was also monitored by the ISO committee concerned and the new ▪ protected objects for better real-time control, language finally became an ISO standard in 1995. ▪ more comprehensive predefined library, especially for The development of Ada 2005 from Ada 95 has been (and character and string handling, continues to be) on a more modest scale. The work has ▪ specialized annexes such as those for system almost entirely been by voluntary effort with support from programming, real-time, and numerics. within the industry itself through bodies such as the Ada Resource Association and Ada-Europe. By contrast the changes from Ada 95 to Ada 2005 are relatively modest. Ada 95 was almost a new language The development is being performed under the guidance of which happened to be compatible with Ada 83. However, a ISO/IEC JTC1/SC22 WG9 (hereinafter just called WG9) new language always brings surprises and despite very chaired adroitly by James Moore whose deep knowledge careful design things do not always turn out quite as leads us safely through the minefield of ISO procedures. expected when used in earnest. This committee has included national representatives of many nations including Belgium, Canada, France, Indeed, a number of errors in the Ada 95 standard were Germany, Italy, Japan, Sweden, Switzerland, the UK and corrected in the Corrigendum issued in 2001 [2] and then the USA. WG9 developed guidelines [1] for a revision to incorporated into the Consolidated Ada Reference Manual Ada 95 which were then used by the Ada Rapporteur [3]. But it was still essentially the same language and Group (the ARG) in drafting the revised standard. further improvement needed to be done. The ARG is a team of experts nominated by the national Technically, Ada 2005 is defined as an Amendment to bodies represented on WG9 and the two liaison rather than a Revision of the Ada 95 standard and this organizations, ACM SIGAda and Ada-Europe. The ARG captures the flavour of the changes not being very was originally led with Teutonic precision by Erhard extensive. Plödereder and is currently led with Transalpine Gallic flair

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 229

In a sense we can think of Ada 2005 as rounding out the ▪ Implementability. Can the feature be implemented at rough edges in Ada 95 rather than making major leaps reasonable cost? forward. This is perhaps not quite true of the Real-Time ▪ Need. Do users actually need it? [A good one!] Systems annex which includes much new material of an optional nature. Nevertheless I am sure that the changes ▪ Language stability. Would it appear disturbing to current will bring big benefits to users at hopefully not too much users? cost to implementors. ▪ Competition and popularity. Does it help to improve the The scope of the Amendment was guided by a document perception of Ada and make it more competitive? issued by WG9 to the ARG in September 2002 [1]. The key ▪ Interoperability. Does it ease problems of interfacing paragraph is: with other languages and systems? [That's the third "The main purpose of the Amendment is to address mention of interfacing.] identified problems in Ada that are interfering with Ada's ▪ Language consistency. Is it syntactically and usage or adoption, especially in its major application areas semantically consistent with the language's current (such as high-reliability, long-lived real-time and/or structure and design philosophy? embedded applications and very large complex systems). The resulting changes may range from relatively minor, to An important further statement is that "In order to produce more substantial." a technically superior result, it is permitted to compromise backwards compatibility when the impact on users is Note that by saying "identified problems" it implicitly judged to be acceptable." In other words don't be paranoid rejects a major redesign such as occurred with Ada 95. The about compatibility. phrase in parentheses draws attention to the areas where Ada has a major market presence. Ada has carved an Finally, there is a warning about secondary standards. Its important niche in the safety-critical areas which almost essence is don't use secondary standards if you can get the inevitably are of a real-time and/or embedded nature. But material into the RM itself. And please put the stuff on Ada is also in successful use in very large systems where vectors and matrices from ISO/IEC 13813 [5] into the the inherent reliability and composition features are language itself. The reason for this exhortation is that extremely valuable. So changes should aim to help in those secondary standards have proved themselves to be almost areas. And the final sentence is really an exhortation to invisible and hence virtually useless. steer a middle course between too much change and not The guidelines conclude with the target schedule. This enough. included WG9 approval of the scope of the amendment in The document then identifies two specific worthwhile June 2004 (this was achieved) and final ISO/IEC JCT1 changes, namely, inclusion of the Ravenscar profile [4] (for ballot in late 2005 (fingers crossed). predictable real-time) and a solution to the problem of mutually dependent types across two packages (see Section 3 Overview of changes 3.3 below). It would be tedious to give a section by section review of The ARG is then requested to pay particular attention to the changes as seen by the Reference Manual language lawyer. Instead, the changes will be presented by areas as A Improvements that will maintain or improve Ada's seen by the user. There can be considered to be six areas: advantages, especially in those user domains where safety and criticality are prime concerns. Within this 1 Improvements to the OO model. These include a more area it cites as high priority, improvements in the real- traditional notation for invoking an operation of an time features and improvements in the high integrity object without needing to know precisely where the features. Of lesser priority are features that increase operation is declared (the Obj.Op(...) style), Java-like static error checking. Improvements in interfacing to multiple inheritance using the concept of interfaces, the other languages are also mentioned. introduction of null procedures as a category of operation rather like an abstract operation, and the B Improvements that will remedy shortcomings in Ada. It ability to do type extension at a more nested level than cites in particular improvements in OO features, that of the parent type. There are also explicit features specifically, adding a Java-like interface feature and for overcoming nasty bugs that arise from confusion improved interfacing to other OO languages. between overloading and overriding. So the ARG is asked to improve both OO and real-time 2 More flexible access types. Ada 95 access types have a with a strong emphasis on real-time and high integrity hair-shirt flavour compared with other languages features. It is interesting that WG9 rejected the thought that because of the general need for explicit conversions with "design by contract" features should be added to the above named access types. This is alleviated by permitting general categories. anonymous access types in more contexts. It is also The ARG is also asked to consider the following factors in possible to indicate whether an access type is an access selecting features for inclusion: to a constant and whether a null value is permitted. Anonymous access-to-subprogram types are also introduced thus permitting so-called downward closures.

Ada User Journal Volume 25, Number 4, December 2004 230 Rationale for Ada 2005: Introduction

3 Enhanced structure and visibility control. The most rules, and the categorization of packages with pragmas important change here is the introduction of limited with Pure and Preelaborate. clauses which allow types in two packages to refer to The reader might feel that the changes are quite extensive each other (the mutual dependence problem referred to but each has an important role to play in making Ada more in the WG9 guidelines). This is done by extending the useful. Indeed many other changes were rejected as really concept of incomplete types (and introducing tagged unnecessary. These include old chestnuts such as in out and incomplete types). There are also private with clauses out parameters for functions (ugh), extensible enumeration just providing access from a private part. And there are types (a slippery slope), defaults for all generic parameters significant changes to limited types to make them more (would lead one astray), and user-defined operator symbols useful; these include initialization using limited (a nightmare). aggregates and composition using a new form of return statement. Before looking at the six areas in a little more detail it is perhaps worth saying a few words about compatibility with 4 Tasking and real-time improvements. Almost all of the Ada 95. The guidelines gave the ARG freedom to be changes are in the Real-Time Systems annex. They sensible in this area. Of course, the worst incompatibilities include the introduction of the Ravenscar profile (as are those where a valid program in Ada 95 continues to be explicitly mentioned in the WG9 guidelines) and a valid in Ada 2005 but does something different. It is number of new scheduling and dispatching policies. believed that serious incompatibilities of this nature will There are also new predefined packages for controlling never arise. There are however, a very few minor and execution time clocks and execution time budgets and benign such incompatibilities concerning the raising of for the notification of task termination and similar exceptions such as that with access parameters discussed in matters. A change related to the OO model is the Section 3.2. introduction of protected and task interfaces thereby drawing the OO and tasking aspects of the language However, incompatibilities whereby a valid Ada 95 closer together. program fails to compile in Ada 2005 are tolerable provided they are infrequent. A few such incompatibilities 5 Improvements to exceptions, generics etc. There are are possible. The most obvious cause is the introduction of some minor improvements in the exception area, three more reserved words: interface, overriding, and namely, neater ways of testing for null occurrence and synchronized. Thus if an existing Ada 95 program uses any raising an exception with a message. Two small but vital of these as an identifier then it will need modification. The numeric changes are a Mod attribute to solve problems introduction of a new category of unreserved keywords was of mixing signed and unsigned integers and a fix to the considered for these so that incompatibilities would not fixed-fixed multiplication problem (which has kept arise. However, it was felt that this was ugly, confusing, some users locked into Ada 83). There are also a number and prone to introducing nasty errors. In any event the of new pragmas: Unsuppress to complement the identifiers Overriding and Synchronized are likely to be rare Suppress pragma, Assert which was already offered by and although Interface is clearly a likely identifier most vendors, No_Return which indicates that a nevertheless to have it both as an identifier and as a procedure never returns normally; and keyword in the same program would be nasty. Note also Unchecked_Union to ease interfacing to unchecked that the pragma Interface which many compilers still unions in C. There is also the ability to have more support from Ada 83 (although not mentioned by Ada 95 at control of partial parameters of generic formal packages all) is being put into Annex J for obsolescent features. to improve package composition. 3.1 The OO model 6 Extensions to the standard library. New packages include a comprehensive Container library, mechanisms The Ada 95 OO model has been criticized as not following for directory operations and access to environment the true spirit of the OO paradigm in that the notation for variables, further operations on times and dates, the applying subprograms to objects is still dominated by the vectors and matrices material from ISO/IEC 13813 (as subprogram and not by the object concerned. directed in the WG9 guidelines) plus commonly It is claimed that real OO people always give the object required simple linear algebra algorithms. There are also first and then the method (subprogram). Thus given wide-wide character types and operations for 32-bit package P is characters, the ability to use more characters in type T is tagged ... ; identifiers, and improvements and extensions to the procedure Op(X: T; ... ); existing string packages. ... Of course, the areas mentioned above interact greatly and end P; much of 2 and 3 could be classed as improvements to the then assuming that some variable Y is declared of type T, in OO model. There are also a number of changes not Ada 95 we have to write mentioned which will mostly be of interest to experts in P.Op(Y, ... ); various areas. These cover topics such as streams, object factory functions, subtle aspects of the overload resolution in order to apply the procedure Op to the object Y whereas a real OO person would expect to write something like

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 231

Y.Op( ... ); function MI(C: Circle) is begin where the object Y comes first and only any auxiliary return 0.5 * C.Area * C.Radius**2; parameters are given in the parentheses. end MI; A real irritation with the Ada 95 style is that the package P whereas in Ada 95 we had to write containing the declaration of Op has to be mentioned as return 0.5 * Area(C) * C.Radius**2; well. (This assumes that use clauses are not being which is perhaps a bit untidy. employed as is usually the case.) However, given an object, from its type we can find its primitive operations and it is A related advantage concerns dereferencing. If we have an illogical to require the mention of the package P. access type such as Moreover, in some cases involving a complicated type type Pointer is access all Object'Class; hierarchy, it is not always obvious to the programmer just ... which package contains the relevant operation. This_One: Pointer := A_Circle'Access; The notation giving the object first is now permitted in Ada and suppose we wish to print out the coordinates and area 2005. The essential rules are that a subprogram call of the then in Ada 2005 we can uniformly write form P.Op(Y, ... ); can be replaced by Y.Op( ... ); provided Put(This_One.X_Coord); ... that Put(This_One.Y_Coord); ... Put(This_One.Area); ... -- Ada 2005 ▪ T is a tagged type, whereas in Ada 95 we have to write ▪ Op is a primitive (dispatching) or class wide operation Put(This_One.X_Coord); ... of T, Put(This_One.Y_Coord); ... Put(Area(This_One.all)); ... -- Ada 95 ▪ Y is the first parameter of Op. In Ada 2005 the dereferencing is all implicit whereas in The new dotted notation has other advantages in unifying Ada 95 some dereferencing has to be explicit which is ugly. the notation for calling a function and reading a component of a tagged type. Thus consider the following geometrical The reader might feel that this is all syntactic sugar for the example which is based on that in a (hopefully familiar) novice and of no help to real macho programmers. So we textbook [6] shall turn to the topic of multiple inheritance. In Ada 95, multiple inheritance is hard. It can sometimes be done package Geometry is type Object is abstract tagged using generics and/or access discriminants (not my record favourite topic) but it is hard work and often not possible at X_Coord: Float; all. So it is a great pleasure to be able to say that Ada 2005 Y_Coord: Float; end record; introduces real multiple inheritance in the style of Java. function Area(O: Object) return Float is abstract; The problem with multiple inheritance in the most general function MI(O: Object) return Float is abstract; case is clashes between the parents. Assuming just two end; parents, what happens if both parents have the same The type Object has two components and two primitive component (possibly inherited from a common ancestor)? operations Area and MI (Area is the area of an object and MI Do we get two copies? And what happens if both parents is its moment of inertia but the fine details of Newtonian have the same operation but with different mechanics need not concern us). The key point is that with implementations? These and related problems are the new notation we can access the coordinates and the area overcome by placing firm restrictions on the possible in a unified way. For example, suppose we derive a properties of parents. This is done by introducing the notion concrete type Circle thus of an interface. package Geometry.Circle is An interface can be thought of as an abstract type with no type Circle is new Object with record components – but it can of course have abstract operations. Radius: Float; It has also proved useful to introduce the idea of a null end record; procedure as an operation of a tagged type; we don't have function Area(C: Circle) return Float; to provide an actual body for such a null procedure (and function MI(C: Circle) return Float; indeed cannot) but it behaves as if it has a body consisting end; of just a null statement. So we might have where we have provided concrete operations for Area and package P1 is MI. Then in Ada 2005 we can access both the coordinates type Int1 is interface; and area in the same way procedure Op1(X: Int1) is abstract; procedure N(X: Int1) is null; X:= A_Circle.X_Coord; end P1; A:= A_Circle.Area; -- call of function Area Note carefully that interface is a new reserved word. We Note that since Area just has one parameter (A_Circle) there could now derive a concrete type from the interface Int1 by are no parentheses required in the call. This uniformity is well illustrated by the body of MI which can be written as type DT is new Int1 with record ... end record; procedure Op1(NX: DT);

Ada User Journal Volume 25, Number 4, December 2004 232 Rationale for Ada 2005: Introduction

We can provide some components for DT as shown Ada.Finalization is at the library level, controlled types (although this is optional). We must provide a concrete could only be declared at the library level. There are similar procedure for Op1 (we wouldn't if we had declared DT advantages in generics since currently many generics can itself as abstract). But we do not have to provide an only be instantiated at the library level. overriding of N since it behaves as if it has a concrete null The final change in the OO area to be described here is the body anyway (but we could override N if we wanted to). ability to (optionally) state explicitly whether a new We can in fact derive a type from several interfaces plus operation overrides an existing one or not. possibly one conventional tagged type. In other words we At the moment, in Ada 95, small careless errors in can derive a tagged type from several other types (the subprogram profiles can result in unfortunate consequences ancestor types) but only one of these can be a normal whose cause is often difficult to determine. This is very tagged type (it has to be written first). So assuming that Int2 much against the design goal of Ada to encourage the is another interface type and that T1 is a normal tagged type writing of correct programs and to detect errors at then all of the following are permitted compilation time whenever possible. Consider type DT1 is new T1 and Int1 with null record; with Ada.Finalization; use Ada.Finalization; type DT2 is new Int1 and Int2 with package Root is record ... end record; type T is new Controlled with ... ; procedure Op(Obj: in out T; Data: in Integer); type DT3 is new T1 and Int1 and Int2 ... procedure Finalise(Obj: in out T); It is also possible to compose interfaces to create further end Root; interfaces thus Here we have a controlled type plus an operation Op of that type Int3 is interface and Int1; type. Moreover, we intended to override the automatically ... inherited null procedure Finalize of Controlled but, being type Int4 is interface and Int1 and Int2 and Int3; foolish, we have spelt it Finalise. So our new procedure Note carefully that new is not used in this construction. does not override Finalize at all but merely provides Such composed interfaces have all the operations of all another operation. Assuming that we wrote Finalise to do their parents and further operations can be added in the something useful then we will find that nothing happens usual way but of course these must be abstract or null. when an object of the type T is automatically finalized at the end of a block because the inherited null procedure is There are a number of simple rules to resolve what happens called rather than our own code. This sort of error can be if two parent interfaces have the same operation. Thus a very difficult to track down. null procedure overrides an abstract one but otherwise repeated operations have to have the same profile. In Ada 2005 we can protect against such errors since it is possible to mark overridden operations as such thus Some more extensive examples of the use of interfaces will be given in a later paper. overriding procedure Finalize(Obj: in out T); Incidentally, the newly introduced null procedures are not And now if we spell Finalize incorrectly then the compiler just for interfaces. We can give a null procedure as a will detect the error. Note that overriding is another new specification whatever its profile and no body is then reserved word. However, partly for reasons of required or allowed. But they are clearly of most value with compatibility, the use of overriding indicators is optional; tagged types and inheritance. Note in particular that the there are also deeper reasons concerning private types and package Ada.Finalization in Ada 2005 is generics which will be discussed in a later paper. package Ada.Finalization is pragma Preelaborate(Finalization); Similar problems can arise if we get the profile wrong. pragma Remote_Types(Finalization); Suppose we derive a new type from T and attempt to type Controlled is abstract tagged private; override Op thus procedure Initialize(Object: in out Controlled) is null; procedure Adjust(Object: in out Controlled) is null; package Root.Leaf is procedure Finalize(Object: in out Controlled) is null; type NT is new T with null record; procedure Op(Obj: in out NT; Data: in String); -- similarly for Limited_Controlled end Root.Leaf; ... end Ada.Finalization; In this case we have given the identifier Op correctly but the profile is different because the parameter Data has The procedures Initialize, Adjust, and Finalize are now inadvertently been declared as of type String rather than explicitly given as null procedures. This is only a cosmetic Integer. So this new version of Op will simply be an change since the Ada 95 RM states that the default overloading rather than an overriding. Again we can guard implementations have no effect. However, this neatly against this sort of error by writing clarifies the situation and removes ad hoc semantic rules. overriding Another important change is the ability to do type procedure Op(Obj: in out NT; Data: in Integer); extension at a level more nested than that of the parent On the other hand maybe we truly did want to provide a type. This means that controlled types can now be declared new operation. In this case we can write not overriding and at any level whereas in Ada 95, since the package

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 233 the compiler will then ensure that the new operation is raised; technically the underlying type still has a null value indeed not an overriding of an existing one thus but Acc_Animal does not. We can also write not null access not overriding constant and not null access all of course. procedure Op(Obj: in out NT; Data: in String); The advantage of using a null exclusion is that when we The use of these overriding indicators prevents errors come to do a dereference during maintenance. Thus if later we add a further Number_of_Legs: Integer := My_Animal.Legs; parameter to Op for the root type T then the use of the indicators will ensure that we modify all the derived types then no check is required to ensure that we do not appropriately. dereference a null pointer. This makes the code faster. 3.2 Access types Exactly the same freedom also applies to access parameters. Thus we can write all of the following in Ada It has been said that playing with pointers is like playing 2005 with fire – properly used all is well but carelessness can lead to disaster. In order to avoid disasters, Ada 95 takes a procedure P(Beast: access Animal); procedure P(Beast: access constant Animal); stern view regarding the naming of access types and their procedure P(Beast: access all Animal); conversion. However, experience has shown that the Ada procedure P(Beast: not null access Animal); 95 view is perhaps unnecessarily stern and leads to tedious procedure P(Beast: not null access constant Animal); programming. procedure P(Beast: not null access all Animal); We will first consider the question of giving names to A little quirk is that all doesn't do anything in this context access types. In Ada 95 all access types are named except since access parameters always were general (that is, they for access parameters and access discriminants. Thus we could refer to declared objects as well as to allocated ones). might have Note what is in practice a minor incompatibility, the first of type Animal is tagged the above now permits a null value as actual parameter in record Legs: Integer; ... end record; Ada 2005 whereas it was forbidden in Ada 95. This is type Acc_Animal is access Animal; -- named actually a variation at runtime which is normally procedure P(Beast: access Animal; ... ); -- anonymous considered abhorrent. But in this case it just means that any check that will still raise Constraint_Error will be in a Moreover, there is a complete lack of symmetry between different place – and in any event the program was named access types and access parameters. In the case of presumably incorrect. named access types, they all have a null value (and this is the default on declaration if no initial value be given). But Another change in Ada 2005 is that we can use anonymous in the case of access parameters, a null value is not access types other than just as parameters (and permitted as an actual parameter. Furthermore, named discriminants). We can in fact also use anonymous access access types can be restricted to be access to constant types types in such as ▪ the declaration of stand-alone objects and components of type Rigid_Animal is access constant Animal; arrays and records, which means that we cannot change the value of the Animal ▪ a renaming declaration, referred to. But in the case of access parameters, we cannot say ▪ a function return type.

procedure P(Beast: access constant Animal); -- not 95 Thus we can extend our farmyard example In Ada 2005 almost all these various restrictions are swept type Horse is new Animal with ... ; away in the interests of flexibility and uniformity. type Acc_Horse is access all Horse; type Acc_Pig is access all Pig; First of all we can explicitly specify whether an access type Napoleon, Snowball: Acc_Pig := ... ; (strictly subtype) has a null value. We can write Boxer, Clover: Acc_Horse := ... ; type Acc_Animal is not null access all Animal'Class; and now we can declare an array of animals This means that we are guaranteed that an object of type Animal_Farm: constant array (Positive range <>) of Acc_Animal cannot refer to a null animal. And so on access Animal'Class := declaration such an object should be initialized as in the (Napoleon, Snowball, Boxer, Clover); following sequence (With acknowledgments to George Orwell.) Note that the type Pig is new Animal with ... ; components of the array are of an anonymous access type. Empress_Of_Blandings: aliased Pig := ... ; We can also have record components of an anonymous My_Animal: Acc_Animal := -- must initialize type Empress_Of_Blandings'Access; type Ark is (The Empress of Blandings is a famous pig in the novels record concerning Lord Emsworth by the late P G Wodehouse.) If Stallion, Mare: access Horse; Boar, Sow: access Pig; we forget to initialize My_Animal then Constraint_Error is

Ada User Journal Volume 25, Number 4, December 2004 234 Rationale for Ada 2005: Introduction

Cockerel, Hen: access Chicken; function Integrate(Fn: Integrand; Lo, Hi: Float) Ram, Ewe: access Sheep; return Float; ... end record; The idea is that the function Integrate finds the value of the Noahs_Ark: Ark := (Boxer, Clover, ... ); integral of the function passed as parameter Fn between the limits Lo and Hi. This works fine in Ada 95 for simple cases This is not a very good example since I am sure that Noah such as where the function is declared at library level. Thus took care to take actual animals into the Ark and not merely to evaluate their addresses. ⌠1 A more useful example is given by the classic linked list. In │ √x dx Ada 95 (and Ada 83) we have ⌡0 type Cell; type Cell_Ptr is access Cell; we can write type Cell is Result := Integrate(Sqrt'Access, 0.0, 1.0); record Next: Cell_Ptr; where the function Sqrt is from the library package Value: Integer; Ada.Numerics.Elementary_Functions. end record; However, if the function to be integrated is more elaborate In Ada 2005, we do not have to declare the type Cell_Ptr in then we run into difficulty in Ada 95 if we attempt to use order to declare the type Cell and so we do not need to use access to subprogram types. Consider the following the incomplete declaration to break the circularity. We can example which aims to compute the integral of the simply write expression xy over the square region 0 ≤ x, y ≤ 1. type Cell is record with Integrate; Next: access Cell; procedure Main is Value: Integer; function G(X: Float) return Float is end record; function F(Y: Float) return Float is begin Here we have an example of the use of the type name Cell return X*Y; within its own declaration. In some cases this is interpreted end F; begin as referring to the current instance of the type (for example, return Integrate(F'Access, 0.0, 1.0); -- illegal in 95 in a task body) but the rule has been changed to permit its end G; usage as here. Result: Float; We can also use an anonymous access type for a single begin Result:= Integrate(G'Access, 0.0, 1.0); -- illegal in 95 variable such as ... List: access Cell := ... ; end Main; An example of the use of an anonymous access type for a But this is illegal in Ada 95 because of the accessibility function result might be in another animal function such as rules necessary with named access types in order to prevent dangling references. Thus we need to prevent the function Mate_Of(A: access Animal'Class) return access Animal'Class; possibility of storing a pointer to a local subprogram in a global structure. This means that both F'Access and We could then perhaps write G'Access are illegal in the above. if Mate_Of(Noahs_Ark.Ram) /= Noahs_Ark.Ewe then G ... -- better get Noah to sort things out Note that although we could make the outer function end if; global so that G'Access would be allowed nevertheless the function F has to be nested inside G in order to gain access Anonymous access types can also be used in a renaming to the parameter X of G. It is typical of functions being declaration. This and other detailed points on matters such integrated that they have to have information passed as accessibility will be discussed in a later paper. globally – the number of parameters of course is fixed by The final important change in access types concerns access the profile used by the function Integrate. to subprogram types. Access to subprogram types were introduced into Ada 95 largely for the implementation of The solution in Ada 2005 is to introduce anonymous access callback. But important applications of such types in other to subprogram types by analogy with anonymous access to languages (going back to Pascal and even Algol 60) are for object types. Thus the function Integrate becomes mathematical applications such as integration where a function Integrate(Fn: access function(X: Float) return Float; function to be manipulated is passed as a parameter. The Lo, Hi: Float) return Float; Ada 83 and Ada 95 approach has always been to say "use Note that the parameter Fn has an anonymous type defined generics". But this can be clumsy and so a direct alternative by the profile so that we get a nesting of profiles. This may is now provided. seem a bit convoluted but is much the same as in Pascal. Recall that in Ada 95 we can write The nested example above is now valid and no accessibility type Integrand is access function(X: Float) return Float; problems arise. (The reader will recall that accessibility

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 235 problems with anonymous access to object types are cannot do this because both the incomplete declaration and prevented by a runtime check; in the case of anonymous its completion have to be in the same package. access to subprogram types the corresponding problems are The net outcome is that we end up with giant cumbersome prevented by decreeing that the accessibility level is packages. infinite.) What we need therefore is some way of logically enabling Anonymous access to subprogram types are also useful in the incomplete view and the completion to be in different many other applications such as iterators as will be packages. The elderly might remember that in the 1980 illustrated later. version of Ada the situation was even worse – the Note that we can also prefix all access to subprogram types completion had to be in the same list of declarations as the both named and anonymous by not null in the same way as incomplete declaration. Ada 83 relaxed this (the so-called for access to object types. Taft Amendment) and permits the private part and body to be treated as one list – the same rule applies in Ada 95. We 3.3 Structure, visibility and limited types now go one step further. Structure is vital for controlling visibility and thus abstraction. There were huge changes in Ada 95. The Ada 2005 solves the problem by introducing a variation on whole of the hierarchical child unit mechanism was the with clause – the limited with clause. The idea is that a introduced with both public and private children. It was library package (and subprogram) can refer to another hoped that this would provide sufficient flexibility for the library package that has not yet been declared and can refer future. to the types in that package but only as if they were incomplete types. Thus we might have a root package But one problem has remained. Suppose we have two types Geometry containing the declarations of Object, Max, Index where each wishes to refer to the other. Both need to come and so on and then first! Basically we solve the difficulty by using incomplete limited with Geometry.Lines; types. We might have a drawing package concerning points package Geometry.Points is and lines in a symmetric way. Each line contains a list or type Acc_Line_Array is array (1 .. Max) of array of the points on it and similarly each point contains a access Lines.Line; list or array of the lines through it. We can imagine that type Point is new Object with they are both derived from some root type containing record printing information such as colour. In Ada 95 we might No_Of_Lines: Index; write LL: Acc_Line_Array; ... type Object is abstract tagged end record; record ... Its_Colour: Colour; end Geometry.Points; ... end record; The package Geometry.Lines is declared in a similar way. type Point; Note especially that we are using the anonymous access type Line; type facility discussed in Section 3.2 and so we do not even type Acc_Point is access all Point; type Acc_Line is access all Line; have to declare named access types such as Acc_Line in order to declare Acc_Line_Array. subtype Index is Integer range 0 .. Max; type Acc_Line_Array is array (1 .. Max) of Acc_Line; By writing limited with Geometry.Lines; we get access to all type Acc_Point_Array is array (1 .. Max) of Acc_Point; the types visible in the specification of Geometry.Lines but type Point is new Object with as if they were declared as incomplete. In other words we record No_Of_Lines: Index; get an incomplete view of the types. We can then do all the LL: Acc_Line_Array; things we can normally do with incomplete types such as ... use them to declare access types. (Of course the end record; implementation checks later that Geometry.Lines does type Line is new Object with actually have a type Line.) record No_Of_Points: Index; Not only is the absence of the need for a named type PP: Acc_Point_Array; ... Acc_Line a handy shorthand, it also prevents the end record; proliferation of named access types. If we did want to use a This is very crude since it assumes a maximum number named type Acc_Line in both packages then we would have Max of points on a line and vice versa and declares the to declare a distinct type in each package. This is because arrays accordingly. The reader can flesh it out more from the point of view of the package Points, the Acc_Line flexibly. Well this is all very well but if the individual types in Lines would only be an incomplete type (remember each get elaborate and each has a series of operations, we might package only has a limited view of the other) and thus want to declare them in distinct packages (perhaps child would be essentially unusable. The net result would be packages of that containing the root type). In Ada 95 we many named access types and wretched type conversions all over the place.

Ada User Journal Volume 25, Number 4, December 2004 236 Rationale for Ada 2005: Introduction

There are also some related changes to the notation for Note that the public child and private child might have incomplete types. We can now write mutually declared types as well in which case they might type T is tagged; also wish to use the limited with facility. In this case the public child would have a limited private with clause for and we are then guaranteed that the full declaration will the private child written thus reveal T to be a tagged type. The advantage is that we also know that, being tagged, objects of the type T will be limited private with App.Secret_Details; package App.User_View is ... passed by reference. Consequently we can use the type T for parameters before seeing its full declaration. In the In the case of a parent package, its specification cannot example of points and lines above, since Line is visibly have a with clause for a child (logically the specification tagged in the package Geometry.Lines we will thus get an cannot know about the child because the parent must be incomplete tagged view of Lines. declared, that is put into the program library, first). Similarly a parent cannot have a private with clause for a The introduction of tagged incomplete types clarifies the private child. But it can have a limited with clause for any ability to write child (thereby breaking the circularity) and in particular it type T_Ptr is access all T'Class; can have a limited private with clause for a private child. This was allowed in Ada 95 even though we had not So we might also have declared T as tagged at this point. Of course it implied that limited private with App.Secret_Details; T would be tagged. In Ada 2005 this is frowned upon since package App is ... we should now declare that T is tagged incomplete if we The final topic in this section is limited types. The reader wish to declare a class wide access type. For compatibility will recall that the general idea of a limited type is to the old feature has been retained but banished to Annex J restrict the operations that the user can perform on a type to for obsolescent features. just those provided by the developer of the type and in particular to prevent the user from doing assignment and Further examples of the use of limited with clauses will be thus making copies of an object of the type. given in a later paper. However, limited types have never quite come up to Another enhancement in this area is the introduction of expectation both in Ada 83 and Ada 95. Ada 95 brought private with clauses which overcome a problem with significant improvements by disentangling the concept of a private child packages. limited type from a private type but problems have Private child packages were introduced to enable the details remained. of the implementation of part of a system to be decomposed The key problem is that Ada 95 does not allow the and yet not be visible to the external world. However, it is initialization of limited types because of the view that often convenient to have public packages that use these initialization requires assignment and thus copying. A details but do not make them visible to the user. In Ada 95 consequence is that we cannot declare constants of a a parent or sibling body can have a with clause for a private limited type either. Ada 2005 overcomes this problem by child. But the specifications cannot. These rules are allowing initialization by aggregates. designed to ensure that information does not leak out via the visible part of a specification. But there is no logical As a simple example, consider reason why the private part of a package should not have type T is limited access to a private child. Ada 2005 overcomes this by record introducing private with clauses. We can write A: Integer; B: Boolean; private package App.Secret_Details is C: Float; type Inner is ... end record; ... -- various operations on Inner etc end App.Secret_Details; in which the type as a whole is limited but the components private with App.Secret_Details; are not. If we declare an object of type T in Ada 95 then we package App.User_View is have to initialize the components (by assigning to them) type Outer is private; individually thus ... -- various operations on Outer visible to the user X: T; begin -- type Inner is not visible here X.A := 10; X.B := True; X.C := 45.7; private -- type Inner is visible here Not only is this annoying but it is prone to errors as well. If type Outer is we add a further component D to the record type T then we record might forget to initialize it. One of the advantages of X: Secret_Details.Inner; ... aggregates is that we have to supply all the components end record; (allowing automatic so-called full coverage analysis, a key ... benefit of Ada). end App.User_View; Ada 2005 allows the initialization with aggregates thus thus the private part of the public child has access to the type Inner but it is still hidden from the external user. X: T := (A => 10, B => True, C => 45.7);

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 237

Technically, Ada 2005 just recognizes properly that plus a pragma Restrictions with a host of arguments such as initialization is not assignment. Thus we should think of the No_Abort_Statements, No_Asynchronous_Control, and individual components as being initialized individually in No_Dynamic_Priorities. situ – an actual aggregated value is not created and then The pragma Detect_Blocking plus many of the Restrictions assigned. (Much the same happens when initializing identifiers are new to Ada 2005. Further details will be controlled types with an aggregate.) given in a later paper. Sometimes a limited type has components where an initial Ada 95 allows the priority of a task to be changed but does value cannot be given. This happens with task and not permit the ceiling priority of a protected object to be protected types. For example changed. This is rectified in Ada 2005 by the introduction protected type Semaphore is ... ; of an attribute Priority for protected objects and the ability type PT is to change it by a simple assignment such as record Guard: Semaphore; My_PO'Priority := P; Count: Integer; inside a protected operation of the object My_PO. The Finished: Boolean := False; end record; change takes effect at the end of the protected operation. Remember that a protected type is inherently limited. This The monitoring and control of execution time naturally are means that the type PT is limited because a type with a important for real-time programs. Ada 2005 includes limited component is itself limited. It is good practice to packages for three different aspects of this explicitly put limited on the type PT in such cases but it has Ada.Execution_Time – this is the root package and enables been omitted here for illustration. Now we cannot give an the monitoring of execution time of individual tasks. explicit initial value for a Semaphore but we would still like to use an aggregate to get the coverage check. In such Ada.Execution_Time.Timers – this provides facilities for cases we can use the box symbol <> to mean use the default defining and enabling timers and for establishing a value for the type (if any). So we can write handler which is called by the run time system when the execution time of the task reaches a given value. X: PT := (Guard => <>, Count => 0, Finished => <>); Note that the ability to use <> in an aggregate for a default Ada.Execution_Time.Group_Budgets – this enables several value is not restricted to the initialization of limited types. tasks to share a budget and provides means whereby It is a new feature applicable to aggregates in general. But, action can be taken when the budget expires. in order to avoid confusion, it is only permitted with named The execution time of a task or CPU time as it is commonly notation. called is the time spent by the system executing the task Limited aggregates are also allowed in other similar and services on its behalf. CPU times are represented by contexts where copying is not involved including as actual the private type CPU_Time. The CPU time of a particular parameters of mode in. task is obtained by calling the following function Clock in the package Ada.Execution_Time There are also problems with returning results of a limited function Clock(T: Task_ID := Current_Task) type from a function. This is overcome in Ada 2005 by the return CPU_Time; introduction of an extended form of return statement. This will be described in detail in a later paper. A value of type CPU_Time can be converted to a Seconds_Count plus residual Time_Span by a procedure 3.4 Tasking and real-time facilities Split similar to that in the package Ada.Real_Time. Unless mentioned otherwise all the changes in this section Incidentally we are guaranteed that the granularity of CPU concern the Real-Time Systems annex. times is no greater than one millisecond and that the range is at least 50 years. First, the well-established Ravenscar profile is included in Ada 2005 as directed by WG9. A profile is a mode of In order to find out when a task reaches a particular CPU operation and is specified by the pragma Profile which time we use the facilities of the child package defines the particular profile to be used. Thus to ensure that Ada.Execution_Time.Timers. This includes a discriminated a program conforms to the Ravenscar profile we write type Timer and a type Handler thus pragma Profile(Ravenscar); type Timer(T: access Task_ID) is limited private; type Handler is access The purpose of Ravenscar is to restrict the use of many of protected procedure (TM: in out Timer); the tasking facilities so that the effect of the program is We can then set the timer to expire at some absolute time predictable. This is very important for real-time safety- by critical systems. In the case of Ravenscar the pragma is equivalent to the joint effect of the following pragmas Set_Handler(My_Timer, Time_Limit, My_Handler'Access); pragma Task_Dispatching_Policy(FIFO_Within_Priorities); and then when the CPU time of the task reaches Time_Limit pragma Locking_Policy(Ceiling_Locking); (of type CPU_Time), the protected procedure My_Handler pragma Detect_Blocking; is executed. Note how the timer object incorporates the information regarding the task concerned using an access

Ada User Journal Volume 25, Number 4, December 2004 238 Rationale for Ada 2005: Introduction discriminant and that this is passed to the handler via its Readers will recall the old problem of how tasks can have a parameter. Another version of Set_Handler enables the silent death. If something in a task goes wrong in Ada 95 timer to be triggered after a given interval (of type and an exception is raised which is not handled by the task, Time_Span). then it is propagated into thin air and just vanishes. It was always deemed impossible for the exception to be handled In order to program various aperiodic servers it is necessary by the enclosing unit because of the inherent asynchronous for tasks to share a CPU budget. This can be done using the nature of the event. child package Ada.Execution_Time.Group_Budgets. In this case we have This is overcome in Ada 2005 by the package type Group Budget is limited private; Ada.Task_Termination which provides facilities for type Handler is access associating a protected procedure with a task. The protected protected procedure (GB: in out Group_Budget); procedure is invoked when the task terminates with an The type Group_Budget both identifies the group of tasks it indication of the reason. Thus we might declare a protected belongs to and the size of the budget. Various subprograms object Grim_Reaper enable tasks to be added to and removed from a group protected Grim_Reaper is budget. Other procedures enable the budget to be set and procedure Last_Gasp(C: Cause_Of_Termination; replenished. T: Task_Id; X: Exception_Occurrence); end Grim_Reaper; A procedure Set_Handler associates a particular handler We can then nominate Last_Gasp as the protected with a budget. procedure to be called when task T dies by Set_Handler(GB => My_Group_Budget, Ada.Task_Termination.Set_Specific_Handler(T'Identity, Handler => My_Handler'Access); Last_Gasp'Access); When the group budget expires the associated protected The body of protected procedure Last_Gasp might then procedure is executed. output various diagnostic messages A somewhat related topic is that of low level timing events. procedure Last_Gasp(C: Cause_Of_Termination; The facilities are provided by the package T: Task_Id; X: Exception_Occurrence) is Ada.Real_Time.Timing_Events. In this case we have begin case C is type Timing_Event is limited private; when Normal => null; type Timing_Event_Handler is access when Abnormal => protected procedure (Event: in out Timing_Event); Put("Something nasty happened"); ... when Unhandled_Exception => The idea here is that a protected procedure can be Put("Unhandled exception occurred"); ... nominated to be executed at some time in the future. Thus end case; end Last_Gasp; to ring a pinger when our egg is boiled after four minutes we might have a protected procedure There are three possible reasons for termination, it could be normal, abnormal, or caused by an unhandled exception. In protected body Egg is procedure Is_Done (Event: in out Timing_Event) is the last case the parameter X gives details of the exception begin occurrence. Ring_The_Pinger; end Is_Done; Another area of increased flexibility in Ada 2005 is that of end Egg; task dispatching policies. In Ada 95, the only predefined and then policy is FIFO_Within_Priorities although other policies are permitted. Ada 2005 provides further pragmas, policies and Egg_Done: Timing_Event; Four_Min: Time_Span := Minutes(4); packages which facilitate many different mechanisms such ... as non-preemption within priorities, the familiar Round Put_Egg_In_Water; Robin using timeslicing, and the more recently acclaimed Set_Handler(Event => Egg_Done, In_Time => Four_Min, Handler => Egg.Is_Done'Access); Earliest Deadline First (EDF) policy. Moreover it is -- now read newspaper whilst waiting for egg possible to mix different policies according to priority level within a partition. This facility is of course very low level and does not involve Ada tasks at all. Note that we can set the event to Various facilities are provided by the package occur at some absolute time as well as at a relative time as Ada.Dispatching plus two child packages above. Incidentally, the function Minutes is a new function Ada.Dispatching – this is the root package and simply added to the parent package Ada.Real_Time. Otherwise we declares an exception Dispatching_Policy_Error. would have had to write something revolting such as 4*60*Milliseconds(1000). A similar function Seconds has Ada.Dispatching.Round_Robin – this enables the setting of also been added. the time quanta for time slicing within one or more priority levels. There is a minor flaw in the above example. If we are interrupted by the telephone between putting the egg in the Ada.Dispatching.EDF – this enables the setting of the water and setting the handler then our egg will be deadlines for various tasks. overdone. We will see how to cure this in a later paper.

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 239

A policy can be selected for a whole partition by one of procedure Process_Ex(X: Exception_Occurrence) is begin pragma Task_Dispatching_Policy if Exception_Identity(X) = Null_Id then (Non_Preemptive_FIFO_Within_Priorities); -- process the case of a Null_Occurrence pragma Task_Dispatching_Policy ... (Round_Robin_Within_Priorities); end Process_Ex; pragma Task_Dispatching_Policy Ada 95 introduced modular types which are of course (EDF_Across_Priorities); unsigned integers. However it has in certain cases proved In order to mix different policies across different priority very difficult to get unsigned integers and signed integers levels we use the pragma Priority_Specific_Dispatching with to work together. This is a trivial matter in fragile various policy identifiers thus languages such as C but in Ada the type model has proved obstructive. The basic problem is converting a value of a pragma Priority_Specific_Dispatching (Round_Robin_Within_Priority, 1, 1); signed type which happens to be negative to an unsigned pragma Priority_Specific_Dispatching type. Thus suppose we want to add a signed offset to an (EDF_Across_Priorities, 2, 10); unsigned address value, we might have pragma Priority_Specific_Dispatching (FIFO_Within_Priority, 11, 24); type Offset_Type is range -(2**31) .. 2**31-1; type Address_Type is mod 2**32; This sets Round Robin at priority level 1, EDF at levels 2 Offset: Offset_Type; to 10, and FIFO at levels 11 to 24. Address: Address_Type; The final topic in this section concerns the core language We cannot just add Offset to Address because they are of and not the Real-Time Systems annex. Ada 2005 different types. If we convert the Offset to the address type introduces a means whereby object oriented and real-time then we might get Constraint_Error and so on. The solution features can be closely linked together through inheritance. in Ada 2005 is to use a new functional attribute S'Mod Recall from Section 3.1 that we can declare an interface which applies to any modular subtype S and converts a thus universal integer value to the modular type using the corresponding mathematical mod operation. So we can now type Int is interface; write We can also declare an interface to be limited, Address := Address + Address_Type'Mod(Offset); synchronized, task, or protected thus Another new attribute is Machine_Rounding. This enables type Intlim is limited interface; high-performance conversions from floating point types to type Intsync is synchronized interface; type Inttask is task interface; integer types when the exact rounding does not matter. type Intprot is protected interface; The third numeric change concerns fixed point types. It was A task interface or protected interface has to be common practice in some Ada 83 programs to define their implemented by a task type or protected type respectively. own multiply and divide operations, perhaps to obtain However, a synchronized interface can be implemented by saturation arithmetic. These programs ran afoul of the Ada either a task type or a protected type. These interfaces can 95 rules that introduced universal fixed operations resulting also be composed with certain restrictions. Detailed in ambiguities. Without going into details, this problem has examples will be given in a later paper. been fixed in Ada 2005 so that user-defined operations can 3.5 Exceptions, numerics, generics etc now be used. As well as the major features discussed above there are also Ada 2005 has several new pragmas. The first is a number of improvements in various other areas. pragma Unsuppress(Identifier); There are two small changes concerning exceptions. One is where the identifier is that of a check such as that we can give a message with a raise statement, thus Range_Check. The general idea is to ensure that checks are raise Some_Error with "A message"; performed in a declarative region irrespective of the use of a corresponding pragma Suppress. Thus we might have a This is a lot neater than having to write (as in Ada 95) type My_Int that behaves as a saturated type. Writing Ada.Exceptions.Raise_Exception(Some_Error'Identity, function "*" (Left, Right: My_Int) return My_Int is "A message"); pragma Unsuppress(Overflow_Check); The other change concerns the detection of a null exception begin return Integer(Left) * Integer(Right); occurrence which might be useful in a package analysing a exception log of exceptions. The problem is that occurrences are of a when Constraint_Error => limited private type and so we cannot compare an if (Left>0 and Right>0) or (Left<0 and Right<0) then occurrence with Null_Occurrence to see if they are equal. In return My_Int'Last; else Ada 95 applying the function Exception_Identity to a null return My_Int'First; occurrence unhelpfully raises Constraint_Error. This has end if; been changed in Ada 2005 to return Null_Id so that we can end "*"; now write ensures that the code always works as intended even if checks are suppressed in the program as a whole.

Ada User Journal Volume 25, Number 4, December 2004 240 Rationale for Ada 2005: Introduction

Incidentally the On parameter of pragma Suppress which One problem with pragmas (and attributes) is that many never worked well has been banished to Annex J. implementations have added implementation defined ones (as they are indeed permitted to do). However, this can Many implementations of Ada 95 support a pragma Assert impede portability from one implementation to another. To and this is now consolidated into Ada 2005. The general overcome this there are further Restrictions identifiers so idea is that we can write pragmas such as we can write pragma Assert(X >50); pragma Restrictions(No_Implementation_Pragmas, pragma Assert(not Buffer_Full, "buffer is full"); No_Implementation_Attributes); The first parameter is a Boolean expression and the second Observe that one of the goals of Ada 2005 has been to optional parameter is a string. If at the point of the pragma standardize as many of the implementation defined at execution time, the expression is False then action can be attributes and pragmas as possible. taken. The action is controlled by another pragma Readers might care to consider the paradox that GNAT has Assertion_Policy which can switch the assertion mechanism on and off by one of an (implementation-defined) restrictions identifier No_Implementation_Restrictions. pragma Assertion_Policy(Check); pragma Assertion_Policy(Ignore); Another new restrictions identifier prevents us from If the policy is to check then the exception Assertion_Error inadvertently using features in Annex J thus is raised with the message if any. This exception is declared pragma Restrictions(No_Obsolescent_Features); in the predefined package Ada.Assertions. There are some Similarly we can use the restrictions identifier other facilities as well. No_Dependence to state that a program does not depend on The pragma No_Return is also related to exceptions. It can a given language defined package. Thus we might write be applied to a procedure (not to a function) and indicates pragma Restrictions(No_Dependence => that the procedure never returns normally but only by Ada.Command_Line); propagating an exception. Thus we might have The final new general feature concerns formal generic procedure Fatal_Error(Message: String); package parameters. Ada 95 introduced the ability to have pragma No_Return(Fatal_Error); formal packages as parameters of generic units. This And now whenever we call Fatal_Error the compiler is greatly reduced the need for long generic parameter lists assured that control is not returned and this might enable since the formal package encapsulated them. some optimization or better diagnostic messages. Sometimes it is necessary for a generic unit to have two (or Note that this pragma applies to the predefined procedure more) formal packages. When this happens it is often the Ada.Exceptions.Raise_Exception. case that some of the actual parameters of one formal package must be identical to those of the other. In order to Finally there is the pragma Unchecked_Union. This is permit this there are two forms of generic parameters. One useful for interfacing to programs written in C that use the possibility is concept of unions. Unions in C correspond to variant types in Ada but do not store any discriminant which is entirely generic with package P is new Q(<>); in the mind of the C programmer. The pragma enables a C package Gen is ... union to be mapped to an Ada variant record type by omitting the storage for the discriminant. and then the package Gen can be instantiated with any package that is an instantiation of Q. On the other hand we If the C program has can have union { generic spvalue double; with package R is new S(P1, P2, ... ); struct { package Gen is ... length int; first *double; and then the package Gen can only be instantiated with a } mpvalue; package that is an instantiation of S with the given actual } number; parameters P1, P2 etc. then this can be mapped in the Ada program by These mechanisms are often used together as in type Number(Kind: Precision) is record generic case Kind is with package P is new Q(<>); when Single_Precision => with package R is new S(P.F1); SP_Value: Long_Float; package Gen is ... when Multiple_Precision => MP_Value_Length: Integer; This ensures that the instantiation of S has the same actual MP_Value_First: access Long_Float; parameter (assumed only one in this example) as the end case; parameter F1 of Q used in the instantiation of Q to create end record; pragma Unchecked_Union(Number); the actual package corresponding to P.

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 241

There is an example of this in one of the packages for These packages export types for declaring vectors and vectors and matrices in ISO/IEC 13813 which is now matrices and many operations for manipulating them. Thus incorporated into Ada 2005 (see Section 3.6). The generic if we have an expression in mathematical notation such as package for complex arrays has two package parameters. y = Ax + z One is the corresponding package for real arrays and the other is the package Generic_Complex_Types from the where x , y and z are vectors and A is a square matrix, then existing Numerics annex. Both of these packages have a this calculation can be simply programmed as floating type as their single formal parameter and it is X, Y, Z: Real_Vector(1 .. N); important that both instantiations use the same floating type A: Real_Matrix(1 .. N, 1 .. N); ... (eg both Float and not one Float and one Long_Float) Y := A * X + Z; otherwise a terrible mess will occur. This is assured by writing (using some abbreviations) and the appropriate operations will be invoked. The packages also include subprograms for the most useful with ... ; linear algebra computations, namely, the solution of linear generic with package Real_Arrays is equations, matrix inversion and determinant evaluation, new Generic_Real_Arrays(<>); plus the determination of eigenvalues and eigenvectors for with package Complex_Types is symmetric matrices (Hermitian in the complex case). Thus new Generic_Complex_Types(Real_Arrays.Real); package Generic_Complex_Arrays is ... to determine X given Y, Z and A in the above example we can write Well this works fine in simple cases (the reader may wonder whether this example is simple anyway) but in X := Solve(A, Y – Z); more elaborate situations it is a pain. The trouble is that we It should not be thought that these Ada packages in any have to give all the parameters for the formal package or way compete with the very comprehensive BLAS (Basic none at all in Ada 95. Linear Algebra Subprograms). The purpose of the Ada packages is to provide simple implementations of very Ada 2005 permits only some of the parameters to be commonly used algorithms (perhaps for small embedded specified, and any not specified can be indicated using the systems or for prototyping) and to provide a solid box. So we can write any of framework for developing bindings to the BLAS for more with package Q is new R(P1, P2, F3 => <>); demanding situations. Incidentally, they are in the with package Q is new R(P1, others => <>); with package Q is new R(F1 => <>, F2 => P2, F3 => P3); Numerics annex. Note that the existing form (<>) is now deemed to be a Another (but very trivial) change to the Numerics annex is shorthand for (others => <>). As with aggregates the form that nongeneric versions of Ada.Text_IO.Complex_IO have <> is only permitted with named notation. been added in line with the standard principle of providing nongeneric versions of generic predefined packages for Examples using this new facility will be given in a later convenience. Their omission from Ada 95 was an paper. oversight. 3.6 Standard library There is a new predefined package in Annex A for There are significant improvements to the standard library accessing tree-structured file systems. The scope is perhaps in Ada 2005. One of the strengths of Java is the huge indicated by this fragment of its specification library that comes with it. Ada has tended to take the with ... esoteric view that it is a language for constructing programs package Ada.Directories is from components and has in the past rather assumed that -- Directory and file operations the components would spring up by magic from the user function Current_Directory return String; procedure Set_Directory(Directory: in String); community. There has also perhaps been a reluctance to ... specify standard components in case that preempted the -- File and directory name operations development of better ones. However, it is now recognized function Full_Name(Name: in String) return String; that standardizing useful stuff is a good thing. And function Simple_Name(Name: in String) return String; ... moreover secondary ISO standards are not very helpful -- File and directory queries because they are almost invisible. Ada 95 added quite a lot type File_Kind is to the predefined library and Ada 2005 adds more. (Directory, Ordinary_File, Special_File); type File_Size is range 0 .. implementation-defined; First, there are packages for manipulating arrays and function Exists(Name: in String) return Boolean; vectors already mentioned in Section 3.5 when discussing ... formal package parameters. There are two packages, -- Directory searching type Directory_Entry_Type is limited private; Generic_Real_Arrays and Generic_Complex_Arrays. They type Filter_Type is array (File_Kind) of Boolean; can be instantiated according to the underlying floating ... point type used. There are also nongeneric versions as -- Operations on directory entries ... usual. end Ada.Directories;

Ada User Journal Volume 25, Number 4, December 2004 242 Rationale for Ada 2005: Introduction

The package contains facilities which will be useful on any In a similar way types Wide_String and Wide_Character Unix or Windows system. However, it has to be recognized were added to Ada 95. In Ada 2005 this process is also that like Ada.Command_Line it might not be supportable on extended and a set of wide-wide types and packages for 32- every environment. bit characters are added. Thus we have types Wide_Wide_String and so on. There is also a package Ada.Environment_Variables for accessing the environment variables that occur in most A major addition to the predefined library is the package operating systems. Ada.Containers and its children plus two auxiliary child functions of Ada.Strings. These are a very important and A number of additional subprograms have been added to considerable addition to the predefined capability of Ada the existing string handling packages. There are several and brings the best in standard data structure manipulation problems with the Ada 95 packages. One is that conversion to the fingers of every Ada programmer. The scope is between bounded and unbounded strings and the raw type perhaps best illustrated by listing the units involved. String is required rather a lot and is both ugly and inefficient. For example searching only part of a bounded Ada.Containers – this is the root package and just declares or unbounded string can only be done by converting it to a types Hash_Type and Size_Type which are an String and then searching the appropriate slice. implementation-defined modular and integer type respectively. In brief the additional subprograms are as follows Ada.Strings.Hash and Ada.Strings.Unbounded.Hash – these ▪ three further versions of function Index with an are functions that hash a string or unbounded string into additional parameter From indicating the start of the the type Hash_Type. There is no bounded version. search are added to each of Strings.Fixed, Strings.Bounded and Strings.Unbounded. Ada.Containers.Vectors – this is a generic package with parameters giving the index type and element type of a ▪ a further version of function Index_Non_Blank is vector plus "=" for the element type. This package similarly added to all three packages. declares types and operations for manipulating vectors. ▪ a procedure Set_Bounded_String with similar behaviour (These are vectors in the sense of flexible arrays and not to the function To_Bounded_String is added to the mathematical vectors used for linear algebra as in the Strings.Bounded. This avoids the overhead of using a vectors and matrices packages mentioned earlier.) As function. A similar procedure Set_Unbounded_String is well as subprograms for adding, moving and removing added to Strings.Unbounded. elements there are also generic subprograms for searching, sorting and iterating over vectors. ▪ a function and procedure Bounded_Slice are added to Strings.Bounded. These avoid conversions from type Ada.Containers.Doubly_Linked_Lists – this is a generic String. A similar function and procedure package with parameters giving the element type and "=" Unbounded_Slice are added to Strings.Unbounded. for the element type. This package declares types and operations for manipulating doubly-linked lists. It has As well as these additions there is a new package similar functionality to the vectors package. Thus, as Ada.Text_IO.Unbounded_IO for the input-output of well as subprograms for adding, moving and removing unbounded strings. This again avoids unnecessary elements there are also generic subprograms for conversion to the type String. However, it has not been felt searching, sorting and iterating over lists. necessary to add a similar package for bounded strings partly because of the complexity involved since it would Ada.Containers.Hashed_Maps – this is a generic package need to be generic. with parameters giving a key type and an element type plus a hash function for the key, a function to test for Finally, two functions Get_Line are added to Ada.Text_IO equality between keys and "=" for the element type. It itself. These avoid difficulties with the length of the string declares types and operations for manipulating hashed which occurs with the existing procedures Get_Line. maps. In Ada 83, program identifiers used the 7-bit ASCII set. In Ada.Containers.Ordered_Maps – this is a similar generic Ada 95 this was extended to the 8-bit Latin-1 set. In Ada package for ordered maps with parameters giving a key 2005 this is extended yet again to the entire ISO/IEC type and an element type and "<" for the key type and "=" 10646:2003 character repertoire. This means that identifiers for the element type. can now use Cyrillic and Greek characters. Thus we could extend the animal example by Ada.Containers.Hashed_Sets – this is a generic package with parameters giving the element type plus a hash СTалин: access Pig renames Napoleon; Πεγασυς: Horse; function for the elements and a function to test for equality between elements. It declares types and In order to encourage us to write our mathematical operations for manipulating hashed sets. programs nicely the additional constant Ada.Containers.Ordered_Sets – this is a similar generic π: constant := Pi; package for ordered sets with parameters giving the has been added to the package Ada.Numerics in Ada 2005. element type and "<" and "=" for the element type.

Volume 25, Number 4, December 2004 Ada User Journal J Barnes 243

There are then another six packages with similar absolutely no changes at the level of detail presented here. functionality but for indefinite types with corresponding Some quite promising features failed to be included partly names such as Ada.Containers.Indefinite_Vectors. because the need for them was not clear and also because a conclusive design proved elusive. We might think of them Ada.Containers.Generic_Array_Sort – this is a generic as Forthcoming Attractions for any further revision! procedure for sorting arrays. The generic parameters give the index type, the element type, the array type and Some esoteric topics have been omitted in this overview; "<" for the element type. The array type is unconstrained. they concern features such as: streams, object factory functions, the partition control system in distributed Finally there is a very similar generic procedure systems, partition elaboration policy for high integrity Ada.Containers.Generic_Constrained_Array_Sort but for systems, a subtlety regarding overload resolution, the title constrained array types. of Annex H, quirks of access subtypes, rules for pragma It is hoped that the above list gives a flavour of the Pure, and the classification of various units as pure or capability of the package Containers. Some examples of the preelaborable. use of the facilities will be given in a later paper. Further papers will expand on the six major topics of this Finally, there are further packages for manipulating times overview in more detail. (that is of type Ada.Calendar.Time and not It is worth briefly reviewing the guidelines (see Section 2 Ada.Real_Time.Time and thus more appropriate in a above) to see whether Ada 2005 meets them. Certainly the discussion of the predefined library than the real-time Ravenscar profile has been added and the problem of features). The package Ada.Calendar has a number of mutually dependent types across packages has been solved. obvious omissions and in order to rectify this the following packages are added. The group A items were about real-time and high-integrity, static error checking and interfacing. Clearly there are Ada.Calendar.Time_Zones – this declares a type major improvements in the real-time area. And high- Time_Offset describing in minutes the difference integrity and static error checking are addressed by features between two time zones and a function such as the overriding prefix, various pragmas such as UTC_Time_Offset which given a time returns the Unsuppress and Assert and additional Restrictions difference between the time zone of Calendar at that identifiers. Better interfacing is provided by the pragma time and Greenwich Mean Time (alias UTC or Unchecked_Union and the Mod attribute. Coordinated Universal Time). It also has an exception which is raised if the time zone of Calendar is not The group B items were about improvements to the OO known (maybe the clock is broken). model, the need for a Java-like interface feature and better interfacing to other OO languages. Major improvements to Ada.Calendar.Arithmetic – various types and operations for the OO model are brought by the Obj.Op notation and more coping with leap seconds. flexible access types. The Java-like interface feature has Ada.Calendar.Formatting – further types and operations for been added and this provides better interfacing. dealing with leap seconds and time zones and related The final direct instruction was to incorporate the vectors matters. and matrices stuff and this has been done. There are also Most of the new calendar features are clearly only for the many other improvements to the predefined library as we chronological addict but the need for them does illustrate have seen. that this is a tricky area. However, a feature that all will It seems clear from this brief check that indeed Ada 2005 appreciate is that the package Ada.Calendar.Formatting does meet the objectives set for it. includes the following declarations type Day_Name is (Monday, Tuesday, Wednesday, Finally, I need to thank all those who have helped by Thursday, Friday, Saturday, Sunday); reviewing earlier drafts of this paper. There are almost too function Day_Of_Week(Date: Time) return Day_Name; many to name, but I must give special thanks to Randy Brukardt, Pascal Leroy and Tucker Taft of the ARG, to my There is also a small change in the parent package colleagues on the UK Ada Panel (BSI/IST/5/-/9), and to Ada.Calendar itself. The subtype Year_Number is now James Moore of WG9. I am especially grateful to a brilliant subtype Year_Number is Integer range 1901 .. 2399; suggestion of Randy Brukardt which must be preserved for This reveals confidence in the future of Ada by adding the pleasure of future generations. He suggests that this another three hundred years to the range of dates. document when complete be called the Ada Language Enhancement Guide. This means that if combined with the 4 Conclusions final Ada Reference Manual, the whole document can then This overview of Ada 2005 should have given the reader an be referred to as the ARM and ALEG. Thanks Randy. appreciation of the important new features in Ada 2005. As References mentioned earlier, integration of the final text to produce the Amendment remains to be done and this might lead to [1] ISO/IEC JTC1/SC22/WG9 N412 (2002) Instructions some very small adjustments. However, there should be to the Ada Rapporteur Group from SC22/WG9 for Preparation of the Amendment.

Ada User Journal Volume 25, Number 4, December 2004 244 Rationale for Ada 2005: Introduction

[2] ISO/IEC 8652:1995/COR 1:2001, Ada Reference [5] ISO/IEC 13813:1997 (1997) Generic packages of real Manual – Technical Corrigendum 1. and complex type declarations and basic operations for Ada (including vector and matrix types). [3] S. T. Taft et al (eds) (2001) Consolidated Ada Reference Manual, LNCS 2219, Springer-Verlag. [6] J. G. P. Barnes (1998) Programming in Ada 95, 2nd ed., Addison-Wesley. [4] ISO/IEC TR 24718:2004 (2004) Guide for the use of the Ada Ravenscar Profile in high integrity systems. This is based on University of York Technical Report © 2004 John Barnes Informatics. YCS-2003-348 (2003).

Volume 25, Number 4, December 2004 Ada User Journal 246 Ada-Europe 2004 Sponsors

ACT Europe 8 Rue de Milan, F-75009 Paris, France Contact: Zépur Blot Tel: +33-1-49-70-67-16 Fax: +33-1-49-70-05-52 Email: [email protected] URL: www.act-europe.fr

Aonix 66/68, Avenue Pierre Brossolette, 92247 Malakoff, France Contact: Anne Chapey Tel: +33-1-41-48-10-10 Fax: +33-1-41-48-10-20 Email : [email protected] URL : www.aonix.fr

Artisan Software Tools Ltd Suite 701, Eagle Tower, Montpellier Drive, Cheltenham, GL50 1TA, UK Contact: Emma Allen Tel: +44-1242-229300 Fax: +44-1242-229301 Email : [email protected] URL : www.artisansw.com

Green Hills Software Ltd Dolphin House, St Peter Street, Winchester, Hampshire, SO23 8BW, UK Contact: Christopher Smith Tel: +44-1962-829820 Fax: +44-1962-890300 Email : [email protected] URL : www.ghs.com

I-Logix 1 Cornbrash Park, Bumpers Way, Chippenham, Wiltshire, SN14 6RA, UK Contact: Martin Stacey Tel: +44-1249-467-600 Fax: +44-1249-467-610 Email : [email protected] URL : www.ilogix.com

LDRA Ltd 24 Newtown Road, Newbury, Berkshire, RG14 7BN, UK Contact: Jim Kelly Tel: +44-1635-528-828 Fax: +44-1635-528-657 Email: [email protected] URL: www.ldra.com

Praxis Critical Systems Ltd 20 Manvers Street, Bath, BA1 1PX, UK Contact: Rod Chapman Tel: +44-1225-823763 Fax: +44-1225-469006 Email : [email protected] URL : www.sparkada.com

Scientific Toolworks Inc 321 N. Mall Drive Suite I-201, St. George, UT 84790, USA Contact: Matthew Bergeson Tel: +1-435-627-2529 Fax: +1-877-512-0765 Email: [email protected] URL: www.scitools.com

TNI Europe Limited Triad House, Mountbatten Court, Worrall Street, Congleton, Cheshire CW12 1DT, UK Contact: Pam Flood Tel: +44-1260-29-14-49 Fax: +44-1260-29-14-49 Email: [email protected] URL: www.tni-europe.com

Volume 25, Number 4, December 2004 Ada User Journal