Xref: utzoo comp.lang.c++:2101 comp.lang.c:14347 comp.lang.forth:660 comp.lang.fortran:1523 comp.lang.misc:2179
Path: utzoo!attcan!uunet!tank!uwvax!rutgers!mailrus!cornell!uw-beaver!teknowledge-vaxc!sri-unix!garth!tom
From: tom@garth.UUCP (Tom Granvold)
Newsgroups: comp.lang.c++,comp.lang.c,comp.lang.forth,comp.lang.fortran,comp.lang.misc
Subject: Re: Assembly or ....
Summary: Assembly does have its uses.
Keywords: assembly language
Message-ID: <2025@garth.UUCP>
Date: 28 Nov 88 17:23:22 GMT
References: <1388@aucs.UUCP> <729@convex.UUCP> <1961@crete.cs.glasgow.ac.uk>
Reply-To: tom@garth.UUCP (Tom Granvold)
Followup-To: comp.lang.c++,comp.lang.c,comp.lang.forth,comp.lang.fortran,comp.lang.misc
Distribution: comp.lang.c++,comp.lang.c,comp.lang.forth,comp.lang.fortran,comp.lang.misc
Organization: INTERGRAPH (APD) -- Palo Alto, CA
Lines: 27

-

    I must jump in on this discussion with my two cents worth.  There are
definitly cases where assembly language is not only appropriate, but 
nesscary!

    I write diagnostics that test the hardware in computer systems which
makes me a member of very small minorty of programers.  While reasonable
memory tests can be written in languages such as C or Forth, many other
tests require assembly language.  For example in the newer CPU's, especially
RISC chips, it is becomming common to have pipelining of instruction
execution and register scoreboarding.  In order to reasonably test these
features, one must be able to specify exactly whe sequence of instructions
that are to be executed.

     The second need for assembly is in real time control.  In my previous
job we were using a Z80 to control several stepper motors.  The critical
timing restrictions accured in the interrupt routines.  While there were
high level languages available for the Z80 none, that we were aware of,
were optimizing compilers.  Therefore we were able to produce much faster
code in assembler.  This was a case where every machine cycle was of
importance.  The most importent comment in the source code was the number
of machine cycles each instruction took.  Yes we could have used a newer
faster CPU that has  optimizing complier available for it, but Z80's are
cheap!

Thomas Granvold