[comp.sys.acorn] language wars; RE: new ARM-commands; question, questions, questio

mathew@mantis.co.uk (Giving C News a *HUG*) (06/04/91)

zrzm0111@helpdesk.rus.uni-stuttgart.de (MUFTI) writes:
> Most common opinion after the langague-war was, that you should normally use
> highlevel languages and should use assembler for critical parts of the progra
> cause highlevel constructs like "x=x+2*(y-34)+z" are faster to write and 
> very much easier to maintain than the same in Assembler.
> Most agree, that the misadvantage was, that the librarys lacks some memory fo
> unused routines.
> There is a way to use mathematical strings like "x=x+2*(y-34)+z" in programs,
> which run only through a macro-assembler producing a absolutefile and don't 
> lack so much memory for the libraries.

Why not do something like:

main()
{
   register int x,y,z;

   x = 1;
   y = 2;
   z = 3;

   x = x+2*(y+34)+z;

   return(x);
}

Total amount of memory used by libraries: zero.

Total size of compiled and linked code is just over 2K on this '386 box, but
that's including the headers for the relocatable code, the segment map, and
so on.

You don't have to use the libraries just because you're using a high-level
language. Your little program is, effectively, a small compiler for a
high-level language.


mathew