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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,fa591a83ee0ad6bf X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news2.google.com!postnews.google.com!v15g2000yqn.googlegroups.com!not-for-mail From: george.priv@gmail.com Newsgroups: comp.lang.ada Subject: Re: GNAT Pro for .NET Date: Sat, 29 Nov 2008 12:07:20 -0800 (PST) Organization: http://groups.google.com Message-ID: <88f8447f-50c9-447a-a5e7-fce3c643030f@v15g2000yqn.googlegroups.com> References: <22d85cff-dbef-4e94-b4b5-e3e93b73a256@f20g2000yqg.googlegroups.com> NNTP-Posting-Host: 151.196.71.114 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1227989240 20667 127.0.0.1 (29 Nov 2008 20:07:20 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Sat, 29 Nov 2008 20:07:20 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: v15g2000yqn.googlegroups.com; posting-host=151.196.71.114; posting-account=VnNb3AoAAACTpRtCcTrcjmPX7cs92k1Q User-Agent: G2/1.0 X-HTTP-Via: 1.1 SPARKS X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4,gzip(gfe),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:3811 Date: 2008-11-29T12:07:20-08:00 List-Id: On Nov 26, 2:05=A0am, Brad Moore wrote: > george.p...@gmail.com wrote: > > Wonder if anyone has any experience with Ada .NET? =A0How well it is > > integrated and what are the major issues you had with it? > > I've been involved in a port of a number-crunching system originally > written in Ada 83 from a different compiler vendor running on Unix, to > Gnat on Windows in Ada 95, and then most recently to .NET in Ada 2005 > using Gnat Pro for .NET. I say port, but for the most part it was simply > a matter of setting the compiler switches for Ada 95, and Ada 2005, > and recompiling, though we have been introducing new language features > during maintenance of the system. > > The original system features several tasks with rendezvous, and heavy > use of the Ada math libraries. There is no GUI involved. > > My experiences from these ports are; > > Port 1) Ada 83 SCO Unix (non-Gnat vendor) to Win32 Gnat in Ada 95 > > - Issues relating to compiler vendor switch: > =A0 =A0 =A0None come to mind > > _ Issues relating to language switch, Ada 83 - Ada 95 > =A0 =A0 1) =A0We had a generic protected queue, which had used the Ada 95 > =A0 =A0 =A0 =A0 reserved word "protected" in its variable names. We had t= o > =A0 =A0 =A0 =A0 change the name of the variables to something else. > =A0 =A0 =A0 =A0 (A very trivial change) > =A0 =A0 2) =A0The generic would accept an unconstrained type as a formal > =A0 =A0 =A0 =A0 parameter. In Ada 95, we had to add the box notation to t= he > =A0 =A0 =A0 =A0 formal paramter. > > =A0 =A0 =A0 =A0 eg. Instead of; > > =A0 =A0 =A0 =A0 generic > =A0 =A0 =A0 =A0 =A0 =A0 =A0 type Element_Type is private; > =A0 =A0 =A0 =A0 package P is > > we had to write; > =A0 =A0 =A0 =A0 generic > =A0 =A0 =A0 =A0 =A0 =A0 =A0 type Element_Type (<>) is private; > =A0 =A0 =A0 =A0 package P is > ... > =A0 =A0 =A0 =A0Another very trivial change. > > =A0 =A0 =A03) We had used passive tasks in a couple of places. In Ada 95,= we > =A0 =A0 =A0 =A0 replaced these library units with protected types. > =A0 =A0 =A0 =A0 This was a bit more work, but the end result was satisfyi= ng and > =A0 =A0 =A0 =A0 a better result. > > - Issues relating to operating system switch: Unix to Windows > =A0 =A0 =A0This was probably the biggest impact, though we had isolated O= S > =A0 =A0 =A0routines, so changes were quite localized. The biggest challen= ge > =A0 =A0 =A0was finding a replacement for Unix's memory mapped array featu= re, > =A0 =A0 =A0which Windows didn't seem to have matching support for. > > - Issues relating to change from services being invoked by CORBA to > =A0 =A0interface accessed via a DLL. > =A0 =A0 The use of the Interfaces.C library routines was very helpful. > =A0 =A0 To invoke the DLL from .NET, a .NET wrapper was needed to complet= e > =A0 =A0 the interface. > > ------------------------------------------------- > > Port 2: Ada 95 Windows to Ada 2005 .NET > > - Issues relating to the language switch. (Ada 95 to Ada 2005) > =A0 =A0 None: Or at least I don't recall there being any. > =A0 =A0 We have now incorporated new language features including interfac= es, > =A0 =A0 Ada.Directories, containers, object prefix notation, to name a fe= w. > =A0 =A0 These mostly come as enhancements needed for maintenance, and are > =A0 =A0 unrelated to the actual port. > > - Issues going from win32 to .NET > =A0 =A0 For the most part we didn't need to make any significant code > =A0 =A0 changes. There are a few libraries that weren't implemented in .N= ET > =A0 =A0 Ada. The ones that > =A0 =A0 come to mind are Ada.Direct_IO and Ada.Directories I believe, tho= ugh > =A0 =A0 there are other libraries that come with Gnat that provided suita= ble > =A0 =A0 workarounds. There may have been some other minor issues, but we > =A0 =A0 found workarounds for everything. The application runs well in .N= ET. > =A0 =A0 We no longer needed the .NET wrapper around our DLL, which simpli= fied > =A0 =A0 things. We had to get rid of our Interfaces.C pragmas and replace > =A0 =A0 with similar vendor specific pragmas for interfacing to .NET. > =A0 =A0 I believe the full list of issues/differences between .NET Gnat P= ro > =A0 =A0 and Windows Gnat Pro can be obtained from Adacore. > > Regards, > Brad Moore Thanks for the info. I played a little with free version but seems that it has some issues. Maybe it's just lack of documentation. I am considering investing in Gnat Pro next year, so it is nice to know in advance. Regards, George Privalov.