Thu, 17 Feb 2011
Lady Ada
Was reminded of how I first got into Ada, and started using GNAT, the free Ada compiler, and figured I should record it before it slips my mind entirely.
Back in 1980 (I think, though it could have been late '79) I was in the US Air Force as a 51151, which was the career code for "Programming Specialist". I used to joke that I was a Tactical Assault Programmer, but in fact I was just a desk jockey, what they in the USAF called a "titless WAF". One day my boss, who was a civilian, handed out a memo to all of us in the office, which was not an unusual occurrence. It was from the Department of Defense, on official DoD letterhead, and said (I'm paraphrasing from the bureaucratese) something like this:
Deer Military Programmer,
How's yer day! Here in a little bit, we're all gonna be usin this new language we thought up called "Ada". This is for the Good of the Nation, so get used to it.
Regards, the Secy of Defense or his minion
I groaned and thought, well this is going to suck. A few days or weeks later, my boss handed me a slim paperback manual, printed in somebody's back office on letter-size paper, with a light green cover that said, "The Green Programming Language" (or maybe it was just "The Green Language", can't recall). He said, "This is Ada, or what will be Ada. Since we're all switching to it, we want to get a head start. Write a compiler for it so we can start getting used to it."
That wasn't as astounding a request as it may seem now. First, we didn't know anything about Ada, thus didn't know how ludicrous the assignment was, and second, I'd been heavily using a compiler-writing system/language called XPL, which miracle of miracles we had installed on our Univac 1108 and had the definitive Book for in our microscopic tech library. XPL was a delight, and I'd used it to create a patching macro assembler for a CPU called the TI MARC IV, a computer used in the Wild Weasel weapon system. So I said, "I'll get right on it!" and set about (ha!) writing an Ada compiler.
As I started to pore through the Green manual, I began to realize that somehow the DoD had made a good decision. This language was nice, not the colossal fuckup I had assumed it would be. It had everything in it that I could possibly want in a language, plus some things I hadn't even known I wanted, but did after I found out about them. I quickly fell in love. My "compiler" got to the point where it was properly lexing Ada source, and the parser was beginning to recognize basic structures, when my hitch was up and I got discharged in August 1980.
I retained my interest in Ada after that, but never had access to it. I came close sometime in, I think, 1982 or 83, when the company I worked for in Los Angeles, Abacus, had access to a remote timesharing system on some mainframe that had somebody's Ada compiler installed. It had a horribly baroque library system, and an even more contorted build system, so I was never able to build any meaningful Ada programs, not to mention I had other work I was supposed to be doing. But I kept a soft spot in my heart for Ada.
Years passed, and I changed jobs and wound up in Phoenix working for Honeywell. There we used Apollo workstations, and though I could not find Ada for them, I did keep an eye out, and eventually found DEC WRL's Modula-3. And I was able to get the source and actually build a compiler than ran, and produced running apps, on the Apollo! For those of you who haven't had the pleasure, Mod-3 is a lot like Ada in many ways; the differences are mostly ones of detail, not substance. I eagerly jumped on the Mod-3 bandwagon and started making plans to become a rock-ribbed Mod-3 guy.
By then I had started using Linux at home, and was determined to create a working Modula-3 build environment there too. As I was doing that, I read an announcement on a Usenet newsgroup about a new compiler called GNAT, out of NYU and supposedly compiling not just Ada, but the new version known at the time as Ada9x. I was doubtful, but hacked around long enough to find and install their Linux compiler.
And lo! It really did compile Ada, into real working apps. I was ecstatic, and dropped Mod-3 after about two weeks of trying to reconcile the two. For one thing, I could never get a working Modula-3 for Linux. Also, the Apollo version had some serious issues, which they were working furiously to address, but which gave me some notable headaches. And here was GNAT, running just fine on Linux and everything I tried with it Just Worked. For a brand-new compiler for such a complex language, it was amazingly bug-free and featureful. And the features they hadn't implemented yet were things I hadn't gotten around to using, and by the time I did, they'd been implemented. My love affair with Ada was rekindled, and hasn't died since.
I'm still using GNAT today, currently trying to write a GUI toolkit for OpenGL, and it continues to haul my freight like a trooper. Ada itself hasn't stood still: They dropped the DoD mandate in 97, a new version (Ada95) came along in the mid 90s with some nice additions, now a still-newer version (Ada05) is the standard, and they're busy with Ada12, which adds some interesting new features. And GNAT keeps plugging along, releasing new free versions every six months or so, and Ada is now an official front-end for the GNU Compiler Collection, or gcc, which is sorta the de facto standard for open-source software.
So I'm a happy camper, and I have to say, GNAT came along at just the right time in my life. No, this entry has no earth-shattering conclusions or excellent humor, it's just a record of an event in my life. A happy event, and we could all use more of those, eh?
Posted at: 00:06 | category: /Software | Comments (0)