C Board  

Go Back   C Board > Community Boards > Tech Board

Closed Thread
 
LinkBack Thread Tools Display Modes
Old 01-11-2008, 08:34 AM   #1
Registered User
 
Join Date: May 2006
Posts: 1,579
Still confused why working set larger than virtual memory

Hello everyone,


Sorry that this question is related to another question I posted some time before because I have some new findings and self-analysis.

My question is why sometimes from perfmon on Windows, working set larger than virtual memory? I think virtual memory is the total size of memory (committed, reserved, shared, private) and working set is just the RAM touched by current process currently. Virtual memory should always larger than working set...

But, I write a simple program to show working set is larger than virtual memory from perfmon. The program is simple, just open a couple of memory map files and read from beginning to the end.

The only reason I could think of why working set sometimes is larger than virtual memory is, the OS memory management component may not reclaim some RAM consumed by current process even if the current process does not use the RAM. And keeping such RAM could improve performance if the process will use it in the future. But this point makes me confused because I think if it is true, such RAM does not have related virtual memory address, how could the current process utilize or even address (re-use to avoid hard page fault) it in the future?


thanks in advance,
George
George2 is offline  
Old 01-11-2008, 08:38 AM   #2
C++ Witch
 
laserlight's Avatar
 
Join Date: Oct 2003
Location: Singapore
Posts: 11,339
I have moved this thread to the Tech board as it does not seem to be specific to C++ programming.
__________________
C + C++ Compiler: MinGW port of GCC
Build + Version Control System: SCons + Bazaar

Look up a C/C++ Reference and learn How To Ask Questions The Smart Way
laserlight is offline  
Old 01-11-2008, 01:12 PM   #3
Algorithm Dissector
 
iMalc's Avatar
 
Join Date: Dec 2005
Location: New Zealand
Posts: 2,737
I've never seen the working set larger than the virtual size. At this stage I'm inclined to be struck with disbelief.
Care to post some numbers?
What operating system?
__________________
My homepage
Advice: Take only as directed - If symptoms persist, please see your debugger
iMalc is offline  
Old 01-13-2008, 02:13 AM   #4
Registered User
 
Join Date: May 2006
Posts: 1,579
Hi iMalc,


I am using Windows Server 2003. I watch the working set and virtual bytes counter from perfmon of iexplorer process (IE7 browser).

It is usually the size of working set of larger than that of virtual bytes. I have uploaded the screen snapshot for your reference. It is appreciated if you could share some perspective. :-)

Quote:
Originally Posted by iMalc View Post
I've never seen the working set larger than the virtual size. At this stage I'm inclined to be struck with disbelief.
Care to post some numbers?
What operating system?

regards,
George
Attached Images
 
George2 is offline  
Old 01-13-2008, 02:14 AM   #5
Registered User
 
Join Date: May 2006
Posts: 1,579
Thanks laserlight,


Quote:
Originally Posted by laserlight View Post
I have moved this thread to the Tech board as it does not seem to be specific to C++ programming.

regards,
George
George2 is offline  
Closed Thread

Thread Tools
Display Modes

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Virtual Memory utilization during run-time wots_guge C Programming 2 04-13-2006 08:17 PM
virtual memory sweets C Programming 6 11-06-2004 06:55 AM
Virtual functions not working VanJay011379 C++ Programming 2 07-25-2002 12:12 PM
opengl code not working Unregistered Windows Programming 4 02-14-2002 10:01 PM
C++ XML Class edwardtisdale C++ Programming 0 12-10-2001 11:14 PM


All times are GMT -6. The time now is 05:33 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22