Tips for Debugging Threads in Native Code
This article applies to Visual Studio 2015. If you're looking for the latest Visual Studio documentation, use the version selector at the top left. We recommend upgrading to Visual Studio 2019. Download it here
Here are some tips you can use when debugging threads in native code:
You can view the contents of the Thread Information Block by typing
@TIBin the Watch window or QuickWatch dialog box.
You can view the last error code for the current thread by entering
@Errin the Watch window or QuickWatch dialog box.
C Run-Time Libraries (CRT) functions can be useful for debugging a multithreaded application. For more information, see _malloc_dbg.