简体   繁体   English

VS2010 调试器中没有调用堆栈

[英]No call stack in VS2010 debugger

I've got an app that loads a DLL, and subsequently crashes.我有一个加载 DLL 的应用程序,随后崩溃。 I modified the IDE's working directory to be the solution build directory, so that I could run the debugger on the built DLL which is built from another project in this solution.我将 IDE 的工作目录修改为解决方案构建目录,以便可以在构建的 DLL 上运行调试器,该 DLL 是从该解决方案中的另一个项目构建的。 When the app gets an access violation, I can see the current function, but nothing of the call stack, and none of the locals will evaluate.当应用程序发生访问冲突时,我可以看到当前的 function,但没有调用堆栈,并且没有本地人会评估。 I've checked and there are debugger symbols in this directory, and it was all built in debug mode.我检查过,这个目录中有调试器符号,而且都是在调试模式下构建的。 What could be the cause of the debugger failing?调试器失败的原因可能是什么?

Edit: If I place a breakpoint, then the debugger works fine- although, of course, this still doesn't tell me why the app is crashing, but I do get a call stack and all the symbols will happily evaluate.编辑:如果我放置一个断点,那么调试器就可以正常工作——当然,这仍然不能告诉我应用程序崩溃的原因,但我确实得到了一个调用堆栈,所有符号都会愉快地评估。

Having the debugger work when it hits a break point and fails when you break after an access violation in native code usually a sign that the access violation is preceded or accompanied by a corruption of the stack.让调试器在遇到断点时工作,而在本机代码中的访问冲突后中断时失败,这通常表明访问冲突之前或伴随着堆栈损坏。

The debugger depends on certain values in the stack being properly set in order for it to both build the correct stack view and access local variables.调试器依赖于正确设置堆栈中的某些值,以便它构建正确的堆栈视图和访问局部变量。 If this data is corrupted it can prevent both locals from being displayed and an accurate picture of the stack from being generated.如果此数据已损坏,则可能会阻止显示本地数据和生成堆栈的准确图片。

In the case where you hit the break point before the access violation the stack is still in tact and the debugger can freely view information.如果您在访问冲突之前命中断点,堆栈仍然完好无损,调试器可以自由查看信息。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM