What is the bottleneck impacting servers?
OneEyed
Join Date: 2003-03-14 Member: 14493Members
The items that may impact server performance at the highest level are:
<ul><li>Lua Binding</li><li>Gameplay Code</li><li>Physics</li><li>Ray Tracing</li><li>Network Processing</li></ul>
I have been looking for bottlenecks in the gameplay code, and one thing that keeps popping up is loops. Loops everywhere. For example.... The library method "Shared.GetEntitiesWithClassname" is called an insane amount of times. As the name suggests, this returns a list of all entities that have a certain Classname. I don't have access to the library code that contains the GetEntitiesWithClassname method, so I can't say anything about the code. However, this is a function that should definitely have a big O(1) run-time, if optimized correctly with hash tables.
In the math category, a good optimization would be to remove the Square Root calls in Vector Distance checks.
These are just some of the optimizations that can be done to the gameplay code. I can't really critique the other high level items, as I do not have access, but hopefully, this can begin the start of a real discussion on isolating and killing these performance gremlins for the dev team.
<ul><li>Lua Binding</li><li>Gameplay Code</li><li>Physics</li><li>Ray Tracing</li><li>Network Processing</li></ul>
I have been looking for bottlenecks in the gameplay code, and one thing that keeps popping up is loops. Loops everywhere. For example.... The library method "Shared.GetEntitiesWithClassname" is called an insane amount of times. As the name suggests, this returns a list of all entities that have a certain Classname. I don't have access to the library code that contains the GetEntitiesWithClassname method, so I can't say anything about the code. However, this is a function that should definitely have a big O(1) run-time, if optimized correctly with hash tables.
In the math category, a good optimization would be to remove the Square Root calls in Vector Distance checks.
These are just some of the optimizations that can be done to the gameplay code. I can't really critique the other high level items, as I do not have access, but hopefully, this can begin the start of a real discussion on isolating and killing these performance gremlins for the dev team.
Comments
Ahh, thanks! I just started messing with everything a few days ago, so still learning.