Hello Mike Percy,

I'd like you to do a code review. Please visit

    http://gerrit.cloudera.org:8080/9409

to review the following change.


Change subject: KUDU-2291 (part 8): fix a TSAN issue with libunwind 
initialization
......................................................................

KUDU-2291 (part 8): fix a TSAN issue with libunwind initialization

libunwind uses double-checked locking for initialization, which isn't
technically safe. We previously tried to work around this by calling into the
stack trace library before starting any kudu::Threads, but that still left us
open to races in unit tests like rw_mutex-test which uses std::thread.

This patch changes the forced single-threaded initialization to use GoogleOnce
instead.

Prior to this patch, looping rw_mutex-test on TSAN failed 12/1000 times.
With the patch it passed 1000/1000.

Change-Id: I522b6553e9cb9a30d7106ff55ad119f7df1f949c
---
M src/kudu/util/debug-util.cc
M src/kudu/util/thread.cc
2 files changed, 17 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/09/9409/1
--
To view, visit http://gerrit.cloudera.org:8080/9409
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I522b6553e9cb9a30d7106ff55ad119f7df1f949c
Gerrit-Change-Number: 9409
Gerrit-PatchSet: 1
Gerrit-Owner: Todd Lipcon <t...@apache.org>
Gerrit-Reviewer: Mike Percy <mpe...@apache.org>

Reply via email to