Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: Craig Burley <burley@tweedledumb.cygnus.com>
Subject: Re: C vs. Fortran - Perl wins
Date: 1997/10/10	[thread overview]
Message-ID: <y667r5r537.fsf@tweedledumb.cygnus.com> (raw)
In-Reply-To: 61kjsd$i4r$1@goanna.cs.rmit.edu.au


ok@goanna.cs.rmit.edu.au (Richard A. O'Keefe) writes:

> Craig Burley <burley@tweedledumb.cygnus.com> writes:
> >...second, my sense is that when the "programming explosion" began
> >to happen, when portability across a wide number of machines mattered,
> >and when the programs were doing more iron-level things like OSes,
> >compilers, and so on, C *was* the first *convenient* language that allowed
> >manipulation of pointers that were, semantically, much like the
> >underlying machines' pointers.
> 
> "Convenient" will have to be defined fairly carefully.

That was indeed my point, actually, but you've supplied the details
(and more pertinent ones) much better than I did in my attempt.

> It was the contrast between PL/I and C that first taught me a major
> lesson:  STRINGS ARE WRONG.  One of the few lessons from that era which
> I still find valid.

Well, strings are right when what you have are strings: that is,
a collection of characters typed in by a user, or a report being
prepared for output.  PL/I was the easiest of the languages I worked
with for serious projects.  What I learned from PL/I is that there's
a big difference between "natural" and "obvious".  To the PL/I designers,
it was natural that "a = b + c;" meant, when all three variables were
strings, to convert b and c to numbers (by assuming they were encoded
in decimal), add them, then convert the result to a string (again,
decimal).  That's natural to some people, not to others, so it isn't
obvious; C++ proves this by making the "other" obvious choice, where
the same statement means an entirely different thing (concatenate the
two strings).  But I think we've had this discussion before, on
comp.compilers, a few months back.

I agree that using strings where trees and such are appropriate is
"wrong".

> >Now, keep in mind that, during much of the time these issues were
> >*really* being thrashed out, I was at Pr1me, a world unto itself,
> >mostly, that took its architectural and linguistic cues from an
> >entirely different base -- namely, FORTRAN, PL/I, and Multics, plus
> >doses and dashes of other stuff here and there.
> 
> I have written assembly code for a P400.  Terminally weird, I say.
> (The programmers at Auckland University wanted a PDP-11/70 running
> UNIX.  What we _got_ was a flaky P400 -- never get the first model
> of a machine in your country, waiting for parts from another country
> is such a pain -- with an operating system that really wanted to be
> running on a P300 and only grudgingly admitted that there was another
> instruction set that could access more memory.  The Fortran compiler
> was written in assembly code.  I tried to fix a problem with it and
> got completely lost.  A truly _horrible_ machine to write assembly for.

Hmm, I enjoyed it quite a bit.  I admit, after learning assembly on
PDP-8s, -10s, and -11s, plus an early 4-bit micro (4040 or some such
thing), the P400 was a bit of a shock.  And, unlike the guy who
maintained the Cobol compiler when I first arrived there, I never did
memorize the machine instructions (that is, I have no idea what the
actual encodings of P400 instructions were, whereas I can still remember
that the half-word instructions on the -10 were "5xx", and some
-8s instructions like 0=AND).

I've admitted before, though, that having already done P400 means I
don't feel any impulse to do ix86 assembly.  They're quite similar
in their terminal weirdnessicity.  I much prefer VLIW and superscalar
RISC, but really don't get much opportunity to do clever stuff in
assembly anymore.

However, I was pretty amazed to find out, recently, that the SPARCv8
ABI *didn't* bias the stack pointer since, in effect, the P400 one
did a couple of decades ago!  (The SPARCv9 64-bit ABI will -- I
asked.  ;-)  So in some ways the P400 instruction set did reflect
some serious engineering and thought, though usually the kind that
didn't care a lot about orthagonality.

> >C wasn't even a blip
> >on the radar screen when the P400 architecture was conceived,
> >especially for a vendor that cared a lot more about shipping a
> >wide performance range of compatible machines than about writing
> >a lot of software that'd port to alien machines.
> 
> Possibly the world's worst editor, especially with the cheap glass
> TTYs they sold us where the return key stuttered.  An interpreted
> Basic (the compiled Basic came later and we couldn't afford it),
> with Fortran and COBOL as the compiled languages.  No Pascal.  No
> Algol.   No SIL.  An architecture that had borrowed from Multics
> and an operating system that hadn't.  Stack instructions which
> misbehaved if you crossed a page boundary.

I don't remember the page boundary problem, but it sounds like you
were suffering through the rev 15, 16, and 17 versions of PRIMOS,
which, I suppose, posed some problems (although we got lots of work
done using them).  The Multics aspects of PRIMOS didn't really appear
until around 18 and especially 19.4.  But, transparent network file
access?  PRIMOS had that starting at 17.something, IIRC, and had
a pretty darn fast implementation as well, especially in the rewrite
circa 18 (again, IIRC).  In fact, for a while, it looked as if Prime's
big claim to fame was *real* networking (for its day), using token
ring and transparent file access as the basic mechanisms, though there
were some problems (authorization, for example) that they didn't seem
interested in solving, and no useful user apps (email, print spooling,
batch subsystems) they were really interested in providing that
exploited the great networking.

Regarding the editor, yeah, it was bad, but I got pretty proficient
using it in combination with COMINPUT and COMOUTPUT (PRIMOS' versions
of "sh" and "... > foo") to do pretty wild things.  What I didn't
like about the editor was that there was no ability to set up
default configuration to do things like *change* how you switched
between INPUT and EDIT modes (since, as you point out, hitting RETURN
at the beginning of a line was often *not* what Real Users wanted
to mean "switch mode").

> Prime's glossy brochures at the time had pictures of toy steam
> engines.  We made rather sarcastic comments about how appropriate
> they were.

Boy, that brings back memories!

> We never did figure out how come a machine with semiconductor memory
> and a Fortran compiler written in assembler could be so much slower
> at compiling Fortran than a machine with a ferrite core memory and a
> Fortran compiler written in Algol.  But it was.

Dunno what you're comparing it to, but Prime 400/500 were, essentially,
super-minis.  If you're comparing it to a mainframe, that would explain
a lot, especially the larger investment in software done by the mainframe
vendor.  I'd guess your facility bought the P400 because it cost a lot
less (or, if it was truly worse, because they were kinda dumb ;-).

Back then, starting around late 1978 or so IIRC, Prime's ran SPSS.
At the time, that was considered pretty impressive for a "mini" --
at least in-house, the explanation I was given was that, even though
the SPSS port effort wasn't paid for by SPSS licenses, the mere fact
that salesfolk could demo SPSS running on Primes sold a whole bunch
of machines to people who, otherwise, had no interest in SPSS itself.

So, for *some* people, it was *not* a poor performer at the price point.
I guess that's obvious, since there couldn't be *that* many stupid
people with lots of money to keep Prime in the black for so many
years, but your comments made it seem like Prime's were Just Plain
Slower than their competition, which I don't believe was the case.

> Has anyone written up a history of Prime?  I should think it would be
> compelling reading for anyone interested in computer architecture.
> They tried to handle compatibility the onion way.  Every time they
> ran into a restriction in the current architecture (like addressibility)
> they'd invent another, and ship a machine that could support _all_ the
> previous architectures as well.  For the P500, they had a really clean
> 360-ish instruction set, but most of the software used one of the other
> four or five instruction sets, at least at the time we lost interest in
> Prime (Primos 19 vintage).  From the outside, it really did seem as if
> the hardware people and the software people never talked to each other,
> and the software people never talked to the application developers, and
> _nobody_ was doing any long-term planning.  I really think a technical
> history of the Primes would make a fascinating and instructive book.

The P500's new instruction set (called 32I mode) wasn't *really* all
that clean, IIRC, and the fact that it wasn't well supported meant that
we didn't particular care to try to use it in-house.  But it was certainly
cleaner than anything else Prime had at the time (namely, the other
modes, which are [chant with me now ;-]: 16S, 32S, 32R, 64R, and 64V).

The hw and sw people *used* to talk to each other all the time -- in fact,
that was a "selling point" for new hires (like me), that the compiler
people would talk with the hw people about what instructions were most
important.

But, I think the huge success of Prime circa 1978-1980 and other things
led to a loss of high-level technical focus.  Certainly that less was
evident by 1982, when new management took over.  Poduska left around
that time, but had seemed (to us in the trenches) not to be
interested in the overall technical focus in the company for years
anyway.  So during 79-82, it felt to me like we were no longer one,
focused, group of people doing our separate jobs; rather, we were
each little, independent groups each with our *own* technical focus and
priorities, and that probably included the hw department(s) as well,
which increasingly were being told what to do by marketing rather than
the sw people.

When the new management came in in 1982, they quickly started solving
a bunch of longstanding problems in fine fashion (they fortified the
long-ailing Tech Pubs group, and generally improved lots of the
support systems like Education), but they also pretty much killed off
any high-level technical focus.  Even though I switched to Pubs around
that time (perfect timing for me, actually), the feeling was evident
to me through the engineers I dealt with: Prime had, technically, turned
into an amoeba with different legs trying to go in different, rather
fuzzy, directions, which ultimately pulled apart the "center" (which
had been a single line of compatible processors from the low to high
end) and the company itself.  Foundering on one or two shoddy products
(like the externally-supplied but black-hole-for-internal-bugfixing-
resources Office Automation System) didn't help, of course.

But as far as the P400 instruction set and philosophy, as far as I'm
concerned, the Intel x86 series is pretty much just a P400 with
market share.

Wish I'd understood more of these things back then, maybe I could have
helped more than just by doing my job.  Back around '82 or so, I felt
it was possibly a hindrance that we insisted so much on compatibility,
and felt Digital was making a big mistake by tossing away its old,
fine iron for ubiquituous VAXen.  What Digital had that Prime didn't
have was a fairly clear, technical focus at, or near, the top, which
meant that, at least, it was *possible* they'd succeed at doing what
they tried *technically*.  The lack of long-term focus really hurt
Prime, because it turns out that focusing all your energy on doing
what will make your quarter-end quotas makes it unlikely you'll end
up doing the new computer architecture the industry will want through
the next decade.
-- 

"Practice random senselessness and act kind of beautiful."
James Craig Burley, Software Craftsperson    burley@gnu.ai.mit.edu



  reply	other threads:[~1997-10-10  4:00 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-10-03  4:00 Final kick at the "Merced Guessing Game" Robert Harley
1997-10-06  4:00 ` Richard A. O'Keefe
1997-10-06  4:00   ` boo
1997-10-07  4:00     ` Richard A. O'Keefe
1997-10-06  4:00       ` Graham Hughes
1997-10-07  4:00       ` boo
1997-10-07  4:00         ` William Clodius
1997-10-07  4:00       ` William Clodius
     [not found]         ` <y4wwjon203.fsf@mailhost.neuroinformatik.ruhr-uni-bochum.de>
1997-10-08  4:00           ` William Clodius
1997-10-08  4:00             ` Stanley Chow
1997-10-08  4:00         ` Richard A. O'Keefe
1997-10-08  4:00           ` William Clodius
1997-10-08  4:00           ` William Clodius
1997-10-09  4:00         ` William Clodius
1997-10-10  4:00           ` Larry Kilgallen
1997-10-10  4:00             ` Zalman Stern
1997-10-11  4:00             ` Andrew Cruickshank
1997-10-12  4:00               ` Paul D. DeRocco
1997-10-13  4:00               ` Michael Williams
1997-10-08  4:00       ` Gregg E Economou
1997-10-08  4:00         ` Richard A. O'Keefe
1997-10-08  4:00         ` David Chase
1997-10-07  4:00     ` Serge Pachkovsky
1997-10-07  4:00       ` Martin Rodgers
1997-10-07  4:00         ` Greg Weeks
1997-10-07  4:00           ` Martin Rodgers
     [not found]           ` <343AAE5A.A3FCC9D@no.informatik.spam.tu-muenchen.thanks.de>
1997-10-09  4:00             ` Torben AEgidius Mogensen
     [not found]               ` <EHsr7B.Dt8@bit3.com>
1997-10-10  4:00                 ` Torben AEgidius Mogensen
     [not found]       ` <61cv5e$qn$6@vixen.cso.uiuc.edu>
1997-10-08  4:00         ` William Clodius
1997-10-07  4:00     ` Carlie Coats
1997-10-07  4:00       ` Paul Hsieh
1997-10-07  4:00         ` boo
1997-10-08  4:00           ` Carlie Coats
     [not found]             ` <343C3737.5435@Japan.NCR.com>
1997-10-09  4:00               ` C language Craig Burley
     [not found]                 ` <61jc3i$h2q$1@sue.cc.uregina.ca>
1997-10-09  4:00                   ` C vs. Fortran - Perl wins Nick Maclaren
1997-10-09  4:00                     ` Craig Burley
1997-10-10  4:00                       ` Richard A. O'Keefe
1997-10-10  4:00                         ` Craig Burley [this message]
1997-10-10  4:00                         ` David Gay
1997-10-13  4:00                       ` Roger Barnett
1997-10-14  4:00                   ` Richard A. O'Keefe
1997-10-18  4:00                   ` Tom
1997-10-08  4:00     ` Final kick at the "Merced Guessing Game" James C. Stutts
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox