On drunken_f00l's advice I decided to mess with the sleep() call srcds
does. Apparently

stats
CPU   In    Out   Uptime  Users   FPS    Players
99.90  0.00  0.00       0     0 28571.43       0
stats
CPU   In    Out   Uptime  Users   FPS    Players
99.90  0.00  0.00       0     0 31250.00       0
stats
CPU   In    Out   Uptime  Users   FPS    Players
76.25  0.00  0.00       0     0 34482.76       0
stats
CPU   In    Out   Uptime  Users   FPS    Players
76.25  0.00  0.00       0     0 34482.76       0

It seems the server sleeps on every frame, regardless of if its over
*or* undershooting it's FPS goal:

fps_max 300
stats
CPU   In    Out   Uptime  Users   FPS    Players
97.00  0.00  0.00       5     0  299.94       0
stats
CPU   In    Out   Uptime  Users   FPS    Players
96.00  0.00  0.00       5     0  299.94       0
stats
CPU   In    Out   Uptime  Users   FPS    Players
95.25  0.00  0.00       5     0  299.94       0
stats
CPU   In    Out   Uptime  Users   FPS    Players
95.25  0.00  0.00       5     0  299.94       0

Note the CPU usage. This means that the server isn't sleeping more
when it's overshooting its FPS goal, nor is it staying awake longer
when its not quite getting there.

Anyone from valve care to comment on this? Is there a
performance/stability reason it works this way, or might there be a
possible performance/cpu gain/tradeoff from writing a plugin that
tweaks sleep()?

- Neph

_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlds

Reply via email to