VS 2003 Sloooow Debugging

  • Thread starter Thread starter John E Katich
  • Start date Start date
J

John E Katich

I'm just getting into VC++ managed code (VS 2003). Using the App Wizard I
build a VC++ .NET Console Application. When I press F5 it takes 30 seconds
to get to the Console::Writeline().



MFC or WIN32 Console App is Sub-Second response time.



Is .NET really this sloooow or have I got something wrong?
 
John said:
I'm just getting into VC++ managed code (VS 2003). Using the App
Wizard I build a VC++ .NET Console Application. When I press F5 it
takes 30 seconds to get to the Console::Writeline().



MFC or WIN32 Console App is Sub-Second response time.



Is .NET really this sloooow or have I got something wrong?

Make sure you're not using "mixed mode debugging". If you are, change your
debugger type to "managed only". The mixed-mode debugger is heinously slow.

-cd
 
Yep, had it set to Auto...

What does one do if mixing legacy MFC classes with new managed stuffed? Or,
is that a no-no?

JEK
 
John said:
Yep, had it set to Auto...

What does one do if mixing legacy MFC classes with new managed
stuffed? Or, is that a no-no?

One has a hard time debugging it :|

Serioiusly though, I'd endeavor to separate your managed and native
development as much as possible so that you don't have a lot of mixed-mode
code. Then you have a reasonable chance of debugging some components with
the managed debugger and others with the native debugger, wandering into the
mixed-mode debugger only when you absolutely have to.

I've heard that the performance of the mixed-mode debugger is much better
under VC 2005, but I haven't verified that myself.

-cd
 
Hi John,

To debug a mixed-mode application, the evaluation of properties by the
VS.NET 2003 debugger is an expensive operation. So the debugging operations
such as stepping may appear slow.

If you have consern about the poor performance in mixed-mode debugging, you
may want to turn off property evaluation in the debugger windows. To turn
off property evaluation. you can do the following steps inside the VS2003
IDE:

1. From the Tools menu, choose Options.
2. In the Options dialog box, open the Debugging folder and select the
General category.
3. Clear the Allow property evaluation in variables windows check box.


Thanks!

Best regards,

Gary Chang
Microsoft Community Support
--------------------
Get Secure! ¡§C www.microsoft.com/security
Register to Access MSDN Managed Newsgroups!
http://support.microsoft.com/default.aspx?scid=/servicedesks/msdn/nospam.asp
&SD=msdn

This posting is provided "AS IS" with no warranties, and confers no rights.
 
Carl said:
One has a hard time debugging it :|

Serioiusly though, I'd endeavor to separate your managed and native
development as much as possible so that you don't have a lot of mixed-mode
code. Then you have a reasonable chance of debugging some components with
the managed debugger and others with the native debugger, wandering into the
mixed-mode debugger only when you absolutely have to.

I've heard that the performance of the mixed-mode debugger is much better
under VC 2005, but I haven't verified that myself.

-cd
Startup is > 5x faster; single step is about 10x faster.

Ronald Laeremans
Visual C++ team
 
Back
Top