[英]Qt Creator debugger very slow
I'm using Qt Creator debugger but when I want to inspect the current this
variable by expanding it from the Locals and expressions view, it take quite a long (about 30 seconds) before giving back control. 我正在使用Qt Creator调试器,但是当我想通过从Locals和expressions视图扩展
this
变量来检查当前变量时,需要很长的时间(约30秒)才能交还控制权。
I noticed the following message in the Debugger Log view: 我在“ 调试器日志”视图中注意到以下消息:
3518fetchVariables({"autoderef":1,"context":"","displaystringlimit":"100","dyntype":1,"expanded":["return","inspect","local.this","watch","local"],"fancy":1,"formats":{},"nativemixed":0,"partialvar":"local.this","passexceptions":0,"qobjectnames":1,"stringcutoff":"10000","token":3518,"typeformats":{},"watchers":[]})
(lldb) script theDumper.fetchVariables({"autoderef":1,"context":"","displaystringlimit":"100","dyntype":1,"expanded":["return","inspect","local.this","watch","local"],"fancy":1,"formats":{},"nativemixed":0,"partialvar":"local.this","passexceptions":0,"qobjectnames":1,"stringcutoff":"10000","token":3518,"typeformats":{},"watchers":[]})
bridgemessage={msg="Searching for type QObjectPrivate across all target modules, this could be very slow"},
eERROR: Lldb stderr: error: PlaybackDevice.o DWARF DW_TAG_array_type DIE at 0x0000db86 has a class/union/struct element type DIE 0x0000db92 that is a forward declaration, not a complete definition.
Try compiling the source file with -fno-limit-debug-info or disable -gmodule
I'm using: 我正在使用:
Edit: 编辑:
As Kuba Ober suggests I use a debug build of Qt (5.10.0) thanks to this link: Qt Creator debugger very slow 正如库巴·奥伯(Kuba Ober)建议的那样,由于以下链接,我使用了Qt(5.10.0)的调试版本: Qt Creator调试器非常慢
Unfortunately the message has changed to: 不幸的是,该消息已更改为:
eERROR: Lldb stderr: error: PlayBackDevice.o DWARF DW_TAG_array_type DIE at 0x0000f43e has a class/union/struct element type DIE 0x0000f44a that is a forward declaration, not a complete definition.
Try compiling the source file with -fno-limit-debug-info or disable -gmodule
I was having the same issue. 我有同样的问题。 What fixed it for me was unticking "Show QObject names if available" in QtCreator Preferences -> Debugger -> Locals & Expressions.
对我来说,解决此问题的方法是取消选中“ QtCreator首选项->调试器->本地与表达式”中的“显示可用的QObject名称”。
You're not using a debug build of Qt, I presume. 我想您不是在使用Qt的调试版本。 While this "bug" is annoying, it does in effect force you to use a debug build of Qt to debug your projects.
尽管此“ bug”很烦人,但实际上确实迫使您使用Qt的调试版本来调试项目。 It should make you way more productive - many problems are easier to fix when you can meaningfully step into the Qt code.
它应该使您的工作效率更高-当您有意义地进入Qt代码时,更容易解决许多问题。
I had similar issues and they were mostly resolved by changing my compiler to be the Clang in the same directory as the lldb
I was using. 我有类似的问题,通过将我的编译器更改为与我使用的
lldb
相同目录中的Clang,可以解决大多数问题。 (Incidentally, that Clang's filename is gcc
.) (顺便说一句,Clang的文件名是
gcc
。)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.