This app I'm working on seems to just have a huge footprint and GC doesn't seem to do it's job properly:
Most pages aren't too big, but there are some that have a datagrid in it with 100+ columns and 1000+ rows (should the user choose those options); so granted, it should take a lot of memory to render all of that, but it can peak up to around 300MB with a single user - which just seems insane. GC will come along and drop it to 140M at best on it's on. If I explicitly GC on the end of every page (regardless of the page) my footprint can drop down to 80M at best and never gets over 220M between postback and render (before I explicitly call GC).
Something seems very wrong about this. Why if I explicitly call GC over and over again I can free up more memory than if I let GC work on its own. I know it's not a good idea to manually call GC so obviously there's a problem that needs to be fixed. This app is very large, so I can accept the footprint not droping below 80M if there's a valid reason - but I just can't see one... we never load 'all' the classes in one trip to the server, at that's the only way I can see it getting that large.
I wish there was a way (and maybe there is and I just don't know about it) to view the objects in memory so I could determine what's taking up all the space. I've noticed most of the memory chunk gets created during render (understandably), but it seems like part of that chunk gets left over and never gets cleaned up, like large datagrids aren't being disposed when the page is disposed or something.
Any tools or advice for analyzing this type of thing would be great to know about.
Thanks.
Most pages aren't too big, but there are some that have a datagrid in it with 100+ columns and 1000+ rows (should the user choose those options); so granted, it should take a lot of memory to render all of that, but it can peak up to around 300MB with a single user - which just seems insane. GC will come along and drop it to 140M at best on it's on. If I explicitly GC on the end of every page (regardless of the page) my footprint can drop down to 80M at best and never gets over 220M between postback and render (before I explicitly call GC).
Something seems very wrong about this. Why if I explicitly call GC over and over again I can free up more memory than if I let GC work on its own. I know it's not a good idea to manually call GC so obviously there's a problem that needs to be fixed. This app is very large, so I can accept the footprint not droping below 80M if there's a valid reason - but I just can't see one... we never load 'all' the classes in one trip to the server, at that's the only way I can see it getting that large.
I wish there was a way (and maybe there is and I just don't know about it) to view the objects in memory so I could determine what's taking up all the space. I've noticed most of the memory chunk gets created during render (understandably), but it seems like part of that chunk gets left over and never gets cleaned up, like large datagrids aren't being disposed when the page is disposed or something.
Any tools or advice for analyzing this type of thing would be great to know about.
Thanks.