views:

96

answers:

2

I recently added about a dozen classes from another solution into my current solution in Visual Studio. After adding these classes, Visual Studio started freezing for about 10 seconds whenever I Save. The cursor disappears and mouse clicks and keys do nothing.

Some interesting points:

  • Even after I removed the classes, the freezing behavior is still there.

  • Freezing occurs whether I've made changes to the code or not.

  • This behavior ONLY seems to affect this particular version of this solution. No other solutions exhibit this behavior. Older versions of this solution are not affected.

  • In Sysinternals Process Explorer, whenever I save in Visual Studio, the I/O bytes graph jumps from 0 to 2MB for about 5 seconds, then drops to about 1 MB for a split second, then jumps back to 2MB for another 5 seconds. Processor use goes up to about 3-5% during this time.

Here are the details of my setup:

C# Silverlight project (maybe 20 classes), .NET version 3.5 SP1, Visual Studio 2008 v9.0.30729 SP1.

EDIT:

I edited this question extensively to reflect the more detailed information. I thought this might be preferable to starting a new question.

A: 

I can't be sure if it's the same issue, but I've experienced similar slowdowns because of the Windows Forms Designer. I fixed this by going to

Tools --> Options --> Windows Forms Designer

and turning AutoToolboxPopulate to off. It's a longshot, but you might as well give it a try. Also, one thing I do for larger solutions is compile from the command line instead of in visual studio. You just need to open a Visual Studio Command Prompt and use msbuild (solution name | project name). You can also use /m for multicore compilation.

manu08
A: 

I had a similar issue, this did the trick: http://support.microsoft.com/kb/946344 titled 'You may experience performance issues in the IDE after you use Visual Studio 2008 to build a Visual Basic project'

Designysis
Yeah, unfortunately, I'm using C#, and the hotfix is specifically for VB. Also, I'm not using lots of XML comments, and the slowdown happens right AFTER compilation. Thanks for the help, though.
Klay