Download Latest Version Quoin source code.zip (60.6 MB)
Email in envelope

Get an email when there's a new version of ChrysaLisp

Home / v4.7
Name Modified Size InfoDownloads / Week
Parent folder
Monolith source code.tar.gz 2026-05-20 60.0 MB
Monolith source code.zip 2026-05-20 60.3 MB
README.md 2026-05-20 4.6 kB
Totals: 3 Items   120.3 MB 0

This release introduces cross-compilation support for Windows hosts, refactors low-level system and link drivers to improve resource efficiency, and optimizes the translator pipeline. Key updates include a transition to a byte ring-buffer for the shared-memory link protocol, instruction fusing for the ARM64 translator, and stack-usage optimizations across task management and directory operations.


Portability & Host Integration

  • Windows Cross-Compilation Support: Added support for building Windows host executables on macOS and Linux platforms using mingw-w64 and a new Makefile.mingw. This includes automated dependency retrieval for Windows SDL2 and SDL2_mixer libraries.

  • Host Binary Optimization: Refactored host C/C++ source files to reduce external library dependencies. The compressed snapshot.zip asset containing the Windows TUI/GUI executables and the VP64 boot_image has been reduced to approximately 100 KB.

  • Windows Timer Precision: Adjusted the sleep implementation within pii_windows.cpp to utilize a higher-resolution timer and thread-yielding logic for more consistent timing behavior.

Microkernel & Task Management

  • Stack Usage Reductions:

  • Refactored Platform Implementation Interface (PII) directory listing and removal functions to operate iteratively and use off-stack static buffers, lowering the stack overhead of running tasks.

  • Optimized GUI service startup to load dependencies sequentially, further mitigating stack footprint issues.

  • Tuned tk_stack_state settings to ensure only the register sets required during a context switch are saved.

  • Task Prioritization & Scheduling:

  • Assigned priority level 2 to :in links and priority level 1 to :out links.

  • Added the :sys_task :wake_links method to wake sleeping link tasks (priority 1) when messages are appended to the outbound off-chip list.

  • System Definitions: Added the *module_class/lisp/root.inc* :t global definition to explicitly flag when root.inc has been successfully evaluated by the system.

  • Allocation Correction: Resolved an issue in :sys_mail :alloc where the message fragment length was not restored, correcting a rare edge case that could lead to inappropriate buffer size allocations.

  • Byte Ring-Buffer Link Protocol: Replaced the previous slot-based shared-memory (SHMEM) link protocol with a byte ring-buffer implementation. This change enables more compact packing of small messages within the link buffers.

  • Link Driver Tuning:

  • Updated link drivers to use variable polling with exponential backoff.

  • Increased overall link buffer sizes and added an extra buffer in each direction to prioritize hot channels and reduce transit latency.

  • Dynamically adjusted the message fragment data packet size (lk_data_size) to fit optimally into a string object ($\ge$ lk_page_size) matching the system's best-fit memory cells (currently 6104 bytes).

  • Weak Ordering Synchronization: Reviewed memory barrier usage and added missing acquire barriers to sys/link/class.vp to guarantee proper synchronization on weakly ordered architectures such as ARM64.

Translator & Assembly Pipeline

  • ARM64 Instruction Fusing: Introduced an (emit-prepass) function to the translator pipeline. The ARM64 translator uses this pass to implement Load Pair (LDP) and Store Pair (STP) instruction fusing, reducing the compiled size of the boot_image by 6 KB.

  • O(1) Instruction Map Lookups: Restructured the translator instruction maps to avoid linear scans. By aligning instruction symbol str_hashslot values across all maps and filling empty slots with :nil, build performance remains fast. A full build of the system completes in 0.074 seconds, while a 5-platform parallel build on an M4 MacBook takes 0.38 seconds.

  • Validation Mode: Enhanced the validation build mode to verify that all translator instruction maps align correctly with their assigned slots.

Libraries, Tools & Documentation

  • Dependency Analysis: Added an optional end parameter to both (files-all-depends) and (files-depends) helper functions.

  • Forward Reference Checks: Updated the forward command to automatically filter targets, limiting scans to ".vp", ".inc", and ".lisp" file extensions.

  • Documentation: Created docs/ai_digest/turbo_charging.md to document the internal structure and design of the translator instruction maps.

Enjoy

Chris

Source: README.md, updated 2026-05-20