Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Parallelize mark_dirty_trees#23185

Open
aevyrie wants to merge 9 commits intobevyengine:mainfrom
aevyrie:par-mark-dirty-trees
Open

Parallelize mark_dirty_trees#23185
aevyrie wants to merge 9 commits intobevyengine:mainfrom
aevyrie:par-mark-dirty-trees

Conversation

@aevyrie
Copy link
Member

@aevyrie aevyrie commented Mar 2, 2026

Objective

  • Make mark_dirty_trees faster

Solution

  • Use BufferedChannels to make a parallel concurrent worker queue to propagate dirty bits from leaves to the root.
  • Use atomics to coordinate cross-thread early-exiting when hitting visited entities in the hierarchy.

Testing

  • transform_hierarchy humanoids_inactive
image - `bevy_city` while simulating cars image - `bevy_city` while static image

@kfc35 kfc35 added C-Performance A change motivated by improving speed, memory usage or compile times S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Mar 2, 2026
@alice-i-cecile alice-i-cecile added the A-Transform Translations, rotations and scales label Mar 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Transform Translations, rotations and scales C-Performance A change motivated by improving speed, memory usage or compile times S-Needs-Review Needs reviewer attention (from anyone!) to move forward

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants