On Fri, May 22, 2020 at 7:51 PM Greg A. Woods <woods@robohack.ca> wrote:
I always assumed C became popular because there was a very large cohort
of programmers who started with it as their first language, usually on
early Unix, at university, in the late very 1970s and early 1980s.
Exactly - my giving away UNIX, it cemented the language and the technology into a group of young engineers (like me) who then 'spread the gospel' when we went to real jobs.

Well, there were a plethora of both full C and "tiny"/"small" C
compilers widely available in the very early 1980s.
Yep -- I listed a little of the pre-history.


Indeed I would say inexpensive C compilers were widely available and
very popular well before 1985, and a few "toy/tiny" compilers were
freely available by then too. 
Yup, although until the 386 and the DOS extenders, it could be tough to use with the Gordon's awful 'far pointer' infection.

Early Atari (6502) computers were partly programmed with a cross-
compiler, though I've no idea what it was (possibly a re-targeted PCC).
Most 6502 shops were assembler, although you are correct cc65 shows up reasonably early.  It was not PCC based.   

I think VisiCalc had similar origins.
Dan Bricklin wrote it assembler.  He had access to the same Harvard PDP-10 that Gates and Allen had used to write MITS Basic a few years earlier.   I should ask him to be sure, but I was under the impression he used the SAIL based 6502 assembler I mentioned previously.[1]  


The most ground-breaking C compiler might arguably have been
P.J.Plauger's Whitesmiths C compiler, around about 1978.  I don't think
it was what you'd call "inexpensive" necessarily, but it was popular.
Other than his wretched 'anat' - a natural assembler, which was far from natural. But you are correct, particularly for non-UNIX boxes, he had the first 'widely used' compiler.

In my estimation GCC really only served to cement C's early success and
popularity.  It gave people certainty that a good C compiler would be
available for most any platform no matter what happened.
I would agree.  C had already been 'winning' by the time of gcc, and offering a compiler that was so portable and generated 'reasonable' code (sometimes even better than some of the commercial ones) I think was the winning score.

I would also argue that non-Unix C compilers actually drove the adoption
curve of C. 
I would put a small accent on that.  I think the C compilers that targeted non-UNIX systems, and in particular the microprocessors were the driver.  The micro's started with assembler in most cases.  Basic shows up and is small, but it's not good enough for real products like VisiCalc or later Lotus.   Pascal tries to be the answer, but I think it suffered from the fact that it makes Pascal a production quality language, you had a extend it and everybody's extensions were different.

So, C came along and was 'better than assembler' and allowed 'production quality code' to be written, but with the exception of the far pointer stuff, pretty much worked as dmr had defined it for the PDP-11.  So code could be written to work between compilers and systems.   When the 386 DOS extenders show up, getting rid of far, and making it a 32-bit based language like the Vax and 68000, C had won.


1.] FWIW: Bricklin I know socially.  He was one of my brother's quad-mates at HBS in 1978-79 when he wrote VisiCalc to do his homework [the story is on the Wikipedia page].   In fact, there is now a plaque in the shared lounge over the nook where his study carrel was when he wrote it.  The four of them all did pretty well.  You know Dan's story, his roommate went on to found Staples, my brother's roommate became the CEO of Pepsi, and my brother ran Milcron, then founded a materials handling firm that did the automation for Amazon (and he sold the firm a few years ago to Honeywell).   Also, their section-mate was Clay Christensen of the 'Innovators Dilemma' fame and of course classmate Meg Whitman would do eBay.   Pretty impressive class from HBS.