Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce allocations each time a render pass begins in RenderingDevice. #92258

Merged
merged 1 commit into from
May 23, 2024

Conversation

DarioSamo
Copy link
Contributor

@DarioSamo DarioSamo commented May 22, 2024

Using #92206 to verify the result, allocations go down from ~1800 to ~1700 per frame in the TPS demo by making this fairly simple change to reuse the Vectors across function calls.

Copy link
Member

@clayjohn clayjohn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. This isn't a risky change, so we can sneak it in to 4.3. Fewer allocations is always better and this code gets called a lot

@clayjohn clayjohn modified the milestones: 4.x, 4.3 May 23, 2024
@akien-mga akien-mga merged commit abfe8ba into godotengine:master May 23, 2024
16 checks passed
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants