Red Gate forums :: View topic - Increased memory usage of SL app when using ANTS?
Return to RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
ANTS Memory Profiler 7
ANTS Memory Profiler 7 forum

Increased memory usage of SL app when using ANTS?

Search in ANTS Memory Profiler 7 forum
Post new topic   Reply to topic
Jump to:  
Author Message

Joined: 29 Nov 2011
Posts: 6

PostPosted: Thu Dec 01, 2011 11:12 pm    Post subject: Increased memory usage of SL app when using ANTS? Reply with quote

The total memory usage of my app is higher (by observing task manager) when using ANTS than when launching the SL app by itself.

The difference is significant. I am looking at the difference between 2 snapshots and when using ANTS that difference is around 30 MB, but only 15 MB without ANTS.
Back to top
View user's profile Send private message

Joined: 17 Aug 2006
Posts: 137

PostPosted: Mon Dec 05, 2011 12:22 pm    Post subject: Reply with quote

Task manager displays 'working set', which is not the same as 'total memory usage': it can be higher or lower depending on what's going on in your application. Working set is the amount of active physical RAM being used by the application and can include things like file buffers, shared libraries and other things that you might not consider to be a part of your applications 'true' memory usage. It can also go down when your application is paging (which means that as memory usage goes up, the task manager reading can actively go down!)

ANTS uses about 20Mb of memory for the purposes of tracking how objects move between snapshots, plus an unbounded amount of memory that is proportional to the number of objects that are disposed but still in memory. Most of ANTS memory usage is actually in shared memory, so shouldn't show up in private bytes. This probably explains the difference that you're seeing. A certain amount of ANTS own memory usage winds up in the 'unmanaged memory' section of the results as well, though the shared memory does not.

'Total memory usage' is a somewhat nebulous concept in Windows: private bytes are the closest approximation to what most people would consider to be the memory usage of an application (that's the amount of memory allocated exclusively by that application). However, 'out of memory' conditions aren't actually triggered by the amount of used memory, but the amount of used address space, and Windows doesn't really have a good measurement of this - virtual bytes is the closest measurement, but note that it will appear really high, especially on 64-bit systems as .NET will reserve large regions of memory for itself without actually allocating anything.
Andrew Hunter
Software Developer
Red Gate Software Ltd.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB © 2001, 2005 phpBB Group