visual studio memory utilization?


B

BillE

I am using Visual Studio 2008 version 9.0.30729.1 SP

I have a solution with about 25 c# and vb projects in it - these include web
projects, business classes, windows forms projects. These projects all
share business classes.

When I start Visual Studio, the memory usage for devenv.exe is about 20
megabytes in Task Manager.

When I load my solution, the memory usage increases rapidly to over 400
megabytes, and then gradually increases to well over 500 megabytes.

Of course performance is poor, and I assume that something is wrong, but I
don't know where to look.

Thanks
Bill
 
Ad

Advertisements

G

Gregory A. Beamer

BillE said:
I am using Visual Studio 2008 version 9.0.30729.1 SP

I have a solution with about 25 c# and vb projects in it - these include
web projects, business classes, windows forms projects. These projects
all share business classes.

When I start Visual Studio, the memory usage for devenv.exe is about 20
megabytes in Task Manager.

When I load my solution, the memory usage increases rapidly to over 400
megabytes, and then gradually increases to well over 500 megabytes.

Of course performance is poor, and I assume that something is wrong, but I
don't know where to look.

Check the order of loading of references under solution properties and
ensure the shared libraries are at the bottom. Also try to avoid hierarchies
like this (although you can work that way, if you are willing to tweak the
libraries and compilation):

A
|\
| \
| \
B->C

if you have too many of the above situations (both parent and child calling
a child), you might end up having to compile the B and C classes and use the
references rather than have them compile as part of a solution.

As far as where to look, if you don't have a clue, try looking at one of the
projects that does dependency models, like Lattix or nDepend.

--
Peace and Grace,
Greg

Twitter: @gbworld
Blog: http://gregorybeamer.spaces.live.com

************************************************
| Think outside the box! |
************************************************
 
P

Peter Duniho

BillE said:
I am using Visual Studio 2008 version 9.0.30729.1 SP

I have a solution with about 25 c# and vb projects in it - these include web
projects, business classes, windows forms projects. These projects all
share business classes.

When I start Visual Studio, the memory usage for devenv.exe is about 20
megabytes in Task Manager.

When I load my solution, the memory usage increases rapidly to over 400
megabytes, and then gradually increases to well over 500 megabytes.

Of course performance is poor, and I assume that something is wrong, but I
don't know where to look.

I would look at your solution that has TWENTY-FIVE PROJECTS in it!

Given what you're handing it, 500MB sounds like a reasonable number.
That's only 20MB per project, and when you figure how much RAM is
required to support Intellisense, open files, etc. for each project that
doesn't sound too unreasonable. Visual Studio does have a tendency to
be a memory hog sometimes, and your usage pattern is making that show up
in a big way.

I'd recommend you refactor your projects so that they aren't all clumped
together like that. No one can possibly work on 25 projects
simultaneously anyway. By breaking them up into multiple small
solutions, and keeping multiple instances of VS open but just for the
few solutions you're working on at a time, you should be able to
dramatically reduce total memory usage.

Pete
 
M

Mr. Arnold

BillE said:
I am using Visual Studio 2008 version 9.0.30729.1 SP

I have a solution with about 25 c# and vb projects in it - these include web
projects, business classes, windows forms projects. These projects all
share business classes.

When I start Visual Studio, the memory usage for devenv.exe is about 20
megabytes in Task Manager.

When I load my solution, the memory usage increases rapidly to over 400
megabytes, and then gradually increases to well over 500 megabytes.

Of course performance is poor, and I assume that something is wrong, but I
don't know where to look.

If the performance is poor, then set the O/S Virtual Page size to
"System Managed" that way the the O/S controls it.

If the VP size is too small on a default setting on the install of the
O/S, then you're going to have performance issues with VS.
 
M

Mr. Arnold

Peter said:
I would look at your solution that has TWENTY-FIVE PROJECTS in it!

Given what you're handing it, 500MB sounds like a reasonable number.
That's only 20MB per project, and when you figure how much RAM is
required to support Intellisense, open files, etc. for each project that
doesn't sound too unreasonable. Visual Studio does have a tendency to
be a memory hog sometimes, and your usage pattern is making that show up
in a big way.

I'd recommend you refactor your projects so that they aren't all clumped
together like that. No one can possibly work on 25 projects
simultaneously anyway. By breaking them up into multiple small
solutions, and keeping multiple instances of VS open but just for the
few solutions you're working on at a time, you should be able to
dramatically reduce total memory usage.

You ever seen a ASP.Web solution with over 70 projects or more in it. 25
projects? 25 projects is nothing.
 
A

Arne Vajhøj

You ever seen a ASP.Web solution with over 70 projects or more in it. 25
projects? 25 projects is nothing.

25 is not that much.

And most likely this developer is only working on a few of them, but
need the entire solution for reference, test and debugging.

Arne
 
Ad

Advertisements

J

Jeff Johnson

25 is not that much.

And most likely this developer is only working on a few of them, but
need the entire solution for reference, test and debugging.

Bingo. I far prefer project references to DLL references so I can debug
anything I might want to, so I always work with "large" solutions if
possible. I can totally see the OP's point of view.

And I should add, that's about the memory utilization I see, too, so BillE,
I wouldn't worry too much about it. Just don't develop on a machine with
128MB of RAM!
 
Ad

Advertisements

B

BillE

Thanks for the input.
Bill

Jeff Johnson said:
Bingo. I far prefer project references to DLL references so I can debug
anything I might want to, so I always work with "large" solutions if
possible. I can totally see the OP's point of view.

And I should add, that's about the memory utilization I see, too, so
BillE, I wouldn't worry too much about it. Just don't develop on a machine
with 128MB of RAM!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top