Saturday, July 28, 2012

The 0 Swap Initiative

So I've been dealing with a fairly cantankerous game issue - do you need a swap file.  My gut says no, even if my head says yes.

What does a swap file do?  In theory it allows your OS to move inactive memory pages to less volatile, and less fast, storage.  This leaves room for active processes to work with the fast resources.  It can/will also be used as a last resort to store active memory pages when you run out of physical ram.

The problem I'm having is, I'm beginning to suspect that the geniuses who wrote the code in question decided they could do this more efficiently themselves.  Anyways, in the mean time my windows swap file is turned off, to see what happens.  I'm hoping what happens is that the stuff actively working is not in contention with stuff being loaded.

Yes, I'm aware that if I run out of memory my machine will burst into flames and even the Omnisiah will not me able to save me.  The forces of chaos win.  We all end up in the servitude of warp beasts.  Or something.

Some statistics:
Win 7 (64 bit) seems to want to sit right about 1.9 - 2.2 Gb of memory.
The peak I've seen, even with Outlook, Excell, Corel, Chrome and a game open has been about 3.4 Gb of memory.
The commit always seems to be about 10% larger, but may not really matter.
None of this seems to stop the infernal jitter of Diablo III.

I'm beginning to suspect that either the resource management of the engine is rubbish or the need to get out to the server constantly to look up the loot tables is rubbish.  May be both.

I'll keep you posted.