[Lldb-commits] [PATCH] D157041: [lldb] Protect OptionValue accesses from data races
Augusto Noronha via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Thu Aug 3 17:16:36 PDT 2023
augusto2112 marked 2 inline comments as done.
augusto2112 added inline comments.
================
Comment at: lldb/source/Interpreter/OptionValue.cpp:49
+ std::lock_guard<std::recursive_mutex> lock(m_mutex);
if (GetType() == OptionValue::eTypeBoolean)
return static_cast<OptionValueBoolean *>(this);
----------------
kastiglione wrote:
> do these GetAsX functions need to lock?
Hmm, I think we can get away with just locking GetXValue and SetXValue, and replace the lock with a non recursive one.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D157041/new/
https://reviews.llvm.org/D157041
More information about the lldb-commits
mailing list