Domain: adapower.com
Stories and comments across the archive that link to adapower.com.
Comments · 34
-
Re: Is this news for anyone?
"The software, written in Ada....."
That says it all.
Not the important part, no. The problem was bad engineering practice, not Ada.
The software, written in Ada, was included in the Ariane 5 through the reuse of an entire Ariane 4 subsystem despite the fact that the particular software containing the bug, which was just a part of the subsystem, was not required by the Ariane 5 because it has a different preparation sequence[21] than the Ariane 4.
Ada is well proven software engineering technology that can help you produce better software, but it isn't magic. You still have to follow sound procedures for it to help you.
For anyone that is interested, there is more useful detail in these links:
I heard tell that Ada was to blame for the Ariane V disaster. Is this true?
Put it in the contract: The lessons of Ariane -
Re:C A R Hoare on Ada
... and also was commenting on a version of Ada that he was aware of around 3 years before standardisation. See some comments on http://www.adapower.com/index.php?Command=Class&ClassID=Advocacy&CID=39.
-
Re:Language Magic Bullets
Ariane V http://www.adapower.com/index.php?Command=Class&ClassID=FAQ&CID=328
OTOH, remember the link is to a site promoting Ada. They're telling the truth as they know it, but they're biased. -
Ada
I took a class in Ada for a previous employer. I found it a lot like Pascal and not all that difficult. The main issue was the cost of compilers which had to go through an expensive certification process. I did find the language a but verbose for many things, e.g. here
The real issue isn't that it's hard to learn, it's that it's a little cumbersome, but more importantly, not many people know it and they typical clueless manager wants to see 10+ years of Ada experience on the resume/cv before hiring someone. Those people are few and far between, but and competent software developer can learn it.
-
Re:Wrong Question
Parallel programming is going to be a HUGE deal in coming years, and current languages don't handle it well - threading is complicated and prone to errors, leading to product delays. Erlang... Unfortunately, the language also has a high barrier to entry as it is not Algol-based (like C, C++, Java, etc. are).
Hmmm. It sounds like you should consider looking at Ada. Its Algol-based, and has threading designed in from the start as a first-class part of the language.
Its also a supported part of GCC, so a compiler is freely available for most platforms. For the windows version, go to The Mingw Download site and search for "gcc-ada". -
Use a software engineering language instead
A language designed for software engineers instead of a "coders" would preclude the need for Coverity. Now what language could that be? Why Ada, of course.
The problems which Coverity exposes, are less likely to occur, in many cases, impossible to occur in a language such as Ada, which was designed from its inception to avoid these problems. -
Re:Still can have bugs
"Take the supposed wonderful language of ADA. What databases can it talk to? What type of user interface can you construct? Can it talk HTTP or HTTPS? Can it do SOAP? Can it spawn threads or processes?"
Some of the Ada bindings available include:
GNADE (http://gnade.sourceforge.net/ supports ODBC, MySQL 3.X and 4.X, PostgreSQL and SQLite. There are also Ada bindings for Oracle.
The main cross-platform UI kit is GtkAda (https://libre2.adacore.com/GtkAda/) - it works with the glade GUI builder. There are also some Windows-specific kits, including Claw (http://www.rrsoftware.com/html/prodinf/claw/claw. htm).
Web programming is supported by Ada Web Server (https://libre2.adacore.com/aws/). It handles SOAP.
Threads and support for concurrency are part of the language standard. Processes can be spawned via expect-like packages usually available with the compiler.
See http://www.adapower.com/, http://www.adaworld.com/, http://libre.adacore.com/ and http://www.adaic.com/ for additional resources.
- Ed -
Ada
In fact I do know a better language, Ada95/2005.
It's simply meant for threading and unconventional compiler optimizations (through the enforcement of constraints), while still being imperative and having a familiar syntax. And it's meant to be compiled unlike Java.
Here's a site about Ada and here's another one.
A good (alas not perfect) Ada95 compiler is included in GCC 3.4.
So aye, we are ready for the CMT systems. -
Re:Hmm?Erwos writes:
"There's always improvements to be made, and multi-threaded programs are a bitch and a half to debug . .
."Choose the right tool, Ada for example. Ada was designed from the start to support multi-threaded programming. It isn't some sort of add-on library. Multi-threading is intrinsic to the language. Of course you get the bonus that your program will probably run correctly the first time, without the need for a debugger.
-
Re:C++ in embedded applications is a bad idea
Ada
Ada mention
You won't be alone.
Once you get over the ugly syntax, you'll really like Ada. -
On the iAPX-432 and the Ada programming language
The iAPX 432 was a 32-bit processor Intel developed starting in 1975 that embodied CISC technology to the max. It was innovative, but also expensive and slow, and targeted towards the Ada programming language, another market failure.
First, your statements above are contradictory, in 1975 there was no Ada programming language, only a spec (steelman ??) that described what the language should contain (and not contain).
Also, it is not clear whether you meant that the 432 or Ada was a marketing failure (or both). Certainly the 432 was. OTOH, from its first release in 1980 or so, the Ada language has been far from a "market failure", despite there being no low-cost compilers for it and despite the limitations required by the SteelMan spec. Virtually all aeronautics, astronautics or critical communications software (Military or civilian) and weapons control software for the last 20 years was written in Ada (and not just in the US).
In addition, several commercial SW firms also found, even w/ Ada-83, that it allowed them to ship w/ far fewer bugs left for customers to find that code written in (Ugh!) C, as well as allowing bug-fixes using less than 50% of the developer resources than to fix bugs in (Ugh!) C.
As of 1995 the Ada language is much more oriented towards general programming, as well as being much cheaper to use than it had been. There has been a FREE (GPL) Ada compiler available since 1995 or so, and it is now (since version 3.2) integrated into GCC.
For more info on how Ada is being used and why it should be used for all new projects, see My small Ada site or David Botton's Ada Power site. -
Re:A replacement for C?
Gee..What we need is a language that has been around for a long time. Is ISO standardized. Supports OO. Has the power to do low level programming when required. It would actually have to be fast and efficient . It would also be good if it had run time checks on things like buffer overflows but also made them less likely by the structure of the language itself (e.g. Doing pass and array and a separate array size but have the language know about the size of the array to start with). It would be good if this language already had a free implementation. It would have to work under Windows, Linux, most other Unixs and a lot of embedded targets. It would have to have the option of easily letting the user suppress the run-time checks if required but have them basically on by default. Hopefully we could do something in the language that would at least help reduce bugs. But we have to be realistic too. We probably won't be getting rid of Windows any time soon so this made up language would also need to be able to interface easily to things like COM/DCOM for windows. It should also support things like Gtk+ and GNOME out of the box. Hmm...Sounds Like Ada. Oh but wait..It does not use ugly C syntax so programmers will never use it...Not to mention that problem with the military being involved at the beginning (but lets just overlook that for the whole internet thing)...
-
Re:We really need a different language
Ada is a strongly typed language. It's used for jet airplanes. It should be good enough for other things too. If only there were more support for it. Here's an additional link for our faithful viewers: www.adapower.com
-
Re:People still use ADA?Ada has many advantages over C++ and it is still used extensively (although not exclusively) in current military development projects. Inform yourself at:
-
Re:Ada ?
For one thing, Ada is specifically designed as a native-code compiled language, and provides facilities suited to (fairly) speed-critical code. I suspect a compiler would have to be extremely clever to achieve the same efficiency from Java code. For this reason alone, I doubt avionics software could sensibly be written in Java.
Ada is really only a kind of suped-up Pascal, but it has certain genuine advantages over C and C++ -- the languages most commonly used as an alternative to Ada for developing safety-critical software (which tends to be embedded) -- that certain big corporations would prefer people didn't know.
These advantages are really very simple. Ada tends to catch a lot of typical errors at compile-time that (for the equivalent errors) would be caught only at run-time in languages such as C and C++ (and Java, for that matter), or that would not be caught at all. Catching these errors, in practice, reduces the debugging cycle drastically. The economic benefits for commercial software development are obvious -- and this is the reason why savvy companies like Boeing use Ada -- but the benefits for the lone hacker are also obvious.
In addition, Ada programs -- especially if use is made of the simple facilities Ada provides for the purpose -- tend to catch (as a controllable exception) many typical errors at run-time that would not be caught by C or C++ (but would cause uncontrolled failure instead).
So long as exceptions are handled sensibly, this makes it possible to program Ada software to defend itself against catasrophic failure in the field (or in the air). The classic 'buffer overrun' vulnerabilities that have plagued various kinds of Internet service software recently -- costing businesses huge amounts of money in some cases -- would certainly never have occurred if the software had been written in Ada (or, for that matter, in almost any language other than C or C++).
Of course it should be noted that, most of the time, the reliability of a piece of (safety-critical) software as delivered will depend on how well it was designed, specified, coded, and tested, not on which language it was programmed in.
It should be emphasised that there are plenty of other languages (e.g. Modula III, Oberon, Eiffel) that offer advantages similar to Ada. I believe, of these, Ada is the only one which is an ISO standard (which it has been since 1983).
Ada is a totally general-purpose language. It can certainly be used for anything that C or C++ can. If you are curious, you may be surprised to learn that if you throw a file ending with ".ads" or ".adb" at any recent gcc it will compile it.
If you are curious about Ada, the best starting point is:
Happy hunting!
-
for Ada: Ada Power
-
Re:use a better language...Besides Pascal doesn't have templates.
Ada does. They are called "generics". More powerful and type-safe than templates, IMO.
-
checker-gcc or a better languageThere is an older version of gcc, "checker-gcc" (based on gcc 2.8) which is the most powerful memory checker available under Free Software.
Without a doubt, the most industrial strength language avaiable for Free Sofware use is GNU Ada. Ada won't let you f*ck up. It is truly an awesome language. Check out the GNU Visual Debugger - gvd- for an example of one of the coolest examples of what Free Software Ada technology can do.
Good places to start:
There is a wealth of Ada lerning resources on the web, perhaps more on line instruction than any other progrmming language. Ada is at or above the same level of abstraction as C++. C++ programmers should not have too much trouble learning Ada. One other nice aspect of Ada is that since it was the first ISO standard OOP language, and since the way it interacts with other programming languages is codified as part of that standard, it is very easy to use Ada for the "mission critical parts of a software project. There is no need to re-write a whole project to start taking advantage of Ada; it can be done piece by piece.
-
Re:Programming in the US Military
Ada is almost dead in the military. Why? Because there isn't enough money in maintaining Ada programs. They work, first time. Great for the military, lousy for the military-industrialist complex. Spend twice as much making it in the first place, then get no lucrative bugfix money afterwards. Making expensive programs that actually work is commercial suicide. Making cheap programs that actually work (which you do after some experience) gives you only subsistance level profits. Making cheap programs that almost work and require lots of profitable maintainance for years is the road to riches. So what if a few ships need towing to port due to a divide-by-zero error?
Of course, where firms could get sued if they screw up, such as in commercial avionics and jet engines, Ada is universally used. Ada doesn't guarantee good, safe, maintainable programs, but it's relatively easy to make them in Ada, and darn near impossible to make them in C.
As for Ada being harder to learn than C, which is harder
for(i=0;i<BUFFER_SIZE;i++){ :
read(i);
}
or
for i in buffer loop
read(i);
end loop;
Maybe if people just quietly gave facts and hard numbers in the Great Language Wars then the Truth Will Out.... Nah. But it's worth a shot, anyway.
-
Try Ada-95
URLs To backup my bald assertions below. Browse the sites and you'll see studies and numbers. Facts not Religious opinion. Adapower is a good start. Or the Ada Information Clearinghouse
"intuitive and easy to use IDE; simplified GUI design and event handling; advanced error handling; advanced object oriented design including multiple inheritance, abstract classes, and garbage collection; full support for operator and function overloading; and portable (at compile-time) across various platforms."
IDE - there's a variety of freeware ones.
Simplified GUI - there's a variety of bindings to various APIs, from X-windows to SWING to W32. Plus many other simplified freeware ones, some thin, some thick. Pick which one is most appropriate. Ada (the language) doesn't have anything more advanced than stdio - but then again, neither does Java, it relies on the awt and swing libraries *shrug*
Advanced Error Handling - Java's exceptions contain more info than Ada's. Ada ones are more simple, easy to use, but I think Java's are better in most ways. They should be - both C++ and Java copied their exception handling from Ada's 1983 incarnation. OTOH most of the time all Java programmers (like me) do is make an exception without using any of the internal data, so YMMV.
Advanced OOD including multiple inheritance and abstract classes - As regards OOD. Ada's the most flexible of the lot. You can do strict OO, but don't have to. Methods are properties of Classes(actually packages) rather than objects, so you can say Wooden.paint(a_wooden_door) or Door.paint(a_wooden_door) rather than a_wooden_door.paint(). So you get all the advantages of multiple inheritance, without the horrendous penalties (which method are you inheriting, the paint for wooden things or the paint for doors?). Abstract classes are used all the time.
Garbage Collection - Ada doesn't produce garbage in general. You can do most things using statically allocated memory, or dynamic allocation within a statically-defined garbage-collected area. When you want dynamic allocation, you can choose to rely on the compiler's garbage collection, if it exists, but you're also given tools for explicit disposal of garbage. Note that Java has true garbage collection, but even Sun says that you can't rely on it, you should use explicit disposal. This is true not just for Java, but in general.
Operator/Function Overloading Ada has had this since 1983. Often copied, never bettered
Portable Stories abound of million- and 100,000-line Ada programs that require a dozen lines changed to make em work on different systems. My own personal war story is of a 20,000 liner developed on a 386 on an Irvine compiler, ported with 3 lines changed to a MicroVax using a DEC compiler, thence to a Vax using another DEC compiler, then to an embedded system using a DDC-I compiler. Was an AI to do anti-missile defence, people's lives depended on it. It's been in service since 1995. Cost less to make than the 7,000 lines of C in its test bed too. I've just help finish a 20,000 line piece of spaceflight avionics that makes not one Operating System call, even though it has 60+ simultaneous threads of execution. Oh yes, there's a shareware (or GNU licence? I forget) Ada compiler that produces Java bytecode, so will run on any Sun JVM.
So why isn't Ada-95 used by anyone? Because everyone knows it's too big (nearly as many keywords as C++,), needs a huge machine to run (bigger than a 286 running at 4 MHz - which was big in 1983 when Ada-83 was invented), it's designed by a committee (like Linux - one really good designer Jean Ichbiah, then peer review), and it's a product of the US Military (like Unix, and the Web - designed for not by). Oh yes, and expensive (GNAT is open source...) and uses a lot of risky concepts ( to wit, Operator Overloading, Object Oriented Design, Exceptions, all risky and untried in 1983 ). It's also obsolete, (the Ada-95 version being a little younger than C++). And it is used, for Avionics of all modern airliners ( Illyushin, Boeing, Lockheed, Airbus) and many satellites, railway- and air- traffic control systems, where quality is vital. It's not used much elsewhere, as there's a vested interest for software developers and programmers to keep software buggy (so they have job security) and quick to market (it takes a long time to develop reliable software).
So Ada's perfect, right? Wrong. It's just better than most general-purpose languages for many purposes. BUT It's not language of the month ( C# this month? ) so getting Ada programmers is very difficult. Though it's easy to learn, based like the similar Eiffel, Delphi, Object Pascal and Modula-2/3 on Pascal. If you've programmed hardware design in VDML, or used Oracle's access language, you've used Ada without knowing it.
-
AdaAda has all these qualifications except multiple inheritance, but considering Ada's powerful generic facility, you probably won't need it. Ada is perhaps the best available language for software engineering. It is fast, high level, yet easily allows low-level bit-twiddling if need be. GNU GNAT is the without a doubt the highest quality compiler in the GNU family of compilers. It is ISO certified, and must pass over 6500 regression tests before it is shipped. Several studies have shown that projects written in Ada lead the pack in fewest defects per 1000 lines of code, besting all comers.
Here are some Ada links:
-
Re:VHDL, Verilog and "those other languages"
Thank you for your comments, but the Ada FAQ (see section 2.6), a timeline of the language's history, and a writeup for a UMich course suggest otherwise. While S. Tucker Taft may have led the Ada 95 revision team and Jean Ichbiah led the Cii Honeywell Bull team designing the submission to the DoD (which became Ada 83), the design of the language is clearly not the work of a small number of people.
Rather, it was designed to meet a specification from a DoD working group and received feedback from hundreds of reports (and dozens of individuals or other groups).
While Robert Dewar's answer to "Was Ada designed by a committee?" is certainly witty, a rose by any other name would smell the same. Taft's answer lists -- for just Ada 95 -- not only the core "Design Team," but five other full- or nearly-full-time teams ("Language Precision Team", "Requirements Team", and three "user/implementor" teams) and the large group of "Distinguished Reviewers."
Given all that, I will retract my description of Ada as being designed by a committee -- it was in fact designed by a beauracracy!
(As for VHDL, I cannot find as detailed information on the web about its history, and don't have my VHDL books with me right now. However, the timeline at the University of Erlangen-Nürnberg's VHDL-online -- with discussions and defining requirements taking up most of a decade -- suggests that it suffered from too many cooks at times.)
While I agree that Ada and VHDL are very expressive and powerful, it's not good to get rose-colored glasses about their history or (especially in VHDL's case) drawbacks.
-
Re:The wrong starting point?And pace ESR, it wasn't designed by a committee.
Um, read entry 2.5 of the Ada FAQ. Ada was designed by a committee for the Department of Defense, based on an original design by Jean Ichbiah, with modifications made throughout the period from 1978 to 1983, then the later committees that modified and approved it to what became Ada95. It has DOD and Committeeness written all over it...makes me barf every time I have to look at it.
-
Re:The wrong starting point?
> The biggest problem at the moment is that none of these "safer" languages has yet developed the same raw expressive power of C++.
Take a look at Ada. Extremely safe, extremely powerful, extremely unpopular. Go figure.
It's object-oriented, it supports generic classes ("packages", in Ada terminology), it has built-in support for multitasking and distributed programming, it lets you (optionally) specify even such details as numeric representations for the ultimate in portability, and it has a set of first-class and well-documented bindings for GTK+.
There's a free compiler called GNAT, which is built on gcc and will actually be rolled in to gcc 3.1 or thereabouts. There's also a Linux-specific site for gathering and distributing component packages.
And pace ESR, it wasn't designed by a committee. -
Re:From the same folks who gave you ADA. :)Sorry, had to get my ADA dig in there (it's a beautiful language, really.
:) )At least you could get it right: "Ada" not "ADA". Its named after Ada Lovelace, and is not an acronym (like FORTRAN or COBOL).
I don't know about "beautiful", but "useful" certainly comes to mind...
;-)Perhaps it will see a resurgence with the arrival of jgnat.
186,282 mi/s...not just a good idea, its the law!
-
Re:unusual...
Try comp.lang.ada. It's swarming with Ada fans, many of whom would be happy to explain why they love the language so. Ada Home and AdaPower both have quite a bit of information and evangelism (the former is a bit of a 'classic', though).
-
Re:wish: strongly-typed typedefs?
You guys are just uisng the wrong language!
It would be especially nice if these types were *not* considered, for the sake of signatures, type-identical to counterpart size-variant types, and if enums were also given a generic root type instead of being int in signature.
I always wished that typedefs created new types, instead of behaving like wimpy macros.
typedef int FOO;
typedef int BAR;
FOO f = 1;
BAR b = 2;
int i = 3;
f = b; // ILLEGAL TYPE MISMATCH!
b = i; // ILLEGAL TYPE MISMATCH!
i = f; // ILLEGAL TYPE MISMATCH!
How about this? (pardon the formatting, <pre> is not allowed.)
type FOO is new integer
;
type BAR is new integer ;
function fiz( i : FOO ) return FOO ;
function fiz( i : BAR ) return BAR ; -- Different, overloaded
function fizzle( i : FOO ) return FOO ;
function frazzle( f : FOO ; b : BAR ) return integer ;
f : FOO := 1 ;
b : BAR := 2 ;
i : integer := 3 ;
f := b; -- ILLEGAL TYPE MISMATCH!
b := i; -- ILLEGAL TYPE MISMATCH!
i := f; -- ILLEGAL TYPE MISMATCH!
-- further:
f := fiz( 5 ) ; -- first fix
b := fiz( b ) ; -- second fiz
f := fizzle( f ) ; -- legal
b := fizzle( f ) ; -- ILLEGAL, TYPE MISMATCH
f := fizzle( b ) ; -- ILLEGAL, TYPE MISMATCH
i := frazzle( f, b ) ; -- All legal and proper
i := frazzle( 7, b ) ; -- All legal and proper
i := frazzle( f, 7 ) ; -- All legal and proper
i := frazzle( 7, 7 ) ; -- All legal and proper
i := frazzle( b, f ) ; -- ILLEGAL, 2 type mismatches
-- (operands reversed).
-- And so forth.
-- All arithetic, comparison, indexing, operations are inherited.Each enumeration type is distinct (with its own namespace). Enumeration types may be used for indexing and loop control, but not for arithemtic.
-
Re:Another solution
[stuff about writing in Kylix]
Or look at Ada 95 next time you need to design a piece of multithreaded software. Ada has threading capabilities build into the language, and has proper array datatypes so there is no need to fiddle with pointers and worry about checking of boundaries.
Ada rights many of the wrongs of Pascal and has a strong and rich type system build in.
I am amazed that so many insist on staying away from modern languages that make it easy to find bugs at compile time. Oh well.
The GNAT compiler is GPL'ed and available for Win32 and Linux and quite a number of other platforms. -
Ada and GVD: GNU Visual DebuggerYes, Ada is excellent advice. GNU GNAT is superb, and one of the best multi-threaded debuggers is ACT-Europe's GVD GNU Visual Debugger.
GVD, the GNU Visual Debugger, incorporates all the features of regular debugger GUIs and is complemented with data display and visualization capabilities more powerful than those offered by DDD (the Data Display Debugger). GVD provides the ability to debug multi-process/multi-threaded applications in the same debugging session.
Links for those interested in Ada and GVD:
-
The GNU Visual Debuggerhas support for threads, see the GVD home page.
Note that might want to have a look at the Ada 95 language, it has pretty good support for portable multi-threading (aka tasking, builtin into the language) and a very good compiler: GNAT.
Laurent
-
Better link for GVD
Here's a better place: www.adapower.com/gvd
-
Re:On programming
>All the current fast languages suck from a safety standpoint,
> and all the rigorous ones (the
> Pascal/Modula/Ada/Eiffel/Sather family) are essentially dead.
I have been doing Ada development my entire (11+) year career, and I can tell you that it is *not* dead. It just isn't the current language-du-jour. But lots of new programs are using it.
As to why it isn't as popular as languages like C++, well, the rest of the paragraph I quoted is a pretty good explanation. But if you are looking for a better way, there are lots of actively supported Ada compilers available, including free GPLed ones. Surf over to http://www.adapower.com and check it out. -
Re:On programming
Excellent post, wish I had mod rights so I could send it to the 5 it deserves.
As an older programmer myself, I fully agree with every point, with one minor quibble: Not all "engineering" languages (as opposed to "hacking" languages) are dead--if Ada is dead, for example, it's an awfully lively zombie, especially on free OS's. So take heart, and take a look.
Despite this, it's a great time to be a programmer. Amen, brother. When I was starting out, I had fantasies about systems with a tenth the capability of what's on my desk right now. I never dreamed I'd actually own a system with this much power, with this wide a choice of languages, this much flexibility, etc. Sure, the software bites--but hey, that's just more opportunity, right? A target-rich environment.
-
Things are getting better...We now have Ada95 output from GLADE targeting the GtkAda binding.
I have both Ada and C experience. Ada thrashes C for non-trivial programs. Maybe the problem is that most open source software starts out as trivial programs that scratch a programmers itch.
C++ and Ada95 are roughly equivalent. To my mind C++ suffers from its class-centric view of everything. Look at the hassles C++ has with singletons while Ada neatly solves this with the package structure.
adapower is a good place to start for those interested.