[lldb-dev] SBThread::IsStopped() always returns false on Linux

Eugene Birukov eugenebi at hotmail.com
Fri Jun 5 14:43:15 PDT 2015

OOPS, on server I tried wrong class, that's why the method is not here. Still, client inspects local m_state to make the call, and it is "unloaded" in cases I inspected.

From: eugenebi at hotmail.com
To: lldb-dev at cs.uiuc.edu
Date: Fri, 5 Jun 2015 14:28:22 -0700
Subject: [lldb-dev] SBThread::IsStopped() always returns false on Linux

I am running lldb-4.7 that I built from sources on Linux Ubuntu 14.04.
I am using C++ API to debug my program. The program runs into different events: breakpoints I set, signals. But all threads always returnIsStopped() as false in any program state. I traced this call and it seems that the thread state is eStateUnloaded. The only place I found that changes thread state in Thread.cpp is this method:
voidThread::SetState(StateType state){    Mutex::Locker locker(m_state_mutex);    m_state = state;}
So, I put breakpoint there and it is never hit. I tried to put similar breakpoint in lldb-server, but it seems that the method is not present here:
(gdb) b lldb_private::Target::SetSSetSectionLoadAddress(std::shared_ptr<lldb_private::Section> const&, unsigned long, bool)SetSectionUnloaded(std::shared_ptr<lldb_private::Section> const&)SetSectionUnloaded(std::shared_ptr<lldb_private::Section> const&, unsigned long)SetStopHookActiveStateByID(unsigned long, bool)(gdb) b lldb_private::Target::SetStateFunction "lldb_private::Target::SetState" not defined.Make breakpoint pending on future shared library load? (y or [n])
So far, this seems broken to me.

lldb-dev mailing list
lldb-dev at cs.uiuc.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20150605/0eeb07f1/attachment.html>

More information about the lldb-dev mailing list