General discussion

Locked

Windows: Stop the Swap!

By oldbaritone ·
Disk swapping began in the days of magnetic-core mainframes, when RAM was unbelievably expensive. A single one-K core module cost many thousands of dollars. (I have one framed on my wall). Swapping to a DASD was a great way to share resources and increase utilization and performance.

Then came solid-state RAM, first dynamic and then static. The cost dropped significantly; I remember what a "bargain" I got when I bought a 16K static RAM S100 card at the Trenton Computerfest for "only" $125. Yes, 16K, not Meg.

I'm "experienced" enough to remember back to the dawn of Windows. In those days, the way to get screaming performance was to max your system with RAM, then go to the kernel executive options and disable disk swapping.

Then came Windows 95. Although it would run with 8M RAM, and wanted a swap file twice that size, when I told a system with 64M RAM to disable swapping in the executive, the system would not boot.

Such has been the way of Windows ever since. Computers have increased from tens of Megabytes of RAM, to hundreds of Megabytes, to Gigabytes and beyond. No matter how much RAM you give it, the Windows executive MUST have a swap file, larger than the amount of physical RAM. Try to prevent that, and you're sunk.

Now let's examine that premise for a moment. RAM access speeds are now measured in nanoseconds. That's roughly the amount of time it takes light to travel ONE FOOT. (11.8 inches, 30 cm. Thank-you, Grace Hopper for the delightful illustration.)

Hard-drive access speeds are measured in milliseconds. That's a million times slower than the RAM access time. That's roughly the amount of time it takes light to travel 186 MILES!

Since inexpensive gigabyte RAM is the rule rather than the exception, it seems obvious to ask "How much memory is needed? Why do we permit applications to allocate endless resources? When should the OS say 'no' to an allocation request?" and the most obvious, "Why should anything in the OS be swapped to a storage medium with six orders of magnitude worse response time?"

Probably, the case can be made for a virtual server that swapping permits effective resource sharing. (Think mainframe again.) But on a standalone desktop system or physical server box, why swap? Define a minimum set of criteria for disabling the swap function, and redefine Windows' paradigms. Let the users configure a system that will run efficiently with only available RAM, and not waste time chugging and thrashing the Hard Disk Drive.

Windows: Stop the swap, and start screaming again.

What does the TR community add to that?

This conversation is currently closed to new comments.

5 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Win 95 liked about 130megs of RAM

by Slayer_ In reply to Windows: Stop the Swap!

If you set up to about 256 or 512, you could disable swap file in Win95 and get the performance boost.

But its a good question, I often on my computer see the message that my virtual memory is to low, but a quick check to task manager shows I am not even utilizing half my available RAM. Windows is just absolutely stupid about memory management these days. It worked great in Win95 when you needed the swap file to maintain those large GUI'd applications, but now its not needed.

Collapse -

I agree

by oldbaritone In reply to Win 95 liked about 130meg ...

"Windows is just absolutely stupid about memory management these days."

Collapse -

Back in my Win95 days...

by wizard57m-cnet Moderator In reply to Windows: Stop the Swap!

I would run a RAM Disk, and set my swap file there, usually about 30 megs,
with some 64 megs RAM for other use...I suppose you could do something
similar with "modern" Windows? Hmmm...might have to try that one of these
days.

Collapse -

Kludge

by oldbaritone In reply to Back in my Win95 days...

but it's a shame to have to do a kludge like that - block out the ram to reserve it as a ram disk to use for the swap file for ram...

Edit - or using a stick on the USB (serial bus) instead of directly on the 32-bit or 64-bit system memory bus.

Collapse -

The demise of RTOS and direct disk access, and advent of "Protected Mode".

by seanferd In reply to Windows: Stop the Swap!

I can see having a small swapfile/paging file/whatever they want to call it these days "just in case" or for conditions that involve accessing ridiculously large files or large numbers of files. But no, it shouldn't be so difficult to do without the swapfile, nor raise warnings, when enough RAM is available, without creating RAM disks or using the stupid Flash drive method. Er, Ready Boost; that's what it's called.

Edit: Heck, I can't even figure out why Windows defaults to "lazy write". Under most circumstances, this is completely unnecessary.

Back to Windows Forum
5 total posts (Page 1 of 1)  

Related Discussions

Related Forums