More debugger bugs

Andras Mantia amantia at kde.org
Tue Nov 28 23:05:57 UTC 2006


On Wednesday 29 November 2006 00:26, Andras Mantia wrote:
> - step into (F11): cursor remains on the same line (I think this is
> because of -O2 there)

Some more test, now with --enable-debug=full (I reverted the change I 
made to pluginmanager, did new configure, makeobj clean in src, then 
makeobj, makeobj install).

Test 1:
- while opening the m_info structure:
There is no member or method named QValueList. (but not for the second 
try)
- no crazy cursor jumping problem backward/forward
- after returning to loadLocalParts() a step over (F10) continues the 
program... This *IS* reproducible for me.

So gdb survives, but simply runs the application instead of stepping 
over a line.


Test 2:
- no error messages when switching frames
- fast switching still broken
- during stepping, when I reached the end of the unloadPlugins method, I 
got the first error:
No symbol "oldProfile" in current context.
- after continue, breaks in projectmanager:
No symbol "newProfile" in current context
- no erros again when switching to #1
- #1 is the correct one now (but remember, I moved the line from the end 
of the method, so I'm not sure this or the =full made the difference)
- after step out from  unloadPlugins: 
No symbol "unload" in current context.

Bonus test:
- once it continues Test2, load another project in the debugged KDevelop
- it will break inside unloadPlugins:
No symbol "unload" in current context
- step out:
No symbol "m_info" in current context. (still in unloadPlugins hit the 
other breakpoint)
- step out until it really steps out: unload becomes enabled.
- remove the unload watch variable
- continue to run, break in unloadPlugins
- switch to #1: some errors, including
mi_cmd_var_create: unable to create variable object ( a new one)
Variable object not found
Variable object not found

And a crash (what you probably cannot easily reproduce):
- program run and hang (my problem with KDevelop I tried to debug)
- interrupt
- switch between frames: errors and KDevelop crashes:

Using host libthread_db library "/lib64/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread 47778140127872 (LWP 23468)]
[New Thread 1082132800 (LWP 23483)]
[KCrash handler]
#5  QString::operator+= (this=0x7fff7d9291c0, str=@0x8291bd0)
    at tools/qstring.cpp:5553
#6  0x00002b742d4040cc in kdbgstream::operator<< (this=0x7fff7d9291c0, 
    string=@0x8291bd0) at /opt/kde-35/include/kdebug.h:218
#7  0x00002b743fe9b5db in GDBDebugger::VarItem::handleSpecialTypes (
    this=0x8291b10)
    
at /data/development/sources/kde-3.5/kdevelop-3.4/languages/cpp/debugger/variablewidget.cpp:1646
#8  0x00002b743fe9b860 in GDBDebugger::VarItem::updateValue (
    this=0x7fff7d9291c0)
    
at /data/development/sources/kde-3.5/kdevelop-3.4/languages/cpp/debugger/variablewidget.cpp:1527
#9  0x00002b743fe9f4c0 in GDBDebugger::VariableTree::handleVarUpdate (
    this=0x1d01eb0, r=<value optimized out>)
    
at /data/development/sources/kde-3.5/kdevelop-3.4/languages/cpp/debugger/variablewidget.cpp:856
#10 0x00002b743fe93a56 in GDBDebugger::GDBCommand::invokeHandler (
    this=0x282f790, r=@0x6986680)
    
at /data/development/sources/kde-3.5/kdevelop-3.4/languages/cpp/debugger/gdbcommand.cpp:36
#11 0x00002b743fe8fc7e in 
GDBDebugger::GDBController::processMICommandResponse
    (this=0x1ce19f0, result=@0x6986680)
    
at /data/development/sources/kde-3.5/kdevelop-3.4/languages/cpp/debugger/gdbcontroller.cpp:1413
#12 0x00002b743fe900b1 in GDBDebugger::GDBController::slotDbgStdout (
    this=0x1ce19f0, buf=<value optimized out>, buflen=<value optimized 
out>)
    
at /data/development/sources/kde-3.5/kdevelop-3.4/languages/cpp/debugger/gdbcontroller.cpp:1534
#13 0x00002b743fe8c4e0 in GDBDebugger::GDBController::qt_invoke (
    this=0x1ce19f0, _id=<value optimized out>, _o=0x7fff7d929760)
    at ./languages/cpp/debugger/gdbcontroller.moc:248
#14 0x00002b7433081adc in QObject::activate_signal (this=0x2a203e0, 
    clist=<value optimized out>, o=0x7fff7d929760) at 
kernel/qobject.cpp:2356
#15 0x00002b7431cfc37b in KProcess::receivedStdout (
    this=<value optimized out>, t0=0x2a203e0, 
    
t1=0x7fff7d929800 "^done,changelist=[{name=\"KDEV47\",in_scope=\"true\",type_changed=\"false\"}]\n(gdb) 
\n", t2=79) at ./kdecore/kprocess.moc:152
#16 0x00002b7431cfcfee in KProcess::childOutput (this=0x2a203e0, 
    fdno=<value optimized out>)
    
at /data/development/sources/kde-3.5/kdelibs/kdecore/kprocess.cpp:853
#17 0x00002b7431cfd019 in KProcess::slotChildOutput 
(this=0x7fff7d9291c0, 
    fdno=136911824)
    
at /data/development/sources/kde-3.5/kdelibs/kdecore/kprocess.cpp:733
#18 0x00002b7431cfd364 in KProcess::qt_invoke (this=0x2a203e0, _id=2, 
    _o=0x7fff7d929ce0) at ./kdecore/kprocess.moc:201
#19 0x00002b7433081adc in QObject::activate_signal (this=0x20bd240, 
    clist=<value optimized out>, o=0x7fff7d929ce0) at 
kernel/qobject.cpp:2356
#20 0x00002b74330826df in QObject::activate_signal (this=0x7fff7d9291c0, 
    signal=<value optimized out>, param=<value optimized out>)
    at kernel/qobject.cpp:2449
#21 0x00002b743309c2cb in QSocketNotifier::event (this=0x20bd240, 
    e=0x7fff7d929fc0) at kernel/qsocketnotifier.cpp:258
#22 0x00002b743302aeb5 in QApplication::internalNotify (
    this=<value optimized out>, receiver=0x20bd240, e=0x7fff7d929fc0)
    at kernel/qapplication.cpp:2636
#23 0x00002b743302bc40 in QApplication::notify (this=0x7fff7d92a250, 
    receiver=0x20bd240, e=0x7fff7d929fc0) at 
kernel/qapplication.cpp:2359
#24 0x00002b7431ccdd82 in KApplication::notify (this=0x7fff7d92a250, 
    receiver=0x20bd240, event=0x7fff7d929fc0)
    
at /data/development/sources/kde-3.5/kdelibs/kdecore/kapplication.cpp:550
#25 0x00002b743302061b in QEventLoop::activateSocketNotifiers 
(this=0x66ebc0)
    at kernel/qapplication.h:520
#26 0x00002b7432fe15f0 in QEventLoop::processEvents (this=0x66ebc0, 
    flags=<value optimized out>) at kernel/qeventloop_x11.cpp:383
#27 0x00002b743303f963 in QEventLoop::enterLoop (this=0x7fff7d9291c0)
    at kernel/qeventloop.cpp:198
#28 0x00002b743303f812 in QEventLoop::exec (this=0x7fff7d9291c0)
    at kernel/qeventloop.cpp:145
#29 0x000000000040891c in main (argc=3, argv=0x7fff7d92a6d8)
    at /data/development/sources/kde-3.5/kdevelop-3.4/src/main.cpp:149

I saw crashes when deleting watched variables previously as well, and 
I'll try to find how to easily reproduce.

Conclusions (from my POV):
- --enable-debug=full (-g3 , without -O2) helps to have less error 
messages, better stepping, but still gives errors and introduces a new 
bug (run instead of step)
- as --enabel-debug=full is not that well known and as I saw SUSE for 
example uses -O2 for debug packages as well, at least the error 
reporting part should be fixed. I believe the stepping issue cannot be 
fixed in KDevelop
- watched variable handling needs improvements: no need to warn if they 
are not available in the current context and it should be possible to 
remove them even if they are disabled.

Unfortunately I still couldn't reproduce the framestack bug as I 
reported. :-( 

Andras
-- 
Quanta Plus developer - http://quanta.kdewebdev.org
K Desktop Environment - http://www.kde.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20061129/0b370886/attachment.sig>


More information about the KDevelop-devel mailing list