Задайте вопросЗадайте вопрос
 

Общие обсужденияVisual Studio 2008 SP1 Stepping and Breakpoint Issues

  • 22 октября 2008 г. 2:53Brad SullivanMSFT, ВладелецМедали пользователяМедали пользователяМедали пользователяМедали пользователяМедали пользователя
     
     

    Last Update: 10/21/2008

    Many of you have reported the issue documented at http://social.msdn.microsoft.com/Forums/en-US/vsdebug/thread/c800abbc-5a67-4c43-bf61-e6d86f48658b and we thank you for that.  The details provided are helping us understand and ultimately fix the problem.  
     

    This issue may impact you if ALL of the following conditions are met:

    -          You have Visual Studio 2008 with SP1 installed

    -          You are developing a managed language project (C#, VB, etc)

    -          Your project makes use of multiple threads

    -          You are debugging your project on a multi-processor or multi-core machine

     

    The potential symptoms include:

    -          When stepping through your project, sometimes your application continues running when it should have stepped.

    -          When stepping through your project, sometimes breakpoints that should be hit are not.

     

    The first available fix is now here as part of Microsoft Silverlight Tools for Visual Studio 2008 SP1 (RC1).
    http://www.microsoft.com/downloads/details.aspx?FamilyId=c22d6a7b-546f-4407-8ef6-d60c8ee221ed
    This package will revert some debugger behavior back to that of the original release, while still maintaining the rest of the updates that went into SP1.

    A stand-alone fix is also under development and will be made available as soon as possible.

    If you do not want to install Silverlight Tools, there is an alternative work around that may eliminate these issues for you until the stand-alone fix is ready.
    Workaround:

    1)      Open Visual Studio but do not open any projects.

    2)      Start the Task Manager (Ctrl+Shift+Esc) and navigate to the “Processes” tab.

    3)      Right-click on devenv.exe and select “Set Affinity…” (this option is only available on multi-processor or multi-core machines).

    4)      Uncheck every CPU except one and click OK.

    5)      Open your project and debug as normal.

     

    Workaround notes and limitations:

    -          If you restart Visual Studio, you will have to repeat these steps.

    -          If you are attaching to a process to debug, you should perform the above steps on your target process before attaching Visual Studio.  (If you are debugging foo.exe, change the affinity on foo.exe.)

    -          If you are specifically testing or debugging your process to see how it works on a multi-core or multi-processor system, this workaround will not be sufficient since it forces your process to use a single processor or core when executing.
    -       Will not work on single-core machines that can run multiple threads simultaneously (e.g. Perntium 4 with Hyperthreading)

     

    Once again, please check back here regularly as we will update this posting when a fix is available.

     

    Thank you!

    The Visual Studio Debugger Team

     


    Brad Sullivan - Program Manager - Visual Studio Debugger

Все ответы