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

Unified Diff: src/objects-inl.h

Issue 1135353003: Factor out handling of mixed objects preprocessing after migration (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 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
« src/objects.h ('K') | « src/objects.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects-inl.h
diff --git a/src/objects-inl.h b/src/objects-inl.h
index 026166fbf70ee7e8755215361914abddc698c038..3ac52bdf626024a33f52a428db0449b4a1a5e9af 100644
--- a/src/objects-inl.h
+++ b/src/objects-inl.h
@@ -1549,6 +1549,22 @@ bool HeapObject::MayContainRawValues() {
}
+bool HeapObject::MayContainMixedValues() {
+ InstanceType type = map()->instance_type();
+ switch (type) {
+ case CONSTANT_POOL_ARRAY_TYPE:
+ case JS_FUNCTION_TYPE:
+ return true;
+ default:
+ if (type >= FIRST_FIXED_TYPED_ARRAY_TYPE &&
+ type <= LAST_FIXED_TYPED_ARRAY_TYPE) {
+ return true;
+ }
+ return false;
+ }
+}
+
+
void HeapObject::IteratePointers(ObjectVisitor* v, int start, int end) {
v->VisitPointers(reinterpret_cast<Object**>(FIELD_ADDR(this, start)),
reinterpret_cast<Object**>(FIELD_ADDR(this, end)));
« src/objects.h ('K') | « src/objects.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698