From 0552c8ef896c4356f4db85618972dedccd6ad53b Mon Sep 17 00:00:00 2001 From: "boliu@chromium.org" Date: Tue, 10 Sep 2013 22:44:43 +0000 Subject: [Android WebView] First cut memory management Based on simple algorithm of visible rect x constant. Completely disregards the preferred allocation from based on content of the page. Constants extermined experimentally using current android nexus devices. BUG=286026 Review URL: https://chromiumcodereview.appspot.com/23572023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@222372 0039d316-1c4b-4281-b951-d872f2087c98 --- android_webview/lib/main/aw_main_delegate.cc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'android_webview/lib') diff --git a/android_webview/lib/main/aw_main_delegate.cc b/android_webview/lib/main/aw_main_delegate.cc index ff7dfbf..10906c7 100644 --- a/android_webview/lib/main/aw_main_delegate.cc +++ b/android_webview/lib/main/aw_main_delegate.cc @@ -6,6 +6,7 @@ #include "android_webview/browser/aw_content_browser_client.h" #include "android_webview/browser/gpu_memory_buffer_factory_impl.h" +#include "android_webview/browser/in_process_view_renderer.h" #include "android_webview/browser/scoped_allow_wait_for_legacy_web_view_api.h" #include "android_webview/lib/aw_browser_dependency_factory_impl.h" #include "android_webview/native/aw_geolocation_permission_context.h" @@ -50,6 +51,8 @@ bool AwMainDelegate::BasicStartupComplete(int* exit_code) { gpu_memory_buffer_factory_.get()); gpu::InProcessCommandBuffer::EnableVirtualizedContext(); + InProcessViewRenderer::CalculateTileMemoryPolicy(); + CommandLine* cl = CommandLine::ForCurrentProcess(); cl->AppendSwitch(switches::kEnableBeginFrameScheduling); cl->AppendSwitch(cc::switches::kEnableMapImage); -- cgit v1.1