home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / forth / compiler / fpc / history.doc < prev    next >
Text File  |  1991-04-25  |  71KB  |  1,540 lines

  1. °Notes                  Development Notes
  2.  
  3.  06/26/89
  4.  
  5.         Added ARRAY to the list of available data structures.
  6.  
  7.         You don't need to put a BYE at the end of you program any more,
  8.         as it is built into the initialization code.
  9.  
  10.         Corrected compiler so it only includes variables and arrays when
  11.         they are referenced by an application or application referenced
  12.         word.  This reduced the data segment overhead from about 150
  13.         bytes to two bytes if no data is referenced.
  14.  
  15.         Added two target compiler optimizers, the first looks for an
  16.         "LODSW" (POP AX) preceeded by "SUB SI, # 2  MOV 0 [SI], AX"
  17.         (PUSH AX), and deletes both.  The second optimizer looks for
  18.         "MOV BX, AX" preceeded by "MOV AX, # immediate", and changes the
  19.         move immediate AX to a move immediate BX.  These two optimizers
  20.         shortened the CLOCK program from about 5000 bytes down to 3800
  21.         bytes.  The smallest .COM file I can now generate is 50 bytes,
  22.         and the "Hello World!" program is 173 bytes, down from 330 bytes.
  23.  
  24.         Modified compiler so there are select words for specifying where
  25.         words are going, rather than using special word names for each
  26.         place. Specifically : (colon) and CODE are defered, and directed
  27.         to either Forth, Target, or Library controlled by the words:
  28.  
  29.                 >FORTH          >LIBRARY        >TARGET
  30.  
  31.         This makes the source code much easier to read, and much less
  32.         error prone on entry.
  33.  
  34.  06/28/89
  35.  
  36.         Add automatic boot compiling to TCOM. Now it will initialize
  37.         itself when it boots, and compile whatever file you put on the
  38.         DOS command line. Here is an example of how to use TCOM:
  39.  
  40.                         TCOM CLOCK <enter>
  41.  
  42.                                 or
  43.  
  44.                         TCOM SAMPLE <enter>
  45.  
  46.         You can keep TCOM from automatically starting to compile, with
  47.         the following sequence:
  48.  
  49.                         TCOM CLOCK QUIT <enter>
  50.  
  51.         TCOM will open CLOCK.SEQ, but will QUIT before starting to
  52.         compile it. You can then compile CLOCK by typing:
  53.  
  54.                         TARG <enter>
  55.  
  56.  06/28/89       ----
  57.  
  58.         Corrected the bug that was keeping me from starting to allocate
  59.         data variables from address zero. The default flag for an
  60.         unresolved symbol was zero (0), it has been changed to "-1".
  61.         This should prevent further problems.
  62.  
  63.  07/07/89
  64.  
  65.         Extended the MOV_BX,AX optimizer to test for the additional case
  66.         where this instruction is preceeded by MOV AX, 0 [SI]. If this
  67.         is found, then the instruction is changed to MOV BX, 0 [SI].
  68.  
  69.         Added two additional optimizers. The first tests for the
  70.         following case:
  71.  
  72.  
  73.                 DEC IP            ──┐
  74.                 DEC IP              │     push item1 on the stack
  75.                 MOV 0 [SI], AX    ──┘
  76.                 MOV AX, 0 [SI]            get a copy of item one in AX
  77.  
  78.         This sequence can occur whenever we push "item1" on the stack
  79.         and follow it with an operator that modifies item one
  80.         subsequently returning it to the stack.  The optimization here
  81.         is simply to discard the final instruction, saving two bytes and
  82.         15 clock cycles.
  83.  
  84.         The second optimizer tests for multiple occurances of DROP in a
  85.         program, and folds all multiple drops into a single inctruction
  86.         "ADD SI, # xxxx" for the correct operation.
  87.  
  88.  07/13/89
  89.  
  90.         Factored the compiler to get as much of the target specific code
  91.         out of it as possible. The target specific code has been moved
  92.         into the library file.
  93.  
  94.         This is part of the process of modifying the compiler to work
  95.         with additional target processors. I have coded a sample target
  96.         that looks somewhat like a Forth Chip. It outputs assembly
  97.         source at the moment that is re-directable to the printer. If
  98.         you want to write a new target, you need only re-write the
  99.         library file for the target processor. Of course this is only in
  100.         theory for now.
  101.  
  102.  07/17/89
  103.  
  104.         Here is a list of command line parameters that can be passed to
  105.         the target compiler. Also included is a description of their
  106.         functions:
  107.  
  108.                 /CODE           Display the assembled code as compiling
  109.                 /SRC            Display the source while compiling
  110.                 /OPT            Turn on the code optimizer
  111.                 /LST            Direct any output from the /CODE or /SRC
  112.                                   options to IMAGE.LST.
  113.  
  114.         These options are used as follows:
  115.  
  116.                 C> TCOM <filename> /CODE /SRC /OPT /LST <enter>
  117.  
  118.         They may be used in any order on the DOS command line.
  119.  
  120.  09/12/89
  121.  
  122.         Added help to display when TCOM is executed without any command
  123.         line parameters. Here is the /HELP display:
  124.  
  125.       ┌──────────────────────────────────────────────────────────────────────┐
  126.       │ Command line format:    "TCOM <filename> <option> <option> <...>"    │
  127.       │ Command line compiler options available are:                         │
  128.       │                                                                      │
  129.       │ /code     = Enable the display of compiled code.                     │
  130.       │ /codeoff  = Disable the display of compiled code ........ (default). │
  131.       │ /src      = Enable the display of source while compiling.            │
  132.       │ /srcoff   = Disable the display of source while compiling (default). │
  133.       │ /opt      = Enable compiler optimization.                            │
  134.       │ /optoff   = Disable compile optimization  ............... (default). │
  135.       │ /lst      = Generate a listing file.                                 │
  136.       │ /lstoff   = Don't generate a listing file ............... (default). │
  137.       │ /sym      = Generate a symbol file for BXDEBUG.                      │
  138.       │ /symoff   = Don't generate a symbol file ................ (default). │
  139.       │ /DOS      = Shell out to DOS .......... (NOT a command line option). │
  140.       │ /bye      = Return to DOS ............. (NOT a command line option). │
  141.       │ /help     = Re-display this help text.                               │
  142.       │                                                                      │
  143.       │ Type /BYE to leave the compiler.                                     │
  144.       └──────────────────────────────────────────────────────────────────────┘
  145.  
  146.  09/21/89
  147.  
  148.           Fixed VARIABLEs, CONSTANTS and ARRAYs so they return their
  149.         proper value or address when they are used in interpret mode.
  150.         This allows variables to be pre-initialized, and allows
  151.         defined constants to be used in defining additional
  152.         constants. This change also allowed me to get rid of the
  153.         "L[']" word which was needed when variables were used in
  154.         library code words.
  155.  
  156.           Modified compiler so it creates .COM, .SYM, and .LST files
  157.         with the same name but different extensions as the file being
  158.         compiled.
  159.  
  160.  09/30/89               **** Version .77 ****
  161.  
  162.           Modified entire LIBRARY to keep the top of stack in BX.
  163.         This reduces the compiler output size, and improves code
  164.         performance. All of the optimizers had to be re-written.
  165.         Cleaned up some bugs in the way the optimizer flags were
  166.         working, they were getting turned off, and not back on.
  167.         FIXED. Added new flags /SHOW, and /SHOWOFF to control whether
  168.         the application symbols were to be displayed as the compile
  169.         was performed. The default is /SHOWOFF. /BYE can now be used
  170.         on the command line to force the compiler to return to dos
  171.         when the compile completes.
  172.  
  173.  09/03/89
  174.  
  175.           Added several optimizers, to improve the produced code. The
  176.         most significant optimizer is IMM_OPT. It compresses in many
  177.         cases 7 or 8 instructions into one instruction saving many
  178.         clock cycles. The resulting code after optimization is now
  179.         greater than 10% smaller. There are still problems with the
  180.         listing file generated with the optimizer turned on, as many
  181.         of the listing instructions are written, and subsequently
  182.         discarded by the optimizer. I need to work on this, but I
  183.         haven't yet figured out a good solution.
  184.  
  185.  10/06/89
  186.  
  187.           Improved string handling in libraries. You can now use " and
  188.         ." in libraries. The strings are handled correctly, and no
  189.         space in the target is allocated until the function containing
  190.         the string is used in the target. You still must not use ," or
  191.         CREATE in a library, as this will immediately allocate space
  192.         and a symbol. Use ARRAY to specify an area of memory that will
  193.         be needed by a library definition.
  194.  
  195.  10/10/89
  196.  
  197.           Added list file buffering to reduce the DOS overhead while
  198.         creating a listing. Listings can be as much as 10 times the
  199.         size of the original source files being compiled, so a 50k
  200.         source file like the SZ editor, can create a listing file up to
  201.         almost 500k bytes. If all you want is a listing of the symbols
  202.         map, you can try the following command line options in the
  203.         shown sequence: "TCOM <filename> /LST /SRCOFF /CODEOFF"
  204.  
  205.           The /LST turns on the source as well as the code output,
  206.         alone with the symbol map at the listing end. following /LST
  207.         with /SRCOFF and /CODEOFF leaves a listing file containing only
  208.         the symbol map.
  209.  
  210.  10/11/89       **** Version .80 ****
  211.  
  212.           Changed the status of TCOM from Copyrighted to Public Domain
  213.         this date.      Tom Zimmer
  214.  
  215.           Also added a new option to the compiler, /NOINIT. This
  216.         option allows you to tell the compiler not to include the
  217.         initialization code for console I/O. You can create smaller
  218.         utilities with this option, but you cannot use TYPE, or SPACES.
  219.  
  220.  10/19/89
  221.  
  222.         Added a few new words to the system, cleaned up some problems
  223.         associated with redefining words in the kernel. Added VALUE's,
  224.         =:, !>, ABORT, ABORT", and MS. Added Peter Midnight's Towers of
  225.         Hanoi solution to TCOM as another sample of an application you
  226.         can target compile.
  227.  
  228.  10/23/89
  229.  
  230.         Added some simple graphics support for PLOT, POINT, LINE and
  231.         LINETO. PLOT uses the BIOS, and as such is quite slow. You can
  232.         use VMODE! to set whatever graphics mode you want. It is very
  233.         simple, but it works with CGA, EGA, and VGA.
  234.  
  235.  10/24/89       **** Version .90 ****
  236.  
  237.         Added DEFER to the defining word set, thus allowing defered words
  238.         to be used in a target compiled application. Use !>, =: or IS to
  239.         store a function into a defered word.
  240.  
  241.  10/25/89
  242.  
  243.         Added support for:
  244.  
  245.                 Pull down menus
  246.                 Framed boxes
  247.                 Screen save and restore
  248.  
  249.  10/26/89
  250.  
  251.         Got the previous entries functions reasonably debugged.
  252.  
  253.  10/29/89
  254.  
  255.         Added SAVE>, SAVE!> and RESTORE> to the compiler for variables
  256.         and values. These are handy if you are trying to port applications
  257.         to the target compiler from FPC.
  258.  
  259.  10/30/89
  260.  
  261.         Added LINEEDITOR to target library. This handy utility is used
  262.         in many of my programs, and has proven indispensable.
  263.  
  264.         Fixed some bugs in ABORT", and added code to allow ABORT" to
  265.         be used in a library routine. ABORT" will always do a BYE if
  266.         an error occurs, so don't use it unless thats ok.
  267.  
  268.  11/01/89       **** Version 1.00 ****
  269.  
  270.         Modified the default initializaton, so more things are
  271.         automatically initialized in the target. I spent a lot of time
  272.         the other day trying to get an application to target compile
  273.         only to find out my problems were caused by forgetting to
  274.         initialize a utility that is automatically initialized in FPC,
  275.         but wasn't in the target compiler. Sooo, I decided it was
  276.         better to make larger target programs that work, than smaller
  277.         target programs that don't work. You can always disable the
  278.         default initialization with /NOINIT, and do your own, but the
  279.         default should be to init.
  280.  
  281.  11/13/89
  282.  
  283.         Added the window file selection tool to TCOM, simply place the
  284.         word GETFILE in your program when you want to pick a file from
  285.         a list of files. Returns a1, the address of the selected file,
  286.         and f1 true if a file was selected.
  287.  
  288.         Added SPINNER2. The two spinners show: left=lines compiled,
  289.         and right=library colon definitions compiled.
  290.  
  291.         If the right spinner spins, and the left spinner stops, the
  292.         compiler is compiling from the library rather than the disk.
  293.         Spinners are turned off when output is directed to the listing
  294.         file.
  295.  
  296.  11/15/89       ***** Version 1.01 *****
  297.  
  298.         Added Hypertext Help to the TCOM compiler. Just type TCOM <enter>
  299.         then press the F1 key to invoke help.
  300.  
  301.  11/16/89       STDIO and IO redirection
  302.  
  303.         Added GETCHAR and PUTCHAR, the DOS redirectable I/O operators.
  304.         GETCHAR returns a char unless the end of file has been reached.
  305.         If the end of file is encountered, it returns a -1.
  306.  
  307.         The new function RAW_STDIN can be used at the start of a program
  308.         to tell DOS to make STDIN "raw" and "unbuffered". Characters will
  309.         be read one at a time rather than a line at a time as is normal
  310.         for STDIN.
  311.  
  312.         Made KEY deferable, like TYPE. Added KEY-F a variable that gets
  313.         initialized to hold %KEY which is a BDOS key that filters function
  314.         keys and translates them, to greater than 127. KEY can be
  315.         redirected to GETCHAR with STDIN_INIT for proper input redirection.
  316.  
  317.         Since the default I/O initialization DOSIO_INIT and the video
  318.         version VMODE.SET both set KEY-F to %KEY, you must perform
  319.         STDIN_INIT after one of these initialization words has been done
  320.         to make it take effect.
  321.  
  322.  11/17/89
  323.  
  324.         Found a BUG in DEALLOC in the library. It was completely missing
  325.         the MOV AH, # $49 instruction just before the INT $21. Added the
  326.         afor mentioned instruction to fix.
  327.  
  328.         Reworked TSAVESCR and TWFL to ALLOC and DEALLOC the memory they
  329.         need for operation. This makes thing cleaner, and removes the
  330.         nest limit on saveing and restoring screens.
  331.  
  332.         Added TABLE and END-TABLE to the compiler, to be used for building
  333.         tables of literal values in the target or in library functions.
  334.  
  335. °11/20/89               ***** Version 1.02 *****
  336.  
  337.         Added ICODE and IMACRO to the defining word list. These words
  338.         create CODE or MACRO type words that actually compile at target
  339.         compiler build time rather than when they are referenced in the
  340.         target. The object code is then moved into the target when
  341.         needed. This saves both time and space in the compiler. One
  342.         caution with ICODE and IMACRO words, they must not be used to
  343.         define words that access external data, that is thry can't refer
  344.         to BASE, or CAPS, or any other external to themselves variable or
  345.         address. Since they are actually assembled when building the
  346.         library, those variables won't exist yet so use CODE or MACRO if
  347.         you need reference external data. ALSO these words are for use in
  348.         the LIBRARY ONLY, there is no reason to use them in the actual
  349.         target compiled application source code since that source is
  350.         actually compiled at target time anyway. If you look at
  351.         LIBRARY.SEQ, you will see many examples of how these words are
  352.         used. They save about 4k in the target compiler, and make it
  353.         about 10 percent faster.
  354.  
  355.  11/20/89
  356.  
  357.         Added simple hercules graphics support to TCOM. Mike Mayo obtained
  358.         routines from Oliver Shank, and extracted and simplified the point
  359.         plot routine for use with TCOM.
  360.  
  361.         Use GRAPH-INIT to initialize PLOT and POINT for COLOR or HERCULES,
  362.         it returns TRUE if on a COLOR system, and FALSE for Hercules.
  363.         Use this flag to select either HERCULES, or one of the COLOR
  364.         graphics modes listed in TGRAPH.SEQ.
  365.  
  366.         The "VALUES" VDOTS, HDOTS and #COLORS are set according to the
  367.         graphics mode selected.
  368.  
  369.  11/22/89
  370.  
  371.         Added LABEL to the set of defining words, it is currently ONLY
  372.         available in the LIBRARY.
  373.  
  374.                 ******************************************
  375.                 *** Not true any longer, see 03/27/90 ****
  376.                 ** LABEL can be used in the target code **
  377.                 ******************************************
  378.  
  379.         Added sample application LINES.SEQ to show how to make a program
  380.         that will work in graphics mode on either CGA or HERCULES.
  381.  
  382.  11/23/89
  383.  
  384.         Removed the requirement that a "main" definition be added to the
  385.         beginning of each target compilable file to set the entry point.
  386.         TCOM NOW AUTOMATICALLY MAKES THE LAST DEFINITION IN YOUR FILE THE
  387.         ENTRY POINT OF THE PROGRAM. Since this is normally the way Forth
  388.         programs are written, transporting programs to TCOM should be a
  389.         bit simpler. If you want to enter your program at a place other
  390.         than what would normally be the last definition, you will need to
  391.         add a definition to the end of your program to call your desired
  392.         entry point.
  393.  
  394.         This change also makes it easier to make a program compilable on
  395.         F-PC for debugging purposes since forward references are NO
  396.         LONGER REQUIRED.
  397.  
  398.  11/23/89 10:39:54.67   ***** Version 1.03 *****
  399.  
  400.         This version was released to all attendees at the 1989 FORML
  401.         conference at Asilimar, California. The conference occured
  402.         between November 24th and 26th.
  403.  
  404.         *****************************************************************
  405.  
  406.  11/25/89
  407.  
  408.         Added "EXECUTES>" to the compiler. EXECUTES> allows target library
  409.         words to have a specified FORTH vocabulary function they will
  410.         execute when they are used in INTERPRET mode (as opposed to
  411.         compiling) while target compiling.
  412.  
  413.         EXECUTES> is used as follows:
  414.  
  415.         MACRO TIB       ( -- a1 )       \ Terminal Input Buffer address
  416.                         SAVE_BX
  417.                         MOV BX, 'TIB    END-MACRO       EXECUTES> TIB
  418.  
  419.         Here we specify that the target TIB definition executes the
  420.         FORTH TIB definition when in interpret mode. EXECUTES> looks up
  421.         the word following in the FORTH vocabulary.
  422.  
  423.         The only limitation on EXECUTE>, is it may not be used after an
  424.         ICODE or IMACRO library definition.
  425.  
  426.  11/27/89               ***** Version 1.04 *****
  427.  
  428.       ****************************************************************
  429.       ******* The following ROMability has not yet been tested *******
  430.       ****************************************************************
  431.  
  432.         Added some new command line options and code to allow TCOM to
  433.         produce romable code as follows;
  434.  
  435.           /code-start   ( | <addr> -- )
  436.                         Set target CODE starting address. Defaults to
  437.                         $100, a DOS type program.
  438.  
  439.           /code-limit   ( | <addr> -- )
  440.                         Set max size of CODE compiled into the target.
  441.                         Defaults to $A000, which allows 40k of code and
  442.                         24k of data in a compiled program.
  443.  
  444.           /data-start   ( | <addr> -- )
  445.                         Set target data starting address. Normally zero,
  446.                         but can be set to other values.
  447.  
  448.           /ram-start    ( | <seg> -- )
  449.                         Set the segment in target memory where ram
  450.                         is located, data is them moved into that ram from
  451.                         the ROM.
  452.  
  453.           /ram-size     ( | <n1> -- )
  454.                         set amount of ram available in the target.
  455.                         Defaults to $FFEE if not specified.
  456.  
  457.         The /RAM-START segment defaults to $FFFF if not specified which
  458.         signifies to the compiler that this is a RAM based system, which
  459.         does not need to have its data moved from ROM to RAM.
  460.  
  461.         When compiling DOS type programs or utilities, the above
  462.         parameters can usually be left with their default values.
  463.  
  464.         The /NOINIT option would of course need to be specified when
  465.         compiling a ROMable application since much of the default
  466.         initialization code deals with a DOS environment.
  467.  
  468.  11/28/89
  469.  
  470.         Finally fixed the branch distance limit. Conditional branches can
  471.         now be as long as you want, you need only specify the command
  472.         "LONG_BRANCH" either at the beginning of your source file, or
  473.         before a definition that needs a longer branch than 127 bytes.
  474.         The command "SHORT_BRANCH" switches back to 127 byte branch
  475.         limits. The advantage of short branches, is they are faster and
  476.         require less space.  The default is still SHORT.
  477.  
  478.         An additional pair of operators LONG_LIBRARY and SHORT_LIBRARY
  479.         allow you to specify long or short branchs in the library files.
  480.         Again the default is SHORT. Unless you add additional library
  481.         functions that need long branches, short branches work for all
  482.         library functions.
  483.  
  484.  11/29/89               ***** Version 1.05 *****
  485.  
  486.         Added TSHAPES.SEQ from Mike Mayo. This adds support for ARC and
  487.         CIRCLE drawing. Small mod to TGRAPH, added "LINESET", to
  488.         initialize line drawing so you can then use LINETO for successive
  489.         segments to be drawn.
  490.  
  491.  12/05/89
  492.  
  493.         Modified line drawing some, renamed LINESET to be LINEFROM as in
  494.         draw a LINE FROM point x, y. Modified LINE to reduce the number
  495.         of stack operations needed. It is now defined interms of LINEFROM
  496.         and LINETO. rather than the other way around.
  497.  
  498.         Added the read/write mode control from F-PC back into the target
  499.         compiler. The new words available are:
  500.  
  501.                 READ-ONLY   READ-WRITE   WRITE-ONLY   DEF-RWMODE
  502.  
  503.         The default HOPEN mode is READ-ONLY. If you use the sequence:
  504.  
  505.                 READ-WRITE DEF-RWMODE
  506.  
  507.         at the beginning of your program, then all HOPEN's will be
  508.         READ-WRITE.  HCREATE always makes files READ-WRITE which is the
  509.         way they will stay until you HCLOSE and re-HOPEN them.
  510.  
  511.         Also needed to modify CARD.SEQ to make it select READ-WRITE for its
  512.         BLOCK operations.
  513.  
  514.  12/12/89               ***** Version 1.06 *****
  515.  
  516.         Added 2VARIABLE, and 2CONSTANT to the defining words the compiler
  517.         will recognize.
  518.  
  519.         Re-factored TARG_COMPILE to eliminate the large CASE statment,
  520.         and instead use an EXEC: for speed. Changed the data types from
  521.         literal 'LETTER' definitions, to an array of data types starting
  522.         with the value 0.
  523.  
  524.  12/15/89
  525.  
  526.         Added full date/time and timer support from F-PC. New words
  527.         include:
  528.  
  529.         HOURS           MINUTES         TENTHS          SECONDS
  530.         10TH-ELAPSED    SEC-ELAPSED     .ELAPSED        B>SEC
  531.         TIME-ELAPSED    TIME-RESET      B>T             T>B
  532.         TTIME           STIME           .DATE           D.M.Y
  533.         Y-M-D           M/D/Y           .TIME           DTBUF
  534.         SETTIME         GETTIME         SETDATE         GETDATE
  535.  
  536.  12/18/89               ***** Version 1.07 *****
  537.  
  538.         Fixed a bug in EXHREAD and EXHWRITE. The word HDOS3 was broken,
  539.         and was preventing these two wordds from working. Repaired.
  540.  
  541.         Added LINEREAD support, see the file TSREAD.SEQ for details.
  542.         Some of the added words are:
  543.  
  544.             LINEREAD  LINEREAD_INIT  IBRESET  OUTBUF  LRHNDL
  545.  
  546.             LOADLINE .LRHNDL  MEMCHK  CURPOINTER  LINE_LIMIT
  547.  
  548.         Also added LOOK.SEQ an example of how to use the LINEREAD
  549.         support just added.
  550.  
  551.  12/19/89
  552.  
  553.         Made some minor repairs to TPATH in the definition PATHSET, and
  554.         added PATHSET back into HOPEN. Had to split THANDLES into two
  555.         files to get TPATH to load without forward references.
  556.  
  557.  12/20/89
  558.  
  559.         Added a couple of words to library:
  560.  
  561.                 $>TIB  ?LINE  ?CR  LMARGIN  RMARGIN  TABSIZE
  562.  
  563.         Adjusted automatic initialization to set LMARGIN to zero,
  564.         RMARGIN to 64 and TABSIZE to 8.
  565.  
  566.  12/20/89               ****** Version 1.08 ******
  567.  
  568.         Just added Bob Smiths "Public Domain" high level floating point
  569.         package to the target compiler. Preliminary testing indicates
  570.         it is functioning properly. You can now use floating point
  571.         functions in target compiled programs.
  572.  
  573.         The performance will probably not be up to Bob's SFLOAT package
  574.         in F-PC, but shouldn't be too bad since the compiler generates
  575.         call threaded assembly language. The file is TFLOAT.SEQ. It is
  576.         not being included as a precompiled library, as it would add
  577.         another 12k to the compiler. It is however defined as a library
  578.         file, so if you FLOAD it at the start of your application, only
  579.         the needed functions will actually be included in your program.
  580.         Floating point space overhead will run from 4k to 10k depending
  581.         on the functions used.
  582.  
  583.  12/21/89
  584.  
  585.         Found and fixed several bugs in the the TFLOAT.SEQ file, There
  586.         were some stack problems that have been fixed.
  587.  
  588.  12/22/89               ***** Version 1.09 *****
  589.  
  590.         Split the first portion of LIBRARY.SEQ out to OPTIMIZ.SEQ to
  591.         reduce its size some. It was over 100k.
  592.  
  593.         Changed MAXDIR in TWFL.SEQ from a constant to a value. You can
  594.         now set MAXDIR to some value other than 300 to get the $GETDIR
  595.         to get a different number of files than 300.
  596.  
  597.  01/02/90               ***** Version 1.10 *****
  598.  
  599.         Fixed a bug in LONG_BRANCHes, it seems the defered word T@ was
  600.         not getting initialized to the target memory area, and when a
  601.         long branch was being resolved with ">RESL", improper branch
  602.         locations were being resolved.
  603.  
  604.         Added UPC, UPPER and ?UPPERCASE to the library word list.
  605.  
  606.         Renamed ADJ_MEMORY to SET_MEMORY, and changed the function from
  607.         a segment adjustment of memory, to a byte adjustment of memory.
  608.         It now is used to reduce DOS memory usage to a user specified
  609.         amount of ram above PAD. The physical memory address is passed
  610.         into SET_MEMORY. Typically you will do something like the
  611.         following:
  612.                         PAD 100 + SET_MEMORY
  613.  
  614.         This will reduce the DOS memory usage from "all of memory" down
  615.         to the memory needed for the programs CODE plus DS: ram upto
  616.         PAD+100. The return stack and TIB are automatically moved down
  617.         to the new location, and the data stack is cleared. An additional
  618.         250 bytes are allocated for the data stack and the return stack.
  619.  
  620.  01/04/90               ***** Version 1.11 *****
  621.  
  622.         Fixed EXECUTES> so it will always assemble the two instructions
  623.         it needs to assembler, into the Forth CODE space, not the target
  624.         space.
  625.  
  626.         Mostly working on making the floating point useful. Needed to
  627.         be able to enter floating point numbers at interpret time so
  628.         new floating point constants and arrays could be created by a
  629.         target application. So now TFLOAT will load FLOAT4TH before
  630.         loading itself. FLOAT4TH gets loaded into the FORTH vocabulary
  631.         so it can be used to manipulate floating point numbers while
  632.         target compiling.
  633.  
  634.         Added the floating point wordset description to the LIBRARY.DOC
  635.         file. They are in a different format from the rest of the
  636.         glossary, but still provide useful information.
  637.  
  638.  01/05/90
  639.  
  640.         Enhanced PERFORM, and EXECUTE so they compile a single
  641.         instruction when the optimizer is enabled. This resulted in an
  642.         improvement in performance for DEFERed words, allowing me to
  643.         get rid of the I/O variables KEY-F, EMIT-F, TYPE-F and
  644.         SPACES-F that were used in the colon definitions of KEY, EMIT,
  645.         TYPE and SPACES. These words were then converted to DEFERed
  646.         words, which subsequently compile a single instruction. Overall
  647.         this results in an improvement in performance with a very small
  648.         target program size increase.
  649.  
  650.         Making KEY, EMIT, and TYPE defered words also improves code
  651.         compatibility with F-PC.
  652.  
  653.  01/06/90
  654.  
  655.         Added "@>" to the list of forward words at the end of
  656.         COMPILER.SEQ. Apperently I just forgot it when I made the list
  657.         of forward words. It can be used on VALUE's, VARIABLE's, and
  658.         DEFERed words.
  659.  
  660.         NOTE:  You CANNOT use ['] on DEFERed words, as they are not
  661.         accessed with a CALL. DEFERed words are treated like MACRO's.
  662.         The ['] function in the target compiler is a RUNTIME operation,
  663.         that is, it obtains the "CFA" of the function following at
  664.         runtime, by looking following itself at the address in the CALL
  665.         following. For ['] to work properly, it can ONLY be followed by
  666.         a Forth word that is NOT A MACRO.
  667.  
  668.         Added a test for end of file reached while compiling. If you
  669.         forget to terminate a definition with a ";", then TCOM will
  670.         abort with a message informing you that the end of file has
  671.         been reached while compiling.
  672.  
  673. 01/08/90                ***** Version 1.12 *****
  674.  
  675.       ╔═════╗ THE FOLLOWING NOTE IS INVALID, SEE NOTE ∙03/26/90 ╔═══════╗
  676.       ║     ╚═══════════════════════════════════════════════════╝       ║
  677.       ║                                                                 ║
  678.       ║ Added user created defining words to the target compiler. the   ║
  679.       ║ format is somewhat different from the normal F-83/F-PC type     ║
  680.       ║ defining words, but provides similar functionality. Here are a  ║
  681.       ║ couple of examples of how to add defining words to the target   ║
  682.       ║ program:                                                        ║
  683.       ║                                                                 ║
  684.       ║          \ at runtime, new definitions return addr              ║
  685.       ║ :DOES> ; ( -- a1 )                                              ║
  686.       ║                                                                 ║
  687.       ║ DEF: NEWARRAY   ( n1 -- ) CREATE ALLOT ;                        ║
  688.       ║                                                                 ║
  689.       ║ 25 NEWARRAY ARRAY1                                              ║
  690.       ║                                                                 ║
  691.       ║ As you can see the DOES> portion is defined first. This is      ║
  692.       ║ somewhat similar to a technique Bill Ragsdale proposed a few    ║
  693.       ║ years ago. It make the target compile process simpler. The      ║
  694.       ║ ":DOES>" word defines the runtime function of the words the new ║
  695.       ║ defining word will make. The "DEF:" word defines a new defining ║
  696.       ║ word, and specifies what the compile time operations will be    ║
  697.       ║ for the new defining word. In this case we are creating a new   ║
  698.       ║ array word, which will do a CREATE, and ALLOT some space in the ║
  699.       ║ target for data. The runtime function of the new "ARRAY1"       ║
  700.       ║ simply returns the address of the array on the stack.           ║
  701.       ║                                                                 ║
  702.       ║            \ at runtime, new definitions return contents        ║
  703.       ║ :DOES> @ ; ( -- n1 )                                            ║
  704.       ║                                                                 ║
  705.       ║ DEF: NEWCONSTANT ( n1 -- ) CREATE , ;                           ║
  706.       ║                                                                 ║
  707.       ║ 52 NEWCONSTANT MYCONSTANT                                       ║
  708.       ║                                                                 ║
  709.       ║ Here we are creating a new defining word that is like CONSTANT, ║
  710.       ║ at compile time it creates the new name "MYCONSTANT" and        ║
  711.       ║ comma's 52 into the target data space. At runtime, MYCONSTANT   ║
  712.       ║ will fetch the data and return it.                              ║
  713.       ║                                                                 ║
  714.       ╚═════════════════════════════════════════════════════════════════╝
  715.  
  716.         P.S. DON'T try to ['] a target defining word and step into the
  717.         body of the definition, you will get unexpected results. It is
  718.         legal to ['] a definition for storage into a defered word.
  719.  
  720.  
  721.         Added TIMER.SEQ to the group of sample programs.
  722.  
  723.  01/16/90               ***** Version 1.13 *****
  724.  
  725.         Split out the STDIO words into a new file called TSTDIO.SEQ.
  726.         Also added several new buffered STDIO words as follows:
  727.  
  728.         GCH.MAX         Maximum read characters to buffer.
  729.         PCH.MAX         Maximum write characters to buffer.
  730.         BUFIO_INIT      Initialize buffered I/O for use.
  731.         GETCHAR_B       Read one character from buffered I/O console.
  732.         PUTCHAR_B       Write one character to the buffered I/O channel.
  733.         FLUSH_B         Flush the buffered I/O channel before leaving.
  734.  
  735.         Buffered I/O must be initialized with BUFIO_INIT before using
  736.         either GETCHAR_B or PUTCHAR_B. The word FLUSH_B must be used
  737.         before returning to DOS, to flush any character not already
  738.         written.
  739.  
  740.         Performance is significantly affected by the size of the read
  741.         and write buffers. The default size of 32 bytes works well, but
  742.         a considerable improvement in throughput can be obtained by
  743.         increasing GCH.MAX and or PCH.MAX to around 2000.  This will of
  744.         course use more DS: memory.
  745.  
  746.         Also added the FILTER.SEQ example.
  747.  
  748.  01/18/90
  749.  
  750.         Generalized the symbol table generation words. The /SYM option
  751.         can be used to tell TCOM to build a .SYM file for your
  752.         debugger. The only debugger currently supported is BXDEBUG.
  753.         Three words have been added to allow a symbol table file to be
  754.         built for other debuggers, but you will need to know the
  755.         format of their symbol table. The words are SYMWRITE,
  756.         SYMHEADER, and SYMFOOTER. Look at the COMPILER.SEQ for an
  757.         example.
  758.  
  759.  01/19/90
  760.  
  761.         Added RS232IB.SEQ a buffered RS232 driver to the TCOM.ZIP
  762.         file. RS232IB.SEQ provides a serial driver that is compatible
  763.         with both F-PC and TCOM, you can load it on either one and use
  764.         it directly. RS232IB.SEQ is not a library file, but is a simple
  765.         terminal program with the serial driver included.
  766.  
  767.  01/22/90               ***** Version 1.14 *****
  768.  
  769.         Added another command line option. Since TCOM normally contains
  770.         the full F-PC Forth system, including the SED editor, it seemed
  771.         only natural to add an edit command line parameter. Start TCOM
  772.         in edit mode as follows:
  773.  
  774.                 TCOM /EDIT <filename> <enter>
  775.  
  776.         TCOM will open the file if it already exists, or open it as a
  777.         NEWFILE if it doesn't exist. Leaving the editor, will then
  778.         return to DOS after saving changes. "/E" is short for "/EDIT".
  779.  
  780.         TCOM is still not a full compiler environment like TurboC, but
  781.         it is getting closer.
  782.  
  783.  01/24/90               ***** Version 1.15 *****
  784.  
  785.         Integrated Bob Smiths new (1.2) version of FLOAT4TH into TCOM.
  786.  
  787.  01/29/90
  788.  
  789.         The compiler now returns a DOS errorlevel code that corresponds
  790.         to the number of errors encountered while compiling.
  791.  
  792.         A /QUIET of /Q option can be used to reduce the junk displayed
  793.         while compiling to errors only. When used with the DOS
  794.         ">filename" option on the commandline, an error file will be
  795.         built that can be scanned by an editor for compile error
  796.         locations to fix. In other words, I am in the process of
  797.         modifying the Z editor to use it as a compiler integrator, and
  798.         I needed a way to pass errors back to the editor from the
  799.         compiler. These options provide a way to do that. Here is an
  800.         example:
  801.  
  802.                 C:>TCOM TEST /Q >TEST.TMP
  803.  
  804.         Here the compiler will compile the file TEST, and re-direct the
  805.         compilers message output to the file TEST.TMP.
  806.  
  807.  01/31/90               ***** Version 1.16 *****
  808.  
  809.         Added ZZ (I don't know what it stands for) to TCOM. ZZ is the
  810.         first version of an integrator for TCOM. Is uses the SZ editor,
  811.         TCOM.EXE and BXDEBUG as sub programs to provide an environment
  812.         that can create, compile and debug programs. Some additional
  813.         keys and functions have been added to the SZ editor to make
  814.         this work. SZ has a new command line option "/CMD" that will
  815.         tell SZ to automatically examine a <filename>.MSG file when
  816.         atarting up to look for error messages in the Microsoft C error
  817.         format. If the file containing valid error messages is found,
  818.         then SZ will automatically place the cursor on the error line
  819.         and display the error message on the last line of the display.
  820.         When the SZ editor leaves, a file ZZ.CMD will be created that
  821.         contains information that the Mini Shell will look at to decide
  822.         what to do next. ZZ will look at a file ZZ.CFG that will
  823.         contain DOS command lines to perform. The first line will be
  824.         executed when ZZ starts, and other lines will be executed
  825.         according to the command (an ascii character 1 to 9, or Q)
  826.         passed back from the SZ editor. Multiple commands on a line in
  827.         ZZ.CFG can be entered separated by the ";" character.
  828.  
  829.         All this may seem complicated, so here is an overview:
  830.  
  831.                 Type ZZ <filename>.SEQ <enter> to start editing a file.
  832.  
  833.                 Press F5 to compile the file.
  834.  
  835.                 If an error occurs, the editor will display errors.
  836.  
  837.                 Press ESC to get out of error mode or press Ctrl-F2 to
  838.                 execute the compiled program.
  839.  
  840.                 Press F7 to enter BXDEBUG on your file, or press F10 to
  841.                 leave SZ.
  842.  
  843.         Here is a list of the keys in SZ that pass back commands to ZZ.
  844.  
  845.                 F10                     command Q
  846.                 Alt-F10                 command Q
  847.                 Ctrl-F1 or Alt-1        command 1
  848.                 Ctrl-F2    Alt-2        command 2
  849.                 Ctrl-F3    Alt-3        command 3
  850.                 Ctrl-F4    Alt-4        command 4
  851.                 F5         Alt-5        command 5
  852.                            Alt-6        command 6
  853.                 F7         Alt-7        command 7
  854.                            Alt-8        command 8
  855.                            Alt-9        command 9
  856.                            Alt-0        command 10
  857.  
  858.         These commands are used by ZZ to make it perform ZZ.CFG lines 2
  859.         through 11.
  860.  
  861.         Commands can be separated by the ';' character, and if you
  862.         place a double '||' vertical bar then the rest of the line can
  863.         be used for comments. Here are a couple of examples:
  864.  
  865.                 CLS|BXDEBUG %F.com||        F7=Debug program "COMMENT"
  866.  
  867.         The above sequence will, CLS the screen, and execute BXDEBUG,
  868.         passing it the parameter "%F.com" that is the same as "%1",
  869.         except ZZ removes the file extention so you can specify it
  870.         ".com". The "||" two vertical bars signify the end of the
  871.         command, and the remaining text on the line is treated as
  872.         comments.
  873.  
  874.         When you leave and re-enter ZZ, and don't specify a file to
  875.         edit, as in "ZZ <enter>", then ZZ will remember where you were,
  876.         and return to that file and edit position.
  877.  
  878.  02/05/90
  879.  
  880.         Switched to modified versions of TGRAPH.SEQ, and THERC.SEQ.
  881.         Added THERCTXT.SEQ to TCOM. Jerry Modrow cleaned them up a bit,
  882.         and provided code to do text output in Hercules graphics mode.
  883.         The code was written by Mike Mayo, and generalized by Jerry
  884.         Modrow. Also added GRAPH.SEQ, and HERC.SEQ to allow for
  885.         comparable simple graphics in F-PC for debugging purposes. The
  886.         graphics available from SMILEY, is faster, but GRAPH and HERC
  887.         are compatible with TGRAPH, and THERC.
  888.  
  889.  02/22/90               ***** Version 1.17 *****
  890.  
  891.         Changed the default return-stack/TIB size "RPSIZE" from 240
  892.         bytes to 256 bytes.
  893.  
  894.         Modified ZZ, to handle upto four parameters on the command
  895.         line. I am currently only using three. The order of the
  896.         parameters in the ZZ.CMD file has been changed to match the
  897.         order of the same parameters on the command line, that is:
  898.  
  899.                 <filename> <row> <col>
  900.  
  901.         Rather than the previous:
  902.  
  903.                 <row> <col> <filename>
  904.  
  905.         This makes more sense, and allows me to increase the total
  906.         number of parameters that can be handled to four so people with
  907.         other editors can generate command files with upto four
  908.         parameters in the same order as they accept parameters.
  909.  
  910.         Im still working on a way to document ZZ so it will be easy to
  911.         understand what it does. Currently the inter-connection between
  912.         ZZ and the programs it integrates is quite obscure, and I don't
  913.         know if anyone can figure out how to use ZZ with only what I am
  914.         providing. Need to work on this a LOT MORE.
  915.  
  916.  03/07/90               ***** Version 1.18 *****
  917.  
  918.         Added DIS.SEQ and DIS.COM to TCOM.ZIP. While this may seem like
  919.         a silly reason to change the version number, DIS adds important
  920.         functionality to TCOM. DIS will disassemble any .COM file that
  921.         was created by TCOM that has a .SYM file available, into a
  922.         symbolic assembly listing file. It only disassembles the CODE
  923.         portion of the .COM file, but it seems to do that perfectly.
  924.         Now you can easily see the difference between optimized and
  925.         non-optimized compiler output. The DOS ">" symbol can be used
  926.         to force redirection into a file as follows:
  927.  
  928.                 DIS CLOCK >CLOCK.LST
  929.  
  930.         This will disassemble CLOCK.COM (with symbols if CLOCK.SYM is
  931.         available, and with imbeded source if CLOCK.LIN and CLOCK.SEQ
  932.         are available.) to the file CLOCK.LST. The .SYM and .LIN files
  933.         are created by TCOM when the /SYM command line option is used.
  934.         If no redirection is used, disassembly is directed to the
  935.         display.
  936.  
  937.         DIS can be used to disassemble .COM files that don't have .SYM
  938.         files, or .COM file from other assemblers of compilers, but it
  939.         will not properly know how much to disassemble, and will not
  940.         display symbols.
  941.  
  942.  03/08/90
  943.  
  944.         Added CASE, OF, ENDOF, ENDCASE in the F-PC style. Like Eakers
  945.         CASE.  I got tired of converting programs that use CASE
  946.         statments over to use IF-ENDIF, so I added the CASE statment to
  947.         the compiler. It has been tested, and when the optimizer is
  948.         turned on, it generates very good code.
  949.  
  950.  03/19/90               ***** Version 1.19 *****
  951.  
  952.         Started modifications to generalize TCOM for a new target. Mike
  953.         Mayo has finished the first pass on an 80196 assembler. Some
  954.         changes were needed (more will be needed) to work with this new
  955.         target. I am looking forward to this new addition to TCOM, it
  956.         should add considerable flexibility to the compiler.
  957.  
  958.  03/23/90               ***** Version 1.20 *****
  959.  
  960.         Many small changes. Adjusted TYPE, EMIT, CR, SPACES, AT, AT?
  961.         to be more like F-PC. Several were made into defered words.
  962.         This will cause the compiler output to increase in size
  963.         somewhat for small programs. This is unfortunate, but
  964.         necessary for better compatibility.
  965.  
  966.         Fixed a couple of bugs, the small version of the compiler
  967.         couldn't create proper listing files because I was removing too
  968.         much from SF-PC for the disassembler to load. CORRECTED
  969.  
  970.         Made corrections to TGRAPH for CPLOT. It needed to be clearing
  971.         BX before performing the plot interrupt.
  972.  
  973. °03/26/90
  974.  
  975.         Re-worked defining words. You can now create ordinary CREATE
  976.         DOES> type defining words, you simply start the definition with
  977.         "::" rather than ":". The compiler will only include the DOES>
  978.         portion in your target, and will execute the part before DOES>
  979.         whenever the defining word is used to define a new target word.
  980.         Here is a simple example of a TCOM defining word:
  981.  
  982.                 :: 6VAR         ( | <name> -- )
  983.                                 CREATE 0 , 0 , 0 , DOES> ;
  984.  
  985.                 6VAR MYVARIABLE
  986.                 6VAR YOURVARIABLE
  987.  
  988.         6VAR is a defining word that creates new 6 byte variables. 6VAR
  989.         is being used to create two such variables called MYVARIABLE,
  990.         and YOURVARIABLE. When these variables are later used, they
  991.         will return the address of a 6 byte data area that was
  992.         pre-initialized to zero.
  993.  
  994.  03/27/90
  995.  
  996.         Added the definition for Target LABEL, you can now use labels
  997.         in the target code. They can be accessed from within a code
  998.         word with a CALL. When used labels return their address.
  999.  
  1000.  03/28/90
  1001.  
  1002.         Removed THERC.SEQ, TGRAPH.SEQ, & TSHAPES.SEQ from the
  1003.         precompiled library. You will need to "NEEDS" or "FLOAD" them
  1004.         into an application that requires graphics support. This makes
  1005.         the compiler about 7k smaller. The reason this is being done
  1006.         now, is that LABEL which is used in THERC was only available as
  1007.         a LIBRARY word before yesterday.
  1008.  
  1009.  03/28/90               ***** Version 1.21 *****
  1010.  
  1011.         Made ['] smart, so it tests for the type of word being looked
  1012.         up. The word must be a subroutine, or ['] will complain. The
  1013.         purpose here is to prevent looking up macros, which get
  1014.         compiled in line, and have no actual target address.
  1015.  
  1016.  03/29/90
  1017.  
  1018.         Modified typed output from a TCOM application so you can use
  1019.         PRINTING ON to cause typed output to go to the printer. This
  1020.         works with both DOS output, and the video typed output.
  1021.  
  1022.  03/30/90
  1023.  
  1024.         Added INLINE to TCOM. INLINE forces a routine that is normally
  1025.         accessed by a CALL to be compiled inline in the current colon
  1026.         definition. This avoids the overhead of a CALL RET in areas
  1027.         that need the highest performance. The generated code will of
  1028.         course be larger.
  1029.  
  1030.         Also added NO_INLINE to abort an inline operation if a LIBRARY
  1031.         word with multiple exits is preceeded by the INLINE directive.
  1032.         See the LIBRARY.SEQ definition of UM/MOD for an example.
  1033.  
  1034.         Added code to prevent INLINE from trying to compile a target
  1035.         (as opposed to LIBRARY) word inline.
  1036.  
  1037.  03/31/90
  1038.  
  1039.         Added colon definition MACROS to TCOM. Use "M:" to define colon
  1040.         definitions you want to always be compiled inline when they are
  1041.         referenced.
  1042.  
  1043.  04/03/90               ***** Version 1.22 *****
  1044.  
  1045.         Added CSEG, DSEG, END-CSEG, and END-DSEG to create multiple
  1046.         code segment areas. This is useful for target processors that
  1047.         need to compile code or data into specific areas of their
  1048.         memory. CSEG is used as follows:
  1049.  
  1050.                 $1000 CSEG MY_PROGRAM
  1051.                 $FFF0 CSEG VECTOR_SEG
  1052.  
  1053.                 MY_PROGRAM              \ select the code segment
  1054.                                         \ starting at $1000
  1055.                 <your code goes here>
  1056.  
  1057.                 VECTOR_SEG              \ select the vector segment
  1058.                                         \ area
  1059.  
  1060.                 xx , xx , xx , xx , xx , xx , xx , xx ,
  1061.  
  1062.                 MY_PROGRAM              \ switch baack to MY_SEGMENT
  1063.  
  1064.                 <more code goes here>
  1065.  
  1066.                 END-CSEG                \ completes MY_PROGRAM segment
  1067.                                         \ in preperation for saving the
  1068.                                         \ image to disk.
  1069.  
  1070.         As in the CODE example above, the words DSEG and END-DSEG are
  1071.         used to create, select and end a DATA segment of the target.
  1072.  
  1073.  04/09/90
  1074.  
  1075.         Made a minor modification to TFLOAT.SEQ and FLOAT4TH.SEQ. They
  1076.         now return a 1 rather than -1 for conversion successful. It
  1077.         seems SFLOAT returns a 1 for successful, and -1 for double
  1078.         number conversion. This was causing Jerry's MANDEL program to
  1079.         underflow the stack when the number entered was convertable to
  1080.         a double number. For example SFLOAT will convert "1.0" as a
  1081.         double number rather than a floating point number since there
  1082.         is no "E" to signal a floating point conversion. Applications
  1083.         that want to be compatible with both AFLOAT and FLOAT4TH, need
  1084.         to use the following conversion code when using "(FNUMBER?)":
  1085.  
  1086.                 : #INPUT        ( | <number> -- floating# )
  1087.                                 BL WORD (FNUMBER?) DUP 0=
  1088.                                 ABORT" Bad floating point number"
  1089.                                 0<
  1090.                                 IF      FLOAT   \ convert double to
  1091.                                                 \ float
  1092.                                 THEN    ;
  1093.  
  1094.  04/10/90
  1095.  
  1096.         Enhanced DUMP in the library, it now displays 16 bytes of hex
  1097.         data, followed by 16 bytes of ascii characters per line. Also
  1098.         added LDUMP to the library.
  1099.  
  1100.  04/11/90
  1101.  
  1102.         Added the value ABORT_FUNC and modified ABORT, such that, if
  1103.         ABORT_FUNC is non-zero, then it is executed. If it is zero,
  1104.         then a BYE is performed.
  1105.  
  1106.         Fixed COMPARE, and the sub functions COMP and CAPS-COMP so they
  1107.         use SSEG to determine what segment is being used for the
  1108.         compare.
  1109.  
  1110.  04/12/90               ***** Version 1.23 *****
  1111.  
  1112.         Added the ability to create an interpretive Forth system on top
  1113.         of your application program with the "/FORTH" command-line
  1114.         option. When this option is specified, TCOM will load a file
  1115.         called TFORTH.SEQ on top of your application, which adds a
  1116.         Forth like interactive shell, and about 8k bytes to your
  1117.         application. When your program is then executed, it will come
  1118.         up in the Forth shell, rather than your program. You can then
  1119.         execute words, dump memory and more interactively test your
  1120.         program than with the fully optimized .COM file. You cannot
  1121.         however define any new words, as there is no compiler included
  1122.         in this interpretive environment.
  1123.  
  1124.  04/13/90
  1125.  
  1126.         Fixed a bug in TFLOAT.SEQ and FLOAT4TH.SEQ. The number output
  1127.         routine was not shifting the mantissa properly. Corrected.
  1128.  
  1129.  04/14/90
  1130.  
  1131.         Added /DIS option, when used with the /FORTH option, also
  1132.         appends the disassembler to your application. This allows you
  1133.         to use SEE and DIS (in assembly language) to examine your
  1134.         routines while in the interpretive environment.
  1135.  
  1136.  04/17/90               ***** Version 1.24 *****
  1137.  
  1138.         Added a target compiled version of CODEBUG to TCOM, called
  1139.         TDEBUG.SEQ. The compiler option /DEBUG will force inclusion of
  1140.         ALL interpretive options, Forth, DIS, and DEBUGing. It is now
  1141.         possible to make programs that include a built in debugger. The
  1142.         overhead for the interpretive environment, with disassembly and
  1143.         debugger, is around 21k optimized, and 27k non-optimized. While
  1144.         this is not an insignificant amount, it does allow debugging.
  1145.         The commands available are TRACE <name>, and BREAKAT <name>.
  1146.  
  1147.  04/18/90
  1148.  
  1149.         Modified the .SYM file format, so it marks the most significant
  1150.         bit of the first letter of each subroutine name. This is done
  1151.         when the /FORTH command line option is used, and allows the
  1152.         interpretive environment to know which words are to be executed
  1153.         rather than returned as an address. Since this change is not
  1154.         compatible with the BXDEBUG debugger, the /SYM option when used
  1155.         without /FORTH will create a normal .SYM file usable with
  1156.         BXDEBUG.
  1157.  
  1158.  04/19/90
  1159.  
  1160.         Added environment string processing to TCOM. If you add a
  1161.         statment to your environment similar to the following;
  1162.  
  1163.                 SET PATH= /OPT /NOINIT
  1164.  
  1165.         TCOM will default to using optimization, and no initialization
  1166.         when it compiles an application file. This environment string
  1167.         can be upto 250 characters in length, and is interpreted BEFORE
  1168.         the command line options are interpreted. This means your
  1169.         environment selections can be overridden by command line
  1170.         options if desired.
  1171.  
  1172.         Also added a default PATH to TCOM from the environment. You can
  1173.         add an additional statment to your environment as follows;
  1174.  
  1175.                 SET TPATH=C:\FPC\TCOM
  1176.  
  1177.         TCOM will search for any source libraries or source files in the
  1178.         specified directory or directories, allowing TCOM to be used
  1179.         from other directories on your hard disk.
  1180.  
  1181.  04/23/90
  1182.  
  1183.         Added PROMPTER.SEQ as an additional example program. It prompts
  1184.         for user input, and passes that input off with a DOS shell to
  1185.         another program. It is an example of how to get user input, and
  1186.         how to shell out to DOS.
  1187.  
  1188.  04/24/90
  1189.  
  1190.         Added a couple of new functions to the library. #INPUT will
  1191.         wait for the user to enter an integer, and return it. TIB0
  1192.         holds the reset address of 'TIB. QUIT is TFORTH.SEQ has been
  1193.         modified to reset 'TIB at its start. SET_MEMORY has been
  1194.         modified to readjust 'TIB which it didn't do before. It MUST do
  1195.         this when resetting the stacks.
  1196.  
  1197.         Added TPAS.SEQ an updated version of my Pascal compiler, and
  1198.         PASX.PAS a sample pascal source file for TPAS to translate into
  1199.         Forth. See TPAS.SEQ for more information.
  1200.  
  1201.  04/25/90               ***** Version 1.25 *****
  1202.  
  1203.         Substantialy reorganized TCOM's files into a more workable
  1204.         form. TCOM.Zip now contains several other .ZIP files containing
  1205.         things like the source for TCOM, the utilities for TCOM, and
  1206.         the example file for TCOM. I have created a documentation file
  1207.         specific for each .Zip file. I think it is just about time to
  1208.         make an installation program for TCOM.
  1209.  
  1210.         Removed all references to HIDE and REVEAL from COMPILER.SEQ.
  1211.         Since TCOM doesn't allow redefinition of functions, all headers
  1212.         are created findable. This makes recursive operations easy,
  1213.         and eliminates a bug caused by HIDE when it is used in any word
  1214.         that built a header. Since the header to be built may already
  1215.         exist, then the word like ":" trying to make the ehader checks
  1216.         for this condition, and just resolves the name if a forward
  1217.         reference condition exists. Unfortunately HIDE went ahead and
  1218.         hid the most recent header created, NOT A GOOD IDEA!.
  1219.  
  1220.  04/26/90
  1221.  
  1222.         Today I re-factored TCOM again, It now consists of five .ZIP
  1223.         files as follows:
  1224.  
  1225.                 TCOM        The executable with documentation
  1226.                 TCOMSAMP    Sample TCOMable program examples
  1227.                 TCOMUTIL    Utilities, and more library functions
  1228.                 TCOMSRC     The source for TCOM, usable with F-PC 3.50
  1229.                 SMALTCOM    Files to build a small TCOM compiler
  1230.  
  1231.         Also coded up and tested TCOMINST.COM an installation program
  1232.         for TCOM compiled with TCOM. Similar to INSTALL.EXE for F-PC,
  1233.         it allows the user to specify the target drive and directory.
  1234.         TCOM is getting more friendly all the time.
  1235.  
  1236.  04/27/90
  1237.  
  1238.         Received and integrated the bug fixes today from Bob Smith on
  1239.         FLOAT4TH and TFLOAT to F< F> FMIN and FMAX. Preliminary tests
  1240.         indicate they work properly.
  1241.  
  1242.  05/09/90
  1243.  
  1244.         Completed first pass prototype of the 8080 target for TCOM. It
  1245.         doesn't work yet, but the assembler seems to work. The
  1246.         assembler for now at least has been left as POSTFIX ONLY, as
  1247.         has the 8080 kernel.
  1248.  
  1249.  05/10/90
  1250.  
  1251.         Added START-T: to the list of defered words that needs to be
  1252.         implimented for a new target. In the 8086 target, this word is
  1253.         defined as a NOOP. In the 8080 target where we are generating
  1254.         indirect threaded code, this word compiles into the current
  1255.         target here, a word that is passed on the stack. For CODE type
  1256.         words, that would be a pointer to HERE+2, for colon type words,
  1257.         a pointer to NEST.
  1258.  
  1259.         Also added a defered word COMP_HEADER that compiles a header
  1260.         into the target. COMP_HEADER is passed an address counted
  1261.         string of the name to compile into the target. Two compile
  1262.         flags added /HEADER and /NOHEAD (default) select wheather
  1263.         headers are to be built for a particular target processor.
  1264.  
  1265.         Still have lots of work to do on the 8080 target, before it
  1266.         will generate real programs, but it has at least been able to
  1267.         compile through a very simple program, and generate what
  1268.         appears to be reasonable code. Its a start!
  1269.  
  1270.         I notice we are coming up on a whole year of work on TCOM. It
  1271.         is amazing what can be done in a year.
  1272.  
  1273.  05/11/90
  1274.  
  1275.         Added "RESOLVE_1" as a defered word to be used in resolving
  1276.         forward references. The default version resolves forward
  1277.         references as relative, and the 8080 version needed absolute
  1278.         addressing, so this was added.
  1279.  
  1280.  05/14/90               ***** Version 1.26 *****
  1281.  
  1282.         More minor modifications to allow TCOM to work with the 8080
  1283.         indirect threaded kernel. I keep finding things that are CALL
  1284.         threaded specific. The 8080 target is comming along very well,
  1285.         I have not been able to "run test" any code yet, but the manual
  1286.         disassemblies look very good.
  1287.  
  1288.         fixed some more bugs in the branch resolution words in
  1289.         LABEL80.SEQ. I believe branches are now working properly
  1290.         (again?). Added the compiler words to perform ." and " for the
  1291.         8080 target, these are in LIB80.SEQ.
  1292.  
  1293.  05/16/90
  1294.  
  1295.         Defered the DOES> portion of FOR>WORD so it can work properly
  1296.         with the 8080 indirect threaded target.
  1297.  
  1298.  07/03/90
  1299.  
  1300.         Added ALLSPECS.SEQ. A utility that is usable on either TCOM or
  1301.         F-PC that will return a list of all directories on a drive.
  1302.         Useful for searching an entire drive for things. Currently
  1303.         being used in LOOK.COM to allow a string search of an entire
  1304.         drive. Also used in the NEWZ editor, to allow hyper indexing an
  1305.         entire disk drive.
  1306.  
  1307.  07/09/90           **** 8086 Target Version 2.01 *****
  1308.  
  1309.         Changed a few of the "M:" words back to ":" words. Things like
  1310.         SPACE and some others are used too oftain to have them compiled
  1311.         inline as macros. This of course highly subjective, but it
  1312.         seemed like a proper change to make.
  1313.  
  1314.         Also fixed a bug in DIS.SEQ, it seems I added a word SPACE
  1315.         after an "EXEC:" in ".DISP". Not a good idea. Also modified DIS
  1316.         so it will only stop disassembling a file for which it has no
  1317.         symbol table when the end of the file is reached, or when the
  1318.         user stops it.
  1319.  
  1320.  07/24/90
  1321.  
  1322.         Added two words to the compiler to verify the state of the
  1323.         default code inclusion. CHECK_/NOINIT and CHECK_/DEFINIT These
  1324.         words will check to make sure their respective option is
  1325.         currently active, and will issue an error message but continue
  1326.         compiling if the option is not active. Use these near the start
  1327.         of a file that needs to always have one of the ..INIT options
  1328.         set a specific way.
  1329.  
  1330.  10/28/90           ***** Version 1.27 *****
  1331.  
  1332.         Added SKIP'C' to TDEFINED in the compiler, is was converting
  1333.         lowercase 'a' type letters to uppercase when it shouldn't.
  1334.         Also bumped version.
  1335.  
  1336.         Also added a verify section to TDEFINED, that makes sure that
  1337.         any words found are above the forth kernel, to make sure no
  1338.         invalid words get used in the target. This will improve the
  1339.         reliability of the generated code.
  1340.  
  1341.  10/29/90       **** 8086 Target Version 2.02 *****
  1342.  
  1343.         Added CRLF>BL'S to LIBRARY.SEQ. A very useful word when dealing
  1344.         with lines read from a file.
  1345.  
  1346.         Added ?DEF.EXE & DEFEXT to THANDLES.SEQ. The default extension
  1347.         is NONE, but you can now specify a default file extension if
  1348.         you want to, just by putting it in DEFEXT.
  1349.  
  1350.         I have separated out the Hyper-text compiler from the edito,
  1351.         and turned it into a separate TCOM application. This will (when
  1352.         I remove the old code from the editor) make the editor somewhat
  1353.         smaller. You can still SHELL out to run the indexxer, if you
  1354.         want to. It is now called INDEX.COM, and will by default use
  1355.         INDEX.CFG for the compile specification if no other filename is
  1356.         specified ont he command line after INDEX.
  1357.  
  1358.         Enhanced the DIS (disassembler), to include a new command line
  1359.         option. "/Wxx" where xx is a number of pages will disassemble
  1360.         the specified file in "Wide" mode for xx pages. If xx is
  1361.         omitted, then all pages will be disassembled. An escape
  1362.         sequence is also sent at the beginning of the output to put a
  1363.         laser printer in compressed mode. With this option, you can
  1364.         disassemble directly to a laser printer as follows:
  1365.  
  1366.                 DIS [filename] /W2 [wordname] >PRN [enter]
  1367.  
  1368.         This command line will disassemble [filename] starting at
  1369.         [wordname] for 2 pages, with output directed to the PRN device,
  1370.         typically your printer.
  1371.  
  1372.  12/14/90            ***** Version 1.28 *****
  1373.                 **** 8086 Target Version 2.03 ****
  1374.  
  1375.         Added &> to the compiler, it puts the address of a VALUE on the
  1376.         stack. Useful when you may have a series of values that you
  1377.         want to work with as a group.
  1378.  
  1379.         Added BLINK_OFF and BLINK_ON to TVIDEO.SEQ. This allows the
  1380.         colors from 8 to 15 to be used in the background without
  1381.         causing the screen to blink.
  1382.  
  1383.         Added ZLIST.SEQ to TCOMSAMP.ZIP. ZLIST allows viewing files in a
  1384.         similar fashion to Buerg's LIST, with fewer features, but it is
  1385.         fully public domain, and can be used by anyone for anything.
  1386.         Allows viewing BIIIGG files. You also get the source of course.
  1387.  
  1388.  01/28/91         ***** Version 1.30 *****
  1389.                 **** 8086 Target Version 2.04 ****
  1390.  
  1391.         Fixed a couple of bugs in the CSEG/DSEG code, It was nessecary
  1392.         that you create a CSEG statment and use the CSEG name created,
  1393.         and then use END-CSEG at the end of your code. All this was
  1394.         needed to get it to save your compiled code is HEXSAVE was used
  1395.         to save the compilers output in INTEL HEX format. This has been
  1396.         fixed, such that a default segment is specified by the compiler
  1397.         initialization code in the optimizer file, and an end-cseg /
  1398.         end-dseg is performed automatically when the compile is
  1399.         finished.
  1400.  
  1401.         Two new directives have been added, ORG, and DORG. They allow
  1402.         specification of a new code or data origin, without having to
  1403.         specify a name for the new segment. This is much more like
  1404.         traditional assemblers, and allows you to freely move the code
  1405.         compiling around as desired. NOTE HOWEVER THAT TCOM PERFORMS NO
  1406.         OVERLAP CHECKING, and code compiled later can easily overlap
  1407.         code compiled earlier if these words are used haphazardly.
  1408.  
  1409.         Named segments are of course still allowed, making it possible to
  1410.         switch back and forth between existing segments. When ORG is
  1411.         used, it is not possible to switch back to a previous ORG, since
  1412.         no name available.
  1413.  
  1414.  01/28/91 17:36
  1415.  
  1416.         Added the ability in CODE words in the target to branch to and
  1417.         define named labels, both forward and backward. They are used as
  1418.         follows:
  1419.  
  1420.                 code x1
  1421.                         jmp x2          \ forward branch to undefined
  1422.                                         \ label or code is now legal
  1423.                         jmp x3
  1424.                         ret             end-code
  1425.  
  1426.                 code x2
  1427.                         jne x1
  1428.                 label x3                \ code words can now contain
  1429.                                         \ label definitions
  1430.                         jmp x3
  1431.                         ret             end-code
  1432.  
  1433.         If you enter a forward branch to a label that is never defined,
  1434.         then an undefined symbol error will occur. You can also see a
  1435.         branch out of range error for labels that get defined too far
  1436.         away. The "WORD" instruction modifier will fix this problem for
  1437.         those instructions that allow word length branching.
  1438.  
  1439.  02/06/91               ***** Version 1.31 *****
  1440.  
  1441.         Modified the memory management in TCOM to use the new memory
  1442.         management technique just installed in F-PC. That is to use POINTER
  1443.         to define a word that will return a physical segment at runtime of
  1444.         the desired area of memory rather than using ALLOC. The primary
  1445.         advantage of this, is now F-PC internally uses only one segment
  1446.         pointer, and performs the heap management itself, adjusting its
  1447.         segment as needed for each new pointer used. At a later time, it
  1448.         will now be possible to move some or all "pointers" into expanded
  1449.         memory.
  1450.  
  1451.  
  1452.  02/06/91               ***** Version 1.32 *****
  1453.  
  1454.         Changed to compile order of TCOM to move ALIST.SEQ to after the
  1455.         compiler, so some additional "listing format" specific words could
  1456.         be moved into ALIST.SEQ.  ALIST is still an optional file, and need
  1457.         not be loaded if no listing capability is needed.
  1458.  
  1459.         TCOM is now much more flexable in allowing the target to define the
  1460.         listing format than before. Added defered words ?.MACRO and ?.CALL
  1461.         so ALIST.SEQ can define the format of the listing file format.
  1462.  
  1463.  02/20/91               ***** Version 1.33 *****
  1464.  
  1465.         Fixed bug in END-DSEG that was preventing proper functioning of the
  1466.         hex save.
  1467.  
  1468.         Modified ORG to set LINESTRT.
  1469.  
  1470.         Modified the way the compiler detects the /CODE command line
  1471.         option. It used to test the defered word .INST to see if it was set
  1472.         to a function other than NOOP. This is clumsy, and now the compiler
  1473.         variable ?CODE has been added, and returns a true if we are
  1474.         displaying the disassembled code/instructions while compiling.
  1475.  
  1476.         Added the defered word TARGET-FINISH to allow a target to perform
  1477.         any cleanup it desires after the compile is completed, but before
  1478.         the image save is performed.
  1479.  
  1480.  03/07/91        **** 8086 Target Version 2.05 ****
  1481.  
  1482.         Fixed a bug in the design on "EXEC:" which was patching the
  1483.         application code at runtime to vector to the desired function
  1484.         (self-modifying code).  Now it is probably a littel slower, but it
  1485.         should work on higher level processors with pipe-lines and caches.
  1486.  
  1487.  03/13/91        **** 8086 Target Version 2.06 ****
  1488.  
  1489.         Fixed a bug in -SKIP, changed an INC CX to DEC CX.
  1490.  
  1491.  03/19/91
  1492.  
  1493.         Fixed a bug in LABEL. The new version of label was not usable
  1494.         outside of a CODE word. It didn't install TINTERP like CODE did,
  1495.         so END-CODE would crash after reinstalling the null in the value
  1496.         INTERPSAVE. Things have been fixed now, so LABEL can be used
  1497.         outside of a CODE word, and infact really calls CODE in this
  1498.         case.  The purpose of using LABEL outside of a CODE word, was to
  1499.         make a code sequence that could return its address rather than
  1500.         executing like a CODE word does when used. In TCOM, CODE and
  1501.         LABEL both return their address when used in another code word.
  1502.  
  1503.  03/21/91       ***** TCOM Version 1.34 *****
  1504.  
  1505.         Factored the way TCOM compiles data statments like " or ."
  1506.         strings. In a target that generates romable code, data statments
  1507.         need to be in the CODE area since ram is not initialized in a rom
  1508.         program like it is in the 8086 PC .COM programs. To do this I
  1509.         have created a new set of "ORG" words with the "V" prefix (like
  1510.         VORG, VSEG, and END-VSEG), and changed the "D" org words to
  1511.         defered words.  This allows the 8086 TCOM to continue to assume
  1512.         data will be compiled into DATA space, and to allow ROM targets
  1513.         to use "V" words for variables, and have the "D" words compile
  1514.         into CODE/ROM space.  The way you switch between these two forms,
  1515.         is with "/DATA_IN_ROM" and "/DATA_IN_RAM".  When data is in ram,
  1516.         then you use only the ORG and DORG words. When data is in rom,
  1517.         then you also use VORG to specify where the variables will start.
  1518.  
  1519.  03/22/91
  1520.  
  1521.         Changed the automatic local label branch assign word BR# so it
  1522.         returns the number of the most recent branch number assigned,
  1523.         rather than the next available number.  BR# used to be a VALUE,
  1524.         it is now a function, and the VALUE BR#VAL has been created to
  1525.         take its place.
  1526.  
  1527.         Also added /DATA_IN_CODE, to allow placement of string inline
  1528.         with the code being generated.
  1529.  
  1530.  04/24/91
  1531.  
  1532.         Modified @-T and C@-T to be defered words in COMPILER.SEQ.
  1533.  
  1534.  04/25/91       ***** Compiler Version 1.35 *****
  1535.  
  1536.         Made ," defered, so a target can make it compile into some place
  1537.         other than data space. Modified COMPILER.SEQ
  1538.  
  1539.  
  1540.