Skip to content

kernel: update to Tarver's S41.2 (2026-07-11 refresh)#9

Merged
pyrex41 merged 1 commit into
mainfrom
kernel/tarver-s41-refresh-20260711
Jul 14, 2026
Merged

kernel: update to Tarver's S41.2 (2026-07-11 refresh)#9
pyrex41 merged 1 commit into
mainfrom
kernel/tarver-s41-refresh-20260711

Conversation

@pyrex41

@pyrex41 pyrex41 commented Jul 14, 2026

Copy link
Copy Markdown
Owner

Update vendored kernel to Mark Tarver's S41.2 (2026-07-11 refresh)

Replaces the community ShenOSKernel-41.2 kernel this port vendored with
Mark Tarver's re-uploaded S41.2 (2026-07-11 refresh) — the same
version string
but a restructured kernel of a different lineage.

Canonical source: the pyrex41/shen-s41.1 mirror, tag
s41.2-pristine-20260711 (commit 11fc51b); byte-identical to
https://www.shenlanguage.org/Download/S41.2.zip (Last-Modified
2026-07-11, sha256 51becbf…3ee836). Full detail in
kernel/klambda/PROVENANCE.md.

Upstream delta

  • 15 refreshed core .kl vendored byte-identical: backend core declarations load macros prolog reader sequent sys t-star toplevel track types writer yacc.
  • Removed dict.kl, compiler.kl, init.kl:
    • put/get now store pointer lists on *property-vector* directly
      (shen.change-pointer-value/shen.remove-pointer in sys.kl) — no
      dict layer, no native dict primitives needed.
    • compiler.kl was a shen-cl artifact (never in the release zip).
    • init.kl is gone and there is no shen.initialise function any
      more: declarations.kl sets *property-vector*, runs
      shen.initialise-arity-table, and builds the lambda table
      (shen.build-lambda-table (external shen)) via top-level forms
      evaluated during file load
      .
  • backend.kl (new cl.* Common-Lisp backend) is vendored +
    AOT-generated for audit completeness but not booted (upstream loads
    it as precompiled backend.lsp; dead weight for a Rust port).

What this PR does

  • Vendors the 15 files; deletes dict/compiler/init.kl; retains
    stlib.kl (community stdlib) + community extensions as an overlay

    upstream now ships StLib as separate lazy Shen sources, but the
    conformance suite and the Ratatoskr stage-1 launcher still need them
    (migration to Lib/StLib sources tracked as follow-up).
  • Fixes boot order to upstream install.lsp (the reference SBCL
    runtime loader), not Sources/make.shen (the bootstrap-generation
    order). This is now load-bearing: declarations.kl and macros.kl
    must precede types.kl, whose 161 top-level (declare …) forms invoke
    the type checker (shen.prolog-vector, the prolog-memory global).
    types.kl loads last.
  • Makes run_shen_initialise a graceful no-op when shen.initialise
    is absent
    (the refreshed kernel self-initialises at load); still
    calls it when present, preserving the Ratatoskr stage-2 contract.
  • Regenerates all AOT kernel modules (scripts/codegen-kernel-aot.sh);
    updates aot/kernel/mod.rs, the shenffi embedded KERNEL_PARTS,
    PROVENANCE.md, and the 21-file references in the docs.

Test status

Gate Result
0 shengen-codegen PASS
1 fmt + clippy PASS
2 build (workspace) PASS
3 test (port-authored) PASS
4 shen-check PASS
5 tcb-audit PASS
6 kernel-aot-audit PASS
7 kernel-tests (release) 134/134
8 kernel-tests (debug) 134/134
9 kernel-tests (debug-gc) 134/134
10 cedar-equiv PASS

REPL smoke: boots clean, *version* = 41.2, arithmetic / map /
reverse / append / shen.hush all correct.

Remaining work / notes for other ports

  • StLib migration: retained community stlib.kl as an overlay rather
    than loading upstream's Lib/StLib Shen sources. Functionally complete
    (134/134) but not the upstream stdlib-load path.
  • Ratatoskr stage-2: crates/ratatoskr-build still defaults its
    manifest init to shen.initialise. Boot no longer requires it (the
    no-op change covers shaken kernels), but a shaken slice of this kernel
    has no such function — the builder's default should move to "none".
    Out of scope here; flagged for the Ratatoskr repo.
  • Cross-port gotchas confirmed: no shen.initialise (call
    only-if-defined); properties live on a plain *property-vector*
    absvector, not a dict (a port with native dict-backed put/get
    would break — shen-rust's are kernel defuns, so it dodged this); the
    declarations-before-types load order.

🤖 Generated with Claude Code

Replace the community ShenOSKernel-41.2 with Mark Tarver's re-uploaded
S41.2 (2026-07-11) — same version string, restructured kernel of a
different lineage. Canonical source: pyrex41/shen-s41.1 tag
s41.2-pristine-20260711 (commit 11fc51b); byte-identical to
shenlanguage.org/Download/S41.2.zip (sha256 51becbf…3ee836).

Vendor the 15 refreshed core .kl files byte-identical. Drop dict.kl
(put/get now store pointer lists on *property-vector* directly, no dict
layer), compiler.kl (shen-cl artifact), and init.kl (absorbed into
declarations.kl/toplevel.kl; there is no shen.initialise function any
more — declarations.kl self-initialises via top-level forms at load).
Retain community stlib.kl + extensions as an overlay (upstream now ships
StLib as separate lazy Shen sources, but the conformance suite and the
Ratatoskr stage-1 launcher still need them). Vendor backend.kl for audit
completeness but do not boot it (upstream loads it as precompiled
backend.lsp; dead weight for a Rust port).

Boot order now follows upstream install.lsp (runtime loader), not
make.shen (bootstrap-generation order): declarations.kl and macros.kl
must precede types.kl, whose 161 top-level (declare …) forms invoke the
type checker; types.kl loads last. run_shen_initialise is a graceful
no-op when shen.initialise is absent (keeps shaken/legacy kernels
working). Regenerate all AOT kernel modules; update the shenffi embedded
KERNEL_PARTS, PROVENANCE, and docs.

All gates green: kernel-tests 134/134 across release/debug/debug-gc,
fmt+clippy, workspace tests, shen-check, tcb-audit, kernel-aot-audit,
cedar-equiv.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant