From 086eea93b1f8253420c233c33cdabc0e74b08091 Mon Sep 17 00:00:00 2001 From: reed Date: Wed, 4 May 2016 17:12:46 -0700 Subject: Revert of SK_DECLARE_STATIC_MUTEX -> static SkMutex (patchset #1 id:1 of https://codereview.chromium.org/1948193002/ ) Reason for revert: broken the Mac and Linux builders, e.g.: https://build.chromium.org/p/chromium/builders/Mac/builds/15151 https://build.chromium.org/p/chromium/builders/Linux%20x64/builds/19052 Original issue's description: > SK_DECLARE_STATIC_MUTEX -> static SkMutex > > There's no need to use a macro to declare static SkMutexes any more > (and there's likewise no need to restrict them to global scope). > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1948193002 > > Committed: https://skia.googlesource.com/skia/+/5e56cfd3fa1041dbb83899844fb92fa9a2ef1009 TBR=mtklein@google.com,mtklein@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/1945353003 --- tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp | 2 +- tools/sk_tool_utils_font.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'tools') diff --git a/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp b/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp index a6f62f0028..850adaaf25 100644 --- a/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp +++ b/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp @@ -142,7 +142,7 @@ static const GrGLInterface* create_command_buffer_interface() { // We use a poor man's garbage collector of EGLDisplays. They are only // terminated when there are no more EGLDisplays in use. See crbug.com/603223 -static SkMutex gDisplayMutex; +SK_DECLARE_STATIC_MUTEX(gDisplayMutex); static int gActiveDisplayCnt; SkTArray gRetiredDisplays; diff --git a/tools/sk_tool_utils_font.cpp b/tools/sk_tool_utils_font.cpp index 67f86d1bb6..adbfa1692b 100644 --- a/tools/sk_tool_utils_font.cpp +++ b/tools/sk_tool_utils_font.cpp @@ -27,7 +27,7 @@ void release_portable_typefaces() { } } -static SkMutex gTestFontMutex; +SK_DECLARE_STATIC_MUTEX(gTestFontMutex); SkTypeface* create_font(const char* name, SkTypeface::Style style) { SkTestFontData* fontData = nullptr; -- cgit v1.2.3