Synchronize coupled caches in folly::threadlocal_detail::StaticMeta
authorYedidya Feldblum <yfeldblum@fb.com>
Wed, 29 Nov 2017 20:12:01 +0000 (12:12 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Wed, 29 Nov 2017 20:23:33 +0000 (12:23 -0800)
commit73c52b9f7d7dc1db75838b33064a4f7e4a5b2e51
treedd8e7b6074280814756e374a816402ad5489b767
parent70230b7a106820807c8d74fcf3d21ebab3442fbb
Synchronize coupled caches in folly::threadlocal_detail::StaticMeta

Summary:
[Folly] Synchronize coupled caches in `folly::threadlocal_detail::StaticMeta`.

The caches should be set together, and only together, because they are coupled. This prevents bugs where one function that sets one cache but not the other cache is inlined into the caller in one module, and another function that reads both caches is inlined into the caller in another module.

Reviewed By: djwatson

Differential Revision: D6435175

fbshipit-source-id: 846c4972b40e525f2c04da6e6609c2ad54f674c0
folly/detail/ThreadLocalDetail.h