feat: add ASLRef-backed PTO reference model - #2
Conversation
|
Dependency chain: PTO-ISA/pto-spec#188 owns architecture; LinxISA/SuperScalarModel#428 consumes this ABI; LinxISA/linx-isa#191 pins exact heads. Keep Draft and unmerged. |
|
Scope decision: this Draft PR intentionally exposes stop-PC-only execution for the first release. Host-exit/service termination is deferred to PTO-ISA/pto-spec#150. The accepted evidence set is the three exact scalar, block64, and Tile TADD result hashes. |
|
A follow-up model PR is available: #4, stacked on this branch. It ports the more complete runtime design (sparse memory, host bridge, session/snapshot/PE runtime, persistent worker and tests) into the same package while retaining this PR's C ABI and runner as the sole hosted entry. It depends on PTO-SPEC#188 and should be reviewed before SuperScalarModel#428 is finalized. |
|
Issue #3 implementation update is in
Performance/correctness evidence from the real
The PR remains Draft. Resolving automatic header-to-body transition is a PTO architecture decision not covered by ADR-0111; no semantic workaround was added here. |
|
Update: added rejected-instruction fault context, corrected hosted sp/ra seeding against the PTO register map, added fresh-process reset specialization with fail-closed source matching, and documented the model NDF. The same 128 KiB TLOAD carrier fell from 600.6s to 61.0s with identical terminal PC and result SHA (about 9.8x). Manifest-backed C/C++ consumers now use quiet mode. |
|
Repinned the model lock in aeb0a49 to PTO #190 head 7b990451 (tree 03bda540), which includes the relative-generation and ordinary floating Matrix reference-profile fixes. |
c4c5f83 to
9a98f2a
Compare
Summary
Add the public ASLRef-backed PTO reference runner and versioned C ABI used by downstream
gfrun. PTO instruction semantics remain entirely in the exact locked PTO-SPEC ASL tree.The model repository owns:
ExecuteNextPTOInstruction()execution inside one ASLRef process;It contains no custom PTO decoder or instruction handler and applies zero parser/typechecker/interpreter semantic patches to ASLRef.
Correctness evidence
git diff --check: passedscalar_add_i32_lat0xE9 ELF: final TPC0x111e8, result3905, exact 8192-byte independent goldenPerformance evidence
Measured process-per-case cold runs take 526-563 s. A persistent native prototype reaches ready in 510.271 s, then warm decode/step takes 0.284-0.983 ms at about 498 MiB peak RSS. Full reset takes 544-582 s and is rejected as a per-case strategy.
The selected acceleration design is an exact-profile pristine initialized parent with one copy-on-write child per case, a memory-bounded worker pool, Unix fd passing for the verified ELF, and a 512 MiB Darwin LC_MAIN stack. See
docs/worker-snapshot-design.md. This is model lifecycle/NDF, not PTO architecture.Linked work
Closes #1
Closes #3