Commit 02149d89 authored by adamk's avatar adamk Committed by Commit bot

Include harmony-string-padding.js in the context snapshot

The attached chromium bug suggests that turning this on via a flag
regressed a perf test. Having previously run into slowdowns due
to experimental JS natives, my suspicion is that this regression
can be fixed by including the new builtins in the snapshot.
My intention is to land this patch to see if the regression
goes away on the bots.

Given the nature of this feature, it seems low-risk to remove
the runtime flag. If need be, it would be trivial to craft
a patch to remove these two methods from String.prototype
if we run into web compat issues during the release (note
that no release branch has yet picked up this feature).

BUG=v8:4954, chromium:677444

Review-Url: https://codereview.chromium.org/2610853010
Cr-Commit-Position: refs/heads/master@{#42111}
parent 2c60a1fa
......@@ -425,6 +425,7 @@ action("js2c") {
"src/js/spread.js",
"src/js/proxy.js",
"src/js/async-await.js",
"src/js/harmony-string-padding.js",
"src/debug/mirrors.js",
"src/debug/debug.js",
"src/debug/liveedit.js",
......@@ -469,7 +470,6 @@ action("js2c_experimental") {
"src/messages.h",
"src/js/harmony-atomics.js",
"src/js/harmony-simd.js",
"src/js/harmony-string-padding.js",
]
outputs = [
......
......@@ -3437,7 +3437,6 @@ EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_named_captures)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_string_padding)
#ifdef V8_I18N_SUPPORT
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(datetime_format_to_parts)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(icu_case_mapping)
......@@ -3996,8 +3995,6 @@ bool Genesis::InstallExperimentalNatives() {
static const char* harmony_regexp_property_natives[] = {nullptr};
static const char* harmony_function_sent_natives[] = {nullptr};
static const char* harmony_array_prototype_values_natives[] = {nullptr};
static const char* harmony_string_padding_natives[] = {
"native harmony-string-padding.js", nullptr};
#ifdef V8_I18N_SUPPORT
static const char* icu_case_mapping_natives[] = {"native icu-case-mapping.js",
nullptr};
......
......@@ -222,9 +222,7 @@ DEFINE_IMPLICATION(es_staging, move_object_start)
#endif
// Features that are shipping (turned on by default, but internal flag remains).
#define HARMONY_SHIPPING_BASE(V) \
V(harmony_async_await, "harmony async-await") \
V(harmony_string_padding, "harmony String-padding methods")
#define HARMONY_SHIPPING_BASE(V) V(harmony_async_await, "harmony async-await")
#ifdef V8_I18N_SUPPORT
#define HARMONY_SHIPPING(V) \
......
......@@ -2258,6 +2258,7 @@
'js/spread.js',
'js/proxy.js',
'js/async-await.js',
'js/harmony-string-padding.js',
'debug/mirrors.js',
'debug/debug.js',
'debug/liveedit.js',
......@@ -2267,7 +2268,6 @@
'messages.h',
'js/harmony-atomics.js',
'js/harmony-simd.js',
'js/harmony-string-padding.js',
],
'libraries_bin_file': '<(SHARED_INTERMEDIATE_DIR)/libraries.bin',
'libraries_experimental_bin_file': '<(SHARED_INTERMEDIATE_DIR)/libraries-experimental.bin',
......
......@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --harmony-string-padding
(function TestMeta() {
assertEquals(1, String.prototype.padEnd.length);
assertEquals("function", typeof String.prototype.padEnd);
......
......@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --harmony-string-padding
(function TestMeta() {
assertEquals(1, String.prototype.padStart.length);
assertEquals("function", typeof String.prototype.padStart);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment