From: Yedidya Feldblum Date: Tue, 16 Jan 2018 17:32:21 +0000 (-0800) Subject: Use thread-local in RequestContext::getStaticContext X-Git-Tag: v2018.01.22.00~30 X-Git-Url: http://plrg.eecs.uci.edu/git/?p=folly.git;a=commitdiff_plain;h=6746259314362d89f3d1d1dbfdf00c9fe18de202;hp=6746259314362d89f3d1d1dbfdf00c9fe18de202 Use thread-local in RequestContext::getStaticContext Summary: [Folly] Use thread-local in `RequestContext::getStaticContext`. `folly::SingletonThreadLocal` uses `folly::ThreadLocal`. However, `static FOLLY_TLS` (`static __thread`) is always faster than `folly::ThreadLocal` for thread-local singletons for which iteration is not required. Reviewed By: djwatson Differential Revision: D6725091 fbshipit-source-id: 9979f39677284b1051cb109b461097495d77ca17 ---