Sun, 29 Sep 2002 02:28:30 +0900, William Djaja Tjokroaminata <billtj / y.glue.umd.edu> pisze:

> However, this is just my guess, when we use a garbage collector,
> there immediately we incur significant performance drop as compared
> to C.

Not that significant. OCaml is fast and garbage-collected. I've
heard some Lisp and Scheme implementations are also fast despite
dynamic types.

In fact almost all languages are garbage-collected, except C, C++,
Pascal and some either old languages or those with limited data types
(e.g. Unix shell).

For a high level language it makes no sense to not have GC:
apart of being inconvenient for programmers, it would complicate
the language (passing by value *and* by reference, definitions of
copying constructors and destructors and assignment for each type)
or values of simple types are handled differently than values of
user-defined types requiring variable-sized storage.

Also high level languages tend to create many small short-lived
objects which is more efficient with GC than with an allocator like
malloc/free which is not allowed to move objects.

-- 
  __("<      Marcin Kowalczyk
  \__/     qrczak / knm.org.pl
   ^^    http://qrnik.knm.org.pl/~qrczak/