Virtual Memory Necessary?

Eccentric

Distinguished
Oct 4, 2008
11
0
18,510
With 4 GB of RAM nowadays and using a 32 bit Windows XP, does having a virtual memory page file even necessary? Will there also be a slight performance increase if I set the page file to like 20 MB or zero?
 

Scarchunk

Distinguished
Mar 9, 2006
328
0
18,780
You won't see a performance increase or decrease. I've tried it. Only issue is that a few apps from Adobe and others like to reserve paging file space even if they don't use it. So a few apps may complain but no biggie.
 

aziraphale

Distinguished
May 6, 2004
785
0
18,980
@ dagger

Wouldn't it be advisable to leave just a reasonable amount of VM available for just these very few instances, where some programs or maybe even win might need (want) it? Just to be sure to avoid strange problems?
 

I

Distinguished
May 23, 2004
533
2
18,995
Disable virtual memory then use system... if any apps complain, re-enable VM. There's no point in setting a very low amount of VM as an upper limit, if it's enabled then leave it 1GB or larger.

It is false that there is no reason not to disable VM if you can, because if it is enabled windows will allocate space to it, the system continually pauses waiting for the must slower disk subsystem to write out (even a few bytes of allocation that is never used is much slower than only waiting on real memory).

Windows is not "meant" to have virtual memory, virtual memory was just a feature allowing less-endowed systems to run more demanding applications, and a way to make it run, have sales for MS. It's a great feature to have if you need it, and a great feature to disable if you don't.
 

Scarchunk

Distinguished
Mar 9, 2006
328
0
18,780


I have 4GB of RAM and have ran benchmarks as well as running without a pagefile for extended periods. I noticed no performance increase or decrease. If you have a small amount of RAM you can increase performance by placing the pagefile on a separate disk from the OS, but that is only because you have a small amount of RAM and are actually using your pagefile. AFAIK if you have enough RAM, Windows will allocate, but not actually use a pagefile, thus no performance hit. Do you have any experience otherwise? However, I do set a static pagefile to avoid fragmenting.
 

mikrev007

Distinguished
Oct 28, 2008
264
0
18,790


An application cannot directly allocate space in the paging file. It a allocate memory, and that memory will be backed by physical ram or the paging file (controlled by the memory manager), the app doesn't care about it.
 

Scarchunk

Distinguished
Mar 9, 2006
328
0
18,780


I'm not sure of the technical reasoning behind it, all I know is that if you install, for instance, Photoshop without a pagefile enabled the app will complain about it. No big deal, but worth noting that some apps are "pagefile aware" and like to have one for whatever reason.
 

mikrev007

Distinguished
Oct 28, 2008
264
0
18,790
Photoshop knows it uses a lot of memory, and knows that if the user has no paging file, the system might run out of memory. The app can check if one exists, but that it all