On Wed, 2011-02-02 at 13:21 -0500, erik quanstrom wrote:
> > A runtime system is just a library whose entry points are language
> > keywords.[1] In go, dynamic allocation, threads, channels, etc. are
> > accessed via language features, so the libraries that implement those
> > things are considered part of the RTS. That's a terminological
> > difference only from Plan 9 C, which has the same features[2] but
> > accesses them through ordinary library entry points so the libraries
> > that implement them aren't called `runtimes'. But I think complaining
> > about a library only because its entry point is a keyword is kind of
> > silly.
>
> i think this glosses over a key difference. a runtime can do things
> that are not invoked by function call. the canonical example is
> garbage collection.
I don't follow. Garbage collection certainly can be done in a library
(e.g., Boehm). GC is in my experience normally triggered by
* Allocation --- which is a function call in C
* Explicit call to the `garbage collect now' entry point in the
standard library. A function call in every language.
What other events canonically would trigger garbage collection, but not
be invoked by function calls?
jcc