Repository navigation
native order: dormant working book, flat per-point cost for never-filled orders - #578
Closed
luisleo526 wants to merge 10 commits into
Closed
luisleo526 wants to merge 10 commits into
luisleo526 wants to merge 10 commits into
Conversation
….hpp Mechanical relocation of the BookSpill implementation (about 290 lines gathered from three places in native_order.cpp) into a header of its own, included once from native_order.cpp. No behaviour change: only the order of definitions inside the translation unit moves, and nothing between the old sites uses them. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…led orders A working order that cannot act at the current point is kept dormant instead of being evaluated at every point. Resident dormant rows are refreshed by one bounded bulk sweep in winner order, and spilled rows carry a stamp so their allowance is projected on read to the exact value the eager path would hold. Rows above 4096 spill to a disk-backed book, and the match path touches only candidates in a resident tier plus O(log n) index steps, so the cost of a point no longer grows with the number of standing orders. Trades, fills, hashes and refusals are unchanged on every valid input: the dormant tier is an exact cache of the eager allowance (same value, same epoch, same token), any dormant-only failure degrades to the eager path, and a run that cannot use the fast path takes the eager path unchanged. Tests: a transcript suite compares eager and dormant runs byte for byte (hashes, allowances, fills) across the seven driver classes, spill from the middle inside notification callbacks, held-copy reads, bad_alloc and read-failure degrade paths, and a cost row bounding disk reads per extra spilled row. 43 mutation patches with a manifest name the row each one must turn red. test_native_dormant_book_capacity is added to the pinned slow rows. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Comment-only (plus the text of diagnostic messages) rewrite of the dormant-book tests, the mutation README and manifest, and the new comments in the kernel sources: every passage now says what behaviour it pins and why, with no reviewer, process or row-number names. No executable code, assertion or constant changes. The manifest row for the epoch mutation names the test that actually turns red, and two mutation patches are regenerated against the reworded context. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
The dormant-book fixtures used internal-looking ticker labels. They are renamed to TEST:DORMANT (and TEST:UNREACHABLE for the unreachable-book fixture). The ticker is only a symbol label shared by the eager and dormant runs of one test; nothing else changes. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…und manifest and the doc anchors The working-book implementation moved into src/native_order_book.hpp, so the reviewed allocation-bound entries and site records that named src/native_order.cpp are relocated (ids, owners and states kept), and the new working-book containers get open, unreviewed entries: their resident vectors, spill tables and byte buffers grow with live work, so none is marked bounded. 117 doc anchors that cite moved source lines are re-pointed to the lines that hold the cited symbol or statement; no doc line is added or removed. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…ing book and refresh the generated site inventory The first manifest pass missed thirteen sites in src/native_order.cpp (the scratch directory references, retained path text and the opening, live-order and successor-root row vectors). Two entries now cover them, both left unreviewed because their size follows the number of orders; the unreviewed ceiling rises by the same two. ci/cr150-source-sites.json is replaced by the gate's own generated inventory for this tree. The doc-anchor checker's one-line fix to the parity table is applied, and two anchors in the contracts page that landed on comment-only lines point at the calls they describe. No code, bound or behaviour changes. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…nt of the real-tree gate test The real-tree gate test pins the number of open manifest entries. The manifest changed in this branch, so the pinned count moves to the number the gate now reports. No other change. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
luisleo526
added a commit
that referenced
this pull request
Oct 28, 2026
…aling, UDT graphs, metrics replay and the CI admission fix (#616) This lands twelve engine pull requests as one change, verified and measured once on the combined tree: - #593 scratch: a fixed write-through read cache for the adapter's id tables - #594 live runner: a delta report stream by default, and report-path work that does not rescan closed trades - #597 live runner: typed pre-growth stop for the ledger budget and flat pending counts - #608 run_json: reserve the report channel, so strategy output on fd 1 cannot corrupt a report - #586 Pine UDT object graphs on the paged object Store - #578 native order: dormant working book, flat per-point cost for never-filled orders - #579 adapter: skip roster passes and empty-family scans that cannot change anything - #599 adapter: read projected pending orders through one cached duplicate index - #563 adapter: gate the reversal exit cancel on candidate owners instead of every historical id - #591 report sink: retire sealed closed-trade rows on sink routes when the module opts in - #596 metrics: stream the bar Sharpe and Sortino through an ordered, packed return replay - #615 ci: accept release.yml's matrix runner under its fetched path in PR admission Fixes found while testing the combined tree are in the final commits: the retiring ledger's cache sizing, a residency witness that bounds sink-run heap by the declared cache cap and checks zero growth at 100k, 200k and 1M trades, a test fix for a descriptor reuse race, and a standing-orders timing grid whose 20,000-order point is tracked in #621. The member pull requests are closed as landed here.
Collaborator
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
native order: move the working-book spill code into native_order_book.hpp
Mechanical relocation of the BookSpill implementation (about 290 lines gathered from three places in native_order.cpp) into a header of its own, included once from native_order.cpp. No behaviour change: only the order of definitions inside the translation unit moves, and nothing between the old sites uses them.
native order: dormant working book, flat per-point cost for never-filled orders
A working order that cannot act at the current point is kept dormant instead of being evaluated at every point. Resident dormant rows are refreshed by one bounded bulk sweep in winner order, and spilled rows carry a stamp so their allowance is projected on read to the exact value the eager path would hold. Rows above 4096 spill to a disk-backed book, and the match path touches only candidates in a resident tier plus O(log n) index steps, so the cost of a point no longer grows with the number of standing orders.
Trades, fills, hashes and refusals are unchanged on every valid input: the dormant tier is an exact cache of the eager allowance (same value, same epoch, same token), any dormant-only failure degrades to the eager path, and a run that cannot use the fast path takes the eager path unchanged.
Tests: a transcript suite compares eager and dormant runs byte for byte (hashes, allowances, fills) across the seven driver classes, spill from the middle inside notification callbacks, held-copy reads, bad_alloc and read-failure degrade paths, and a cost row bounding disk reads per extra spilled row. 43 mutation patches with a manifest name the row each one must turn red. test_native_dormant_book_capacity is added to the pinned slow rows.
dormant book: state each test's purpose in plain words
Comment-only (plus the text of diagnostic messages) rewrite of the dormant-book tests, the mutation README and manifest, and the new comments in the kernel sources: every passage now says what behaviour it pins and why, with no reviewer, process or row-number names. No executable code, assertion or constant changes. The manifest row for the epoch mutation names the test that actually turns red, and two mutation patches are regenerated against the reworded context.
🤖 Generated with Claude Code