commit | 33a4cc7bdd83777961f617704188d5fc0f6ca999 | [log] [tgz] |
---|---|---|
author | Hans Boehm <hboehm@google.com> | Fri Apr 12 17:08:36 2019 -0700 |
committer | Hans Boehm <hboehm@google.com> | Fri Apr 12 17:08:36 2019 -0700 |
tree | e3b652780944addb56250997a06742411addb3cb | |
parent | b4de7721d6e4742ef917233e5757b2b72196f5e3 [diff] |
Make concurrently accessed globals atomic Eliminate data races on gHaveTLS, and gShutdown by declaring them as atomic. Use explicit load() and store() operations to access them. Note that gHaveTLS requires memory ordering guarantees, and thus, even with a cooperative compiler, the old code would never have been compiled to correct ARM object code. Bug: 36697681 Test: Boot AOSP, TreeHugger Change-Id: I60b95b9483940e37e97cb522fbbf403d3dc75374