★ wanayoo — archive 1999 http://pfe.sourceforge.net/Nouvelle recherche | Portail wanayoo

 

PFE - The Portable Forth Environment


1922

Project

The Portable Forth Environment (PFE) is based on the ANSI Standard for Forth. The PFE has been created by Dirk-Uwe Zoller and had been maintained up to the 0.9.x versions (1993-1995). Tektronix has adopted the PFE package in 1998 and made a number of extensions. It is now fully multithreaded and it features a module system. You can load additional C objects at runtime to extend the Forth dictionary. It is best targeted for embedded environments since you can easily exchange the terminal driver and the initilization routines.

Download

Download from the PFE filelist
at sourceforge.net/download.php/pfe

Snapshots are taken on a regular basis. Have a look
at pfe.sourceforge.net/pub

There is currently no CVS at sourceforge. The main releases are to be found at the PFE sourceforge project page
at sourceforge.net/projects/pfe

Documentation

The standard documenation is automatically generated and benefits from comments directly integrated in the PFE sources. See the unpacked documentation on this site, and fetch a copy of the compressed archive from the snapshot directory. In any case, you should read some documentation that encompasses the ANSI Forth Standard, e.g.
the Draft Proposal for ANSI Forth (dpans).

Author

Guido Draheim has been working on PFE at Tektronix in the last years. The released version is now maintained by me, Guido Draheim on a sparetime basis. You can contact me by e-mail, <guidod@gmx.de>.

In 1998 I had been contacting the original author Dirk-Uwe Zoller - well, his e-mail adress had changed since 1995 but I did find him. He told me that he has no intentions at all to do anything about Forth again, and so it came that I did not inform him any further about changes to the PFE. Please don't bother him either about anything that has to do with Forth, 'cause his mind is set elsewhere these days.

Changelog

 2000-07-01new <guidod@gmx.de>
 * put in a rule for a pfe-config.h that can get installed into
   a system directory.
 * prepare for Makefile-changes (and header-install rule later).
 * may need to upload a snapshot

2000-06-30new <guidod@gmx.de>
 * start off changes for flat loadlists. first change is 
   inclusion of a magic into p4Words/P4_COUNTWORDS.
 * name cleanup, prefix _p4 for Head,Wordl,File,Dict,Input,Iframe,Except
 * hmm, PFE_memory -> p4_MEMORY of course...
 * new file p4_defs.h to hold the shorthand definitions 
   (that is, without the prefix p4_ ), after all, the defines do
   now look like p4_STATE in the standard headers, and there is a
   "define STATE p4_STATE" in p4_defs.h - btw, the P4HLD, P4DPL
   and P4PAD were reversed in support.c/core.c
 * P4_SLOTS for the p-field, but P4_DL_SLOTS for dl-reservation,
   ie. DL_SLOTS = SLOTS - RESERVED_SLOTS
 * PFE.priv goes into a p-slot (PFE_TERM_SLOT)
 * p4SP/IP/RP/LP/FP -> p4_SP/IP/RP/LP/FP (only p4TH leaves as is for now)
 * P4_opt -> p4_OPT (and a P4_OPTIONS macro for term-k12.c inits)
 * debugging the SIGBUS that occurs after return from main(), it seems
   the compiler's crt0 assumes some registers to have certain values
   while the Forth VM has been overwriting them. Hmm, so let's create
   a p4_VM structure and utitility methods that can load/save the
   cpu registers to/from that struct. let's see to have s0&friends to
   occupy a VM-init member in PFE (where the usual .sp's will be also
   part of a VM-struct-member). Hope that helps us out.

2000-06-27new <guidod@gmx.de>
 * merge with tek src...
 * p4_compile1 and p4_compile do vanish, as they were kinda
   tricky they were out here to create errornous results. This
   has touched many source files that had their p4_compile1 changed
   into FX_COMPILE1. Some words had been calling other c-level words
   assuming that their p4_compile1 would use their own semantics
   definitions. This is now a wrong assumption, so that some forth
   implementations had to be changed considerably. yours.c/VAR is
   completly gone in the course, and in many place we had to use
   copy&paste to arrive at a correct behaviour.
 * changed many COMMA into FX_COMMA.
 * --------------
 * p4_count was missing a return (got rid of the warning though).
 * set a few FX_COMPILE1 into FX_COMPILE in core.c
 * need to use %ebp on i586 only if -fomit-frame-pointer was
   specified.
 * P4_MOPTRS -> P4_SLOTS (an ifndef to be -Definable)
 * PFE_memory defined as p[PFE_SLOTS], swap PFE.memory with it
 * get rid of cooperative forth threads stuff
 * p4_main_thread to be ready for _USE_PTH
 * p4_main -> implicit p4TH becomes an explicit argument

2000-05-22 <guiddod@gmx.de>
 * merge with tek src. This includes a few smallish changes.
 * add an "OFFSET:" word. This is best for "STRUCTURE" words like
   "/w+" or "CELL+" which are still simple fcode in the core.
   Having the offtset_RT in the base-pfe is nice since it will now 
   show up correctly in the debugger and there is a wordlist makro
   called "OT(name,offsetval)" which can take any compile-time
   integer-constant and build an "OFFSET:" entry in the dictionary.
   example: 
       > 5 OFFSET: ->myoffset
       > 3 ->myoffset .
       8
 * "LOADM" has a small semantic change - if the module is already
   LOADED the word will immediatly return (and not call "(LOADM)" 
   which will work the traditional way).
 * with-fig changes continued, still not complete (DOES words are wrong).
 * Makefile.in rules tweaked, taken out implicit reconfigure,
   it was too much trouble in a few occasions. 

 

License

This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

The complete License should come with the distribution archive (COPYING.LIB) or look for the latest version at the FSF website. The HTML-version of the LGPL-License can also be obtained from OpenSource.org.

As with all free software, there are no warranties for use cases that the copyright holders have not given an explicit liability. The distributor of the program should give you more information about support options to pay for.

The program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details.

You should have received a copy of the GNU Library General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.


(P) 2000-07-02 "PFE - Portable Forth Environment" guidod @ pc3