Newsgroups: comp.lang.lisp
Path: cantaloupe.srv.cs.cmu.edu!bb3.andrew.cmu.edu!news.sei.cmu.edu!cis.ohio-state.edu!math.ohio-state.edu!jussieu.fr!univ-lyon1.fr!swidir.switch.ch!newsfeed.ACO.net!Austria.EU.net!EU.net!uunet!sytex!smcl
From: smcl@sytex.com (Scott McLoughlin)
Subject: Re: Why do people like C? (Was: Comparison: Beta - Lisp)
Message-ID: <aJZmTc1w165w@sytex.com>
Sender: bbs@sytex.com
Organization: Sytex Access Ltd.
References: <Cx3zo5.5sE@cogsci.ed.ac.uk>
Date: Mon, 3 Oct 1994 20:17:09 GMT
Lines: 62

jeff@aiai.ed.ac.uk (Jeff Dalton) writes:

> >After that, _everything_ became a lot easier!
> 
> I find it difficult to judge how much difference it makes to learn
> assembler.  I did learn an assembly language fairly early on, and
> I'm not sure how difficult things would have been if I hadn't.
> But I'd be surprised if novices typically learned such things
> at / near the start.
> 
> -- jeff

Howdy,
        I increasingly think that this is an important issue: the
role a "machine model" plays in a users understanding of a langauge.
Here are a few unscientific observations that point to a significant
if not universal role played by asm knowledge in "novices" understanding
of "computation" and hence of languages used to express computations:

o PC Magazine, a popular "novice hackers" mag, regularly publishes
the source for utilities etc written in assembler and compilable with
DOS's DEBUG.
o At "Border Books", a national chain that tends to carry "good books"
on CS and other topics, there are currently more books on asm than on
BASIC, although the popularity of VB seems to be leading a charge. If
you include books on "cpu architecture" with an emphasis on assembler,
asm still leads by a wide margin.
o In just about every DOS BASIC, Pascal, C source I've inherited, 
examined, and written there is some asm in the source.
o The Windows API online help includes some asm (See, at least, 
"InterruptRegister").
o Dr. Dobbs/C Users Journal/Windows/Dos Dev Journal routinely include
asm listings. Whether or not one considers readers of these "novices"
is a matter of opinion (standards?).
o The famous "SS != DS" .DLL problem, small/medium/large model issue,
near/far pointer issues in DOS and Windows programming certainly
aquaint C/Pascal DOS and Windows programmers with CPU related issues.
The most popular "intro" books include discussions of these issues
(e.g. Petzold).

Anyway, many of the "novices" reared on DOS (a large percentage of 
novice hackers out there, I'd wager) almost certainly have _some_
aquaintance with asm, sometimes only "cookbook".

There are similar issues in other areas of computing. I recently
taught my wife (an MBA) about stacks using Forth so that she could
use her HP financial calculator. Once we "played computer" a bit,
examined the stack, etc. she began RPN'ing like a pro. Before 
absorbing this "machine model" she used to write down all
intermediate values on paper and reenter them! She's a smart
cookie too (Harvard/Georgetown).

Anyway, I've been hacking a bit on the weekends on a very simple
Lisp compiler written in Lisp that compiles to 386 asm to see just
how simply/closely/lucidly a Lisp can be hooked up to a common 
CPU. I call it "SLC-1", "Stupid Lisp Compiler - v1". If anyone is
interested, email.

=============================================
Scott McLoughlin
Conscious Computing
=============================================
