Mixed mode assembly not loading symbol for native C++ pdbs

后端 未结 1 1460
孤街浪徒
孤街浪徒 2021-01-18 03:57

I am working with mixed mode assemblies in C++/CLI. All managed mode assembled pdb\'s get loaded when successfully in mixed mode assembly, but native dll\'s and pdb\'s are n

相关标签:
1条回答
  • 2021-01-18 04:32

    Mixed-mode debugging can be hit and miss, mostly miss. First check that you've actually have mixed-mode debugging enabled. From a C# project, it is Project + Properties, Debug, Enabled unmanaged code debugging check box. Next, mixed-mode debugging is not enabled for 64-bit processes. If you run on a 64-bit operating system, make sure you force the .exe to run in 32-bit mode. Project + Properties, Build tab, Platform Target = x86.

    Next verify where the debugger looked for the .pdb files. From the Debug + Windows + Modules window, right-click the DLL and select "Symbol load information". Final gasp is to use __debugbreak() in the unmanaged code.


    UPDATE: Recent versions of VS (starting with VS2012) have a new managed debugging engine that is not compatible enough with the unmanaged debugging engine. Tools > Options > Debugging > General, tick "Use Managed Compatibility Mode". It enables the legacy debugging engine, the one last used in VS2010.

    0 讨论(0)
提交回复
热议问题