Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(152)

Unified Diff: test/cctest/test-heap.cc

Issue 11416200: Make unit tests that fill new-space work under stress. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-heap.cc
diff --git a/test/cctest/test-heap.cc b/test/cctest/test-heap.cc
index a51b37ebae91788c4835edd525055a3408b15ac1..f5bac2c5def2edcc1246805cdcdb82c79c17cccb 100644
--- a/test/cctest/test-heap.cc
+++ b/test/cctest/test-heap.cc
@@ -1944,7 +1944,7 @@ TEST(OptimizedAllocationAlwaysInNewSpace) {
if (!i::V8::UseCrankshaft() || i::FLAG_always_opt) return;
v8::HandleScope scope;
- FillUpNewSpace(HEAP->new_space());
+ SimulateFullSpace(HEAP->new_space());
AlwaysAllocateScope always_allocate;
v8::Local<v8::Value> res = CompileRun(
"function c(x) {"
@@ -2153,14 +2153,9 @@ TEST(Regress2237) {
// Generate a sliced string that is based on the above parent and
// lives in old-space.
- FillUpNewSpace(HEAP->new_space());
+ SimulateFullSpace(HEAP->new_space());
AlwaysAllocateScope always_allocate;
- Handle<String> t;
- // TODO(mstarzinger): Unfortunately FillUpNewSpace() still leaves
- // some slack, so we need to allocate a few sliced strings.
- for (int i = 0; i < 16; i++) {
- t = FACTORY->NewProperSubString(s, 5, 35);
- }
+ Handle<String> t = FACTORY->NewProperSubString(s, 5, 35);
CHECK(t->IsSlicedString());
CHECK(!HEAP->InNewSpace(*t));
*slice.location() = *t.location();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698