summaryrefslogtreecommitdiffstats
path: root/src/v8/0004-Generalize-external-object-resources.patch
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2011-09-07 10:51:39 +1000
committerQt by Nokia <qt-info@nokia.com>2011-09-07 04:50:45 +0200
commitbc2eac1ef3e6902f8fed65f72b70b582f93bcb19 (patch)
tree6af22cb1316b194268981bee884d17ba40dbce3a /src/v8/0004-Generalize-external-object-resources.patch
parent846c5c9459331cde33ef92b665fab1457eaf1252 (diff)
Update V8
This fixes a few bugs in QML mode name resolution and simplifies our V8 patchset a little by folding some patches together. Change-Id: Ia528a43ac8ccad95ac81bcdff5d05aaeab4b48b2 Reviewed-on: http://codereview.qt.nokia.com/4294 Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
Diffstat (limited to 'src/v8/0004-Generalize-external-object-resources.patch')
-rw-r--r--src/v8/0004-Generalize-external-object-resources.patch272
1 files changed, 136 insertions, 136 deletions
diff --git a/src/v8/0004-Generalize-external-object-resources.patch b/src/v8/0004-Generalize-external-object-resources.patch
index a05aad0889..3a232af619 100644
--- a/src/v8/0004-Generalize-external-object-resources.patch
+++ b/src/v8/0004-Generalize-external-object-resources.patch
@@ -1,7 +1,7 @@
-From 4827116b12c50f6662794017c5a662b5dbb2da0b Mon Sep 17 00:00:00 2001
+From f9368b52060c31e9532ef26f6cca1a2cb0283f51 Mon Sep 17 00:00:00 2001
From: Aaron Kennedy <aaron.kennedy@nokia.com>
Date: Mon, 23 May 2011 16:55:35 +1000
-Subject: [PATCH 04/16] Generalize external object resources
+Subject: [PATCH 04/14] Generalize external object resources
V8 was already able to manage and finalize an external string
resource. This change generalizes that mechanism to handle a
@@ -31,13 +31,13 @@ object space.
11 files changed, 280 insertions(+), 115 deletions(-)
diff --git a/include/v8.h b/include/v8.h
-index 85452aa..7f06ae7 100644
+index bb31ea0..205e856 100644
--- a/include/v8.h
+++ b/include/v8.h
-@@ -1630,6 +1630,25 @@ class Object : public Value {
+@@ -1631,6 +1631,25 @@ class Object : public Value {
/** Sets a native pointer in an internal field. */
V8EXPORT void SetPointerInInternalField(int index, void* value);
-
+
+ class V8EXPORT ExternalResource { // NOLINT
+ public:
+ ExternalResource() {}
@@ -60,10 +60,10 @@ index 85452aa..7f06ae7 100644
// Testers for local properties.
V8EXPORT bool HasRealNamedProperty(Handle<String> key);
V8EXPORT bool HasRealIndexedProperty(uint32_t index);
-@@ -2331,6 +2350,12 @@ class V8EXPORT ObjectTemplate : public Template {
+@@ -2332,6 +2351,12 @@ class V8EXPORT ObjectTemplate : public Template {
*/
void SetInternalFieldCount(int value);
-
+
+ /**
+ * Sets whether the object can store an "external resource" object.
+ */
@@ -79,8 +79,8 @@ index 8b0b32a..1a6fbbb 100644
+++ b/src/api.cc
@@ -1294,6 +1294,34 @@ void ObjectTemplate::SetInternalFieldCount(int value) {
}
-
-
+
+
+bool ObjectTemplate::HasExternalResource()
+{
+ if (IsDeadCheck(Utils::OpenHandle(this)->GetIsolate(),
@@ -110,12 +110,12 @@ index 8b0b32a..1a6fbbb 100644
+
+
// --- S c r i p t D a t a ---
-
-
+
+
@@ -3652,6 +3680,34 @@ void v8::Object::SetPointerInInternalField(int index, void* value) {
}
-
-
+
+
+void v8::Object::SetExternalResource(v8::Object::ExternalResource *resource) {
+ i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate();
+ ENTER_V8(isolate);
@@ -145,8 +145,8 @@ index 8b0b32a..1a6fbbb 100644
+
+
// --- E n v i r o n m e n t ---
-
-
+
+
@@ -4144,7 +4200,7 @@ Local<String> v8::String::NewExternal(
LOG_API(isolate, "String::NewExternal");
ENTER_V8(isolate);
@@ -155,7 +155,7 @@ index 8b0b32a..1a6fbbb 100644
+ isolate->heap()->external_resource_table()->AddString(*result);
return Utils::ToLocal(result);
}
-
+
@@ -4162,7 +4218,7 @@ bool v8::String::MakeExternal(v8::String::ExternalStringResource* resource) {
}
bool result = obj->MakeExternal(resource);
@@ -173,7 +173,7 @@ index 8b0b32a..1a6fbbb 100644
+ isolate->heap()->external_resource_table()->AddString(*result);
return Utils::ToLocal(result);
}
-
+
@@ -4194,7 +4250,7 @@ bool v8::String::MakeExternal(
}
bool result = obj->MakeExternal(resource);
@@ -211,7 +211,7 @@ index dcdc645..d530a75 100644
+++ b/src/factory.cc
@@ -997,15 +997,21 @@ Handle<JSFunction> Factory::CreateApiFunction(
Handle<Code> construct_stub = isolate()->builtins()->JSConstructStubApi();
-
+
int internal_field_count = 0;
+ bool has_external_resource = false;
+
@@ -224,7 +224,7 @@ index dcdc645..d530a75 100644
+ has_external_resource =
+ !instance_template->has_external_resource()->IsUndefined();
}
-
+
int instance_size = kPointerSize * internal_field_count;
+ if (has_external_resource) instance_size += kPointerSize;
+
@@ -232,9 +232,9 @@ index dcdc645..d530a75 100644
switch (instance_type) {
case JavaScriptObject:
@@ -1040,6 +1046,11 @@ Handle<JSFunction> Factory::CreateApiFunction(
-
+
Handle<Map> map = Handle<Map>(result->initial_map());
-
+
+ // Mark as having external data object if needed
+ if (has_external_resource) {
+ map->set_has_external_resource(true);
@@ -249,8 +249,8 @@ index f4fce7b..58e7adf 100644
+++ b/src/heap-inl.h
@@ -205,21 +205,36 @@ MaybeObject* Heap::NumberFromUint32(uint32_t value) {
}
-
-
+
+
-void Heap::FinalizeExternalString(String* string) {
- ASSERT(string->IsExternalString());
- v8::String::ExternalStringResourceBase** resource_addr =
@@ -277,7 +277,7 @@ index f4fce7b..58e7adf 100644
+ if (*resource_addr != NULL) {
+ (*resource_addr)->Dispose();
+ }
-
+
- // Clear the resource pointer in the string.
- *resource_addr = NULL;
+ // Clear the resource pointer in the string.
@@ -290,18 +290,18 @@ index f4fce7b..58e7adf 100644
+ resource = reinterpret_cast<v8::Object::ExternalResource*>(Internals::GetExternalPointerFromSmi(value));
+ } else if (value->IsProxy()) {
+ resource = reinterpret_cast<v8::Object::ExternalResource*>(Proxy::cast(value)->proxy());
-+ }
++ }
+ if (resource) {
+ resource->Dispose();
+ }
+ }
}
-
-
+
+
@@ -556,53 +571,63 @@ inline bool Heap::allow_allocation(bool new_state) {
#endif
-
-
+
+
-void ExternalStringTable::AddString(String* string) {
- ASSERT(string->IsExternalString());
+void ExternalResourceTable::AddString(String* string) {
@@ -324,8 +324,8 @@ index f4fce7b..58e7adf 100644
+ old_space_objects_.Add(object);
}
}
-
-
+
+
-void ExternalStringTable::Iterate(ObjectVisitor* v) {
- if (!new_space_strings_.is_empty()) {
- Object** start = &new_space_strings_[0];
@@ -343,8 +343,8 @@ index f4fce7b..58e7adf 100644
+ v->VisitPointers(start, start + old_space_objects_.length());
}
}
-
-
+
+
// Verify() is inline to avoid ifdef-s around its calls in release
// mode.
-void ExternalStringTable::Verify() {
@@ -366,8 +366,8 @@ index f4fce7b..58e7adf 100644
}
#endif
}
-
-
+
+
-void ExternalStringTable::AddOldString(String* string) {
- ASSERT(string->IsExternalString());
- ASSERT(!heap_->InNewSpace(string));
@@ -377,15 +377,15 @@ index f4fce7b..58e7adf 100644
+ ASSERT(!heap_->InNewSpace(object));
+ old_space_objects_.Add(object);
}
-
-
+
+
-void ExternalStringTable::ShrinkNewStrings(int position) {
- new_space_strings_.Rewind(position);
+void ExternalResourceTable::ShrinkNewObjects(int position) {
+ new_space_objects_.Rewind(position);
Verify();
}
-
+
diff --git a/src/heap.cc b/src/heap.cc
index 900f462..bf2940e 100644
--- a/src/heap.cc
@@ -397,68 +397,68 @@ index 900f462..bf2940e 100644
- external_string_table_.heap_ = this;
+ external_resource_table_.heap_ = this;
}
-
-
+
+
@@ -1030,8 +1030,8 @@ void Heap::Scavenge() {
-
+
new_space_front = DoScavenge(&scavenge_visitor, new_space_front);
-
+
- UpdateNewSpaceReferencesInExternalStringTable(
- &UpdateNewSpaceReferenceInExternalStringTableEntry);
+ UpdateNewSpaceReferencesInExternalResourceTable(
+ &UpdateNewSpaceReferenceInExternalResourceTableEntry);
-
+
LiveObjectList::UpdateReferencesForScavengeGC();
isolate()->runtime_profiler()->UpdateSamplesAfterScavenge();
@@ -1053,38 +1053,38 @@ void Heap::Scavenge() {
}
-
-
+
+
-String* Heap::UpdateNewSpaceReferenceInExternalStringTableEntry(Heap* heap,
- Object** p) {
+HeapObject* Heap::UpdateNewSpaceReferenceInExternalResourceTableEntry(Heap* heap,
+ Object** p) {
MapWord first_word = HeapObject::cast(*p)->map_word();
-
+
if (!first_word.IsForwardingAddress()) {
// Unreachable external string can be finalized.
- heap->FinalizeExternalString(String::cast(*p));
+ heap->FinalizeExternalString(HeapObject::cast(*p));
return NULL;
}
-
+
// String is still reachable.
- return String::cast(first_word.ToForwardingAddress());
+ return HeapObject::cast(first_word.ToForwardingAddress());
}
-
-
+
+
-void Heap::UpdateNewSpaceReferencesInExternalStringTable(
- ExternalStringTableUpdaterCallback updater_func) {
- external_string_table_.Verify();
+void Heap::UpdateNewSpaceReferencesInExternalResourceTable(
+ ExternalResourceTableUpdaterCallback updater_func) {
+ external_resource_table_.Verify();
-
+
- if (external_string_table_.new_space_strings_.is_empty()) return;
+ if (external_resource_table_.new_space_objects_.is_empty()) return;
-
+
- Object** start = &external_string_table_.new_space_strings_[0];
- Object** end = start + external_string_table_.new_space_strings_.length();
+ Object** start = &external_resource_table_.new_space_objects_[0];
+ Object** end = start + external_resource_table_.new_space_objects_.length();
Object** last = start;
-
+
for (Object** p = start; p < end; ++p) {
ASSERT(InFromSpace(*p));
- String* target = updater_func(this, p);
+ HeapObject* target = updater_func(this, p);
-
+
if (target == NULL) continue;
-
+
- ASSERT(target->IsExternalString());
+ ASSERT(target->IsExternalString() || target->map()->has_external_resource());
-
+
if (InNewSpace(target)) {
// String is still in new space. Update the table entry.
@@ -1092,12 +1092,12 @@ void Heap::UpdateNewSpaceReferencesInExternalStringTable(
@@ -469,13 +469,13 @@ index 900f462..bf2940e 100644
+ external_resource_table_.AddOldObject(target);
}
}
-
+
ASSERT(last <= end);
- external_string_table_.ShrinkNewStrings(static_cast<int>(last - start));
+ external_resource_table_.ShrinkNewObjects(static_cast<int>(last - start));
}
-
-
+
+
@@ -4468,7 +4468,7 @@ void Heap::IterateWeakRoots(ObjectVisitor* v, VisitMode mode) {
v->Synchronize("symbol_table");
if (mode != VISIT_ALL_IN_SCAVENGE) {
@@ -486,18 +486,18 @@ index 900f462..bf2940e 100644
v->Synchronize("external_string_table");
}
@@ -4970,7 +4970,7 @@ void Heap::TearDown() {
-
+
isolate_->global_handles()->TearDown();
-
+
- external_string_table_.TearDown();
+ external_resource_table_.TearDown();
-
+
new_space_.TearDown();
-
+
@@ -5835,31 +5835,31 @@ void TranscendentalCache::Clear() {
}
-
-
+
+
-void ExternalStringTable::CleanUp() {
+void ExternalResourceTable::CleanUp() {
int last = 0;
@@ -530,8 +530,8 @@ index 900f462..bf2940e 100644
+ old_space_objects_.Rewind(last);
Verify();
}
-
-
+
+
-void ExternalStringTable::TearDown() {
- new_space_strings_.Free();
- old_space_strings_.Free();
@@ -539,33 +539,33 @@ index 900f462..bf2940e 100644
+ new_space_objects_.Free();
+ old_space_objects_.Free();
}
-
-
+
+
diff --git a/src/heap.h b/src/heap.h
index ae4e9e7..8cbf378 100644
--- a/src/heap.h
+++ b/src/heap.h
@@ -237,8 +237,8 @@ class Isolate;
class WeakObjectRetainer;
-
-
+
+
-typedef String* (*ExternalStringTableUpdaterCallback)(Heap* heap,
- Object** pointer);
+typedef HeapObject* (*ExternalResourceTableUpdaterCallback)(Heap* heap,
+ Object** pointer);
-
+
typedef bool (*DirtyRegionCallback)(Heap* heap,
Address start,
@@ -284,43 +284,45 @@ class PromotionQueue {
};
-
-
+
+
-// External strings table is a place where all external strings are
-// registered. We need to keep track of such strings to properly
-// finalize them.
-class ExternalStringTable {
+// External resource table is a place where all external strings and
-+// objects with an external resource are registered. We need to keep
++// objects with an external resource are registered. We need to keep
+// track of such strings to properly finalize them.
+class ExternalResourceTable {
public:
@@ -573,95 +573,95 @@ index ae4e9e7..8cbf378 100644
inline void AddString(String* string);
+ // Registers an external object.
+ inline void AddObject(HeapObject* object);
-
+
inline void Iterate(ObjectVisitor* v);
-
+
// Restores internal invariant and gets rid of collected strings.
- // Must be called after each Iterate() that modified the strings.
+ // Must be called after each Iterate() that modified the objects.
void CleanUp();
-
+
// Destroys all allocated memory.
void TearDown();
-
+
private:
- ExternalStringTable() { }
+ ExternalResourceTable() { }
-
+
friend class Heap;
-
+
inline void Verify();
-
+
- inline void AddOldString(String* string);
+ inline void AddOldObject(HeapObject* object);
-
+
// Notifies the table that only a prefix of the new list is valid.
- inline void ShrinkNewStrings(int position);
+ inline void ShrinkNewObjects(int position);
-
+
// To speed up scavenge collections new space string are kept
// separate from old space strings.
- List<Object*> new_space_strings_;
- List<Object*> old_space_strings_;
+ List<Object*> new_space_objects_;
+ List<Object*> old_space_objects_;
-
+
Heap* heap_;
-
+
- DISALLOW_COPY_AND_ASSIGN(ExternalStringTable);
+ DISALLOW_COPY_AND_ASSIGN(ExternalResourceTable);
};
-
-
+
+
@@ -753,7 +755,7 @@ class Heap {
-
+
// Finalizes an external string by deleting the associated external
// data and clearing the resource pointer.
- inline void FinalizeExternalString(String* string);
+ inline void FinalizeExternalString(HeapObject* string);
-
+
// Allocates an uninitialized object. The memory is non-executable if the
// hardware and OS allow.
@@ -1191,8 +1193,8 @@ class Heap {
survived_since_last_expansion_ += survived;
}
-
+
- void UpdateNewSpaceReferencesInExternalStringTable(
- ExternalStringTableUpdaterCallback updater_func);
+ void UpdateNewSpaceReferencesInExternalResourceTable(
+ ExternalResourceTableUpdaterCallback updater_func);
-
+
void ProcessWeakReferences(WeakObjectRetainer* retainer);
-
+
@@ -1228,8 +1230,8 @@ class Heap {
return &mark_compact_collector_;
}
-
+
- ExternalStringTable* external_string_table() {
- return &external_string_table_;
+ ExternalResourceTable* external_resource_table() {
+ return &external_resource_table_;
}
-
+
inline Isolate* isolate();
@@ -1462,7 +1464,7 @@ class Heap {
// Performs a minor collection in new generation.
void Scavenge();
-
+
- static String* UpdateNewSpaceReferenceInExternalStringTableEntry(
+ static HeapObject* UpdateNewSpaceReferenceInExternalResourceTableEntry(
Heap* heap,
Object** pointer);
-
+
@@ -1593,7 +1595,7 @@ class Heap {
// configured through the API until it is setup.
bool configured_;
-
+
- ExternalStringTable external_string_table_;
+ ExternalResourceTable external_resource_table_;
-
+
bool is_safe_to_read_maps_;
-
+
diff --git a/src/liveobjectlist.cc b/src/liveobjectlist.cc
index 5795a6b..8866e58 100644
--- a/src/liveobjectlist.cc
@@ -685,26 +685,26 @@ index 5795a6b..8866e58 100644
} else {
delete resource;
diff --git a/src/mark-compact.cc b/src/mark-compact.cc
-index 68a5062..1b1e361 100644
+index 68a5062..775f787 100644
--- a/src/mark-compact.cc
+++ b/src/mark-compact.cc
@@ -163,7 +163,7 @@ void MarkCompactCollector::Finish() {
// objects (empty string, illegal builtin).
heap()->isolate()->stub_cache()->Clear();
-
+
- heap()->external_string_table_.CleanUp();
+ heap()->external_resource_table_.CleanUp();
-
+
// If we've just compacted old space there's no reason to check the
// fragmentation limit. Just return.
@@ -1019,8 +1019,9 @@ class SymbolTableCleaner : public ObjectVisitor {
-
+
// Since no objects have yet been moved we can safely access the map of
// the object.
- if ((*p)->IsExternalString()) {
- heap_->FinalizeExternalString(String::cast(*p));
+ if ((*p)->IsExternalString() ||
-+ (*p)->IsHeapObject() && HeapObject::cast(*p)->map()->has_external_resource()) {
++ ((*p)->IsHeapObject() && HeapObject::cast(*p)->map()->has_external_resource())) {
+ heap_->FinalizeExternalString(HeapObject::cast(*p));
}
// Set the entry to null_value (as deleted).
@@ -717,13 +717,13 @@ index 68a5062..1b1e361 100644
- heap()->external_string_table_.CleanUp();
+ heap()->external_resource_table_.Iterate(&v);
+ heap()->external_resource_table_.CleanUp();
-
+
// Process the weak references.
MarkCompactWeakObjectRetainer mark_compact_object_retainer;
@@ -1948,11 +1949,11 @@ static void UpdatePointerToNewGen(HeapObject** p) {
}
-
-
+
+
-static String* UpdateNewSpaceReferenceInExternalStringTableEntry(Heap* heap,
- Object** p) {
+static HeapObject* UpdateNewSpaceReferenceInExternalResourceTableEntry(Heap* heap,
@@ -733,17 +733,17 @@ index 68a5062..1b1e361 100644
- return String::cast(HeapObject::FromAddress(new_addr));
+ return HeapObject::FromAddress(new_addr);
}
-
-
+
+
@@ -2083,8 +2084,8 @@ static void SweepNewSpace(Heap* heap, NewSpace* space) {
updating_visitor.VisitPointer(heap->global_contexts_list_address());
-
+
// Update pointers from external string table.
- heap->UpdateNewSpaceReferencesInExternalStringTable(
- &UpdateNewSpaceReferenceInExternalStringTableEntry);
+ heap->UpdateNewSpaceReferencesInExternalResourceTable(
+ &UpdateNewSpaceReferenceInExternalResourceTableEntry);
-
+
// All pointers were updated. Update auxiliary allocation info.
heap->IncrementYoungSurvivorsCounter(survivors_size);
diff --git a/src/objects-inl.h b/src/objects-inl.h
@@ -757,15 +757,15 @@ index 6aaca2f..231b835 100644
- map()->inobject_properties();
+ map()->inobject_properties() - map()->has_external_resource()?1:0;
}
-
-
+
+
int JSObject::GetInternalFieldOffset(int index) {
ASSERT(index < GetInternalFieldCount() && index >= 0);
- return GetHeaderSize() + (kPointerSize * index);
+ return GetHeaderSize() + (kPointerSize * (index + map()->has_external_resource()?1:0));
}
-
-
+
+
@@ -1407,7 +1407,7 @@ Object* JSObject::GetInternalField(int index) {
// Internal objects do follow immediately after the header, whereas in-object
// properties are at the end of the object. Therefore there is no need
@@ -773,8 +773,8 @@ index 6aaca2f..231b835 100644
- return READ_FIELD(this, GetHeaderSize() + (kPointerSize * index));
+ return READ_FIELD(this, GetHeaderSize() + (kPointerSize * (index + map()->has_external_resource()?1:0)));
}
-
-
+
+
@@ -1416,12 +1416,29 @@ void JSObject::SetInternalField(int index, Object* value) {
// Internal objects do follow immediately after the header, whereas in-object
// properties are at the end of the object. Therefore there is no need
@@ -784,8 +784,8 @@ index 6aaca2f..231b835 100644
WRITE_FIELD(this, offset, value);
WRITE_BARRIER(this, offset);
}
-
-
+
+
+void JSObject::SetExternalResourceObject(Object *value) {
+ ASSERT(map()->has_external_resource());
+ int offset = GetHeaderSize();
@@ -794,7 +794,7 @@ index 6aaca2f..231b835 100644
+}
+
+
-+Object *JSObject::GetExternalResourceObject() {
++Object *JSObject::GetExternalResourceObject() {
+ if (map()->has_external_resource()) {
+ return READ_FIELD(this, GetHeaderSize());
+ } else {
@@ -808,8 +808,8 @@ index 6aaca2f..231b835 100644
// properties stored in the properties array.
@@ -2521,6 +2538,20 @@ bool Map::is_shared() {
}
-
-
+
+
+void Map::set_has_external_resource(bool value) {
+ if (value) {
+ set_bit_field3(bit_field3() | (1 << kHasExternalResource));
@@ -822,7 +822,7 @@ index 6aaca2f..231b835 100644
+{
+ return ((1 << kHasExternalResource) & bit_field3()) != 0;
+}
-+
++
+
void Map::set_named_interceptor_is_fallback(bool value)
{
@@ -831,9 +831,9 @@ index 6aaca2f..231b835 100644
ACCESSORS(ObjectTemplateInfo, constructor, Object, kConstructorOffset)
ACCESSORS(ObjectTemplateInfo, internal_field_count, Object,
kInternalFieldCountOffset)
-+ACCESSORS(ObjectTemplateInfo, has_external_resource, Object,
++ACCESSORS(ObjectTemplateInfo, has_external_resource, Object,
+ kHasExternalResourceOffset)
-
+
ACCESSORS(SignatureInfo, receiver, Object, kReceiverOffset)
ACCESSORS(SignatureInfo, args, Object, kArgsOffset)
diff --git a/src/objects.h b/src/objects.h
@@ -843,7 +843,7 @@ index a209cd0..1bdb5c7 100644
@@ -1636,6 +1636,9 @@ class JSObject: public HeapObject {
inline Object* GetInternalField(int index);
inline void SetInternalField(int index, Object* value);
-
+
+ inline void SetExternalResourceObject(Object *);
+ inline Object *GetExternalResourceObject();
+
@@ -853,22 +853,22 @@ index a209cd0..1bdb5c7 100644
@@ -3715,6 +3718,12 @@ class Map: public HeapObject {
inline void set_is_access_check_needed(bool access_check_needed);
inline bool is_access_check_needed();
-
+
+
+ // Tells whether the instance has the space for an external resource
+ // object
+ inline void set_has_external_resource(bool value);
+ inline bool has_external_resource();
+
-
+
// Whether the named interceptor is a fallback interceptor or not
inline void set_named_interceptor_is_fallback(bool value);
@@ -3912,6 +3921,7 @@ class Map: public HeapObject {
-
+
// Bit positions for bit field 3
static const int kNamedInterceptorIsFallback = 0;
+ static const int kHasExternalResource = 1;
-
+
// Layout of the default cache. It holds alternating name and code objects.
static const int kCodeCacheEntrySize = 2;
@@ -6426,6 +6436,7 @@ class ObjectTemplateInfo: public TemplateInfo {
@@ -876,9 +876,9 @@ index a209cd0..1bdb5c7 100644
DECL_ACCESSORS(constructor, Object)
DECL_ACCESSORS(internal_field_count, Object)
+ DECL_ACCESSORS(has_external_resource, Object)
-
+
static inline ObjectTemplateInfo* cast(Object* obj);
-
+
@@ -6442,7 +6453,8 @@ class ObjectTemplateInfo: public TemplateInfo {
static const int kConstructorOffset = TemplateInfo::kHeaderSize;
static const int kInternalFieldCountOffset =
@@ -887,8 +887,8 @@ index a209cd0..1bdb5c7 100644
+ static const int kHasExternalResourceOffset = kInternalFieldCountOffset + kPointerSize;
+ static const int kSize = kHasExternalResourceOffset + kPointerSize;
};
-
-
---
-1.7.6
+
+
+--
+1.7.4.4