Windows willingly swaps its own code from memory to make room for your other programs. But since Windows code is the most often used when you run your system, swapping it can slow things down. You can save swap time by making Windows lock its own kernel in RAM, as long as you have enough memory (512MB).

Note that the Registry controls all swapping of the kernel, and any erroneous alteration in the Registry can make your PC inoperable. Use the program Regedit (usually found in your Windows or WinNT folder). Click on My Computer | Local Disk (C:) | Windows | Regedit.

Expand the listings to HKEY_LOCAL_MACHINE\ SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management in the left-hand half of the window. Highlight DisablePagingExecutive on the right-hand side. Then click on Edit | Modify and enter the value 1. Click on OK, close Regedit, and reboot your computer.

Who doesn't have enough RAM to avoid these kinda mumbo-jumbo, these days?And forcing the kernel into RAM on a low memory system, so it's even more busy swapping the currently active application in and out of memory, instead of some kernel code you're not using (much) at the moment?

Yup. It's rarely a good idea to manually edit the registry. And when it comes to the above suggestion, it's definitely a bad idea. As Ath pointed out, the situation this hack attempts to 'fix' has long since been addressed by improvements made to Windows and the hardware it runs on.

There are times when a RAM disk still makes sense. Mostly for busy caching situations on a server - although even those situations are becoming less common now that programs that can benefit from such now handle it for you.

Generally speaking, unless there's a very specific and special requirement that can provably benefit from second guessing your OS, I've found it's best to just let system handle caching, swapping, and other memory management activities. Today's operating systems are quite sophisticated and adept at handling that sort of thing. Rarely will you be able to do it better tweaking those things by hand.

I used to do this back in the days when I didn't have enough RAM to disable the pagefile entirely.

Now, the following quite from Ath makes sense logically:

And forcing the kernel into RAM on a low memory system, so it's even more busy swapping the currently active application in and out of memory, instead of some kernel code you're not using (much) at the moment?

...but the real-world effect was a system that ran somewhat more smoothly. With DisablePagingExecutive enabled, Windows "recovered" faster (with lots less page-in activity) after, say, exiting a memory-hungry game. And I never ran into any adverse effects by having the setting enabled.

Dunno if there'd be any idea of doing it when you've running without pagefile. While there's nothing to page-out to, perhaps the setting could influence whether unmodified code sections are discarded and later page-in'd? *shrug* - not like I'm ever running low on memory on my current rig

But on old systems with limited RAM and slow harddrives? It's worth checking out - depending on how you're using the system, it might be a performance increase.