GDB (on Android) has problems resolving the current location using 'where'
Trying to determine the last line location of execution using gdb is turning into a real nightmare. I've using the where command I only get up until the second last call in the stack trace and never the actual line its on.
I do not know why, but the last call in the stack trace appears as ??.
Any and all help would be greatly appreciated on getting gdb to actually output where it is!
(gdb) where
#0 0xafd0c7b8 in __futex_syscall3 () from /root/xxx/yyy/zzz/android/SviCore/obj/local/armeabi/libc.so
#1 0xafd1138c in pthread_mutex_lock () from /root/xxx/yyy/zzz/android/SviCore/obj/local/armeabi/libc.so
warning: (Internal error: pc 0x81892c3b in read in psymtab, but not in symtab.)
warning: (Internal error: pc 0x81892c3b in read in psymtab, but not in symtab.)
#2 0x81892c3c in boost::mutex::lock (this=0xfffffe00) at external/boost/include/boost/thread/pthread/mutex.hpp:52
warning: (Internal error: pc 0x81892d01 in read in psymtab, but not in symtab.)
warning: (Internal error: pc 0x81892d01 in read in psymtab, but not in symtab.)
#3 0x81892d02 in boost::unique_lock<boost::mutex>::lock (this=0xbec9032c) at external/boost/include/boost/thread/locks.hpp:412
warning: (Internal error: pc 0x81893279 in read in psymtab, but not in symtab.)
warning: (Internal error: pc 0x81893279 in read in psymtab, but not in symtab.)
#4 0x8189327a in ReadLock1 (this=<value optimized out>, mutex=@0x162acc) at external/boost/include/boost/thread/locks.hpp:290
#5 0x8188e0ec in SVI::DownloadManager::resumeAll (this=0x12fc00) at src/cm/DownloadManager.cp开发者_如何转开发p:285
#6 0x81884e00 in Java_com_svi_core_DownloadManager_resumeAll (env=0xae28, obj=0x405181d8) at /root/xxx/yyy/zzz/android/SviCore/jni/DownloadManager.cpp:265
#7 0x80217ef8 in ?? ()
this=<value optimized out>
Looks like you are building with enabled optimizations. Disable them (-O0
option of gcc) and you should get better call stack.
Also upgrade gdb to a more recent version to get rid of these warnings warning: (Internal error: pc 0x81892c3b in read in psymtab, but not in symtab.)
.
精彩评论