Merge train: #9912, #9917 - #9982
Merged
Merged
Conversation
added 6 commits
September 8, 2026 01:22
(cherry picked from commit a667b28)
(cherry picked from commit b5d502f)
(cherry picked from commit b737697)
The tier shipped default OFF because the runtime's view entry points did not exist. #9870 landed them on main, and on claude-code the tier with #9893's levers is -14 % CPU and -30…-42 MB peak RSS across 5/5 paired runs with identical output. `PERRY_SEGVIEW=0` remains as the opt-out. A switch that changes emitted code needs an off position that does not require rebuilding the compiler, and a program whose loops the tier declines pays nothing either way. The test asserts the default through the same environment read the compiler uses. Without it, a predicate that was accidentally always-false would leave every other segview test passing — they call the rewrite directly — while the tier silently never fired in a real compile. (cherry picked from commit e495a1e)
…ating #9917 collapses the three RegExp.prototype.test proof slots into one CanonicalTestSite behind a single HotKey, but was written before #9970 gated that surface for the no-default-features product build. Merged so both hold: the unified record, carrying #9970's cfg on the struct, its impl, the thread_local and TEST_ACCESSOR_KEY_BIT. Consequences reconciled: - object_static_prototype_known_non_meta is #9917's, and its only caller is regex-engine gated, so it is dead in a product build. Same gate. - The three _SLOT holder entries added for #9893 are stale: the statics no longer exist. Deleted, and a duplicate TEST_WALKS entry removed. The new REGEXP_PROTOTYPE_TEST_SITE needs no entry — the walk reaches it through scan_canonical_test_site_roots_mut, which scan_object_cache_roots_mut calls and reg_scanner! registers. - segments_view's cursor-number store carried GC_STORE_AUDIT(NUMBER), which is not an accepted class, so the marker never satisfied the gate. POINTER_FREE is the class that states what the comment argues.
#9917's canonical-test-site test nests an `unsafe` block inside one that already covers it. Only `-D warnings` on test targets rejects it, so a plain `cargo check --workspace --all-targets` passes. Worth noting how this surfaced: the first run of that gate died on ENOSPC alongside perry-codegen, and it would have been easy to write both off as disk collateral. Re-running it on a healthy disk showed codegen was collateral and this was not.
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.
Merge train: #9912, #9917.
#9917 against #9970
#9917 collapses the three
RegExp.prototype.testproof slots into oneCanonicalTestSitebehind a singleHotKey— one TLS address resolved per call instead of three. It was written before #9970 (landed in #9978) gated that surface for the no-default-features product build, so taking its side wholesale would have re-broken that build. Merged so both hold: the unified record, carrying #9970'scfgon the struct, its impl, thethread_local!andTEST_ACCESSOR_KEY_BIT.Three consequences reconciled rather than left to surface later:
object_static_prototype_known_non_metais perf(intl): Segments view — one realm record for the test proof, fixed-slot cursor fields, no duplicate pointer validation #9917's, and its only caller isregex-enginegated, so it is dead in a product build. Same gate._SLOTholder entries added for perf(intl): take the view mode's canonicality proof and UTF-8 re-validation off the per-grapheme path #9893 are stale — those statics no longer exist. Deleted, along with a duplicateTEST_WALKSentry. The replacementREGEXP_PROTOTYPE_TEST_SITEneeds no entry: the gate's walk reaches it throughscan_canonical_test_site_roots_mut, whichscan_object_cache_roots_mutcalls andreg_scanner!registers. Verified, not assumed.segments_view's cursor-number store carriedGC_STORE_AUDIT(NUMBER), andNUMBERis not an accepted class — the marker never satisfied the gate.POINTER_FREEis the class that states what its comment argues.#9912 turns the segment-view lowering on by default
Its blocker is resolved: the runtime entry points it needs landed in #9870 (#9888). Measured on claude-code, the tier with #9893's levers is −14 % CPU and −30…−42 MB peak RSS with identical output.
PERRY_SEGVIEW=0remains as an opt-out, deliberately, because a switch that changes emitted code needs an off position that does not require rebuilding the compiler.It also adds a test asserting the default really is ON — written because a typo making the predicate always-false would leave every direct-call test passing while the tier silently never fired in a real compile.
A note on how one fix here was found
The first validation run of this train died on ENOSPC.
perry-codegenreportedRC=101with zero tests, and the-D warningsall-targets gate failed alongside it. It would have been easy to write both off as disk collateral. Re-running them individually on a healthy disk showed codegen was collateral (1948 passed, 0 failed) and the warnings gate was not: #9917's test nests anunsafeblock inside one that already covers it, which only-D warningson test targets rejects. An ENOSPC run mixes spurious failures with real ones, so each has to be re-run to tell them apart.Validation
run_lint_gates: 3 of 80 FAILED; 0 ENOSPC, all three accounted for: public-baseline is pre-existing onmain(verified on a pristine worktree, red since 2026-07-29), and the two API docs gates trip on this session'sCARGO_TARGET_DIRoverride — with the binary whereregen_api_docs.shexpects it, regeneration succeeds and the drift check is clean.