diff options
author | Michał Górny <mgorny@moritz.systems> | 2022-01-24 18:52:49 +0100 |
---|---|---|
committer | Michał Górny <mgorny@moritz.systems> | 2022-01-28 17:47:47 +0100 |
commit | ac666d1799c45a1ecd59f7503e1fc649deffd4d4 (patch) | |
tree | 470f5d279cd6b236a8f906dbb1bc024549a27894 /lldb/source/API/SBThread.cpp | |
parent | a858e25f1cf384af9f7350b92594467321070cf1 (diff) | |
download | llvm-ac666d1799c45a1ecd59f7503e1fc649deffd4d4.zip llvm-ac666d1799c45a1ecd59f7503e1fc649deffd4d4.tar.gz llvm-ac666d1799c45a1ecd59f7503e1fc649deffd4d4.tar.bz2 |
[lldb] [gdb-remote] Support getting siginfo via API
Add Thread::GetSiginfo() and SBThread::GetSiginfo() methods to retrieve
the siginfo value from server.
Differential Revision: https://reviews.llvm.org/D118055
Diffstat (limited to 'lldb/source/API/SBThread.cpp')
-rw-r--r-- | lldb/source/API/SBThread.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lldb/source/API/SBThread.cpp b/lldb/source/API/SBThread.cpp index 46a6c27..a08cb74 100644 --- a/lldb/source/API/SBThread.cpp +++ b/lldb/source/API/SBThread.cpp @@ -1317,3 +1317,12 @@ lldb_private::Thread *SBThread::operator->() { lldb_private::Thread *SBThread::get() { return m_opaque_sp->GetThreadSP().get(); } + +SBValue SBThread::GetSiginfo() { + LLDB_INSTRUMENT_VA(this); + + ThreadSP thread_sp = m_opaque_sp->GetThreadSP(); + if (!thread_sp) + return SBValue(); + return thread_sp->GetSiginfoValue(); +} |