Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Hi all sometimes I run photoshop along with a ton of Chrome tabs and a couple of other programs and my memory looks dangerously near to my 7.99 GB of virtual memory.

I was wondering what happens when a program allocates more memory then my virtual memory allows? Does it mean that my computer will simply BSOD itself?

Or can I guarantee that even though the program that requires the additional memory would crash, the OS will be stable (no BSODs) ?

share|improve this question
add comment

2 Answers

up vote 6 down vote accepted

Depending on the OS, its configuration, and possibly other things, one of the following will happen:

  • The OS will increase the paging file size and move unused processes to it. (Windows will do this; Linux cannot, as it usually uses a fixed-size partition for historical reasons.)
  • The OS will start killing other processes to free up memory. (Linux, or Windows without a pagefile, do this.)
  • The OS will kill the offending process.
  • The memory allocation will simply fail, causing the process to crash sooner or later (not sure if any OS behaves like this).

Simply running out of memory should never cause a BSOD, which is only for unrecoverable situations.

share|improve this answer
1  
Hmm, when I open a very large image with photoshop (scanned picture, about 12000x50000), everything just hanged and suddenly the computer BSOD itself. What may be the problem? –  Pacerier Nov 25 '11 at 10:54
2  
I think Windows actually behaves like point 4, i.e. memory allocation call can fail but the program doesn't have to be killed immediately. Windows reserved a non-paged pool for kernel use, so normally it won't crash because of low memory. However, some drivers can allocate paged memory and if they're poorly written, can cause an exception in kernel mode which triggers BSoD. However, this can be automatically checked and I bet Microsoft checks for it during driver certification. –  billc.cn Nov 25 '11 at 10:58
1  
@billc.cn: Driver writers manage to cheat even the WHQL -- and that's assuming they do get their drivers certified, as opposed to just auto-clicking the unsigned driver approval dialog. –  grawity Nov 25 '11 at 22:26
add comment

Your virtual memory is limited by the maximum size of your paging file. This defaults to be managed by the operating system and will grow as is needed, so you will probably only run out when your hard disk is full.

You can check to see whether you are using these settings or whether they have been changed via

Right-Click on my My-Computer and select properties.
Advanced system settings.
Advanced
Settings (on performance section)
Advanced
Change (on Virtual Memory section)

When windows gets close to the limit, it will display a warning and recommend that you close some of the programs that are using the most memory.

If you ignore these errors and your system continues to use more memory, then eventually some program will try to allocate memory which will fail. What happens next depends on the program, ie if the program is specifically written to cope with that request being denied, it will fail cleanly, otherwise it may simple crash.

For example, if you try to open another large file in PhotoShop, it may display a message saying that it can't open it because the system does not have enough memory but still allow you to continue to work with the files you are already working on. But if you are totally out of memory, you may not have enough free to display this message and maybe not enough to display the message asking you if want to save your files when you try to close.

So, in my experience, there are just too many things that fail badly when you get to this point, that you are really should heed the warning, but even if you ignore it, you certainly should not expect a BSOD.

share|improve this answer
    
But for my situation everything just sort of hanged I can't even Ctrl Alt Del. and then the computer just BSOD itself.. what may be the problem? –  Pacerier Nov 25 '11 at 12:14
    
It is possible that it could be a hardware issue, so I would run some tests on the memory just to make sure that is ok. But it is more likely to be a buggy device driver. I think you need to try the decode the information on the BSOD which may help determine which driver is causing the BSOD. The BSOD/Stop info should be recorded in your event log if you haven't already got a note of it. –  sgmoore Nov 25 '11 at 13:23
    
ok thanks for the help =) –  Pacerier Nov 25 '11 at 14:19
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.