| Index: base/lazy_instance.h
|
| diff --git a/base/lazy_instance.h b/base/lazy_instance.h
|
| index 496fc1f0404948986de277bfe7b472827dce9cc6..ac94a009111cf230ef70984add4b22034f53fdac 100644
|
| --- a/base/lazy_instance.h
|
| +++ b/base/lazy_instance.h
|
| @@ -133,8 +133,11 @@ class LazyInstance : public LazyInstanceHelper {
|
| }
|
|
|
| Type* Pointer() {
|
| +#ifndef NDEBUG
|
| + // Avoid making TLS lookup on release builds.
|
| if (!Traits::kAllowedToAccessOnNonjoinableThread)
|
| base::ThreadRestrictions::AssertSingletonAllowed();
|
| +#endif
|
|
|
| // We will hopefully have fast access when the instance is already created.
|
| // Since a thread sees state_ != STATE_CREATED at most once,
|
|
|