Repository navigation
perf: seed raw HTML and deopt DOM expandos - #1015
Merged
domgan-oai merged 1 commit intoSep 9, 2026
Merged
Conversation
Closed
68 of 84 tasks
domgan-oai
marked this pull request as ready for review
September 9, 2026 13:17
14 of 21 tasks
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.
Summary
defaultValuebaseline symbol.for...inwalks do not expose them.Why
#981 identified repeated absent-property reads on ordinary DOM nodes after raw HTML ownership is activated and during de-opt child scans. Bootstrap now turns those misses into inherited
undefinedreads. ThedefaultCheckedinitialized symbol is deliberately not seeded: its only runtime read is a presence test, and seeding it would force an own-property check on every first defaultChecked write.Validation
pnpm format:check(repository-wide check not run)pnpm typecheck(repository-wide check not run)pnpm test(repository-wide prechecks and browser projects not run locally)pnpm sync(no generated changes)pnpm exec tsgo --noEmit -p packages/octane/tsconfig.jsonoctane/octane-prodrun passed 17,475 tests with one 5-second timeout under concurrent build load; that test passed in isolation in both projects (6/6 tests).Risk / follow-ups
The native DOM prototype initialization runs once per client realm. The local probe uses jsdom and does not measure browser DOM throughput; current-head CI will cover browser behavior. #981 remains open for other findings.
Provenance
agent-authored)Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.Note
Medium Risk
One-time mutation of native DOM prototypes affects all elements in a realm; behavior is covered by new tests but real browser impact is indirect (lookup path only).
Overview
Seeds hot DOM expando lookups on native prototypes so absent-property reads become inherited
undefinedhits after the first raw-HTML host or during de-opt child scans (#981).initDomOperationsnow pre-seeds raw HTML ownership keys (__oct_dangerHTMLand related child markers), the de-opt descriptor symbol, and the uncontrolleddefaultValuebaseline onElement/CharacterDataprototypes.seedExpandoacceptsPropertyKeyand can define non-enumerable slots so new keys do not show up infor...inover elements.defaultCheckedis intentionally not seeded.Adds a Node/jsdom dom-expando benchmark (baseline vs candidate, semantic hash checks) and regressions for pristine checkbox
defaultCheckedupdates and mixed raw HTML + de-opt sibling reconciliation.Reviewed by Cursor Bugbot for commit f033625. Bugbot is set up for automated code reviews on this repo. Configure here.