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

Unified Diff: src/objects.h

Issue 2810653002: Add a host parameter to ObjectVisitor methods. (Closed)
Patch Set: rebase Created 3 years, 8 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/mips64/assembler-mips64-inl.h ('k') | src/objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 1bd2846185f017bd6837f42323d38cad3866e7c0..00144d2ae31c118e445f0bd5c4fe2e2300c1a666 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -10205,47 +10205,52 @@ class ObjectVisitor BASE_EMBEDDED {
// Visits a contiguous arrays of pointers in the half-open range
// [start, end). Any or all of the values may be modified on return.
- virtual void VisitPointers(Object** start, Object** end) = 0;
+ virtual void VisitPointers(HeapObject* host, Object** start,
+ Object** end) = 0;
// Handy shorthand for visiting a single pointer.
- virtual void VisitPointer(Object** p) { VisitPointers(p, p + 1); }
+ virtual void VisitPointer(HeapObject* host, Object** p) {
+ VisitPointers(host, p, p + 1);
+ }
// Visit weak next_code_link in Code object.
- virtual void VisitNextCodeLink(Object** p) { VisitPointers(p, p + 1); }
+ virtual void VisitNextCodeLink(Code* host, Object** p) {
+ VisitPointers(host, p, p + 1);
+ }
// To allow lazy clearing of inline caches the visitor has
// a rich interface for iterating over Code objects..
// Visits a code target in the instruction stream.
- virtual void VisitCodeTarget(RelocInfo* rinfo);
+ virtual void VisitCodeTarget(Code* host, RelocInfo* rinfo);
// Visits a code entry in a JS function.
- virtual void VisitCodeEntry(Address entry_address);
+ virtual void VisitCodeEntry(JSFunction* host, Address entry_address);
// Visits a global property cell reference in the instruction stream.
- virtual void VisitCell(RelocInfo* rinfo);
+ virtual void VisitCellPointer(Code* host, RelocInfo* rinfo);
// Visits a runtime entry in the instruction stream.
- virtual void VisitRuntimeEntry(RelocInfo* rinfo) {}
+ virtual void VisitRuntimeEntry(Code* host, RelocInfo* rinfo) {}
// Visits a debug call target in the instruction stream.
- virtual void VisitDebugTarget(RelocInfo* rinfo);
+ virtual void VisitDebugTarget(Code* host, RelocInfo* rinfo);
// Visits the byte sequence in a function's prologue that contains information
// about the code's age.
- virtual void VisitCodeAgeSequence(RelocInfo* rinfo);
+ virtual void VisitCodeAgeSequence(Code* host, RelocInfo* rinfo);
// Visit pointer embedded into a code object.
- virtual void VisitEmbeddedPointer(RelocInfo* rinfo);
+ virtual void VisitEmbeddedPointer(Code* host, RelocInfo* rinfo);
// Visits an external reference embedded into a code object.
- virtual void VisitExternalReference(RelocInfo* rinfo);
+ virtual void VisitExternalReference(Code* host, RelocInfo* rinfo) {}
// Visits an external reference.
- virtual void VisitExternalReference(Address* p) {}
+ virtual void VisitExternalReference(Foreign* host, Address* p) {}
// Visits an (encoded) internal reference.
- virtual void VisitInternalReference(RelocInfo* rinfo) {}
+ virtual void VisitInternalReference(Code* host, RelocInfo* rinfo) {}
};
« no previous file with comments | « src/mips64/assembler-mips64-inl.h ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698