diff options
author | deanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-18 12:18:14 +0000 |
---|---|---|
committer | deanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-18 12:18:14 +0000 |
commit | fadf97f2f16f6b3ad2756cd07657c4f47172da92 (patch) | |
tree | ba24cf444ef2696e32639d51ef30e9f0d96df330 /chrome/browser/cache_manager_host.cc | |
parent | 1918c4e12cea21c56d5d9e07f3759de6ad9e3dd3 (diff) | |
download | chromium_src-fadf97f2f16f6b3ad2756cd07657c4f47172da92.zip chromium_src-fadf97f2f16f6b3ad2756cd07657c4f47172da92.tar.gz chromium_src-fadf97f2f16f6b3ad2756cd07657c4f47172da92.tar.bz2 |
Add cross platform base::SysInfo::AmountOfPhysicalMemoryMB to replace the Windows only env_util::GetPhysicalMemoryMB.
From Seo Sanghyeon.
Review URL: http://codereview.chromium.org/2962
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2358 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cache_manager_host.cc')
-rw-r--r-- | chrome/browser/cache_manager_host.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/chrome/browser/cache_manager_host.cc b/chrome/browser/cache_manager_host.cc index 0e329d3..13fc171 100644 --- a/chrome/browser/cache_manager_host.cc +++ b/chrome/browser/cache_manager_host.cc @@ -6,6 +6,7 @@ #include "chrome/browser/cache_manager_host.h" +#include "base/sys_info.h" #include "base/time.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/render_process_host.h" @@ -31,7 +32,7 @@ int GetDefaultCacheSize() { int default_cache_size = kDefaultMemoryCacheSize; // Check how much physical memory the OS has - int mem_size_mb = env_util::GetPhysicalMemoryMB(); + int mem_size_mb = base::SysInfo::AmountOfPhysicalMemoryMB(); if (mem_size_mb >= 1000) // If we have a GB of memory, set a larger default. default_cache_size *= 4; else if (mem_size_mb >= 512) // With 512 MB, set a slightly larger default. |