Repository navigation
perf(module): limit creature work to indexed candidates - #711
Merged
Merged
Conversation
This was referenced Oct 16, 2026
Mathih13
force-pushed
the
perf/simulation-candidates
branch
from
October 16, 2026 06:21
64abed4 to
9d24f1c
Compare
Contributor
Author
|
Merged after adversarial review and repairs. Added a populated upgrade fixture. It publishes the new Module over the pinned old Module without clearing state, then checks preserved Character and Entity fields, legacy schemas, appended defaults, backfill, and native event delivery. All nine checks passed at Comment review passed. No real-client or capacity measurement is claimed. |
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.
Creature firings scan WorldEntity rows for regeneration, combat, Characters and pets. Dedicated Instance firings also scan every creature spline, and repeated collision queries decode the same static cells.
Maintain indexed simulation predicates on every Entity insert and update. Select Characters and pets through existing or new indexes, scope splines by Instance, and reuse decoded static collision cells within each firing. Most changed Module files only route Entity writes through the methods that maintain the predicates.
Part 2 of 6. Follows #710. Merged in stack order. Next: #712.
Verification
CI now builds the pinned old Module, populates it, publishes this Module without clearing, and checks preserved state, table schemas, backfill, and native notification delivery.
Two independent adversarial review rounds are complete. No actionable finding remains. The reviewed stack passed offline binding generation, formatting, workspace Clippy with all targets and features, and the Gateway unit and integration test targets. The Gateway binary passed 2,148 tests. Local builds used one job; no local SpacetimeDB instance or load test ran.
All nine checks passed at
9d24f1c4: Module durable tests and Gateway bindings, Runtime Scripts, Rust.Comment review passed for the final changed source, tests, scripts and configuration. Retained protocol and ordering contracts match the code.
Verification limits
A real build-5875 client and capacity measurements were not run. No capacity gain is claimed.
Risk
Three defaulted columns are appended to WorldEntity, and indexes are added. Creature firings backfill at most 512 rows each and pause their phases until all predicates are current. Other reducers continue. Rehearse that pause on an isolated copy before rollout. Operator SQL that changes the indexed game fields must set
simulation_indexed=false. Dynamic GameObject collision stays uncached.Models: GPT-6 Astra and GPT-6.1 Sol. Harness: Codex in T3 Code.