Skip to content

Remove redundant initialization in Table::allocate - #25353

Open
JaySpruce wants to merge 4 commits into
bevyengine:mainfrom
JaySpruce:remove_redundant_init
Open

Remove redundant initialization in Table::allocate#25353
JaySpruce wants to merge 4 commits into
bevyengine:mainfrom
JaySpruce:remove_redundant_init

Conversation

@JaySpruce

Copy link
Copy Markdown
Member

Objective

Table::allocate zero-initializes ticks immediately after reserving a new row in its columns, but this isn't really necessary since either Column::initialize_from_unchecked (in Tables::move_row) or Column::initialize (in BundleInfo::write_components) is always called before they're assumed to be initialized.

Solution

Remove the initialization in Table::allocate (and update Column::initialize to expect to actually initialize them).

Testing

Pretty good:
Screenshot_20260810_123427

@JaySpruce JaySpruce added A-ECS Entities, components, systems, and events C-Performance A change motivated by improving speed, memory usage or compile times D-Unsafe Touches with unsafe code in some way S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Aug 10, 2026
@github-project-automation github-project-automation Bot moved this to Needs SME Triage in ECS Aug 10, 2026
@mockersf
mockersf added this pull request to the merge queue Aug 13, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Aug 13, 2026
@JaySpruce JaySpruce added S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it and removed S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Aug 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-ECS Entities, components, systems, and events C-Performance A change motivated by improving speed, memory usage or compile times D-Unsafe Touches with unsafe code in some way S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it

Projects

Status: Needs SME Triage

Development

Successfully merging this pull request may close these issues.

3 participants