diff options
Diffstat (limited to 'JavaScriptCore/runtime/RegExpCache.h')
| -rw-r--r-- | JavaScriptCore/runtime/RegExpCache.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/JavaScriptCore/runtime/RegExpCache.h b/JavaScriptCore/runtime/RegExpCache.h index e897b43..b5b637f 100644 --- a/JavaScriptCore/runtime/RegExpCache.h +++ b/JavaScriptCore/runtime/RegExpCache.h @@ -47,7 +47,14 @@ public: private: static const unsigned maxCacheablePatternLength = 256; + +#if PLATFORM(IOS) + // The RegExpCache can currently hold onto multiple Mb of memory; + // as a short-term fix some embedded platforms may wish to reduce the cache size. + static const int maxCacheableEntries = 32; +#else static const int maxCacheableEntries = 256; +#endif FixedArray<RegExpKey, maxCacheableEntries> patternKeyArray; RegExpCacheMap m_cacheMap; |
