Factor investigation notes

Findings from investigating the Factor VM, and experiments with the language, shared with the Factor team.

Windows ARM64: faults inside VM primitives are unrecoverable

The build-windows-arm CI job fails in core/kernel/kernel-tests.factor at [ f 0 alien-unsigned-1 ] [ vm-error? ] must-fail-with. This is not caused by the PRs it appears on.

Read the write-up

Zig VM: differential GC fuzzing

The zig-vm-fuzzing branch adds a fuzzer for the Zig VM that runs random GC-heavy Factor programs on it and on the C++ VM, and compares the output. It also adds GC stress flags to the Zig VM (-gc-zeal, -gc-zeal-code, -nursery-budget, -verify-heap).

Read the guide

Zig VM: format-float returns an empty string on Linux

On glibc the Zig VM’s (format-float) returns an empty byte-array for every call, so sprintf with %f or %e fails, and 41 formatting tests fail. The C++ VM is unaffected.

Read the bug report

Symbolic algebra: an experiment

The symbolic-algebra branch adds a computer algebra system in extra/math/symbolic: symbolic expressions and simplification, derivatives and integrals, limits, user-defined rewrite rules, and compilation of an expression back into a quotation.

Read the write-up