Fix a race in ThreadLocalStorage::StaticSlot::initialized which triggers a TSAN error.
Also fix a data race with ThreadData::status_. TSan doesn't see this race explicitly, but it contributes to a race with the use of StaticSlot in ThreadData::tls_index_.
BUG=268941
TESTED=Ran base_unittests.
TSAN errors before: lots, oodles, slathers, acres
After: Zip, zilch, nadda
Review URL: https://codereview.chromium.org/1222123002
Cr-Commit-Position: refs/heads/master@{#339219}
CrOS-Libchrome-Original-Commit: 42d16882080508876676ef164c1f7a863ca1fbf3
4 files changed