views:

1376

answers:

3

I have a VS solution that contains 6 library projects and 1 web folder project.

When I try to use the "Find All References" feature on an object or method, it takes more than 6 minutes to finish !

It seems to be refactoring every aspx & ascx file of the web project.

Any idea on how to make it faster ?

+1  A: 

That does seem slow, I have a solution with 276 projects (don't ask) and it takes less than six minutes to find references.

I started using Source Insight and found it much quicker.

Another thought, your virus checker might be interfering. Sysinternals filemon or procexp would confirm.

Ed Guiness
(it's the legacy of a hyperactive architect)
Ed Guiness
+1  A: 

I would try deleting out all your ncb files, these files sometimes get corrupted and can have many wide ranging effects. Since your feature is using them it might help, they will be automagically regenerated next time you open your solution

Alex
I was going to vote for this, but you used the "word" 'automagically'
John Sheehan
+2  A: 

You didn't mention which version of Visual Studio you are running, but I found a blurb that claims they did some performance improvements between 2005 and 2005SP1

We made a change in the VS2005 SP1 (and included it in VS 2008) which optimizes performance in web projects by first performing a lexical search of the element being refactored to determine if the page needs to be loaded. I apologize for it taking us so long to update this issue with the resolution; there were several connect bugs that were related and while we updated most we managed to miss some.

We expect that in the future we'll do even more performance enhancements for this scenario (post VS 2008), but hopefully the optimizations we have done drastically increase performance in most cases.

Also, this solution kinda sucks, but MS offered this workaround too:

With respect to workarounds you can increase the performance fairly significantly if you open all of the web pages prior to performing the refactoring. I agree that it isn't a particularly good workaround, but for VS 2005 we chose to prioritze correctness over performance for refactoring.

Source: https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=92239

JohnFx