diff --git a/deps/v8/include/v8-version.h b/deps/v8/include/v8-version.h index 25ce5d071e71c3..ce000d06c11659 100644 --- a/deps/v8/include/v8-version.h +++ b/deps/v8/include/v8-version.h @@ -11,7 +11,7 @@ #define V8_MAJOR_VERSION 6 #define V8_MINOR_VERSION 2 #define V8_BUILD_NUMBER 414 -#define V8_PATCH_LEVEL 50 +#define V8_PATCH_LEVEL 51 // Use 1 for candidates and 0 otherwise. // (Boolean macro values are not supported by all preprocessors.) diff --git a/deps/v8/src/objects.cc b/deps/v8/src/objects.cc index 28c1cd681ffd46..d9d00e058f4ee0 100644 --- a/deps/v8/src/objects.cc +++ b/deps/v8/src/objects.cc @@ -6368,13 +6368,8 @@ Smi* JSObject::GetOrCreateIdentityHash(Isolate* isolate) { return Smi::cast(hash_obj); } - int masked_hash; - // TODO(gsathya): Remove the loop and pass kHashMask directly to - // GenerateIdentityHash. - do { - int hash = isolate->GenerateIdentityHash(Smi::kMaxValue); - masked_hash = hash & JSReceiver::kHashMask; - } while (masked_hash == PropertyArray::kNoHashSentinel); + int masked_hash = isolate->GenerateIdentityHash(JSReceiver::kHashMask); + DCHECK_NE(PropertyArray::kNoHashSentinel, masked_hash); SetIdentityHash(masked_hash); return Smi::FromInt(masked_hash); diff --git a/deps/v8/src/objects.h b/deps/v8/src/objects.h index f9987c2837c466..5456bfc47f6027 100644 --- a/deps/v8/src/objects.h +++ b/deps/v8/src/objects.h @@ -1954,8 +1954,13 @@ class PropertyArray : public HeapObject { typedef BodyDescriptor BodyDescriptorWeak; static const int kLengthMask = 0x3ff; +#if V8_TARGET_ARCH_64_BIT static const int kHashMask = 0x7ffffc00; STATIC_ASSERT(kLengthMask + kHashMask == 0x7fffffff); +#else + static const int kHashMask = 0x3ffffc00; + STATIC_ASSERT(kLengthMask + kHashMask == 0x3fffffff); +#endif static const int kMaxLength = kLengthMask; STATIC_ASSERT(kMaxLength > kMaxNumberOfDescriptors);