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

Unified Diff: src/heap-inl.h

Issue 7477045: Tentative implementation of string slices (hidden under the flag --string-slices). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Some more suggested changes. Created 9 years, 4 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
Index: src/heap-inl.h
diff --git a/src/heap-inl.h b/src/heap-inl.h
index b0b4fbe2dcbd45f0a7a437e956efbf74004f0927..7aed7bb114d7d50ad04e36f0bc4f33bfe6266165 100644
--- a/src/heap-inl.h
+++ b/src/heap-inl.h
@@ -318,10 +318,10 @@ AllocationSpace Heap::TargetSpaceId(InstanceType type) {
ASSERT(type != JS_GLOBAL_PROPERTY_CELL_TYPE);
if (type < FIRST_NONSTRING_TYPE) {
- // There are three string representations: sequential strings, cons
- // strings, and external strings. Only cons strings contain
- // non-map-word pointers to heap objects.
- return ((type & kStringRepresentationMask) == kConsStringTag)
+ // There are four string representations: sequential strings, external
+ // strings, cons strings, and sliced strings.
+ // Only the latter two contain non-map-word pointers to heap objects.
+ return ((type & kIsIndirectStringMask) == kIsIndirectStringTag)
? OLD_POINTER_SPACE
: OLD_DATA_SPACE;
} else {

Powered by Google App Engine
This is Rietveld 408576698