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

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

Issue 2310143002: [heap] Introduce enum of garbage collection reasons. (Closed)
Patch Set: rebase Created 4 years, 3 months 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 | « test/cctest/test-log.cc ('k') | test/cctest/test-serialize.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-mementos.cc
diff --git a/test/cctest/test-mementos.cc b/test/cctest/test-mementos.cc
index 8aac478d2658ef5858ddc4d71b351af90d95ff87..da5ce8ce692e50371994bdf4f8a656b5ef908167 100644
--- a/test/cctest/test-mementos.cc
+++ b/test/cctest/test-mementos.cc
@@ -46,7 +46,7 @@ static void SetUpNewSpaceWithPoisonedMementoAtTop() {
NewSpace* new_space = heap->new_space();
// Make sure we can allocate some objects without causing a GC later.
- heap->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
// Allocate a string, the GC may suspect a memento behind the string.
Handle<SeqOneByteString> string =
@@ -72,8 +72,7 @@ TEST(Regress340063) {
// Call GC to see if we can handle a poisonous memento right after the
// current new space top pointer.
- CcTest::i_isolate()->heap()->CollectAllGarbage(
- Heap::kAbortIncrementalMarkingMask);
+ CcTest::CollectAllGarbage(Heap::kAbortIncrementalMarkingMask);
}
@@ -90,8 +89,7 @@ TEST(Regress470390) {
// Call GC to see if we can handle a poisonous memento right after the
// current new space top pointer.
- CcTest::i_isolate()->heap()->CollectAllGarbage(
- Heap::kAbortIncrementalMarkingMask);
+ CcTest::CollectAllGarbage(Heap::kAbortIncrementalMarkingMask);
}
@@ -103,5 +101,5 @@ TEST(BadMementoAfterTopForceScavenge) {
SetUpNewSpaceWithPoisonedMementoAtTop();
// Force GC to test the poisoned memento handling
- CcTest::i_isolate()->heap()->CollectGarbage(i::NEW_SPACE);
+ CcTest::CollectGarbage(i::NEW_SPACE);
}
« no previous file with comments | « test/cctest/test-log.cc ('k') | test/cctest/test-serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698