mtasa-blue
mtasa-blue copied to clipboard
getPerformanceStats giving back wrong memory usage
Describe the bug
When you monitor someone with performancebrowser or somehow, getPerformanceStats will give back false lua memory usage for clients until requesting more accurate memory usage. When you go back to normal memory usage (removing option a) it will give correct memory usage.
Steps to reproduce
- Open MTA webadmin / request memory usage via script
Version
Multi Theft Auto v1.5.9-release-21261
Additional context
Screen record: https://i.imgur.com/J3mBW5T.gif
Relevant log output
No response
Security Policy
- [X] I have read and understood the Security Policy and this issue is not security related.
Lua sampling instrumentation is very unreliable anyways, even for local player it doesn't reflect most types of memory leaks in /ipb. Even to the point that a memory leaking script can cause a perceivable game processing latency delay
The best indicator for script performance and optimization is realtime CPU usage, that's the only working thing when it comes to the sampling that MTA has, other things may need to be reimplemented or fixed somehow