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

Unified Diff: src/heap/mark-compact.cc

Issue 1728593002: [Interpreter] Add support for cpu profiler logging. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 years, 10 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 | « src/full-codegen/full-codegen.cc ('k') | src/heap/spaces.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/mark-compact.cc
diff --git a/src/heap/mark-compact.cc b/src/heap/mark-compact.cc
index b2143d63443da94bd99a2fa9a22cecae5bf80b5a..198aa04f7835ae941774b31339069ab99d49273b 100644
--- a/src/heap/mark-compact.cc
+++ b/src/heap/mark-compact.cc
@@ -2630,11 +2630,14 @@ void MarkCompactCollector::MigrateObject(HeapObject* dst, HeapObject* src,
DCHECK(IsAligned(size, kPointerSize));
heap()->MoveBlock(dst->address(), src->address(), size);
+ if (FLAG_ignition && dst->IsBytecodeArray()) {
+ PROFILE(isolate(), CodeMoveEvent(AbstractCode::cast(src), dst_addr));
+ }
RecordMigratedSlotVisitor visitor(this, old_to_old_slots, old_to_new_slots);
dst->IterateBody(&visitor);
} else if (dest == CODE_SPACE) {
DCHECK_CODEOBJECT_SIZE(size, heap()->code_space());
- PROFILE(isolate(), CodeMoveEvent(src_addr, dst_addr));
+ PROFILE(isolate(), CodeMoveEvent(AbstractCode::cast(src), dst_addr));
heap()->MoveBlock(dst_addr, src_addr, size);
old_to_old_slots->Record(RELOCATED_CODE_OBJECT, dst_addr);
Code::cast(dst)->Relocate(dst_addr - src_addr);
@@ -3876,18 +3879,6 @@ void MarkCompactCollector::ParallelSweepSpacesComplete() {
sweeping_list(heap()->map_space()).clear();
}
-
-// TODO(1466) ReportDeleteIfNeeded is not called currently.
-// Our profiling tools do not expect intersections between
-// code objects. We should either reenable it or change our tools.
-void MarkCompactCollector::ReportDeleteIfNeeded(HeapObject* obj,
- Isolate* isolate) {
- if (obj->IsCode()) {
- PROFILE(isolate, CodeDeleteEvent(obj->address()));
- }
-}
-
-
Isolate* MarkCompactCollector::isolate() const { return heap_->isolate(); }
« no previous file with comments | « src/full-codegen/full-codegen.cc ('k') | src/heap/spaces.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698