Commit c970c1cb authored by jochen@chromium.org's avatar jochen@chromium.org

Update Isolate::RequestGarbageCollection after r18691

BUG=none
R=hpayer@chromium.org
LOG=n

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18695 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 62ef558d
......@@ -6444,8 +6444,8 @@ void Isolate::RequestGarbageCollectionForTesting(GarbageCollectionType type) {
} else {
ASSERT_EQ(kFullGarbageCollection, type);
reinterpret_cast<i::Isolate*>(this)->heap()->CollectAllGarbage(
i::Heap::kNoGCFlags, "Isolate::RequestGarbageCollection",
kGCCallbackFlagForced);
i::Heap::kAbortIncrementalMarkingMask,
"Isolate::RequestGarbageCollection", kGCCallbackFlagForced);
}
}
......
......@@ -40,14 +40,9 @@ v8::Handle<v8::FunctionTemplate> GCExtension::GetNativeFunctionTemplate(
void GCExtension::GC(const v8::FunctionCallbackInfo<v8::Value>& args) {
i::Isolate* isolate = reinterpret_cast<i::Isolate*>(args.GetIsolate());
if (args[0]->BooleanValue()) {
isolate->heap()->CollectGarbage(
NEW_SPACE, "gc extension", v8::kGCCallbackFlagForced);
} else {
isolate->heap()->CollectAllGarbage(Heap::kAbortIncrementalMarkingMask,
"gc extension", v8::kGCCallbackFlagForced);
}
args.GetIsolate()->RequestGarbageCollectionForTesting(
args[0]->BooleanValue() ? v8::Isolate::kMinorGarbageCollection
: v8::Isolate::kFullGarbageCollection);
}
} } // namespace v8::internal
......@@ -7121,6 +7121,7 @@ void WhammyPropertyGetter(Local<String> name,
THREADED_TEST(WeakReference) {
i::FLAG_expose_gc = true;
v8::Isolate* isolate = CcTest::isolate();
v8::HandleScope handle_scope(isolate);
v8::Handle<v8::ObjectTemplate> templ= v8::ObjectTemplate::New(isolate);
......@@ -13479,6 +13480,7 @@ static void CheckSurvivingGlobalObjectsCount(int expected) {
TEST(DontLeakGlobalObjects) {
// Regression test for issues 1139850 and 1174891.
i::FLAG_expose_gc = true;
v8::V8::Initialize();
for (int i = 0; i < 5; i++) {
......
......@@ -232,6 +232,7 @@ TEST(UncaughtThrow) {
// | JS |
// | C-to-JS |
TEST(C2JSFrames) {
FLAG_expose_gc = true;
v8::HandleScope scope(CcTest::isolate());
v8::Local<v8::Context> context =
CcTest::NewContext(PRINT_EXTENSION | GC_EXTENSION);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment