We should only purge font cache on top of the runloop. Then this stack helper can go away.
Created attachment 244425 [details] patch
https://trac.webkit.org/r178250
This fix rdar://problem/19431581 which was 0 com.apple.WebCore 0x000000010a58cce0 WTF::Ref<WebCore::FontGlyphs>::get() + 16 1 com.apple.WebCore 0x000000010a5893e0 WebCore::pruneUnreferencedEntriesFromFontGlyphsCache() + 176 2 com.apple.WebCore 0x000000010a5995b2 WebCore::FontCache::purgeInactiveFontData(int) + 34 3 com.apple.WebCore 0x000000010a59946c WebCore::FontCache::purgeInactiveFontDataIfNeeded() + 156 4 com.apple.WebCore 0x0000000109ff962c WebCore::FontCache::enablePurging() + 108 5 com.apple.WebCore 0x0000000109ff95b9 WebCore::FontCachePurgePreventer::~FontCachePurgePreventer() + 25 6 com.apple.WebCore 0x0000000109ff6765 WebCore::FontCachePurgePreventer::~FontCachePurgePreventer() + 21 7 com.apple.WebCore 0x000000010b6d036a WebCore::RenderSVGText::removeChild(WebCore::RenderObject&) + 106 ... 83 com.apple.WebCore 0x000000010a589491 WebCore::pruneUnreferencedEntriesFromFontGlyphsCache() + 353 84 com.apple.WebCore 0x000000010a589c21 WebCore::retrieveOrAddCachedFontGlyphs(WebCore::FontDescription const&, WTF::PassRefPtr<WebCore::FontSelector>) + 1697
Looks like this was 2.5% regression on PLT (see Mavericks results)?
The regression was fixed in https://trac.webkit.org/r178673
Unfortunately the bot was down so the step change from the commit is not visible.