Commit b20ed70e authored by Sathya Gunasekaran's avatar Sathya Gunasekaran Committed by Commit Bot

[object-stats] Cleanup ObjectStatsVisitor::Visit

No need to return anything here as the return value doesn't need to be
checked. This is a purely side effecting function.

Change-Id: I5484086e289d9f5104a17c93950c25f656d5a44b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2605185Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Commit-Queue: Sathya Gunasekaran  <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71940}
parent 207bda5d
......@@ -1092,7 +1092,7 @@ class ObjectStatsVisitor {
heap->mark_compact_collector()->non_atomic_marking_state()),
phase_(phase) {}
bool Visit(HeapObject obj, int size) {
void Visit(HeapObject obj) {
if (marking_state_->IsBlack(obj)) {
live_collector_->CollectStatistics(
obj, phase_, ObjectStatsCollectorImpl::CollectFieldStats::kYes);
......@@ -1101,7 +1101,6 @@ class ObjectStatsVisitor {
dead_collector_->CollectStatistics(
obj, phase_, ObjectStatsCollectorImpl::CollectFieldStats::kNo);
}
return true;
}
private:
......@@ -1117,7 +1116,7 @@ void IterateHeap(Heap* heap, ObjectStatsVisitor* visitor) {
CombinedHeapObjectIterator iterator(heap);
for (HeapObject obj = iterator.Next(); !obj.is_null();
obj = iterator.Next()) {
visitor->Visit(obj, obj.Size());
visitor->Visit(obj);
}
}
......
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