X Tutup
Skip to content

Use an array instead of TightLocalVector in RasterizerSceneGLES3::_render_uv2, to avoid allocation.#110781

Merged
Repiteo merged 1 commit intogodotengine:masterfrom
Ivorforce:rasterizer-render-uv2-allocation
Sep 22, 2025
Merged

Use an array instead of TightLocalVector in RasterizerSceneGLES3::_render_uv2, to avoid allocation.#110781
Repiteo merged 1 commit intogodotengine:masterfrom
Ivorforce:rasterizer-render-uv2-allocation

Conversation

@Ivorforce
Copy link
Member

@Ivorforce Ivorforce commented Sep 22, 2025

Just something small I randomly came across.
Due to misuse of TightLocalVector, this actually avoids 4 allocations.

@Ivorforce Ivorforce force-pushed the rasterizer-render-uv2-allocation branch from b3fdd4d to bc7c05b Compare September 22, 2025 14:16
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.

Luckily this code is never called at run time (its for an editor utility)! But it definitely should be fixed so others don't copy this pattern.

@Repiteo Repiteo merged commit 3bf0f77 into godotengine:master Sep 22, 2025
20 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Sep 22, 2025

Thanks!

@Ivorforce Ivorforce deleted the rasterizer-render-uv2-allocation branch September 22, 2025 18:42
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.

3 participants

X Tutup