PDA

View Full Version : Virtual Memory Word v's Photoshop




Zeiss
Feb 9, 2008, 08:10 AM
not much of a programmer, but looking at Activity Monitor and watching Virtual Memory use i noticed that Word uses more VM than Photoshop [in fact if I include the DB Daemon, Word 2004 uses over 2G of VM, just to be open]- this seems simply crazy to me, is there some bad programming here, or is it a page issue? Any ideas would be of interest...



gnasher729
Feb 9, 2008, 08:49 AM
not much of a programmer, but looking at Activity Monitor and watching Virtual Memory use i noticed that Word uses more VM than Photoshop [in fact if I include the DB Daemon, Word 2004 uses over 2G of VM, just to be open]- this seems simply crazy to me, is there some bad programming here, or is it a page issue? Any ideas would be of interest...

Fact is that the "Virtual Memory" number in Activity Monitor is altogether absolutely completely irrelevant to anything and means nothing at all. It is like saying your car uses 20,000 gallons of petrol because someone has figured out that if you manage to drive your car for 400,000 miles and drive it uphill all the time at 20 miles per gallon, it will use 20,000 gallons.

numero
Feb 9, 2008, 04:00 PM
Not really up on the current version. In the OS 9 days Photoshop used its own VM system. It didn't rely on the OS. Given how much legacy code is in PhotoShop and that they have to be cross-platform, I'd be that they still do their own VM. So the numbers reported in Activity Monitor aren't relevant in this case.

As the previous poster pointed out. Who cares and what are you really going to do about it? It is what it is. There are things a developer can do about it, but they won't go to that bother unless their user base finds the memory requirements to be unreasonable.

Catfish_Man
Feb 9, 2008, 04:27 PM
To be more specific about what virtual memory actually measures, it measures the range of memory addresses that are available to that process. So if the process mmap()s a 1GB file, its virtual memory size will increase by 1GB, but without any corresponding increase in physical memory usage or swap usage.

Other causes include shared libraries (only one copy of Cocoa is loaded, but it shows up in the address space of each Cocoa app), and (for 64 bit apps) the 4GB that the kernel maps into each process.