[Android] Cache function templates in GinJavaBridgeObject to avoid memory leak
V8 caches all function templates internally for the lifetime of a web page in an unbounded cache. Thus, creating a new function template for each call to a method of injected object caused JS heap memory to grow linearly. This is similar to a fix for Pepper Plugin objects (https://codereview.chromium.org/785213002/) BUG=462664 Review URL: https://codereview.chromium.org/969353004 Cr-Commit-Position: refs/heads/master@{#318890}
Showing
Please register or sign in to comment