diff options
author | Kent Hansen <kent.hansen@nokia.com> | 2011-10-20 10:31:42 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-10-20 13:30:26 +0200 |
commit | ce5adc76847edf10dc843f5c93485e393f0ca099 (patch) | |
tree | 26ba0fde1d5a343dba15a5e8be1a78c91e3d6bb4 /src/v8/0002-Add-a-bit-field-3-to-Map.patch | |
parent | 3885a45e48b7fd680b6cb83e2d0d618fd04cf690 (diff) |
Revert "Update V8"
This reverts commit 1c4a5fcab76d1b769a4c0369d40dd0dd7c0e7495
Several of the qtdeclarative tests and examples are dying randomly with messages like this:
>
> #
> # Fatal error in ../3rdparty/v8/src/objects-inl.h, line 2169
> # CHECK(object->IsJSFunction()) failed
> #
>
>
> ==== Stack trace ============================================
>
>
> ==== Details ================================================
>
> ==== Key ============================================
>
> =====================
>
> Aborted (core dumped)
Change-Id: Iebaa2497a6f6ef616ef4c3576c217d2a8a2c1ea5
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Diffstat (limited to 'src/v8/0002-Add-a-bit-field-3-to-Map.patch')
-rw-r--r-- | src/v8/0002-Add-a-bit-field-3-to-Map.patch | 118 |
1 files changed, 118 insertions, 0 deletions
diff --git a/src/v8/0002-Add-a-bit-field-3-to-Map.patch b/src/v8/0002-Add-a-bit-field-3-to-Map.patch new file mode 100644 index 0000000000..59dbad3135 --- /dev/null +++ b/src/v8/0002-Add-a-bit-field-3-to-Map.patch @@ -0,0 +1,118 @@ +From 01f7bd262fb1be893fe4bdc6b98a1b43c5a0bb7d Mon Sep 17 00:00:00 2001 +From: Aaron Kennedy <aaron.kennedy@nokia.com> +Date: Mon, 23 May 2011 15:55:26 +1000 +Subject: [PATCH 02/16] Add a bit field 3 to Map + +Bit field 3 will be used to add QML specific map flags. +--- + src/heap.cc | 2 ++ + src/objects-inl.h | 10 ++++++++++ + src/objects.cc | 2 ++ + src/objects.h | 9 ++++++++- + 4 files changed, 22 insertions(+), 1 deletions(-) + +diff --git a/src/heap.cc b/src/heap.cc +index 930c97b..900f462 100644 +--- a/src/heap.cc ++++ b/src/heap.cc +@@ -1573,6 +1573,7 @@ MaybeObject* Heap::AllocatePartialMap(InstanceType instance_type, + reinterpret_cast<Map*>(result)->set_unused_property_fields(0); + reinterpret_cast<Map*>(result)->set_bit_field(0); + reinterpret_cast<Map*>(result)->set_bit_field2(0); ++ reinterpret_cast<Map*>(result)->set_bit_field3(0); + return result; + } + +@@ -1599,6 +1600,7 @@ MaybeObject* Heap::AllocateMap(InstanceType instance_type, int instance_size) { + map->set_unused_property_fields(0); + map->set_bit_field(0); + map->set_bit_field2((1 << Map::kIsExtensible) | (1 << Map::kHasFastElements)); ++ map->set_bit_field3(0); + + // If the map object is aligned fill the padding area with Smi 0 objects. + if (Map::kPadStart < Map::kSize) { +diff --git a/src/objects-inl.h b/src/objects-inl.h +index c82080d..cce3edd 100644 +--- a/src/objects-inl.h ++++ b/src/objects-inl.h +@@ -2430,6 +2430,16 @@ void Map::set_bit_field2(byte value) { + } + + ++byte Map::bit_field3() { ++ return READ_BYTE_FIELD(this, kBitField3Offset); ++} ++ ++ ++void Map::set_bit_field3(byte value) { ++ WRITE_BYTE_FIELD(this, kBitField3Offset, value); ++} ++ ++ + void Map::set_non_instance_prototype(bool value) { + if (value) { + set_bit_field(bit_field() | (1 << kHasNonInstancePrototype)); +diff --git a/src/objects.cc b/src/objects.cc +index dc4b260..79d7240 100644 +--- a/src/objects.cc ++++ b/src/objects.cc +@@ -3614,6 +3614,7 @@ MaybeObject* Map::CopyDropDescriptors() { + } + Map::cast(result)->set_bit_field(bit_field()); + Map::cast(result)->set_bit_field2(bit_field2()); ++ Map::cast(result)->set_bit_field3(bit_field3()); + Map::cast(result)->set_is_shared(false); + Map::cast(result)->ClearCodeCache(heap); + return result; +@@ -3642,6 +3643,7 @@ MaybeObject* Map::CopyNormalized(PropertyNormalizationMode mode, + + Map::cast(result)->set_bit_field(bit_field()); + Map::cast(result)->set_bit_field2(bit_field2()); ++ Map::cast(result)->set_bit_field3(bit_field3()); + + Map::cast(result)->set_is_shared(sharing == SHARED_NORMALIZED_MAP); + +diff --git a/src/objects.h b/src/objects.h +index 6e26f57..07e1089 100644 +--- a/src/objects.h ++++ b/src/objects.h +@@ -3597,6 +3597,10 @@ class Map: public HeapObject { + inline byte bit_field2(); + inline void set_bit_field2(byte value); + ++ // Bit field 3. ++ inline byte bit_field3(); ++ inline void set_bit_field3(byte value); ++ + // Tells whether the object in the prototype property will be used + // for instances created from this function. If the prototype + // property is set to a value that is not a JSObject, the prototype +@@ -3844,7 +3848,7 @@ class Map: public HeapObject { + // Layout description. + static const int kInstanceSizesOffset = HeapObject::kHeaderSize; + static const int kInstanceAttributesOffset = kInstanceSizesOffset + kIntSize; +- static const int kPrototypeOffset = kInstanceAttributesOffset + kIntSize; ++ static const int kPrototypeOffset = POINTER_SIZE_ALIGN(kInstanceAttributesOffset + 2 * kIntSize); + static const int kConstructorOffset = kPrototypeOffset + kPointerSize; + static const int kInstanceDescriptorsOffset = + kConstructorOffset + kPointerSize; +@@ -3876,6 +3880,7 @@ class Map: public HeapObject { + static const int kUnusedPropertyFieldsOffset = kInstanceAttributesOffset + 1; + static const int kBitFieldOffset = kInstanceAttributesOffset + 2; + static const int kBitField2Offset = kInstanceAttributesOffset + 3; ++ static const int kBitField3Offset = kInstanceAttributesOffset + 4; + + STATIC_CHECK(kInstanceTypeOffset == Internals::kMapInstanceTypeOffset); + +@@ -3898,6 +3903,8 @@ class Map: public HeapObject { + static const int kIsShared = 5; + static const int kHasExternalArrayElements = 6; + ++ // Bit positions for bit field 3 ++ + // Layout of the default cache. It holds alternating name and code objects. + static const int kCodeCacheEntrySize = 2; + static const int kCodeCacheEntryNameOffset = 0; +-- +1.7.4.4 + |