TEST 1: Localize
Code:
local min = math.min
Results:
Non-local: 0.719 (158%)
Localized: 0.453 (100%)Conclusion:
Yes, we should localize all standard lua and Spring API functions.
Source: https://springrts.com/wiki/Lua_Performance
What is the reason for that performance boost?