mirror of
https://github.com/intel/llvm.git
synced 2026-01-16 21:55:39 +08:00
Lock the JIT before using it.
<rdar://problem/15958296> llvm-svn: 200951
This commit is contained in:
@@ -238,6 +238,8 @@ IRExecutionUnit::GetRunnableInfo(Error &error,
|
||||
{
|
||||
lldb::ProcessSP process_sp(GetProcessWP().lock());
|
||||
|
||||
static Mutex s_runnable_info_mutex(Mutex::Type::eMutexTypeRecursive);
|
||||
|
||||
func_addr = LLDB_INVALID_ADDRESS;
|
||||
func_end = LLDB_INVALID_ADDRESS;
|
||||
|
||||
@@ -256,6 +258,8 @@ IRExecutionUnit::GetRunnableInfo(Error &error,
|
||||
return;
|
||||
};
|
||||
|
||||
Mutex::Locker runnable_info_mutex_locker(s_runnable_info_mutex);
|
||||
|
||||
m_did_jit = true;
|
||||
|
||||
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_EXPRESSIONS));
|
||||
|
||||
Reference in New Issue
Block a user