Singlethreaded program on a SMP enabled machine and HZ=?

SnakeS gman at tiscali.no
Fri Mar 12 11:57:22 PST 2004


Hi

I have a Dual Pentium3 933Mhz machine with 768MB ram installed running
FreeBSD 5.2.0 that I wish to run HLDS (Half.life dedicated server, I belive
its singlethreaded but I really dont know..), now that Ive got everything
set up I started to wonder if hlds actually would have any benefits of
running on a SMP machine. as I can remember from using windows on the same
machineware was that singlethreaded software never used more than one cpu,
ie only utilizing 50% of theoretical processing power. does FreeBSD act the
same way or does it have some clever ways of making software not built for
MP use more than one cpu and draw the full capacity out of the box?

one other ting, while setting up the game server, I often came across
howto's and faq mailing lists mentioning HZ=1000 or similar would help
boosting the fps of the game server up, while others says that for a
singlethreaded cpu-hog like hlds would benefit more running with a HZ=20 or
abouts would give more precius cpu time to the actual game server. if I
recall right from the manual, HZ has something to do how often the BSD
scheduler checks the running processes and distributed cpu time to them,
right?
if so, my sense of logic would say to me that the less intrerrupts the hlds
have the more speed could I tweak out of the box, am I right?
right now HZ is at the default value of 100, do I really need to mess around
with it or can I just leave it as it is?

maybee I should take half of theese questions to a valve/hl list/forum, but
since its all about freebsd Im posting it here.

Thanks in advance for all the replies. :)

Geir Inge Aurvåg





More information about the freebsd-questions mailing list