Re-land "Add methods to enable configuration of ResourceConstraints based on limits...
authorhpayer@chromium.org <hpayer@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Fri, 27 Sep 2013 10:53:07 +0000 (10:53 +0000)
committerhpayer@chromium.org <hpayer@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Fri, 27 Sep 2013 10:53:07 +0000 (10:53 +0000)
commit4c01c4040a6a1454bf3c32b47953effc429df654
tree9d38015d70b261522036296c13ce88772263ae11
parentc34af4ae6d1af0b3b98cf0ce014d34201525d5c4
Re-land "Add methods to enable configuration of ResourceConstraints based on limits derived at runtime."

Adds ConfigureResourceConstraintsForCurrentPlatform and SetDefaultResourceConstraintsForCurrentPlatform which configure the heap based on the available physical memory, rather than hard-coding by platform as previous. This change also adds OS::TotalPhysicalMemory to platform.h.

The re-land fix the performance regression caused by accidental change in default max young space size.

BUG=292928
R=hpayer@chromium.org

Review URL: https://codereview.chromium.org/24989003

Patch from Ross McIlroy <rmcilroy@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16983 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
include/v8-defaults.h [new file with mode: 0644]
include/v8-testing.h
include/v8.h
src/d8.cc
src/defaults.cc [new file with mode: 0644]
src/globals.h
src/heap.cc
src/platform-posix.cc
src/platform-win32.cc
src/platform.h
tools/gyp/v8.gyp