• kForth-64/32 updates

    From Krishna Myneni@krishna.myneni@ccreweb.org to comp.lang.forth on Fri Mar 7 21:17:32 2025
    From Newsgroup: comp.lang.forth

    The Linux kForth packages (32-bit x86 and 64-bit x86_64) on Github have undergone substantial revision in the assembler portion of the VM code.
    The current version numbers are 2.6.0 for the 32-bit package and 0.6.0
    for the 64-bit package.

    In addition to the 64-bit package implementing the source code
    (vm64-fast.s) for the first working version of kforth64-fast, the
    assembler code for both 32 and 64 bit versions has been improved,
    assembler macros' register use is internally documented, and the macros' interface has been made uniform to enable them to be used more easily
    within internal code.

    From the source, both regular and fast versions of the executables are
    built: {kforth32 / kforth32-fast} or {kforth64 / kforth64-fast}. The
    fast versions omit run-time type checking and provide anywhere from 15
    to 40% improvement in speed, depending on the application.

    The main goal of the changes to the assembly code is to prepare for
    future experimental changes to the VM code to speed up both regular and
    fast versions of the executables.

    kForth's development goals remain the same as for the last 20 years:

    1. simple-to-build from source, requiring few tools (C/C++/assembler)
    2. lightweight, requiring few external libraries
    3. provide useful Forth shell for interactive computing/programming
    4. functional for developing and running simple and complex programs
    5. useful for low-level (machine code) and high-level (modular Forth)
    6. useful for embedding into another program for script extensions
    7. provide numerous programming examples on different topics
    8. well-documented (still much more work needed on this)
    9. easy and fun to learn and use

    --
    Krishna Myneni
    https://github.com/mynenik



    --- Synchronet 3.20c-Linux NewsLink 1.2
  • From Krishna Myneni@krishna.myneni@ccreweb.org to comp.lang.forth on Sat Mar 8 20:21:12 2025
    From Newsgroup: comp.lang.forth

    On 3/7/25 9:17 PM, Krishna Myneni wrote:
    The Linux kForth packages (32-bit x86 and 64-bit x86_64) on Github have undergone substantial revision in the assembler portion of the VM code.
    The current version numbers are 2.6.0 for the 32-bit package and 0.6.0
    for the 64-bit package.
    ...

    Note: Current stable releases are version 2.5.0 for kForth-32 and
    version 0.5.0 for kForth-64. Versions 2.6.0 and 0.6.0 are development
    versions and may be updated frequently.

    A bug in the code for kforth64-fast, for calling external library
    routines, was fixed at kForth-64 commit eefad24.

    I've added the MPFR library test code to the battery of tests I perform
    before pushing commits to the kForth repos. The updated list of
    automated tests are:

    System tests -- these are the numerous test progs found in forth-src/system-test

    FSL tests -- tests of complex number arithmetic and FSL modules, found
    in forth-src/fsl : complex-test.4th and fsl-tester.4th

    External library interface -- libmpfr-test.4th in forth-src/libs/gmp/

    Other tests -- these are found in forth-src/
    parallel-mm.4th
    dd-test.4th
    ftran-test.4th
    lists-test.4th
    lz77-test.4th
    rawfloat-test.4th
    strings-test.4th
    hmac-md5-test.4th

    Testing is a large part of the development, since I use my own programs!

    --
    Krishna Myneni








    --- Synchronet 3.20c-Linux NewsLink 1.2
  • From minforth@minforth@gmx.net (minforth) to comp.lang.forth on Thu Mar 13 09:46:17 2025
    From Newsgroup: comp.lang.forth

    On Sun, 9 Mar 2025 2:21:12 +0000, Krishna Myneni wrote:

    I've added the MPFR library test code to the battery of tests I perform before pushing commits to the kForth repos.

    Just a side notice:

    I implemented a MPFR BiGFloat wordlist using an extra stack for
    mpfr_struct pointer structures. The mpfr wordlist is almost 1:1
    equivalent to the standard Forth fp-number wordlist. This seamless
    integration into the Forth environment greatly improves coding
    productivity, e.g. when converting code from fp-numbers to bigfloat
    numbers for numerical integration.

    MinForth 3.6 (64 bit) (bf mpfr)
    # B1 ok
    B: 1 # B1.3e-1 ok
    B: 1 0.13 # bswap ok
    B: 0.13 1 # b+ ok
    B: 1.13 # bsin ok
    B: 0.904412 # 1000 set-bprecision ok
    B: 0.904412 # b. 9.044121893788259160370815224113958490069049238705633177599189232383754249437441058833871032566866760301966980078276673212982639707524250601795132322907102974263442716497406225816666544659047966957621427557012074916788224587804734255769290030002593994140625e-1
    ok
    # bpi ok
    B: 3.14159 # b. 3.1415926535897932384626433832795028841971693993751058209749445923078164062861980294536250318213496466758841295330717990647287577300387921745554379812433476086285782359849691502495386391042948825058346599055448329813888808104138661292381584644317626953125
    ok
    #

    --
    --- Synchronet 3.20c-Linux NewsLink 1.2
  • From anthk@anthk@openbsd.home to comp.lang.forth on Sat Apr 12 07:14:02 2025
    From Newsgroup: comp.lang.forth

    On 2025-03-08, Krishna Myneni <krishna.myneni@ccreweb.org> wrote:
    The Linux kForth packages (32-bit x86 and 64-bit x86_64) on Github have undergone substantial revision in the assembler portion of the VM code.
    The current version numbers are 2.6.0 for the 32-bit package and 0.6.0
    for the 64-bit package.

    In addition to the 64-bit package implementing the source code
    (vm64-fast.s) for the first working version of kforth64-fast, the
    assembler code for both 32 and 64 bit versions has been improved,
    assembler macros' register use is internally documented, and the macros' interface has been made uniform to enable them to be used more easily
    within internal code.

    From the source, both regular and fast versions of the executables are built: {kforth32 / kforth32-fast} or {kforth64 / kforth64-fast}. The
    fast versions omit run-time type checking and provide anywhere from 15
    to 40% improvement in speed, depending on the application.

    The main goal of the changes to the assembly code is to prepare for
    future experimental changes to the VM code to speed up both regular and
    fast versions of the executables.

    kForth's development goals remain the same as for the last 20 years:

    1. simple-to-build from source, requiring few tools (C/C++/assembler)
    2. lightweight, requiring few external libraries
    3. provide useful Forth shell for interactive computing/programming
    4. functional for developing and running simple and complex programs
    5. useful for low-level (machine code) and high-level (modular Forth)
    6. useful for embedding into another program for script extensions
    7. provide numerous programming examples on different topics
    8. well-documented (still much more work needed on this)
    9. easy and fun to learn and use

    --
    Krishna Myneni
    https://github.com/mynenik




    I'd love an OpenBSD forth for it.


    --- Synchronet 3.20c-Linux NewsLink 1.2