virtual memory with 16gb ram installed

Status
Not open for further replies.
I am just trying to keep it simple, give me a break?

If you look in the windows system settings, under virtual memory it only refers to the page file, even there it just says "Virtual memory, A paging file is an area on the hard disk that Windows uses as if it were RAM". This makes it sound like its extra to me, are you going to say that Windows makes no sense too now?

A 64bit machine with 8GB ram and a 2GB swap file does not have 16 exbibytes available as virtual memory. It has 10GB available, 8GB in the system memory and 2GB on the hard drive.

Also you can have more than 4GB virtual memory on a 32bit system, you could have 4GB ram and a 100GB swap file giving 104GB virtual memory, the limitation applies to a program only being able to address 4GB of it, you could have 20 programs using 4GB each on a 32bit system.

Virtual memory speed depends on the type of media being accessed, its going to stay fairly fast if you only address as much as you have system memory, after the system memory has run out of space, it will depend on the speed of the drive the swap file is residing on, whether its a SSD or a mechanical drive, it will be "slow, cheap, second class, additional, reserve or whatever" compared to the speeds you get addressing the RAM part of the virtual memory. Look up thrashing if you want a worst case scenario of slow Virtual memory.
 
This makes it sound like its extra to me
You may find the following article by Mark Russinovich worth a read...

Pushing the Limits of Windows Virtual Memory - Mark's Blog

Virtual memory separates a program’s view of memory from the system’s physical memory, so an operating system decides when and if to store the program’s code and data in physical memory and when to store it in a file. The major advantage of virtual memory is that it allows more processes to execute concurrently than might otherwise fit in physical memory.

While virtual memory has limits that are related to physical memory limits, virtual memory has limits that derive from different sources and that are different depending on the consumer. For example, there are virtual memory limits that apply to individual processes that run applications, the operating system, and for the system as a whole. It's important to remember as you read this that virtual memory, as the name implies, has no direct connection with physical memory. Windows assigning the file cache a certain amount of virtual memory does not dictate how much file data it actually caches in physical memory; it can be any amount from none to more than the amount that's addressable via virtual memory.

[...]

How Big Should I Make the Paging File?
Perhaps one of the most commonly asked questions related to virtual memory is, how big should I make the paging file? There’s no end of ridiculous advice out on the web and in the newsstand magazines that cover Windows, and even Microsoft has published misleading recommendations. Almost all the suggestions are based on multiplying RAM size by some factor, with common values being 1.2, 1.5 and 2. Now that you understand the role that the paging file plays in defining a system’s commit limit and how processes contribute to the commit charge, you’re well positioned to see how useless such formulas truly are.

Since the commit limit sets an upper bound on how much private and pagefile-backed virtual memory can be allocated concurrently by running processes, the only way to reasonably size the paging file is to know the maximum total commit charge for the programs you like to have running at the same time. If the commit limit is smaller than that number, your programs won’t be able to allocate the virtual memory they want and will fail to run properly.

See also...

Any benefit or detriment from removing a pagefile on an 8GB RAM machine? - Server Fault
RIP Swapfile? - Ars Technica
 
1 - Monitor your commit charge and set the pagefile to match. (Mostly used on an optimized server/workstation)
2 - Turn off the pagefile. (Usually fine for home systems/gaming rigs, can break crash logs)
3 - Leave it on system managed. (Works in all situations, allocates disc space needlessly)
4 - Set it to some arbitrary value. (Saves disc space, allows crash logs to work)

Pick one.
 
If you look in the windows system settings, under virtual memory it only refers to the page file, even there it just says "Virtual memory,

In the context of system committed virtual memory. The paging file has an impact on something known as the system commit limit. This limit represents the maximum amount of virtual memory, which has to be backed by physical memory or stored in the paging file, processes can allocate at any one time. It is the sum of the physical memory of the system plus the size of the paging file(s).

A paging file is an area on the hard disk that Windows uses as if it were RAM".

That isn't really what the paging file is there for and is possibly where the misconception that it's only there too support the user when they're running low on physical memory derives from. The purpose of the paging file is so the system has somewhere to write pages which are not already otherwise backed by files on disk. This includes things like exe's and dll's, which when removed from memory are simply ejected. They don't need to be saved to disk because they can always be retrieved from their original file location.

This is opposed to process private virtual memory, for instance. When a process is born and creates some private virtual memory, if that data needs to be ejected from memory, the only place it can be written too is the paging file, where it can then be retrieved at a later date if necessary. This is why it makes sense to have a paging file. It enables the system to be able to write processes private data out to disk which then free's up that memory for other, much more useful purposes.

As far as sizing the paging file, and assuming you're going to manually set a specific size, your best bet is following the advice which Arthur17 has posted in his post here by Mark Russinovich. I created a thread quite a while ago regarding this subject, which can be found here, if you're interested. That is my understanding of things anyway. There are also some links at the bottom of my second post to a couple of videos and articles regarding Windows Memory Management, one of which has already been posted in this thread by Arthur17. :)
 
I am just trying to keep it simple, give me a break?

If you look in the windows system settings, under virtual memory it only refers to the page file, even there it just says "Virtual memory, A paging file is an area on the hard disk that Windows uses as if it were RAM". This makes it sound like its extra to me, are you going to say that Windows makes no sense too now?
It's not a good idea to try to understand computer science based upon some GUI design in Windows. Those configuration screens are a facade over something far more complex than you can imagine.

A 64bit machine with 8GB ram and a 2GB swap file does not have 16 exbibytes available as virtual memory. It has 10GB available, 8GB in the system memory and 2GB on the hard drive.
The virtual memory address space remains constant. The amount of memory that a system can commit itself to delivering is of course dependent upon how much RAM you have and the size of your page file. This does not alter the fact that each process on a system is shown a full 32 or 64-bit VM address space as though it were all available. It's only when that process tries to take the mick that the OS will eventually start throwing "Out of Memory" exceptions back to that process.

Also you can have more than 4GB virtual memory on a 32bit system, you could have 4GB ram and a 100GB swap file giving 104GB virtual memory, the limitation applies to a program only being able to address 4GB of it, you could have 20 programs using 4GB each on a 32bit system.
No, you'd still only have 4GB of virtual memory. But you'd have 104GB of committable memory. Each process would still only be able to allocate up to 4GB of the available amount. This is the fundamental thing you don't seem to understand. The virtual memory size is constant. It is not the thing that you think it is. This is where all your confusion is coming from.

Virtual memory speed depends on the type of media being accessed, its going to stay fairly fast if you only address as much as you have system memory, after the system memory has run out of space, it will depend on the speed of the drive the swap file is residing on, whether its a SSD or a mechanical drive, it will be "slow, cheap, second class, additional, reserve or whatever" compared to the speeds you get addressing the RAM part of the virtual memory. Look up thrashing if you want a worst case scenario of slow Virtual memory.

You're displaying a distinct lack of ability to learn. I've already said that the way in which you're using the word "virtual memory" is inherently incorrect, so why do you keep on doing it? Virtual memory is nothing but a construct provided by the CPU and OS. It is neither RAM nor Page File. It is the middle layer that enables pages of memory to be swapped between those two storage mediums at all in the first place. It is the mechanism through which processes can be tricked into believing they're not sharing the machine with other processes, it enables process isolation and sand boxing to a level that was not possible when running the CPU in "real mode". Try thinking of "virtual memory" in the same way you do about "virtual machines". It's all about isolation, separation and sharing of resources.
 
Last edited:
No, you'd still only have 4GB of virtual memory. But you'd have 104GB of committable memory. Each process would still only be able to allocate up to 4GB of the available amount.

I thought the max memory a process could address is 2GB under 32 bit windows or that incorrect?
 
In 32bit land you can address a maximum of 2^32 bytes. (4.2 billion unique locations)
This is shared with the Windows Kernel. So the application and the OS together can share a maximum of 4GB.

I think Windows reserved 2GB for the kernel. Later on they allowed you to reduce this footprint with special flags but the kernel and app are still limited to 4GB in total.
 
Last edited:
I thought the max memory a process could address is 2GB under 32 bit windows or that incorrect?

There was an implementation detail on 32-bit Windows NT kernels where the 4GB VM space per process is split (by default at least) 50:50 between the kernel mode space of that process versus its user mode space. There was a boot manager setting to change this split to 3GB user/1GB kernel but it was rarely used.

Most processes are very light on kernel mode memory usage, therefore it was always considered wasteful that the Windows kernel was designed in this way. Microsoft agreed but x64 came along before they could be bothered to fix it. And the rest is history.
 
Last edited:
I game, photo edit and video trim and this machine is on 24/7. Pagefile is set 800MB-2048MB and currently sits at 800MB allocated (SSD). When I game I minimise Photoshop and Lightroom. I could set it fixed to 800MB and it would be no different.

I have 16GB RAM, the PC never crashes and never slows down.

Manually set it to a low figure >>> Have ice cream.
 
Microsoft uses the term "virtual memory" all over the place when talking about the page file. On their website, in their OS, etc. Reading the question leaves no doubt about what it means in this context. So why give the guy such a hard time about it?
 
Personally, I set mine to System Managed on the Ssd, taking up 16gb.

I have a 64gb ssd, so plenty of space left.

Another viable option.. Set it to 1-2gb on the ssd and system managed on the hard drive. This way, you'll never get out of memory messages. And get the added ssd performance for the most part
 
Microsoft uses the term "virtual memory" all over the place when talking about the page file. On their website, in their OS, etc. Reading the question leaves no doubt about what it means in this context. So why give the guy such a hard time about it?

Take it up with Microsoft then. No point having a discussion about a technical concept with woolly and imprecise language making it difficult to understand the correct context.
 
Is this an architectural question about how memory management works? No.

If you are so strict about it, you failed in post #3.

If you look back, not even NathanE is being precise when he talks about protected mode.
 
Last edited:
Is this an architectural question about how memory management works? No.

If you are so strict about it, you failed in post #3.

If you look back, not even NathanE is being precise when he talks about protected mode.

It turned into that after Post #3.

Now pipe down.
 
The question was: "is it advised to keep all 16gb of virtual memory or can i reduce it to a sensible size to save space on ssd."

Your answer was: "The other option is to move it at the default size to a mechanical hard drive. "

You did not use the term "page file" anywhere. Your answer was pointed to "virtual memory". Why should I pipe down? This entire thread - from the point where it derailed - is just ridiculous.
 
I know what I wrote - it's still above, plus I've got a decent memory. A rant about how he's defined the concept wrong then loads of proof from my Computer Science degree books on the Intel 386 design would definitely have been the way to go. :rolleyes:

How foolish of me to try and help the bloke out.

Your troll cave is that way. ->
 
Status
Not open for further replies.
Back
Top Bottom