diff --git a/deps/v8/include/v8-version.h b/deps/v8/include/v8-version.h index c2969d817cf..4fd23ab0953 100644 --- a/deps/v8/include/v8-version.h +++ b/deps/v8/include/v8-version.h @@ -11,7 +11,7 @@ #define V8_MAJOR_VERSION 8 #define V8_MINOR_VERSION 1 #define V8_BUILD_NUMBER 307 -#define V8_PATCH_LEVEL 20 +#define V8_PATCH_LEVEL 26 // Use 1 for candidates and 0 otherwise. // (Boolean macro values are not supported by all preprocessors.) diff --git a/deps/v8/infra/mb/mb_config.pyl b/deps/v8/infra/mb/mb_config.pyl index 95723ea0792..8677333c2f8 100644 --- a/deps/v8/infra/mb/mb_config.pyl +++ b/deps/v8/infra/mb/mb_config.pyl @@ -164,24 +164,34 @@ 'V8 Linux - s390x - sim': 'release_simulate_s390x', }, 'client.v8.branches': { + 'V8 Linux - previous branch': 'release_x86', + 'V8 Linux - previous branch - debug': 'debug_x86', 'V8 Linux - beta branch': 'release_x86', 'V8 Linux - beta branch - debug': 'debug_x86', 'V8 Linux - stable branch': 'release_x86', 'V8 Linux - stable branch - debug': 'debug_x86', + 'V8 Linux64 - previous branch': 'release_x64', + 'V8 Linux64 - previous branch - debug': 'debug_x64', 'V8 Linux64 - beta branch': 'release_x64', 'V8 Linux64 - beta branch - debug': 'debug_x64', 'V8 Linux64 - stable branch': 'release_x64', 'V8 Linux64 - stable branch - debug': 'debug_x64', + 'V8 arm - sim - previous branch': 'release_simulate_arm', + 'V8 arm - sim - previous branch - debug': 'debug_simulate_arm', 'V8 arm - sim - beta branch': 'release_simulate_arm', 'V8 arm - sim - beta branch - debug': 'debug_simulate_arm', 'V8 arm - sim - stable branch': 'release_simulate_arm', 'V8 arm - sim - stable branch - debug': 'debug_simulate_arm', + 'V8 mips64el - sim - previous branch': 'release_simulate_mips64el', 'V8 mips64el - sim - beta branch': 'release_simulate_mips64el', 'V8 mips64el - sim - stable branch': 'release_simulate_mips64el', + 'V8 mipsel - sim - previous branch': 'release_simulate_mipsel', 'V8 mipsel - sim - beta branch': 'release_simulate_mipsel', 'V8 mipsel - sim - stable branch': 'release_simulate_mipsel', + 'V8 ppc64 - sim - previous branch': 'release_simulate_ppc64', 'V8 ppc64 - sim - beta branch': 'release_simulate_ppc64', 'V8 ppc64 - sim - stable branch': 'release_simulate_ppc64', + 'V8 s390x - sim - previous branch': 'release_simulate_s390x', 'V8 s390x - sim - beta branch': 'release_simulate_s390x', 'V8 s390x - sim - stable branch': 'release_simulate_s390x', }, diff --git a/deps/v8/infra/testing/builders.pyl b/deps/v8/infra/testing/builders.pyl index 0e4ac9d875e..b26f1a1f08a 100644 --- a/deps/v8/infra/testing/builders.pyl +++ b/deps/v8/infra/testing/builders.pyl @@ -1686,6 +1686,26 @@ {'name': 'v8testing', 'shards': 3}, ], }, + 'V8 Linux - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'mozilla'}, + {'name': 'test262', 'variant': 'default'}, + {'name': 'v8testing'}, + ], + }, + 'V8 Linux - previous branch - debug': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'mozilla'}, + {'name': 'test262', 'variant': 'default'}, + {'name': 'v8testing', 'shards': 3}, + ], + }, 'V8 Linux64 - beta branch': { 'swarming_dimensions': { 'os': 'Ubuntu-16.04', @@ -1726,6 +1746,26 @@ {'name': 'v8testing', 'shards': 3}, ], }, + 'V8 Linux64 - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'mozilla'}, + {'name': 'test262', 'variant': 'default'}, + {'name': 'v8testing'}, + ], + }, + 'V8 Linux64 - previous branch - debug': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'mozilla'}, + {'name': 'test262', 'variant': 'default'}, + {'name': 'v8testing', 'shards': 3}, + ], + }, 'V8 arm - sim - beta branch': { 'swarming_dimensions': { 'os': 'Ubuntu-16.04', @@ -1766,6 +1806,26 @@ {'name': 'v8testing', 'shards': 10}, ], }, + 'V8 arm - sim - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'mozilla'}, + {'name': 'test262', 'variant': 'default'}, + {'name': 'v8testing', 'shards': 4}, + ], + }, + 'V8 arm - sim - previous branch - debug': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'mozilla', 'shards': 2}, + {'name': 'test262', 'variant': 'default', 'shards': 2}, + {'name': 'v8testing', 'shards': 10}, + ], + }, 'V8 mips64el - sim - beta branch': { 'swarming_dimensions': { 'os': 'Ubuntu-16.04', @@ -1782,6 +1842,14 @@ {'name': 'unittests'}, ], }, + 'V8 mips64el - sim - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'unittests'}, + ], + }, 'V8 mipsel - sim - beta branch': { 'swarming_dimensions': { 'os': 'Ubuntu-16.04', @@ -1798,6 +1866,14 @@ {'name': 'v8testing', 'shards': 4}, ], }, + 'V8 mipsel - sim - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'v8testing', 'shards': 4}, + ], + }, 'V8 ppc64 - sim - beta branch': { 'swarming_dimensions': { 'os': 'Ubuntu-16.04', @@ -1814,6 +1890,14 @@ {'name': 'unittests'}, ], }, + 'V8 ppc64 - sim - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'unittests'}, + ], + }, 'V8 s390x - sim - beta branch': { 'swarming_dimensions': { 'os': 'Ubuntu-16.04', @@ -1830,4 +1914,12 @@ {'name': 'unittests'}, ], }, + 'V8 s390x - sim - previous branch': { + 'swarming_dimensions': { + 'os': 'Ubuntu-16.04', + }, + 'tests': [ + {'name': 'unittests'}, + ], + }, } diff --git a/deps/v8/src/builtins/builtins-intl.cc b/deps/v8/src/builtins/builtins-intl.cc index afa7ef2d30b..3b624af91b1 100644 --- a/deps/v8/src/builtins/builtins-intl.cc +++ b/deps/v8/src/builtins/builtins-intl.cc @@ -265,13 +265,11 @@ Object LegacyFormatConstructor(BuiltinArguments args, Isolate* isolate, // [[Construct]] Handle target = args.target(); - Handle locales = args.atOrUndefined(isolate, 1); Handle options = args.atOrUndefined(isolate, 2); // 2. Let format be ? OrdinaryCreateFromConstructor(newTarget, // "%Prototype%", ...). - Handle map; ASSIGN_RETURN_FAILURE_ON_EXCEPTION( isolate, map, JSFunction::GetDerivedMap(isolate, target, new_target)); @@ -281,45 +279,42 @@ Object LegacyFormatConstructor(BuiltinArguments args, Isolate* isolate, ASSIGN_RETURN_FAILURE_ON_EXCEPTION( isolate, format, T::New(isolate, map, locales, options, method)); // 4. Let this be the this value. - Handle receiver = args.receiver(); + if (args.new_target()->IsUndefined(isolate)) { + Handle receiver = args.receiver(); - // 5. If NewTarget is undefined and ? InstanceofOperator(this, %%) - // is true, then - // - // Look up the intrinsic value that has been stored on the context. - // Call the instanceof function - Handle is_instance_of_obj; - ASSIGN_RETURN_FAILURE_ON_EXCEPTION( - isolate, is_instance_of_obj, - Object::InstanceOf(isolate, receiver, constructor)); + // 5. If NewTarget is undefined and ? InstanceofOperator(this, %%) + // is true, then Look up the intrinsic value that has been stored on + // the context. + Handle is_instance_of_obj; + ASSIGN_RETURN_FAILURE_ON_EXCEPTION( + isolate, is_instance_of_obj, + Object::InstanceOf(isolate, receiver, constructor)); - // Get the boolean value of the result - bool is_instance_of = is_instance_of_obj->BooleanValue(isolate); - - if (args.new_target()->IsUndefined(isolate) && is_instance_of) { - if (!receiver->IsJSReceiver()) { - THROW_NEW_ERROR_RETURN_FAILURE( - isolate, - NewTypeError(MessageTemplate::kIncompatibleMethodReceiver, - isolate->factory()->NewStringFromAsciiChecked(method), - receiver)); + if (is_instance_of_obj->BooleanValue(isolate)) { + if (!receiver->IsJSReceiver()) { + THROW_NEW_ERROR_RETURN_FAILURE( + isolate, + NewTypeError(MessageTemplate::kIncompatibleMethodReceiver, + isolate->factory()->NewStringFromAsciiChecked(method), + receiver)); + } + Handle rec = Handle::cast(receiver); + // a. Perform ? DefinePropertyOrThrow(this, + // %Intl%.[[FallbackSymbol]], PropertyDescriptor{ [[Value]]: format, + // [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }). + PropertyDescriptor desc; + desc.set_value(format); + desc.set_writable(false); + desc.set_enumerable(false); + desc.set_configurable(false); + Maybe success = JSReceiver::DefineOwnProperty( + isolate, rec, isolate->factory()->intl_fallback_symbol(), &desc, + Just(kThrowOnError)); + MAYBE_RETURN(success, ReadOnlyRoots(isolate).exception()); + CHECK(success.FromJust()); + // b. b. Return this. + return *receiver; } - Handle rec = Handle::cast(receiver); - // a. Perform ? DefinePropertyOrThrow(this, - // %Intl%.[[FallbackSymbol]], PropertyDescriptor{ [[Value]]: format, - // [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }). - PropertyDescriptor desc; - desc.set_value(format); - desc.set_writable(false); - desc.set_enumerable(false); - desc.set_configurable(false); - Maybe success = JSReceiver::DefineOwnProperty( - isolate, rec, isolate->factory()->intl_fallback_symbol(), &desc, - Just(kThrowOnError)); - MAYBE_RETURN(success, ReadOnlyRoots(isolate).exception()); - CHECK(success.FromJust()); - // b. b. Return this. - return *receiver; } // 6. Return format. return *format; diff --git a/deps/v8/src/compiler/simd-scalar-lowering.cc b/deps/v8/src/compiler/simd-scalar-lowering.cc index 9d13bbfa987..b5e0410d503 100644 --- a/deps/v8/src/compiler/simd-scalar-lowering.cc +++ b/deps/v8/src/compiler/simd-scalar-lowering.cc @@ -909,29 +909,36 @@ void SimdScalarLowering::LowerNode(Node* node) { } case IrOpcode::kParameter: { DCHECK_EQ(1, node->InputCount()); + int param_count = static_cast(signature()->parameter_count()); // Only exchange the node if the parameter count actually changed. We do - // not even have to do the default lowering because the the start node, + // not even have to do the default lowering because the start node, // the only input of a parameter node, only changes if the parameter count // changes. - if (GetParameterCountAfterLowering() != - static_cast(signature()->parameter_count())) { + if (GetParameterCountAfterLowering() != param_count) { int old_index = ParameterIndexOf(node->op()); + // Parameter index 0 is the instance parameter, we will use old_index to + // index into the function signature, so we need to decrease it by 1. + --old_index; int new_index = GetParameterIndexAfterLoweringSimd128(signature(), old_index); - if (old_index == new_index) { - NodeProperties::ChangeOp(node, common()->Parameter(new_index)); + // Similarly, the index into function signature needs to account for the + // instance parameter, so increase it by 1. + ++new_index; + NodeProperties::ChangeOp(node, common()->Parameter(new_index)); + if (old_index < 0) { + break; + } + + DCHECK(old_index < param_count); + + if (signature()->GetParam(old_index) == + MachineRepresentation::kSimd128) { Node* new_node[kNumLanes32]; - for (int i = 0; i < kNumLanes32; ++i) { - new_node[i] = nullptr; - } new_node[0] = node; - if (signature()->GetParam(old_index) == - MachineRepresentation::kSimd128) { - for (int i = 1; i < kNumLanes32; ++i) { - new_node[i] = graph()->NewNode(common()->Parameter(new_index + i), - graph()->start()); - } + for (int i = 1; i < kNumLanes32; ++i) { + new_node[i] = graph()->NewNode(common()->Parameter(new_index + i), + graph()->start()); } ReplaceNode(node, new_node, kNumLanes32); } diff --git a/deps/v8/src/compiler/wasm-compiler.cc b/deps/v8/src/compiler/wasm-compiler.cc index 55cb950cffe..db1731f3880 100644 --- a/deps/v8/src/compiler/wasm-compiler.cc +++ b/deps/v8/src/compiler/wasm-compiler.cc @@ -6932,6 +6932,11 @@ wasm::WasmCompilationResult ExecuteTurbofanWasmCompilation( call_descriptor = GetI32WasmCallDescriptor(&zone, call_descriptor); } + if (ContainsSimd(func_body.sig) && + (!CpuFeatures::SupportsWasmSimd128() || env->lower_simd)) { + call_descriptor = GetI32WasmCallDescriptorForSimd(&zone, call_descriptor); + } + Pipeline::GenerateCodeForWasmFunction( &info, wasm_engine, mcgraph, call_descriptor, source_positions, node_origins, func_body, env->module, func_index); diff --git a/deps/v8/src/objects/objects.cc b/deps/v8/src/objects/objects.cc index cf1a3dcc204..9b53019297a 100644 --- a/deps/v8/src/objects/objects.cc +++ b/deps/v8/src/objects/objects.cc @@ -7220,10 +7220,9 @@ int BaseNameDictionary::NextEnumerationIndex( // Check whether the next enumeration index is valid. if (!PropertyDetails::IsValidIndex(index)) { // If not, we generate new indices for the properties. - int length = dictionary->NumberOfElements(); - Handle iteration_order = IterationIndices(isolate, dictionary); - DCHECK_EQ(length, iteration_order->length()); + int length = iteration_order->length(); + DCHECK_LE(length, dictionary->NumberOfElements()); // Iterate over the dictionary using the enumeration order and update // the dictionary with new enumeration indices. @@ -7467,8 +7466,8 @@ void BaseNameDictionary::CopyEnumKeysTo( template Handle BaseNameDictionary::IterationIndices( Isolate* isolate, Handle dictionary) { - int length = dictionary->NumberOfElements(); - Handle array = isolate->factory()->NewFixedArray(length); + Handle array = + isolate->factory()->NewFixedArray(dictionary->NumberOfElements()); ReadOnlyRoots roots(isolate); int array_size = 0; { @@ -7480,7 +7479,13 @@ Handle BaseNameDictionary::IterationIndices( array->set(array_size++, Smi::FromInt(i.as_int())); } - DCHECK_EQ(array_size, length); + // The global dictionary doesn't track its deletion count, so we may iterate + // fewer entries than the count of elements claimed by the dictionary. + if (std::is_same::value) { + DCHECK_LE(array_size, dictionary->NumberOfElements()); + } else { + DCHECK_EQ(array_size, dictionary->NumberOfElements()); + } EnumIndexComparator cmp(raw_dictionary); // Use AtomicSlot wrapper to ensure that std::sort uses atomic load and diff --git a/deps/v8/src/parsing/parser.cc b/deps/v8/src/parsing/parser.cc index 029caf2524f..21beff8790c 100644 --- a/deps/v8/src/parsing/parser.cc +++ b/deps/v8/src/parsing/parser.cc @@ -505,7 +505,6 @@ FunctionLiteral* Parser::ParseProgram(Isolate* isolate, Handle