micro optimizations for the evaluation engine

This commit is contained in:
Araq 2013-02-14 08:41:48 +01:00
commit 1c0c80ef2d
4 changed files with 64 additions and 43 deletions

View file

@ -22,6 +22,13 @@ delta-subgraph of the heap that changed since its last run.
The GC is only triggered in a memory allocation operation. It it not triggered
by some timer and does not run in a background thread.
To force a full collection call ``GC_fullCollect``. Note that it is generally
better to let the GC do its work and not enforce a full collection.
Cycle collector
===============
The cycle collector can be en-/disabled independently from the other parts of
the GC with ``GC_enableMarkAndSweep`` and ``GC_disableMarkAndSweep``. The
compiler analyses the types for their possibility to build cycles, but often
@ -30,11 +37,10 @@ it is necessary to help this analysis with the ``acyclic`` pragma (see
You can also use the ``acyclic`` pragma for data that is cyclic in reality and
then break up the cycles explicitly with ``GC_addCycleRoot``. This can be a
very good optimization; the Nimrod compiler itself relies on this optimization
trick to improve performance.
To force a full collection call ``GC_fullCollect``. Note that it is generally
better to let the GC do its work and not enforce a full collection.
very valuable optimization; the Nimrod compiler itself relies on this
optimization trick to improve performance. Note that ``GC_addCycleRoot`` is
a quick operation; the root is only registered for the next run of the
cycle collector.
Realtime support