Newsgroups: | comp.compilers,comp.lang.basic |
From: | maniattb@cs.rpi.edu (Bill Maniatty) |
Organization: | Compilers Central |
Date: | Wed, 12 Aug 1992 20:48:27 GMT |
References: | 92-08-042 |
Keywords: | Basic, C, performance |
Glenn_Johansson@f313.n203.z2.fidonet.cd.chalmers.se writes:
|> 2. Why is the basic compilers creating a slower product than the C
|> compilers?
Slower in what sense, rate of compilation, or the run time speed of
executables generated. C requires more than one pass for compilation, and
therefore compiles slower than Basic. Basic is much easier to compile and
interpret than C (recall in the beginning of the PC movement Basic was the
first higher level language for many machines, Altair, Commodore, Apple,
IBM). The address space for a Basic interpreter/compiler is much smaller
than for C.
C is a more accurate representation of the underlying hardware, and it is
possible for the programmer to take advantage of that knowledge. Basic is
not a stack oriented language and cannot take advantage of the hardware
stack the same way that 'C' can. The C programmer has access to low level
(by that I mean close to the hardware) operations. C supports bit map
management, pointers, compile time constant folding, the register
qualifier etc.
Also since Basic is not suitable for implementation of large projects and
system software, much less work goes into optimization.
Basic programmers just don't have the same tools at their disposal.
Bill
--
| maniattb@cs.rpi.edu - in real life Bill Maniatty
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.