I have a program which does some very intensive graphics work, and requires a lot of memory (> 8GB), however my machine has only 8GB of RAM currently, which means the program throws a bad alloc when it runs out of memory.
Besides this program, I had some other things open that used a bit of my main memory, but mostly it was only the program eating memory.
Now, I wondered why the system throws a bad_alloc
when it gets to > 8GB of memory usage, instead of page faulting and swapping out some pages? Isn't that one of the problems that paging and virtual memory is supposed to solve?
I should be able to run my program that requires > 8GB memory, if it were to just page out not recently accessed pages, to be able to create new pages for the required memory.
Can anybody give an explanation?
My machine has a 8GB page file.