14.09.2011, 16:39
3h, 50m later..
is this normal in SA-MP?
(CPU, memory usage..)
Plugins:
- Object Streamer
- MySQL
- sscanf
- crashdetect
CPU goes up, not down.
085 players = 7225 interactions, 5% CPU, 105 players = 11025 interactions, 9% CPU, 125 players = 15625 interactions, 13% CPU, now extreme: 200 players = 40000 interactions, 35% CPU, 300 players = 90000 interactions, 80% CPU, 400 players = 160000 interactions, 150% CPU, 500 players = 250000 interactions, 250% CPU (most prolly more)
CPU: Intel i7-930 @ 2.80GHz RAM: 8096 MB Kingston 1 GBit/s (1.000 MBit/s) |
yes, thats normal. each player takes some memory to get processed by the server. from the CPU values i see, you can expect the CPU usage rising up 10% more with 125 players:
87 players: 5.3% cpu 105 players: 9% cpu (almost double the CPU-time for just 18 more players) 125 players: 20% cpu time predicted. players, interacting with others, are using CPU time. if you take 80 players, then each single player will use functions which calculates 79 times for all remaining players. 80*80=6400 script "cycles" (or callbacks/functions, whatever runs in your script - it uses CPU). compare that with the amount caused by 20 more players: 100*100=10000. that, compared to 6400, is almost 2* the amount of cycles needed. now again 20 more: 120*120=14400. more than double CPU time needed, for half more (80+40) players... as you see, the RAM usage goes up linear, but the CPU usage raises logarithmic. lets match that "formula" to your CPU usage: Код:
085 players = 7225 interactions, 5% CPU, 105 players = 11025 interactions, 9% CPU, 125 players = 15625 interactions, 13% CPU, now extreme: 200 players = 40000 interactions, 35% CPU, 300 players = 90000 interactions, 80% CPU, 400 players = 160000 interactions, 150% CPU, 500 players = 250000 interactions, 250% CPU (most prolly more) |