From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,3a414836333dfef7 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-01-07 09:22:34 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!canoe.uoregon.edu!arclight.uoregon.edu!newsfeed.mathworks.com!cyclone.swbell.net!bos-service1.ext.raytheon.com!dfw-service2.ext.raytheon.com.POSTED!not-for-mail Message-ID: <3C39D954.58672C0A@Raytheon.com> From: Mark Johnson X-Mailer: Mozilla 4.5 [en] (WinNT; I) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Elaboration in GNAT References: <1006952193.650930@edh3> <5ee5b646.0111281125.7e9fbca3@posting.google.com> <1010151875.216658@edh3> <5ee5b646.0201041650.208d0918@posting.google.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Mon, 07 Jan 2002 11:22:28 -0600 NNTP-Posting-Host: 192.27.48.44 X-Complaints-To: news@ext.ray.com X-Trace: dfw-service2.ext.raytheon.com 1010424152 192.27.48.44 (Mon, 07 Jan 2002 11:22:32 CST) NNTP-Posting-Date: Mon, 07 Jan 2002 11:22:32 CST Organization: Raytheon Company Xref: archiver1.google.com comp.lang.ada:18613 Date: 2002-01-07T11:22:28-06:00 List-Id: Robert Dewar wrote: > > Some things to remember here: > > 1. The static elaboration model of GNAT is primarily intended for the > development of new code. Hmm. I guess I disagree with that statement. See reasons below. > [snip] > 3. If you are working with legacy code, it often makes no > sense to try to use the static model of GNAT, and you should simply > use -gnatE, and use the RM dynamic elaboration model. I am always > surprised by people who > are absolutely determined to beat legacy code into submission to the > GNAT static model. Yes, of course this > makes life easier in the future, but you have to be sure > it is worth the work. Yes and no. Two examples follow. The first example follows Robert's suggestion to use -gnatE. To predict performance of our new system, we got a copy of ACES (Ada Compiler Evaluation System) and ran several hundred of the test programs through GNAT on the several target systems. Since this was a study and not intended to be run operationally, we did not spend the time trying to find and fix all the problems with this software. The use of -gnatE was a good way to make progress without a lot of effort. The second example is our real application. We are nearing the end of porting a couple million lines of code from Apex & VADS to GNAT. We actually have a small script that takes the compiler output, recognizes the "pragma Elaborate_All" messages, and makes those changes automatically. NONE of our software has broken when this was done. It was relatively painless and easy to perform. I expect many other well designed systems fall into this category. The use of the warning of the compiler and the script to make the changes has given us confidence that our code is free from any big issues with elaboration. It is not a "big deal" to make the change in most cases. As Robert's message goes on to say - complicated elaboration code is likely filled with bugs anyway. I am glad we don't have this kind of problem to worry about. -- --Mark