From: erik.corry@gmail.com Date: Wed, 17 Sep 2008 10:58:45 +0000 (+0000) Subject: The OutOfMemory and OutOfMemoryNested tests set a heap limit that was too low. X-Git-Tag: upstream/4.7.83~25358 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5312fc05bedfd76f50dd61b89c410030a6e5eb7c;p=platform%2Fupstream%2Fv8.git The OutOfMemory and OutOfMemoryNested tests set a heap limit that was too low. A change in the way heap was allocated meant that the initial heap size was sometimes not higher than the limit, which mean that the limit started having and effect and prevented V8 from booting up. Fixes http://code.google.com/p/v8/issues/detail?id=25 Review URL: http://codereview.chromium.org/2924 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@325 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- diff --git a/test/cctest/test-api.cc b/test/cctest/test-api.cc index ce6ac84..800cc8b 100644 --- a/test/cctest/test-api.cc +++ b/test/cctest/test-api.cc @@ -1427,14 +1427,14 @@ static const char* js_code_causing_out_of_memory = // These tests run for a long time and prevent us from running tests // that come after them so they cannot run in parallel. -DISABLED_TEST(OutOfMemory) { +TEST(OutOfMemory) { // It's not possible to read a snapshot into a heap with different dimensions. if (v8::internal::Snapshot::IsEnabled()) return; // Set heap limits. static const int K = 1024; v8::ResourceConstraints constraints; constraints.set_max_young_space_size(256 * K); - constraints.set_max_old_space_size(2 * K * K); + constraints.set_max_old_space_size(4 * K * K); v8::SetResourceConstraints(&constraints); // Execute a script that causes out of memory. @@ -1468,14 +1468,14 @@ v8::Handle ProvokeOutOfMemory(const v8::Arguments& args) { } -DISABLED_TEST(OutOfMemoryNested) { +TEST(OutOfMemoryNested) { // It's not possible to read a snapshot into a heap with different dimensions. if (v8::internal::Snapshot::IsEnabled()) return; // Set heap limits. static const int K = 1024; v8::ResourceConstraints constraints; constraints.set_max_young_space_size(256 * K); - constraints.set_max_old_space_size(2 * K * K); + constraints.set_max_old_space_size(4 * K * K); v8::SetResourceConstraints(&constraints); v8::HandleScope scope;