Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!jarthur!uunet!cbmvax!daveh From: daveh@cbmvax.commodore.com (Dave Haynie) Newsgroups: comp.sys.amiga.advocacy Subject: Re: Computer Architecture question -- Daye Haynie Message-ID: <22016@cbmvax.commodore.com> Date: 29 May 91 20:49:36 GMT References: <1991May15.112823.22229@sugar.hackercorp.com> <1991May19.123429.19440@sugar.hackercorp.com> <14750@ucrmath.ucr.edu> Reply-To: daveh@cbmvax.commodore.com (Dave Haynie) Organization: Commodore, West Chester, PA Lines: 41 In article <14750@ucrmath.ucr.edu> trout@ucrmath.ucr.edu (michael griffith) writes: >In article <1991May19.123429.19440@sugar.hackercorp.com> peter@sugar.hackercorp.com (Peter da Silva) writes: >>It's easier to screw up in assembly than C, in C than a B&D language like >>Pascal, in Pascal than C++, in C++ than SmallTalk, in SmallTalk than really >>high level database/dataflow languages like the UNIX shell, and so on... >>ALWAYS use the highest level language available that can get the job done. >This theory only holds if you are a screw-up. Assembly is much faster >and smaller than anything a complier or interpreter could ever write. That's not really true anymore. Certainly, for popular 70's CPUs, like the 6502 and Z-80, you needed assembly just to fit your code into the available 64K of so of memory. When we all graduated to better systems, like 68000s or even 80x86s, compiler could do a heck of alot better than on these older systems. Some 680x0 compilers can approach the quality of hand assembled code in many cases; they approach the problem differently, and don't get as creative as a good assembly hacker, but they can have absolute knowledge of which opcodes go faster where. Moving on to RISC processors, C compilers can generally do as well, or better, than hand assembly, since they can keep track of all kinds of pipelining details that would drive most programmers mad. If you get any stranger, like the MISC machine or some RISCs with multiple parallel execution units, an assembly programmer may not stand a chance. All of which is a moot point. The programming problems are growing much faster than anyone's available time. HLLs, where appropriate, will produce safer and more maintainable code. Going to higher levels of abstration, like from C to C++, you increase the kinds of checking the compiler does for you, cut down on programmer time, and drastically increase the code's maintainability. >ALWAYS use the language that is right for the job. That's true. At least on Amigas and other 680x0 machines, an HLL isn't always the right choice. And no single language solves every problem perfectly. I have used about 20-30 different languages since I started mucking around with computers in the 70s... -- Dave Haynie Commodore-Amiga (Amiga 3000) "The Crew That Never Rests" {uunet|pyramid|rutgers}!cbmvax!daveh PLINK: hazy BIX: hazy "That's me in the corner, that's me in the spotlight" -R.E.M.