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

Unified Diff: test/cctest/test-heap-profiler.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-global-handles.cc ('k') | test/cctest/test-identity-map.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-heap-profiler.cc
diff --git a/test/cctest/test-heap-profiler.cc b/test/cctest/test-heap-profiler.cc
index 55509869a83fdd35c0b80a5a3d1c67b9cb27fb2e..9d1090cdfd90b27aab9ac165f5d69cdad656528d 100644
--- a/test/cctest/test-heap-profiler.cc
+++ b/test/cctest/test-heap-profiler.cc
@@ -501,7 +501,7 @@ void CheckSimdSnapshot(const char* program, const char* var_name) {
// 28 @ 13523 entry with no retainer: /hidden/ system / AllocationSite
// 44 @ 767 $map: /hidden/ system / Map
// 44 @ 59 $map: /hidden/ system / Map
- CcTest::heap()->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
const v8::HeapSnapshot* snapshot = heap_profiler->TakeHeapSnapshot();
CHECK(ValidateSnapshot(snapshot));
@@ -738,7 +738,7 @@ TEST(HeapSnapshotAddressReuse) {
CompileRun(
"for (var i = 0; i < 10000; ++i)\n"
" a[i] = new A();\n");
- CcTest::heap()->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
const v8::HeapSnapshot* snapshot2 = heap_profiler->TakeHeapSnapshot();
CHECK(ValidateSnapshot(snapshot2));
@@ -780,7 +780,7 @@ TEST(HeapEntryIdsAndArrayShift) {
"for (var i = 0; i < 1; ++i)\n"
" a.shift();\n");
- CcTest::heap()->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
const v8::HeapSnapshot* snapshot2 = heap_profiler->TakeHeapSnapshot();
CHECK(ValidateSnapshot(snapshot2));
@@ -821,7 +821,7 @@ TEST(HeapEntryIdsAndGC) {
const v8::HeapSnapshot* snapshot1 = heap_profiler->TakeHeapSnapshot();
CHECK(ValidateSnapshot(snapshot1));
- CcTest::heap()->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
const v8::HeapSnapshot* snapshot2 = heap_profiler->TakeHeapSnapshot();
CHECK(ValidateSnapshot(snapshot2));
@@ -1150,7 +1150,7 @@ TEST(HeapSnapshotObjectsStats) {
// We have to call GC 6 times. In other case the garbage will be
// the reason of flakiness.
for (int i = 0; i < 6; ++i) {
- CcTest::heap()->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
}
v8::SnapshotObjectId initial_id;
@@ -1305,7 +1305,7 @@ TEST(HeapObjectIds) {
}
heap_profiler->StopTrackingHeapObjects();
- CcTest::heap()->CollectAllAvailableGarbage();
+ CcTest::CollectAllAvailableGarbage();
for (int i = 0; i < kLength; i++) {
v8::SnapshotObjectId id = heap_profiler->GetObjectId(objects[i]);
@@ -3058,7 +3058,7 @@ TEST(SamplingHeapProfiler) {
" eval(\"new Array(100)\");\n"
"}\n");
- CcTest::heap()->CollectAllGarbage();
+ CcTest::CollectAllGarbage(i::Heap::kFinalizeIncrementalMarkingMask);
std::unique_ptr<v8::AllocationProfile> profile(
heap_profiler->GetAllocationProfile());
@@ -3112,7 +3112,7 @@ TEST(SamplingHeapProfilerLeftTrimming) {
" a.shift();\n"
"}\n");
- CcTest::heap()->CollectGarbage(v8::internal::NEW_SPACE);
+ CcTest::CollectGarbage(v8::internal::NEW_SPACE);
// Should not crash.
heap_profiler->StopSamplingHeapProfiler();
« no previous file with comments | « test/cctest/test-global-handles.cc ('k') | test/cctest/test-identity-map.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698