Add a new SBThread::SafeToCallFunctions API; this calls over to
the SystemRuntime to check if a thread will have any problems performing an inferior function call so the driver can skip making that function call on that thread. Often the function call can be executed on another thread instead. <rdar://problem/16777874> llvm-svn: 208732
This commit is contained in:
@@ -1437,3 +1437,12 @@ SBThread::GetExtendedBacktraceOriginatingIndexID ()
|
||||
return thread_sp->GetExtendedBacktraceOriginatingIndexID();
|
||||
return LLDB_INVALID_INDEX32;
|
||||
}
|
||||
|
||||
bool
|
||||
SBThread::SafeToCallFunctions ()
|
||||
{
|
||||
ThreadSP thread_sp(m_opaque_sp->GetThreadSP());
|
||||
if (thread_sp)
|
||||
return thread_sp->SafeToCallFunctions();
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user