Bring autoload, project and static variable access speeds inline with script/function #8234
Open
Description
opened on Oct 23, 2023
Describe the project you are working on
Benchmarking tool.
Describe the problem or limitation you are having in your project
The speed of accessing variables via autoloads, project settings and static variables is significantly slower than script or function variables, it would be beneficial if performance could be improved or documented that these methods of variable access were inherently slower.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
I would imagine GDScript 2.0 would make it easier to improve speed of variable access.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
I wrote a simple benchmarker to test the speed to access and change variables in different ways:
ElvisishBenchmarker-main.zip
https://github.com/elvisish/ElvisishBenchmarker
If this enhancement will not be used often, can it be worked around with a few lines of script?
I think it would be engine work.
Is there a reason why this should be core and not an add-on in the asset library?
I think it would be engine work.
Activity