Monthly Archives: August 2009

The best OS for hosting games?

Is FreeBSD, or even newer versions of NetBSD. FreeBSD will busy wait on sleeping, so you get more accurate timing. Linux is okay, but I don’t really like using it for game server hosting due to each kernel having newer bu… err features than previous ones.

The problem with any of the linux binaries is they consume large amounts of CPU compared to their windows counterparts, plus they aren’t as optimized. Alfred from VALVe spoke with me and said they won’t move to a newer GCC because it breaks so many mods.

2000FPS 1.6

I’ve done it. Kind of. The problem is finding the correct divisor for sys_ticrate.

The engine uses sys_ticrate to step time in increments of 20hz (20ms). So a sys_ticrate of 2000 (2000fps) increases the amount of heartbeats, therefor timers etc all go 2x faster. For example, a bomb plant takes half the time.

HPET based timers (For fun)

What good is usleep()/nanosleep() when you have to more or less wait for the scheduler to give you time (even with SCHED_FIFO)

I’m trying a different approach that will give me much better results, the only downside is I have to read() /dev/hpet which is more expensive than syscalling into the kernel at all. Bummer.

Back to the drawing board.

I could use posix timers, but that would be messy, because the engine calibrates CPU speed on startup/mapcycles to step time in the engine, otherwise you’ll get clock aliasing so it needs control over how long something sleeps.