HomePhabricator

[tsan] On OS X, optimize main thread’s ThreadState accesses

Description

[tsan] On OS X, optimize main thread’s ThreadState accesses

This is a very simple optimization that gets about 10% speedup for certain programs. We’re currently storing the pointer to the main thread’s ThreadState, but we can store the state directly in a static variable, which avoid the load acquire.

Differential Revision: http://reviews.llvm.org/D20910

Details

Committed
kuba.breckaJun 6 2016, 9:27 AM
Differential Revision
D20910: [tsan] On OS X, optimize main thread’s ThreadState accesses
Parents
rL271905: [asan] Reenable ASan tests in "check-all"
Branches
Unknown
Tags
Unknown