158 feature define and implement core physicslanes broadphase solver #242
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.
Description
Implement core native physics lanes (Broadphase, Solver)
Refactored the core ECS World struct to adhere to the SAA/CLAD architecture by decomposing it into specialized sub-managers (EntityStore, StorageManager, QueryPlanner). This separation of concerns improves maintainability and prepares the system for the Dynamic Context Core (DCC).
Significant optimizations were introduced, including an$O(1)$
archetype_mapin StorageManager to replace linear page searches.Additionally, implemented Page Vacuuming in the CompactionLane. The WorldMaintenance trait now supports vacuum_hole_at, allowing the generic CompactionLane to actively defragment component pages by moving entities into holes left by removed components, improving memory contiguity and cache locality.
Type of change
How Has This Been Tested?
Added physic testing.
Ran the full ECS test suite to verify no regressions were introduced by the decomposition. Verified that the new vacuum_hole_at logic correctly compiles and integrates with the CompactionLane.
Test Configuration:
Checklist:
cargo fmt --all -- --checklocally and it passes.cargo clippy --workspace --all-targets --all-features -- -D warningsand there are no new clippy warnings.cargo test --workspace --all-targets --all-features).