Engines

Forth Engines

Supported Forth engines

FFL will run on and is tested with the following forth engines :

Engine Since
GForth 0.1.0
BigForth 0.2.0
PFE 0.3.0
Win32Forth 0.4.0
fina 0.5.0
MinForth 0.5.0
iForth 0.6.0
SP-Forth 0.7.0

For these forth engines there is a config file present in the distribution package.

Forth Engines under porting

The following forth engines are being ported at the moment:

Engine
flk

Unsupported Forth Engines

FFL will not run on the following forth engines :

Engine Version Reason
kForth Missing ANS words
ciforth Case sensitive
pforth Missing ANS words
isforth Missing ANS words
4th Missing ANS words
helforth 2.51 Missing ANS words
lxf Segfaults during tests

Not yet checked Forth Engines

  • RetroForth
  • ficl

Environmental dependencies

A few modules have environmental dependencies. As a result they will not be present for some forth engines. For these modules you should test the presence of the version constant after loading the module.

GForth BigForth PFE Win32Forth MinForth iForth SP-Forth
Argument Parser (arg) No No Yes No No No No
Distributed Random Number Generator (rdg) Yes No Yes Yes Yes Yes No
Timer (tmr) Yes Yes Yes Yes Yes Yes Yes

Benchmarks

Some benchmarking info (done on a Celeron 700 MHZ).

Version 0.6.0

GForth BigForth PFE Win32Forth MinForth
Compile Time (msec) 1774 352 720 2630 9440
Compile Size (bytes) 169560 146406 166704 97176 106600
Test Time (sec) 7.9 8.2 24.1 15.3 140.2

Version 0.5.0

GForth BigForth PFE Win32Forth MinForth
Compile Time (msec) 1020 220 374 1760 6100
Compile Size (bytes) 132724 115090 133796 75696 83128
Test Time (sec) 6.8 8.2 23.6 14.3 132.9

Version 0.4.0

GForth BigForth PFE Win32Forth
Compile Time (msec) 690 158 255 1200
Compile Size (bytes) 103132 89710 112628 59660
Test Time (sec) 3.8 6.2 9.2 9.6

Legenda:

  • The Compile Time is the time required to include all modules in the dictionary.
  • The Compile Size is the space required in the dictionary to include all modules.
  • The Test time is the time required to include and run all the test scripts.

Porting

As already stated the FFL is mostly written in ANS forth. If your engine is not listed above and it conforms to the ANS-standard, you can try porting ffl to your forth engine by adding words to and removing words from the ffl/config.fs file. If you succeed, you can send me the config.fs file so that I can add it to the distribution.

ANS and Labelling

The Forth Foundation Library is written in ANS-standard forth. But it requires some extensions. All those extensions are listed in one config source file which is forth engine specific. One exception is the word: include filename. This word is used to include all modules. This is not a big problem, because this word is quite common in forth engines.

FFL is labelled as follows in accordance with the ANS standard:

  • ANS Forth Program with Environmental Dependencies.
  • Requiring names from the Core Extensions word set.
  • Requiring the Double-Number word set.
  • Requiring names from the Double-Number Extensions word set.
  • Requiring the Exception word set.
  • Requiring the Facility word set.
  • Requiring names from the Facility Extensions word set.
  • Requiring the File Access word set.
  • Requiring names from the File Access Extensions word set.
  • Requiring (optional) the Floating-Point word set.
  • Requiring (optional) names from the Floating-Point Extensions word set.
  • Requiring the Memory-Allocation word set.
  • Requiring the Programming-Tools word set.
  • Requiring names from the Programming-Tools Extensions word set.
  • Requiring the String word set.
page_revision: 13, last_edited: 1209720773|%e %b %Y, %H:%M %Z (%O ago)
Unless stated otherwise Content of this page is licensed under GNU Free Documentation License.