Menu

FlashForth V 3.0 released

2007-10-17
2025-11-15
  • Mikael Nordman

    Mikael Nordman - 2007-10-17

    I released FF3.0 today.

    The main feature is replacement of DO LOOP
    with FOR NEXT and a P (pointer) register.

    FF3.0 is slightly faster due to the mildly optimising compiler and inline literals.

    Also the assembler has been rewritten.

    And there is a wordlist.

    Below is the Change info:

    FlashForth V3.0
    ---------------
    - DO LOOP +LOOP I UNLOOP removed
      Replaced by FOR NEXT R@ UNNEXT and the pointer words
    - A pointer register called P and associated words has been introduced.
    - Assembler rewritten. It has now structured conditionals.
    - IHERE and I, IC, exposed to user.
    - ROM changed to FLASH
    - FLASH RAM EEPROM stores the current data space context.
      It can be restored by the word >CS.
    - The compiler generates some optimised code
      - Inline literals
      - Inline ZEROSENSE
      - Inline FOR NEXT
      - DUP and 0= before IF UNTIL WHILE are optimised away
    - NONAME: changed to :NONAME
    - U.2 U.4 replaced by U.R
    - Assembler structured conditionals are in the core and are used to implement
      the Forth conditionals.
    - @EX introduced
    - SEE displays unknown code as numbers only.
    - Input numbers can be prefixed by # $ % for decimal hex or binary conversion
      independently of BASE.

    Hope someone finds FlashForth useful !

    Regards Mikael

     
  • Fred Zelders

    Fred Zelders - 2025-11-15

    What is the advantage of using the P register instead of using a variable I can define myself?
    Is it because of the P register associated words or are there other advantages?

     
    • Mikael Nordman

      Mikael Nordman - 2025-11-15

      The advantage comes from the associated words, and by having a kind of consistency.
      Advantages compared to a variable is that the P register is multitasking safe and also re-entrant, and the associated words are more efficient than if you define them yourself.

      Myself I have had very little use of those P words, so in FF6 I removed them.
      They are mostly cute and an attempt to mimic pointers in C.

       
      • Fred Zelders

        Fred Zelders - 2025-11-15

        OK Mikael. Thank you for your explanation.
        Does your remark about FF6 mean that there will be no P register and associated words available for all of us?

         

        Last edit: Fred Zelders 2025-11-15
        • Mikael Nordman

          Mikael Nordman - 2025-11-15

          Yes, no P register is FF6, but I don't know if it will ever go further than alpha state.

           
          • Fred Zelders

            Fred Zelders - 2025-11-15

            Well we'll wait and see :-)
            Thank you Mikael.

            You do a great job with FF!

             

Log in to post a comment.