I'm trying to print a backtrace after a process stopped.
unfortunately i cant seen to use the frames at all, despite they're valid:
for(int i=0;i<m_process->GetNumThreads();i++) {
lldb::SBThread t = m_process->GetThreadAtIndex(i);
lldb::SBFrame fr = t.GetFrameAtIndex(0);
fr.IsValid() --> true
fr.GetFunction().isValid() --> false
fr.GetBlock().isValid() --> false
fr.GetCompileUnit().isValid() --> false
while attempting to print the highest frame
t.GetFrameAtIndex(t.GetNumFrames()-1)
i got a bunch of crashes. one trace of the crash revealed that its trying to
read memory through
the gdb remote process plugin, despite the process was started by the macos
process plugin
In source/Target/Process.cpp Process::FindPlugin :
the exact conditions there are unclear to me, all i know is that they are
inconsistent across the
debuggers lifetime, meaning it randomly picks an available plugin.
Also, if CanDebug returns false, it looks like the plugin instance is leaked?
After forcing the plugin to "process.macosx", I still get the same unusable
frames though.
Should i use a different method there? Unfortunately the API does not match the
internal command usage,
so i can only guess how this is meant to be used.
_______________________________________________
lldb-dev mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev