[Lldb-commits] [PATCH] D30702: Fix remaining threading issues in Log.h

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Mar 9 02:04:41 PST 2017


labath added a comment.





================
Comment at: source/Utility/Log.cpp:82
+  if (mask | flags) {
+    m_options.store(options, std::memory_order_release);
+    m_stream_sp = stream_sp;
----------------
zturner wrote:
> Might as well use `memory_order_relaxed` here.
Done. I missed that one.


================
Comment at: unittests/Utility/LogTest.cpp:16
 #include "llvm/Support/Threading.h"
+#include <future>
 #include <thread>
----------------
zturner wrote:
> Is this included needed?
Not anymore. I had tried implementing the test with futures, but I couldn't get tsan to work with them properly.


https://reviews.llvm.org/D30702





More information about the lldb-commits mailing list