Ramdisk & Preventing Windows From Swapping

FAQ, getting help, user experience about Primo Ramdisk
Post Reply
Jamil
Level 3
Level 3
Posts: 10
Joined: Fri Mar 21, 2014 12:31 am

Ramdisk & Preventing Windows From Swapping

Post by Jamil »

I recently registered Primo Ramdisk Ultimate Edition after testing it for several days. I ran into no issues during my trial, and it did everything that I was looking for. Great job on the creation of this utility. My setup is simple -- I use only a ramdisk and do not use a physical disk for this ram drive at all. I do not even have an image file, since I primarily use the ram drive for my Windows temp folder and a temporary media folder. I set my ramdisk for 51200MG (50GB), and my workstation has 128GB total RAM. Note that I allow Windows to manage the virtual memory, and my page file is set to the default 130997MB.

Initially I set my 50GB ramdisk to be fixed in RAM and not use dynamic memory management. My understanding from reading the site is that all memory gets allocated and becomes reserved exclusively for Primo Ramdisk. My thought was that there would be no performance impact if all of this RAM was reserved from the start (in contrast, DMM and Compact mode requires extra processing and CPU cycles for allocation at runtime that would be slower). I ran my workstation this way for a few days, but I notice that running other applications caused my available memory to get lower (Photoshop, VMware w/multiple VMs, Eclipse IDE, web browsers, etc). I was concerned that Windows may decide to swap some data from memory to pagefile even though I have plenty of available RAM, so I changed Primo Ramdisk back to DMM + Compact mode. This results in Task Manager showing only 10GB of memory in use while running.

Does anyone have a measurable impact of running Primo Ramdisk with and without DMM + Compact Mode?

Thanks.
User avatar
Support
Support Team
Support Team
Posts: 3623
Joined: Sun Dec 21, 2008 2:42 am

Re: Ramdisk & Preventing Windows From Swapping

Post by Support »

Jamil wrote:My thought was that there would be no performance impact if all of this RAM was reserved from the start (in contrast, DMM and Compact mode requires extra processing and CPU cycles for allocation at runtime that would be slower).
It's right. However usually in normal secenario where CPU load is not high, there's no noticable performance difference between them.
Jamil wrote:I ran my workstation this way for a few days, but I notice that running other applications caused my available memory to get lower (Photoshop, VMware w/multiple VMs, Eclipse IDE, web browsers, etc).
Isn't it normal that applications consume available memory?
Jamil
Level 3
Level 3
Posts: 10
Joined: Fri Mar 21, 2014 12:31 am

Re: Ramdisk & Preventing Windows From Swapping

Post by Jamil »

Please let me rephrase the question to get the answer I am looking for.

Windows decides on its own to swap data from memory to my pagefile. Will PrimoRam Disk data that exists in memory be swapped to pagefile? I do not want this to happen, and there is no need for Windows to do this at all. Is Windows going to automatically do this on its own when I use my ram disk? The amount of free memory seems to have no factor on when Windows decides to swap based on my searching.

Does PrimoRam disk prevent its own used memory from being swapped out in some way? If it can do this, fantastic. If it is up to Windows on when my memory gets swapped out (even though I have plenty), this is not a good thing.
User avatar
Support
Support Team
Support Team
Posts: 3623
Joined: Sun Dec 21, 2008 2:42 am

Re: Ramdisk & Preventing Windows From Swapping

Post by Support »

Jamil wrote:Will PrimoRam Disk data that exists in memory be swapped to pagefile?
No. Memory used by ramdisks cannot be swapped out.
CrypEd
Level 6
Level 6
Posts: 71
Joined: Mon Nov 11, 2013 11:04 am

Re: Ramdisk & Preventing Windows From Swapping

Post by CrypEd »

What you are seeing is windows always swapping some OS-internal stuff (kernal) if not in use... there's no problem with it, because this should be "small chunks" that you really high likely-never need during your runtime... unneccessary kernel-hardware modules etc.

Only way known to deactivate that is to deactivate swap at all.... but by that you forcing all that to stay in RAM.

Also i wonder why you address 130 Gigabyte of swap?

I watch over swap-file with Aida 64 > Motherboard > Memory, there you find system Swap file, showing actual and maximum.

Mine is actually: 194 /208 mb.

So i put at fixed size of: 256MB... for any cases xD

Anyhow..these are basically only hardware-drivers that we don't need.


There is no problem with Primo-RAMdisk....but PrimoCache would cache the blocks of the pagefile.sys too... but doesn't matter.... there neither frequently or recently used ever, so whatever they got "literally" cached... when real app wants cache it's gonna be thrown out first.


I wonder if it might be possible to use swap on a ram-disk at all, by simply enabling it manually ... sure no sense in that. :D

For safety i assume it is best decision not "choose windows to automatically pick a swap for all device" but to setup a swap for C:\ and any other disk-drive with Apps, which is not a RAM-drive.

With enough RAM nowadays there's no real need for SWAP-files..except freeing system-RAM-usage by offloading unlikely deprecated old stuff. :D ...the ~200mb i noted above. :D
Jamil
Level 3
Level 3
Posts: 10
Joined: Fri Mar 21, 2014 12:31 am

Re: Ramdisk & Preventing Windows From Swapping

Post by Jamil »

support wrote:No. Memory used by ramdisks cannot be swapped out.
Thank you. I have changed my settings to no longer use dynamic memory. My only concern was that data on the ramdisk may be swapped out. If there is no chance of that happening, then there is no point in me paying a performance penalty with dynamic memory (regardless of how small that performance penalty may be).
Jamil
Level 3
Level 3
Posts: 10
Joined: Fri Mar 21, 2014 12:31 am

Re: Ramdisk & Preventing Windows From Swapping

Post by Jamil »

CrypEd wrote:With enough RAM nowadays there's no real need for SWAP-file
There are tons of posts all over the Internet that disagree with you.

I allow Windows to manage my swap file, because the creators of Windows are a lot smarter than both you and me combined. I trust that they designed Windows 7 correctly to handle this properly, and I don't need to second guess their judgment.
Stubi
Level 5
Level 5
Posts: 47
Joined: Tue Aug 24, 2010 12:36 pm

Re: Ramdisk & Preventing Windows From Swapping

Post by Stubi »

Without page file windows will not create memory dumps in case of a crash. Just do not wounder if you cannot find any + some applications might crash without a page file but most will work fine.
CrypEd wrote: There is no problem with Primo-RAMdisk....but PrimoCache would cache the blocks of the pagefile.sys too... but doesn't matter.... there neither frequently or recently used ever, so whatever they got "literally" cached... when real app wants cache it's gonna be thrown out first.
:D
If I remember correctly the support said that the swap file does not get cached by PrimoCache.
Post Reply