diff --git a/implementation-contributed/curation_logs/v8.json b/implementation-contributed/curation_logs/v8.json index 35a2852a259e4e2e86b08f7c4c9158654310057b..7191a0c0008ad2dd292264969f9dfe5453df64ad 100644 --- a/implementation-contributed/curation_logs/v8.json +++ b/implementation-contributed/curation_logs/v8.json @@ -1,5 +1,5 @@ { - "sourceRevisionAtLastExport": "9583858e", - "targetRevisionAtLastExport": "d420adb9f2", + "sourceRevisionAtLastExport": "44b1b245", + "targetRevisionAtLastExport": "ae464533ad", "curatedFiles": {} } \ No newline at end of file diff --git a/implementation-contributed/v8/intl/break-iterator/default-locale.js b/implementation-contributed/v8/intl/break-iterator/default-locale.js index e1a42a100a6b0f7544c9759586b252fe471b4e2d..fd379db1c8a276fb4cbaaf5a7e537e7c4ddd8a03 100644 --- a/implementation-contributed/v8/intl/break-iterator/default-locale.js +++ b/implementation-contributed/v8/intl/break-iterator/default-locale.js @@ -37,9 +37,6 @@ assertFalse(options.locale === 'und'); assertFalse(options.locale === ''); assertFalse(options.locale === undefined); -// Then check for legitimacy. -assertLanguageTag(%GetDefaultICULocale(), options.locale); - var iteratorNone = new Intl.v8BreakIterator(); assertEquals(options.locale, iteratorNone.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/break-iterator/wellformed-unsupported-locale.js b/implementation-contributed/v8/intl/break-iterator/wellformed-unsupported-locale.js deleted file mode 100644 index ffa44aef081eafb94d6eee5c21d65ccb20ac283c..0000000000000000000000000000000000000000 --- a/implementation-contributed/v8/intl/break-iterator/wellformed-unsupported-locale.js +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2013 the V8 project authors. All rights reserved. -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following -// disclaimer in the documentation and/or other materials provided -// with the distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -// Passing a well formed but unsupported locale falls back to default. - -var iterator = Intl.v8BreakIterator(['xx']); - -assertLanguageTag(%GetDefaultICULocale(), iterator.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/collator/default-locale.js b/implementation-contributed/v8/intl/collator/default-locale.js index fd964f0620682ac1a330413a07a38aa1b8bf76ad..56435d147f8c89883f67860d8fd99462c756be47 100644 --- a/implementation-contributed/v8/intl/collator/default-locale.js +++ b/implementation-contributed/v8/intl/collator/default-locale.js @@ -37,9 +37,6 @@ assertFalse(options.locale === 'und'); assertFalse(options.locale === ''); assertFalse(options.locale === undefined); -// Then check for legitimacy. -assertLanguageTag(%GetDefaultICULocale(), options.locale); - var collatorNone = new Intl.Collator(); assertEquals(options.locale, collatorNone.resolvedOptions().locale); @@ -49,5 +46,4 @@ assertEquals(options.locale, collatorBraket.resolvedOptions().locale); var collatorWithOptions = new Intl.Collator(undefined, {usage: 'search'}); var locale = collatorWithOptions.resolvedOptions().locale; -assertLanguageTag(%GetDefaultICULocale(), locale); assertEquals(locale.indexOf('-co-search'), -1); diff --git a/implementation-contributed/v8/intl/collator/options.js b/implementation-contributed/v8/intl/collator/options.js index f03ff2cafcdf8c0560b19bd22c881b101c71a0ec..126bfc0959500ccf5a95f4aae9e0ccefe5d81235 100644 --- a/implementation-contributed/v8/intl/collator/options.js +++ b/implementation-contributed/v8/intl/collator/options.js @@ -5,14 +5,12 @@ // No locale var collatorWithOptions = new Intl.Collator(undefined); var { locale, usage, collation } = collatorWithOptions.resolvedOptions(); -assertLanguageTag(%GetDefaultICULocale(), locale); assertEquals('sort', usage); assertEquals('default', collation); assertEquals(locale.indexOf('-co-search'), -1); collatorWithOptions = new Intl.Collator(undefined, {usage: 'sort'}); var { locale, usage, collation } = collatorWithOptions.resolvedOptions(); -assertLanguageTag(%GetDefaultICULocale(), locale); assertEquals('sort', usage); assertEquals('default', collation); assertEquals(locale.indexOf('-co-search'), -1); @@ -21,12 +19,10 @@ collatorWithOptions = new Intl.Collator(undefined, {usage: 'search'}); var { locale, usage, collation } = collatorWithOptions.resolvedOptions(); assertEquals('search', usage); assertEquals('default', collation); -assertLanguageTag(%GetDefaultICULocale(), locale); assertEquals(locale.indexOf('-co-search'), -1); collatorWithOptions = new Intl.Collator(locale); var { locale, usage, collation } = collatorWithOptions.resolvedOptions(); -assertLanguageTag(%GetDefaultICULocale(), locale); assertEquals('sort', usage); assertEquals('default', collation); assertEquals(locale.indexOf('-co-search'), -1); diff --git a/implementation-contributed/v8/intl/collator/wellformed-unsupported-locale.js b/implementation-contributed/v8/intl/collator/wellformed-unsupported-locale.js deleted file mode 100644 index ad89e3e2203e31cc2b5ecf2217169c55b548e074..0000000000000000000000000000000000000000 --- a/implementation-contributed/v8/intl/collator/wellformed-unsupported-locale.js +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2013 the V8 project authors. All rights reserved. -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following -// disclaimer in the documentation and/or other materials provided -// with the distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -// Passing a well formed but unsupported locale falls back to default. - -var collator = Intl.Collator(['xx']); - -assertLanguageTag(%GetDefaultICULocale(), collator.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/date-format/default-locale.js b/implementation-contributed/v8/intl/date-format/default-locale.js index 2d79e895b54c38487fc8f850721851343f740d22..ecc85da479d259dbf6cefd4086efd0a6239e72e2 100644 --- a/implementation-contributed/v8/intl/date-format/default-locale.js +++ b/implementation-contributed/v8/intl/date-format/default-locale.js @@ -37,8 +37,5 @@ assertFalse(options.locale === 'und'); assertFalse(options.locale === ''); assertFalse(options.locale === undefined); -// Then check for legitimacy. -assertLanguageTag(%GetDefaultICULocale(), options.locale); - var dtfNone = new Intl.DateTimeFormat(); assertEquals(options.locale, dtfNone.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/date-format/wellformed-unsupported-locale.js b/implementation-contributed/v8/intl/date-format/wellformed-unsupported-locale.js deleted file mode 100644 index b81216483250af335ce2ee71823c32f9f4b150d9..0000000000000000000000000000000000000000 --- a/implementation-contributed/v8/intl/date-format/wellformed-unsupported-locale.js +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2013 the V8 project authors. All rights reserved. -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following -// disclaimer in the documentation and/or other materials provided -// with the distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -// Passing a well formed but unsupported locale falls back to default. - -var dtf = Intl.DateTimeFormat(['xx']); - -assertLanguageTag(%GetDefaultICULocale(), dtf.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/default_locale.js b/implementation-contributed/v8/intl/default_locale.js new file mode 100644 index 0000000000000000000000000000000000000000..453f5e66ed7cb08df7cf7d8d87620f0d5dcac45d --- /dev/null +++ b/implementation-contributed/v8/intl/default_locale.js @@ -0,0 +1,17 @@ +// Copyright 2018 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Environment Variables: LC_ALL=de + +assertEquals("de", (new Intl.Collator([])).resolvedOptions().locale); +assertEquals("de", (new Intl.Collator(['xx'])).resolvedOptions().locale); +assertEquals("de", (new Intl.Collator(undefined)).resolvedOptions().locale); +assertEquals("de", (new Intl.Collator(undefined, {usage: 'sort'})).resolvedOptions().locale); +assertEquals("de", (new Intl.Collator(undefined, {usage: 'search'})).resolvedOptions().locale); +assertEquals("de", (new Intl.DateTimeFormat([])).resolvedOptions().locale); +assertEquals("de", (new Intl.DateTimeFormat(['xx'])).resolvedOptions().locale); +assertEquals("de", (new Intl.NumberFormat([])).resolvedOptions().locale); +assertEquals("de", (new Intl.NumberFormat(['xx'])).resolvedOptions().locale); +assertEquals("de", (new Intl.v8BreakIterator([])).resolvedOptions().locale); +assertEquals("de", (new Intl.v8BreakIterator(['xx'])).resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/intl.status b/implementation-contributed/v8/intl/intl.status index d70056f049f156cd4cb37110ba3c66cb4a2f9505..3841b287dcbb1f4df47eb275f0a1d93e0f594663 100644 --- a/implementation-contributed/v8/intl/intl.status +++ b/implementation-contributed/v8/intl/intl.status @@ -29,6 +29,9 @@ [ALWAYS, { # TODO(jochen): The following test is flaky. 'overrides/caching': [PASS, FAIL], + + # https://crbug.com/v8/8469 + 'regress-8469': [FAIL], }], # ALWAYS ['variant == no_wasm_traps', { @@ -39,14 +42,18 @@ # noi18n cannot turn on ICU backend for Date 'relative-time-format/default-locale-fr-CA': [SKIP], 'relative-time-format/default-locale-pt-BR': [SKIP], + + # Unable to change locale on Windows: + 'default_locale': [SKIP], }], # system == windows' ['system == android', { # Android's ICU data file does not have the Chinese/Japanese dictionary # required for the test to pass. - 'break-iterator/zh-break': [FAIL], + 'break-iterator/zh-break': [SKIP], # Unable to change locale on Android: - 'relative-time-format/default-locale-fr-CA': [FAIL], - 'relative-time-format/default-locale-pt-BR': [FAIL], + 'relative-time-format/default-locale-fr-CA': [SKIP], + 'relative-time-format/default-locale-pt-BR': [SKIP], + 'default_locale': [SKIP], }], # 'system == android' ] diff --git a/implementation-contributed/v8/intl/number-format/default-locale.js b/implementation-contributed/v8/intl/number-format/default-locale.js index a24aec23332786bf35225dc69d4ed0c6d8552ca3..7e67176baf47e55f7aacbc3e578002a6141333a7 100644 --- a/implementation-contributed/v8/intl/number-format/default-locale.js +++ b/implementation-contributed/v8/intl/number-format/default-locale.js @@ -37,8 +37,5 @@ assertFalse(options.locale === 'und'); assertFalse(options.locale === ''); assertFalse(options.locale === undefined); -// Then check for legitimacy. -assertLanguageTag(%GetDefaultICULocale(), options.locale); - var nfNone = new Intl.NumberFormat(); assertEquals(options.locale, nfNone.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/number-format/wellformed-unsupported-locale.js b/implementation-contributed/v8/intl/number-format/wellformed-unsupported-locale.js deleted file mode 100644 index c51753928eeb8741476f5e99b8023aa86f093112..0000000000000000000000000000000000000000 --- a/implementation-contributed/v8/intl/number-format/wellformed-unsupported-locale.js +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2013 the V8 project authors. All rights reserved. -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following -// disclaimer in the documentation and/or other materials provided -// with the distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -// Passing a well formed but unsupported locale falls back to default. - -var nf = Intl.NumberFormat(['xx']); - -assertLanguageTag(%GetDefaultICULocale(), nf.resolvedOptions().locale); diff --git a/implementation-contributed/v8/intl/regress-8414.js b/implementation-contributed/v8/intl/regress-8414.js deleted file mode 100644 index 3e34421636609b2599bd1c4db85cc5db6a4302eb..0000000000000000000000000000000000000000 --- a/implementation-contributed/v8/intl/regress-8414.js +++ /dev/null @@ -1,806 +0,0 @@ -// Copyright 2018 the V8 project authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Flags: --harmony-intl-segmenter --harmony-intl-list-format --harmony-locale - -let locales = [ - "af-NA", - "af", - "af-ZA", - "agq-CM", - "agq", - "ak-GH", - "ak", - "am-ET", - "am", - "an", - "ar-001", - "ar-AE", - "ar-BH", - "ar-DJ", - "ar-DZ", - "ar-EG", - "ar-EH", - "ar-ER", - "ar-IL", - "ar-IQ", - "ar-JO", - "ar-KM", - "ar-KW", - "ar-LB", - "ar-LY", - "ar-MA", - "ar-MR", - "ar-OM", - "ar-PS", - "ar-QA", - "ar-SA", - "ar-SD", - "ar-SO", - "ar-SS", - "ars", - "ar-SY", - "ar-TD", - "ar-TN", - "ar", - "ar-YE", - "asa", - "asa-TZ", - "as-IN", - "ast-ES", - "ast", - "as", - "az-AZ", - "az-Cyrl-AZ", - "az-Cyrl", - "az-Latn-AZ", - "az-Latn", - "az", - "bas-CM", - "bas", - "be-BY", - "bem", - "bem-ZM", - "be", - "bez", - "bez-TZ", - "bg-BG", - "bg", - "bm-ML", - "bm", - "bn-BD", - "bn-IN", - "bn", - "bo-CN", - "bo-IN", - "bo", - "br-FR", - "br", - "brx-IN", - "brx", - "bs-BA", - "bs-Cyrl-BA", - "bs-Cyrl", - "bs-Latn-BA", - "bs-Latn", - "bs", - "ca-AD", - "ca-ES", - "ca-FR", - "ca-IT", - "ca", - "ccp-BD", - "ccp-IN", - "ccp", - "ce-RU", - "ce", - "cgg", - "cgg-UG", - "chr", - "chr-US", - "ckb-IQ", - "ckb-IR", - "ckb", - "cs-CZ", - "cs", - "cy-GB", - "cy", - "da-DK", - "da-GL", - "da", - "dav-KE", - "dav", - "de-AT", - "de-BE", - "de-CH", - "de-DE", - "de-IT", - "de-LI", - "de-LU", - "de", - "dje-NE", - "dje", - "dsb-DE", - "dsb", - "dua-CM", - "dua", - "dyo-SN", - "dyo", - "dz-BT", - "dz", - "ebu-KE", - "ebu", - "ee-GH", - "ee-TG", - "ee", - "el-CY", - "el-GR", - "el", - "en-001", - "en-150", - "en-AG", - "en-AI", - "en-AS", - "en-AT", - "en-AU", - "en-BB", - "en-BE", - "en-BI", - "en-BM", - "en-BS", - "en-BW", - "en-BZ", - "en-CA", - "en-CC", - "en-CH", - "en-CK", - "en-CM", - "en-CX", - "en-CY", - "en-DE", - "en-DG", - "en-DK", - "en-DM", - "en-ER", - "en-FI", - "en-FJ", - "en-FK", - "en-FM", - "en-GB", - "en-GD", - "en-GG", - "en-GH", - "en-GI", - "en-GM", - "en-GU", - "en-GY", - "en-HK", - "en-IE", - "en-IL", - "en-IM", - "en-IN", - "en-IO", - "en-JE", - "en-JM", - "en-KE", - "en-KI", - "en-KN", - "en-KY", - "en-LC", - "en-LR", - "en-LS", - "en-MG", - "en-MH", - "en-MO", - "en-MP", - "en-MS", - "en-MT", - "en-MU", - "en-MW", - "en-MY", - "en-NA", - "en-NF", - "en-NG", - "en-NH", - "en-NL", - "en-NR", - "en-NU", - "en-NZ", - "en-PG", - "en-PH", - "en-PK", - "en-PN", - "en-PR", - "en-PW", - "en-RH", - "en-RW", - "en-SB", - "en-SC", - "en-SD", - "en-SE", - "en-SG", - "en-SH", - "en-SI", - "en-SL", - "en-SS", - "en-SX", - "en-SZ", - "en-TC", - "en-TK", - "en-TO", - "en-TT", - "en-TV", - "en", - "en-TZ", - "en-UG", - "en-UM", - "en-US-POSIX", - "en-US", - "en-VC", - "en-VG", - "en-VI", - "en-VU", - "en-WS", - "en-ZA", - "en-ZM", - "en-ZW", - "eo", - "es-419", - "es-AR", - "es-BO", - "es-BR", - "es-BZ", - "es-CL", - "es-CO", - "es-CR", - "es-CU", - "es-DO", - "es-EA", - "es-EC", - "es-ES", - "es-GQ", - "es-GT", - "es-HN", - "es-IC", - "es-MX", - "es-NI", - "es-PA", - "es-PE", - "es-PH", - "es-PR", - "es-PY", - "es-SV", - "es", - "es-US", - "es-UY", - "es-VE", - "et-EE", - "et", - "eu-ES", - "eu", - "ewo-CM", - "ewo", - "fa-AF", - "fa-IR", - "fa", - "ff", - "fi-FI", - "fil-PH", - "fil", - "fi", - "fo-DK", - "fo-FO", - "fo", - "fr-BE", - "fr-BF", - "fr-BI", - "fr-BJ", - "fr-BL", - "fr-CA", - "fr-CD", - "fr-CF", - "fr-CG", - "fr-CH", - "fr-CI", - "fr-CM", - "fr-DJ", - "fr-DZ", - "fr-FR", - "fr-GA", - "fr-GF", - "fr-GN", - "fr-GP", - "fr-GQ", - "fr-HT", - "fr-KM", - "fr-LU", - "fr-MA", - "fr-MC", - "fr-MF", - "fr-MG", - "fr-ML", - "fr-MQ", - "fr-MR", - "fr-MU", - "fr-NC", - "fr-NE", - "fr-PF", - "fr-PM", - "fr-RE", - "fr-RW", - "fr-SC", - "fr-SN", - "fr-SY", - "fr-TD", - "fr-TG", - "fr-TN", - "fr", - "fr-VU", - "fr-WF", - "fr-YT", - "fur-IT", - "fur", - "fy-NL", - "fy", - "ga-IE", - "ga", - "gd-GB", - "gd", - "gl-ES", - "gl", - "gsw-CH", - "gsw-FR", - "gsw-LI", - "gsw", - "gu-IN", - "gu", - "guz-KE", - "guz", - "gv-IM", - "gv", - "ha-GH", - "ha-NE", - "ha-NG", - "ha", - "haw", - "haw-US", - "he-IL", - "he", - "hi-IN", - "hi", - "hr-BA", - "hr-HR", - "hr", - "hsb-DE", - "hsb", - "hu-HU", - "hu", - "hy-AM", - "hy", - "ia-001", - "ia", - "id-ID", - "id", - "ig-NG", - "ig", - "ii-CN", - "ii", - "in-ID", - "in", - "is-IS", - "is", - "it-CH", - "it-IT", - "it-SM", - "it", - "it-VA", - "iw-IL", - "iw", - "ja-JP", - "ja", - "jgo-CM", - "jgo", - "jmc", - "jmc-TZ", - "jv-ID", - "jv", - "kab-DZ", - "kab", - "ka-GE", - "kam-KE", - "kam", - "ka", - "kde", - "kde-TZ", - "kea-CV", - "kea", - "khq-ML", - "khq", - "ki-KE", - "ki", - "kkj-CM", - "kkj", - "kk-KZ", - "kk", - "kl-GL", - "kln-KE", - "kln", - "kl", - "km-KH", - "km", - "kn-IN", - "kn", - "kok-IN", - "ko-KP", - "ko-KR", - "kok", - "ko", - "ksb", - "ksb-TZ", - "ksf-CM", - "ksf", - "ksh-DE", - "ksh", - "ks-IN", - "ks", - "ku-TR", - "ku", - "kw-GB", - "kw", - "ky-KG", - "ky", - "lag", - "lag-TZ", - "lb-LU", - "lb", - "lg", - "lg-UG", - "lkt", - "lkt-US", - "ln-AO", - "ln-CD", - "ln-CF", - "ln-CG", - "ln", - "lo-LA", - "lo", - "lrc-IQ", - "lrc-IR", - "lrc", - "lt-LT", - "lt", - "lu-CD", - "luo-KE", - "luo", - "lu", - "luy-KE", - "luy", - "lv-LV", - "lv", - "mas-KE", - "mas", - "mas-TZ", - "mer-KE", - "mer", - "mfe-MU", - "mfe", - "mgh-MZ", - "mgh", - "mg-MG", - "mgo-CM", - "mgo", - "mg", - "mi-NZ", - "mi", - "mk-MK", - "mk", - "ml-IN", - "ml", - "mn-MN", - "mn", - "mo", - "mr-IN", - "mr", - "ms-BN", - "ms-MY", - "ms-SG", - "ms", - "mt-MT", - "mt", - "mua-CM", - "mua", - "my-MM", - "my", - "mzn-IR", - "mzn", - "naq-NA", - "naq", - "nb-NO", - "nb-SJ", - "nb", - "nds-DE", - "nds-NL", - "nds", - "nd", - "nd-ZW", - "ne-IN", - "ne-NP", - "ne", - "nl-AW", - "nl-BE", - "nl-BQ", - "nl-CW", - "nl-NL", - "nl-SR", - "nl-SX", - "nl", - "nmg-CM", - "nmg", - "nnh-CM", - "nnh", - "nn-NO", - "nn", - "no-NY", - "no-NO", - "no", - "nus-SS", - "nus", - "nyn", - "nyn-UG", - "om-ET", - "om-KE", - "om", - "or-IN", - "or", - "os-GE", - "os-RU", - "os", - "pa-Arab-PK", - "pa-Arab", - "pa-Guru-IN", - "pa-Guru", - "pa-IN", - "pa-PK", - "pa", - "pl-PL", - "pl", - "ps-AF", - "ps", - "pt-AO", - "pt-BR", - "pt-CH", - "pt-CV", - "pt-GQ", - "pt-GW", - "pt-LU", - "pt-MO", - "pt-MZ", - "pt-PT", - "pt-ST", - "pt-TL", - "pt", - "qu-BO", - "qu-EC", - "qu-PE", - "qu", - "rm-CH", - "rm", - "rn-BI", - "rn", - "rof", - "rof-TZ", - "ro-MD", - "root", - "ro-RO", - "ro", - "ru-BY", - "ru-KG", - "ru-KZ", - "ru-MD", - "ru-RU", - "ru", - "ru-UA", - "rwk", - "rwk-TZ", - "rw-RW", - "rw", - "sah-RU", - "sah", - "saq-KE", - "saq", - "sbp", - "sbp-TZ", - "sd-PK", - "sd", - "se-FI", - "seh-MZ", - "seh", - "se-NO", - "se-SE", - "ses-ML", - "ses", - "se", - "sg-CF", - "sg", - "sh-BA", - "sh-CS", - "shi-Latn-MA", - "shi-Latn", - "shi-MA", - "shi-Tfng-MA", - "shi-Tfng", - "shi", - "sh", - "sh-YU", - "si-LK", - "si", - "sk-SK", - "sk", - "sl-SI", - "sl", - "smn-FI", - "smn", - "sn", - "sn-ZW", - "so-DJ", - "so-ET", - "so-KE", - "so-SO", - "so", - "sq-AL", - "sq-MK", - "sq", - "sq-XK", - "sr-BA", - "sr-CS", - "sr-Cyrl-BA", - "sr-Cyrl-CS", - "sr-Cyrl-ME", - "sr-Cyrl-RS", - "sr-Cyrl", - "sr-Cyrl-XK", - "sr-Cyrl-YU", - "sr-Latn-BA", - "sr-Latn-CS", - "sr-Latn-ME", - "sr-Latn-RS", - "sr-Latn", - "sr-Latn-XK", - "sr-Latn-YU", - "sr-ME", - "sr-RS", - "sr", - "sr-XK", - "sr-YU", - "sv-AX", - "sv-FI", - "sv-SE", - "sv", - "sw-CD", - "sw-KE", - "sw", - "sw-TZ", - "sw-UG", - "ta-IN", - "ta-LK", - "ta-MY", - "ta-SG", - "ta", - "te-IN", - "teo-KE", - "teo", - "teo-UG", - "te", - "tg-TJ", - "tg", - "th-TH", - "th", - "ti-ER", - "ti-ET", - "ti", - "tk-TM", - "tk", - "tl-PH", - "tl", - "to-TO", - "to", - "tr-CY", - "tr-TR", - "tr", - "tt-RU", - "tt", - "twq-NE", - "twq", - "tzm-MA", - "tzm", - "ug-CN", - "ug", - "uk", - "uk-UA", - "ur-IN", - "ur-PK", - "ur", - "uz-AF", - "uz-Arab-AF", - "uz-Arab", - "uz-Cyrl", - "uz-Cyrl-UZ", - "uz-Latn", - "uz-Latn-UZ", - "uz", - "uz-UZ", - "vai-Latn-LR", - "vai-Latn", - "vai-LR", - "vai", - "vai-Vaii-LR", - "vai-Vaii", - "vi", - "vi-VN", - "vun", - "vun-TZ", - "wae-CH", - "wae", - "wa", - "wo-SN", - "wo", - "xh", - "xh-ZA", - "xog", - "xog-UG", - "yav-CM", - "yav", - "yi-001", - "yi", - "yo-BJ", - "yo-NG", - "yo", - "yue-CN", - "yue-Hans-CN", - "yue-Hans", - "yue-Hant-HK", - "yue-Hant", - "yue-HK", - "yue", - "zgh-MA", - "zgh", - "zh-CN", - "zh-Hans-CN", - "zh-Hans-HK", - "zh-Hans-MO", - "zh-Hans-SG", - "zh-Hans", - "zh-Hant-HK", - "zh-Hant-MO", - "zh-Hant-TW", - "zh-Hant", - "zh-HK", - "zh-MO", - "zh-SG", - "zh-TW", - "zh", - "zu", - "zu-ZA" -]; - -var intlObjectNames = [ - "DateTimeFormat", - "NumberFormat", - "Collator", - "v8BreakIterator", - "PluralRules", - "Locale", - "ListFormat", - "Segmenter", - "RelativeTimeFormat" -]; - -for (let loc of locales) { - for (let constructor of intlObjectNames) { - let msg = `new Intl.${constructor}(${loc})`; - print(msg); - let obj = new Intl[constructor](loc); - assertNotNull(obj, msg + ' should not be null'); - } -} diff --git a/implementation-contributed/v8/intl/regress-8469.js b/implementation-contributed/v8/intl/regress-8469.js new file mode 100644 index 0000000000000000000000000000000000000000..7febb51cf988a26db13abea1b76999caf762915e --- /dev/null +++ b/implementation-contributed/v8/intl/regress-8469.js @@ -0,0 +1,87 @@ +// Copyright 2018 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// The following tz are NOT impacted by v8:8469 +var some_tz_list = [ + "ciabj", + "ghacc", +]; + +// The following tz ARE impacted by v8:8469 +var problem_tz_list = [ + "etadd", + "tzdar", + "eheai", + "sttms", + "arirj", + "arrgl", + "aruaq", + "arluq", + "mxpvr", + "brbvb", + "arbue", + "caycb", + "brcgr", + "cayzs", + "crsjo", + "caydq", + "svsal", + "cafne", + "caglb", + "cagoo", + "tcgdt", + "ustel", + "bolpb", + "uslax", + "sxphi", + "mxmex", + "usnyc", + "usxul", + "usndcnt", + "usndnsl", + "ttpos", + "brpvh", + "prsju", + "clpuq", + "caffs", + "cayek", + "brrbr", + "mxstis", + "dosdq", + "brsao", + "gpsbh", + "casjf", + "knbas", + "lccas", + "vistt", + "vcsvd", + "cayyn", + "cathu", + "hkhkg", + "mykul", + "khpnh", + "cvrai", + "gsgrv", + "shshn", + "aubhq", + "auldh", + "imdgs", + "smsai", + "asppg", + "pgpom", +]; + +let expectedTimeZone = (new Intl.DateTimeFormat("en")) + .resolvedOptions().timeZone; + +function testTz(tz) { + print(tz); + let timeZone = (new Intl.DateTimeFormat("en-u-tz-" + tz)) + .resolvedOptions().timeZone; + assertEquals(expectedTimeZone, timeZone); +} + +// first test soem tz not impacted by v8:8469 to ensure testTz is correct. +for (var tz of some_tz_list) testTz(tz); +for (var tz of problem_tz_list) testTz(tz); diff --git a/implementation-contributed/v8/intl/regress-8525.js b/implementation-contributed/v8/intl/regress-8525.js new file mode 100644 index 0000000000000000000000000000000000000000..4d925d73c342c8720e73939643c2f9268bb71a46 --- /dev/null +++ b/implementation-contributed/v8/intl/regress-8525.js @@ -0,0 +1,27 @@ +// Copyright 2018 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// test the numberingSystem is set correctly via -u-nu- +let dtf = new Intl.DateTimeFormat(["en-u-ba-rfoo-nu-arab-fo-obar"]); +assertEquals("arab", dtf.resolvedOptions().numberingSystem); +assertEquals("en-u-nu-arab", dtf.resolvedOptions().locale); + +let nf = new Intl.NumberFormat(["en-u-ba-rfoo-nu-arab-fo-obar"]); +assertEquals("arab", nf.resolvedOptions().numberingSystem); +assertEquals("١٢٣", nf.format(123)); +assertEquals("en-u-nu-arab", nf.resolvedOptions().locale); + +dtf = new Intl.DateTimeFormat(["en-u-ba-rfoo-nu-thai-fo-obar"]); +assertEquals("thai", dtf.resolvedOptions().numberingSystem); +assertEquals("en-u-nu-thai", dtf.resolvedOptions().locale); + +nf = new Intl.NumberFormat(["en-u-ba-rfoo-nu-thai-fo-obar"]); +assertEquals("thai", nf.resolvedOptions().numberingSystem); +assertEquals("๑๒๓", nf.format(123)); +assertEquals("en-u-nu-thai", nf.resolvedOptions().locale); + +nf = new Intl.NumberFormat(["ar-EG-u-nu-latn"]); +assertEquals("latn", nf.resolvedOptions().numberingSystem); +assertEquals("123", nf.format(123)); +assertEquals("ar-EG-u-nu-latn", nf.resolvedOptions().locale); diff --git a/implementation-contributed/v8/mjsunit/code-coverage-block.js b/implementation-contributed/v8/mjsunit/code-coverage-block.js index 8cbb2969f7d050f325a805f31546dc70376d32f6..bdba90cd1e3009ba26b67a581d45aa7d85667386 100644 --- a/implementation-contributed/v8/mjsunit/code-coverage-block.js +++ b/implementation-contributed/v8/mjsunit/code-coverage-block.js @@ -213,7 +213,7 @@ TestCoverage( nop(); // 0100 } // 0150 }(); // 0200 -%RunMicrotasks(); // 0250 +%PerformMicrotaskCheckpoint(); // 0250 `, [{"start":0,"end":299,"count":1}, {"start":1,"end":201,"count":6}, // TODO(jgruber): Invocation count is off. @@ -662,7 +662,7 @@ async function f() { // 0000 await 42; // 0100 }; // 0150 f(); // 0200 -%RunMicrotasks(); // 0250 +%PerformMicrotaskCheckpoint(); // 0250 `, [{"start":0,"end":299,"count":1}, {"start":0,"end":151,"count":3}, diff --git a/implementation-contributed/v8/mjsunit/compiler/regress-910838.js b/implementation-contributed/v8/mjsunit/compiler/regress-910838.js new file mode 100644 index 0000000000000000000000000000000000000000..6e62a453e069d9db51fda89a995cffb375355f59 --- /dev/null +++ b/implementation-contributed/v8/mjsunit/compiler/regress-910838.js @@ -0,0 +1,20 @@ +// Copyright 2018 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Flags: --allow-natives-syntax + +function f(b, s, x) { + if (!b) { + return (x ? b : s * undefined) ? 1 : 42; + } +} + +function g(b, x) { + return f(b, 'abc', x); +} + +f(false, 0, 0); +g(true, 0); +%OptimizeFunctionOnNextCall(g); +assertEquals(42, g(false, 0)); diff --git a/implementation-contributed/v8/mjsunit/es6/microtask-delivery.js b/implementation-contributed/v8/mjsunit/es6/microtask-delivery.js index 6b239bea4706fa8e8a6841113455ae8aa123875b..96035164f2cc76f148f64499fa142db4c7c8ff29 100644 --- a/implementation-contributed/v8/mjsunit/es6/microtask-delivery.js +++ b/implementation-contributed/v8/mjsunit/es6/microtask-delivery.js @@ -40,7 +40,7 @@ function assertArrayValues(expected, actual) { } function assertOrdering(expected) { - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertArrayValues(expected, ordering); } diff --git a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-arguments.js b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-arguments.js index b29f17fce0ef2ce61e8661c5b07db134d5a07bcf..720770ef4994c0138b1d7a49de3728ddd3e914be 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-arguments.js +++ b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-arguments.js @@ -21,7 +21,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; diff --git a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-new.target.js b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-new.target.js index 943267e9d85d1f3095ec70a5b31e0e38f35a17dd..7d016281f819e479d3b037b3b56c44c04cd8e904 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-new.target.js +++ b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-new.target.js @@ -21,7 +21,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; diff --git a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-super.js b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-super.js index b15a3834db9ea2485faa6741db1e312739e54699..b175ac5ae12621caab8b3f4a1ceb1396ee8e533b 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-super.js +++ b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-super.js @@ -21,7 +21,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; diff --git a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-this.js b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-this.js index 38bdddc2c7b67f08b14e82bf9eeebd8ee8d24ed3..a21978d1a0a59883c2e11c14a3b96ca0fff2d8b9 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-this.js +++ b/implementation-contributed/v8/mjsunit/es8/async-arrow-lexical-this.js @@ -21,7 +21,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; diff --git a/implementation-contributed/v8/mjsunit/es8/async-await-basic.js b/implementation-contributed/v8/mjsunit/es8/async-await-basic.js index 6e9ee02ffe8384dbe8f5555ec19d334182aae6f8..1c7b2ac60176b289ec0a83a0f036db2af9499f6c 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-await-basic.js +++ b/implementation-contributed/v8/mjsunit/es8/async-await-basic.js @@ -23,7 +23,7 @@ function assertThrowsAsync(run, errorType, message) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (!hadError) { throw new MjsUnitAssertionError( @@ -57,7 +57,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; @@ -402,7 +402,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "a", "c"], log); } @@ -416,7 +416,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "a", "c"], log); } @@ -430,7 +430,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["a", "b", "c"], log); } @@ -445,7 +445,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "c", "a"], log); } @@ -459,7 +459,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "a", "c"], log); } @@ -473,7 +473,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["a", "b", "c"], log); } @@ -488,7 +488,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "a", "c"], log); } @@ -502,7 +502,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "a", "c"], log); } @@ -516,7 +516,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["a", "b", "c"], log); } @@ -531,7 +531,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "c", "a"], log); } @@ -545,7 +545,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["b", "c", "a"], log); } @@ -559,7 +559,7 @@ assertDoesNotThrow(gaga); } } foo().then(() => log.push("c")); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(["a", "b", "c"], log); } @@ -585,7 +585,7 @@ assertDoesNotThrow(gaga); var ans; f2().then(x => ans = x).catch(e => ans = e); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals([0], ans); } diff --git a/implementation-contributed/v8/mjsunit/es8/async-await-no-constructor.js b/implementation-contributed/v8/mjsunit/es8/async-await-no-constructor.js index e954e2ac5719862311d055207be6ceb1f59e810c..5e4780a6ef6d9710fc363be10e5417045d8c80ae 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-await-no-constructor.js +++ b/implementation-contributed/v8/mjsunit/es8/async-await-no-constructor.js @@ -23,5 +23,5 @@ async function bar() { foo(); bar(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(2, count); diff --git a/implementation-contributed/v8/mjsunit/es8/async-await-species.js b/implementation-contributed/v8/mjsunit/es8/async-await-species.js index b3e925433a94667db8b9f50c212a9c847c85d55a..3fc46fd230ff74950fed73fd84cf84285c188e5d 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-await-species.js +++ b/implementation-contributed/v8/mjsunit/es8/async-await-species.js @@ -21,7 +21,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; diff --git a/implementation-contributed/v8/mjsunit/es8/async-destructuring.js b/implementation-contributed/v8/mjsunit/es8/async-destructuring.js index 1fbac5a0721b5b3a89e05b049877d2fc822c8818..d5e90eb0576f0c27231a5664953f047515df1765 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-destructuring.js +++ b/implementation-contributed/v8/mjsunit/es8/async-destructuring.js @@ -21,7 +21,7 @@ function assertThrowsAsync(run, errorType, message) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (!hadError) { throw new MjsUnitAssertionError( @@ -55,7 +55,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; @@ -77,7 +77,7 @@ function assertEqualsAsync(expected, run, msg) { assertEquals(1, y); assertEquals(1, z); assertEquals(0, w); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(1, y); assertEquals(1, z); assertEquals(1, w); diff --git a/implementation-contributed/v8/mjsunit/es8/async-function-try-finally.js b/implementation-contributed/v8/mjsunit/es8/async-function-try-finally.js index 9ba07eb4276e48c1b53bb6afae91453b8c5b03d2..43badc480aef45de024652d58a17a7688ccc1d86 100644 --- a/implementation-contributed/v8/mjsunit/es8/async-function-try-finally.js +++ b/implementation-contributed/v8/mjsunit/es8/async-function-try-finally.js @@ -21,7 +21,7 @@ function assertThrowsAsync(run, errorType, message) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (!hadError) { throw new MjsUnitAssertionError( @@ -55,7 +55,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; diff --git a/implementation-contributed/v8/mjsunit/harmony/async-from-sync-iterator.js b/implementation-contributed/v8/mjsunit/harmony/async-from-sync-iterator.js index 2d6be098a24166c7a1b54dd9c1194389a9b2027a..e9dfe5d32242084f84e25e452ac8b7ad19fff844 100644 --- a/implementation-contributed/v8/mjsunit/harmony/async-from-sync-iterator.js +++ b/implementation-contributed/v8/mjsunit/harmony/async-from-sync-iterator.js @@ -24,7 +24,7 @@ function assertThrowsAsync(run, errorType, message) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (!hadError) { throw new MjsUnitAssertionError( @@ -185,7 +185,7 @@ class MyError extends Error {}; testFailure = error; }); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); if (testFailed) { throw testFailure; } @@ -619,7 +619,7 @@ if (testFailed) { testFailure = error; }); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); if (testFailed) { throw testFailure; } @@ -663,7 +663,7 @@ if (testFailed) { // Cycle through `f` to extract iterator methods f().catch(function() { %AbortJS("No error should have occurred"); }); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assertEquals(typeof extractedNext, "function"); assertThrowsAsync(() => extractedNext.call(undefined), TypeError); diff --git a/implementation-contributed/v8/mjsunit/harmony/async-generators-basic.js b/implementation-contributed/v8/mjsunit/harmony/async-generators-basic.js index cf21d9a8c8254855a87775c4e2d0bd4da87d836c..5ff7d25eea67fd6b17334189c1d30263d37204b0 100644 --- a/implementation-contributed/v8/mjsunit/harmony/async-generators-basic.js +++ b/implementation-contributed/v8/mjsunit/harmony/async-generators-basic.js @@ -21,7 +21,7 @@ function assertThrowsAsync(run, errorType, message) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (!hadError) { throw new MjsUnitAssertionError( @@ -55,7 +55,7 @@ function assertEqualsAsync(expected, run, msg) { assertFalse(hadValue || hadError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (hadError) throw actual; @@ -448,7 +448,7 @@ async function* asyncGeneratorForNestedResumeNext() { } it = asyncGeneratorForNestedResumeNext(); it.next().then(logIterResult, AbortUnreachable); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "rootbeer", done: false }, { value: "float", done: false }, @@ -464,7 +464,7 @@ let asyncGeneratorExprForNestedResumeNext = async function*() { }; it = asyncGeneratorExprForNestedResumeNext(); it.next().then(logIterResult, AbortUnreachable); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "first", done: false }, { value: "second", done: false }, @@ -482,7 +482,7 @@ let asyncGeneratorMethodForNestedResumeNext = ({ }).method; it = asyncGeneratorMethodForNestedResumeNext(); it.next().then(logIterResult, AbortUnreachable); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "remember", done: false }, { value: "the cant!", done: false }, @@ -498,7 +498,7 @@ let asyncGeneratorCallEvalForNestedResumeNext = yield await Resolver("rainbow!");`); it = asyncGeneratorCallEvalForNestedResumeNext(); it.next().then(logIterResult, AbortUnreachable); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "reading", done: false }, { value: "rainbow!", done: false }, @@ -514,7 +514,7 @@ let asyncGeneratorNewEvalForNestedResumeNext = yield await Resolver("BB!");`); it = asyncGeneratorNewEvalForNestedResumeNext(); it.next().then(logIterResult, AbortUnreachable); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: 731, done: false }, { value: "BB!", done: false }, @@ -536,7 +536,7 @@ async function* asyncGeneratorForNestedResumeThrow() { } it = asyncGeneratorForNestedResumeThrow(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ "throw1", "throw2", @@ -556,7 +556,7 @@ let asyncGeneratorExprForNestedResumeThrow = async function*() { }; it = asyncGeneratorExprForNestedResumeThrow(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ "throw3", "throw4", @@ -578,7 +578,7 @@ let asyncGeneratorMethodForNestedResumeThrow = ({ }).method; it = asyncGeneratorMethodForNestedResumeThrow(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ "throw5", "throw6", @@ -598,7 +598,7 @@ let asyncGeneratorCallEvalForNestedResumeThrow = AbortUnreachable();`); it = asyncGeneratorCallEvalForNestedResumeThrow(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ "throw7", "throw8", @@ -618,7 +618,7 @@ let asyncGeneratorNewEvalForNestedResumeThrow = AbortUnreachable();`); it = asyncGeneratorNewEvalForNestedResumeThrow(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ "throw9", "throw10", @@ -636,7 +636,7 @@ async function* asyncGeneratorForNestedResumeReturn() { } it = asyncGeneratorForNestedResumeReturn(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "step1", done: false }, { value: "step2", done: true }, @@ -651,7 +651,7 @@ let asyncGeneratorExprForNestedResumeReturn = async function*() { }; it = asyncGeneratorExprForNestedResumeReturn(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "step3", done: false }, { value: "step4", done: true }, @@ -668,7 +668,7 @@ let asyncGeneratorMethodForNestedResumeReturn = ({ }).method; it = asyncGeneratorMethodForNestedResumeReturn(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "step5", done: false }, { value: "step6", done: true }, @@ -683,7 +683,7 @@ let asyncGeneratorCallEvalForNestedResumeReturn = yield "step7";`); it = asyncGeneratorCallEvalForNestedResumeReturn(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "step7", done: false }, { value: "step8", done: true }, @@ -698,7 +698,7 @@ let asyncGeneratorNewEvalForNestedResumeReturn = yield "step9";`); it = asyncGeneratorNewEvalForNestedResumeReturn(); it.next().then(logIterResult, logError); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals([ { value: "step9", done: false }, { value: "step10", done: true }, diff --git a/implementation-contributed/v8/mjsunit/harmony/for-await-of.js b/implementation-contributed/v8/mjsunit/harmony/for-await-of.js index e23758a5e160c2b7f46c2f09980ac6baac91c81d..1b4fcd701a268d242f1d063b2b337511ec3461b4 100644 --- a/implementation-contributed/v8/mjsunit/harmony/for-await-of.js +++ b/implementation-contributed/v8/mjsunit/harmony/for-await-of.js @@ -1257,7 +1257,7 @@ let testFailure; testFailure = error; }); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); if (testFailed) { throw testFailure; diff --git a/implementation-contributed/v8/mjsunit/harmony/import-from-compilation-errored.js b/implementation-contributed/v8/mjsunit/harmony/import-from-compilation-errored.js index 3c99498d0e57d4f144e644a21937aecfd93499e1..49570b51def64613270c582b8f7ac2b944d7816f 100644 --- a/implementation-contributed/v8/mjsunit/harmony/import-from-compilation-errored.js +++ b/implementation-contributed/v8/mjsunit/harmony/import-from-compilation-errored.js @@ -7,7 +7,7 @@ var error1, error2; import('modules-skip-12.js').catch(e => error1 = e); import('modules-skip-12.js').catch(e => error2 = e); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(error1, error2); assertInstanceof(error1, SyntaxError); diff --git a/implementation-contributed/v8/mjsunit/harmony/import-from-evaluation-errored.js b/implementation-contributed/v8/mjsunit/harmony/import-from-evaluation-errored.js index 3623091777769f3579ec449bec4225239eb35cfe..87dbc0a6aae38e0ebd202c34edfd59bea12a0633 100644 --- a/implementation-contributed/v8/mjsunit/harmony/import-from-evaluation-errored.js +++ b/implementation-contributed/v8/mjsunit/harmony/import-from-evaluation-errored.js @@ -7,7 +7,7 @@ var error1, error2; import('modules-skip-11.js').catch(e => error1 = e); import('modules-skip-11.js').catch(e => error2 = e); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(error1, error2); assertEquals(typeof error1, "symbol"); diff --git a/implementation-contributed/v8/mjsunit/harmony/import-from-fetch-errored.js b/implementation-contributed/v8/mjsunit/harmony/import-from-fetch-errored.js index f3db881eb2b80113a6b8ab758391f101ef4695cc..6d6510fcdee459c140f216a03eae0762a6fdd149 100644 --- a/implementation-contributed/v8/mjsunit/harmony/import-from-fetch-errored.js +++ b/implementation-contributed/v8/mjsunit/harmony/import-from-fetch-errored.js @@ -7,7 +7,7 @@ var error1, error2; import('no-such-file').catch(e => error1 = e); import('no-such-file').catch(e => error2 = e); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(error1, error2); assertEquals(typeof error1, "string"); diff --git a/implementation-contributed/v8/mjsunit/harmony/import-from-instantiation-errored.js b/implementation-contributed/v8/mjsunit/harmony/import-from-instantiation-errored.js index 2a481d5965e51fe60cbf2d9988bf8adca6ba2129..2cdbaaea32441db596a912b4ba1192cb6e92ac8b 100644 --- a/implementation-contributed/v8/mjsunit/harmony/import-from-instantiation-errored.js +++ b/implementation-contributed/v8/mjsunit/harmony/import-from-instantiation-errored.js @@ -7,7 +7,7 @@ var error1, error2; import('modules-skip-10.js').catch(e => error1 = e); import('modules-skip-10.js').catch(e => error2 = e); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(error1, error2); assertInstanceof(error1, SyntaxError); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-1.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-1.js index 7fd567f56f59ad574b6be2705a54f7aea415e0c8..f62d4d7b320f0e279413aa7123d82006a1d9ccf5 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-1.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-1.js @@ -7,6 +7,6 @@ var life; import('modules-skip-1.js').then(namespace => life = namespace.life()); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, life); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-10.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-10.js index 68e000a131e96a238684c123bb7a4cd6e1361b21..eda4aaf7f9faea437b41112a0ceb62887d77cfe6 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-10.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-10.js @@ -9,7 +9,7 @@ import('modules-skip-6.js').then(namespace => life = namespace.life); assertEquals(undefined, Object.life); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, Object.life); assertEquals("42", life); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-11.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-11.js index a5afa100486324bbb034a92fb1a6f8335b9b4786..ffba6a0722c66bd978cb7179a23222773c8a2303 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-11.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-11.js @@ -18,5 +18,5 @@ async function test() { } test(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-12.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-12.js index bcb85692217a09c6fbecf8817d976c27cc0926b8..d898c984ad4c9e7bbee086eac1d492709682a6f0 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-12.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-12.js @@ -15,5 +15,5 @@ async function test() { } test(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-13.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-13.js index 1cec1cce61478079cd39f8e5961945e05cf94f07..52518350ba95b480808985b8417daa37927b0ae0 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-13.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-13.js @@ -19,7 +19,7 @@ async function test1() { } test1(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); ran = false; @@ -36,5 +36,5 @@ async function test2() { } test2(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-14.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-14.js index 3849c54c59bdb24f4b87f2e44457b62100f9d5bd..32b307eb3b74e11d525c0c7b9a1e047b893e61e4 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-14.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-14.js @@ -22,5 +22,5 @@ async function test() { } test(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-15.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-15.js index 32255ce980cc4dfca50d1707c4d19ea8d3050de5..d041add3db257c250ba028c3c9ea5810eeb90af2 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-15.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-15.js @@ -17,7 +17,7 @@ async function test1() { } test1(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); ran = false; @@ -37,7 +37,7 @@ async function test2() { } test2(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); ran = false; @@ -53,5 +53,5 @@ async function test3() { } test3(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-16.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-16.js index 94510d48fcc8c571e960aaeece5b8d69e3a75675..18ad445a8422733ba0f3884ad7e050ee55a06148 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-16.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-16.js @@ -12,7 +12,7 @@ var body = "import('modules-skip-1.js').then(ns => { x = ns.life();" + var func = new Function(body); func(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, x); assertTrue(ran); @@ -21,7 +21,7 @@ var body = "import('modules-skip-1.js').then(ns => { x = ns.life();" + " ran = true;} ).catch(err => %AbortJS(err))" eval("var func = new Function(body); func();"); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, x); assertTrue(ran); @@ -31,6 +31,6 @@ var body = "eval(import('modules-skip-1.js').then(ns => { x = ns.life();" + var func = new Function(body); func(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, x); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-17.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-17.js index f73aa68f3bb41f4351de12e6e94f19474677b85c..606ebcd385aab3be8b549c7a0348c092f1950dfa 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-17.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-17.js @@ -6,6 +6,6 @@ var ns; import('modules-skip-13.js').then(x => ns = x); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, ns.default); assertEquals(ns, ns.self); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-2.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-2.js index f50a5c8c534f699ed77bdecc73003dc170218b4d..a3fe0bc601cc8afbeb9592cd71dd43c0172c181b 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-2.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-2.js @@ -12,7 +12,7 @@ import('modules-skip-2.js').catch(err => msg = err.message); assertEquals(undefined, life); assertEquals(undefined, msg); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, life); assertEquals('42 is not the answer', msg); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-3.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-3.js index 669f820fd723762c2505f97372a3b118bcb05105..d8cbe2a2280bc27b511861050e8360e1eee7e474 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-3.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-3.js @@ -17,6 +17,6 @@ async function foo () { foo(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-5.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-5.js index d9237828fed87055148092b5b588503af2e50596..c868a0c63f06e67f38163034da794e8f1ef6ced8 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-5.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-5.js @@ -9,5 +9,5 @@ let x = 'modules-skip-1.js'; import(x).then(namespace => life = namespace.life()); x = 'modules-skip-2.js'; -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(42, life); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-6.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-6.js index 6a5b7c8b5b9d3519a100437bf15e407fe2eeb572..02fdf1b5fa34ca83132054ecc230e2121de04423 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-6.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-6.js @@ -25,5 +25,5 @@ async function test() { test(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-7.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-7.js index d0105112f44c30101595893ba329a99a994b5352..8df8ddcdb236df1df19515a0fa0a753e8b941a4b 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-7.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-7.js @@ -19,6 +19,6 @@ async function test() { test(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-8.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-8.js index 4417f0eb7885d9872ad4d58cbec2e0b25a0d05e9..ac21a8c9e920aff21b11ca559b0391e901b5fd36 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-8.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-8.js @@ -43,7 +43,7 @@ async function test1() { test1(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); @@ -66,7 +66,7 @@ async function test2() { test2(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); @@ -86,6 +86,6 @@ async function test3() { test3(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/modules-import-9.js b/implementation-contributed/v8/mjsunit/harmony/modules-import-9.js index 6794311305c08ea2325ef3a79d7a1c596ae4cc61..664416f0eb85334b26ac05610ec6ce053acd6725 100644 --- a/implementation-contributed/v8/mjsunit/harmony/modules-import-9.js +++ b/implementation-contributed/v8/mjsunit/harmony/modules-import-9.js @@ -18,5 +18,5 @@ async function test() { } test(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(ran); diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-and-cleared-weakref.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-and-cleared-weakref.js index a7105771b30a6542ecf6b3fddf4d80a14e552763..66058e8bcdd65fbefc23ef70ce4e76d50eecf17f 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-and-cleared-weakref.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-and-cleared-weakref.js @@ -25,7 +25,7 @@ let weak_ref; })(); // Clear the KeepDuringJob set. -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); weak_ref.deref(); o = null; @@ -37,7 +37,7 @@ gc(); wf.cleanupSome(); assertEquals(0, cleanup_count); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. // This GC detects the WeakRef as dirty. diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-weakref.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-weakref.js index fb113bef0d7bd9bd216e1ab34b653cf002cfa9f1..d6d937309442d9fbaa61b8ebe436c3382857a414 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-weakref.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-dereffed-weakref.js @@ -25,7 +25,7 @@ let weak_ref; })(); // Clear the KeepDuringJob set. -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); weak_ref.deref(); o = null; @@ -37,7 +37,7 @@ gc(); wf.cleanupSome(); assertEquals(0, cleanup_count); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. // Now the WeakRef can be cleared. @@ -51,7 +51,7 @@ assertEquals(weak_ref, cleanup_cells[0]); // The cleanup task is not executed again since all WeakCells have been // processed. -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. assertEquals(1, cleanup_count); diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-weakref.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-weakref.js index ab1e7ebe193d0737d2815889491d3eb45a063f86..d478aaab8c84c1d83d47e4fc2dec7ac924fa3c43 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-weakref.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/cleanupsome-weakref.js @@ -31,7 +31,7 @@ gc(); wf.cleanupSome(); assertEquals(0, cleanup_count); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. // Now the WeakRef can be cleared. diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/clear-after-deref.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/clear-after-deref.js index e76ff0011f87b69ebcbf66264972a249a4fd5c77..9577f48b054dffd3a88f987e053a7cff6d579797 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/clear-after-deref.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/clear-after-deref.js @@ -28,7 +28,7 @@ let wr; gc(); assertNotEquals(undefined, wr.deref()); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // New turn. let o = wr.deref(); diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/two-weakrefs.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/two-weakrefs.js index 067578f29beb26a86cd3c70e5bce328c5dd18139..7109d51fde67b2539e21f5a686d2a7aaae9c7907 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/two-weakrefs.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/two-weakrefs.js @@ -38,7 +38,7 @@ gc(); assertNotEquals(undefined, wr2.deref()); })(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // New turn. assertEquals(0, cleanup_count); @@ -47,7 +47,7 @@ wr1.deref(); o1 = null; gc(); // deref makes sure we don't clean up wr1 -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // New turn. assertEquals(0, cleanup_count); @@ -56,7 +56,7 @@ wr2.deref(); o2 = null; gc(); // deref makes sure we don't clean up wr2 -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // New turn. assertEquals(1, cleanup_count); @@ -64,7 +64,7 @@ assertEquals(wr1, cleared_cells1[0]); gc(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // New turn. assertEquals(2, cleanup_count); diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakcell-and-weakref.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakcell-and-weakref.js index 4e5eec018b91d88d950a0f1f3710e2145373a840..fc400169d0d66b80bd2e57f88de152df9c88ab2e 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakcell-and-weakref.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakcell-and-weakref.js @@ -34,12 +34,12 @@ gc(); assertNotEquals(undefined, weak_ref.deref()); })(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. gc(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. assertTrue(cleanup_called); diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-creation-keeps-alive.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-creation-keeps-alive.js index fd22345104aa292f120af550c7f90f6a088989ab..02313fe761585de0c55b2b547cc57160892e05ca 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-creation-keeps-alive.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-creation-keeps-alive.js @@ -33,14 +33,14 @@ gc(); assertNotEquals(undefined, wr.deref()); })(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. assertFalse(cleanup_called); gc(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. assertTrue(cleanup_called); diff --git a/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-deref-keeps-alive.js b/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-deref-keeps-alive.js index c67dc0a11b978059add7b1a3590a47c2e98396d1..05917c526159286221727f3d6336ec0411bb5387 100644 --- a/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-deref-keeps-alive.js +++ b/implementation-contributed/v8/mjsunit/harmony/weakrefs/weakref-deref-keeps-alive.js @@ -29,12 +29,12 @@ let strong = {a: wr.deref(), b: wr_control.deref()}; gc(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. gc(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. // We have a strong reference to the objects, so the WeakRefs are not cleared yet. @@ -57,7 +57,7 @@ gc(); assertEquals(undefined, wr_control.deref()); })(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. assertEquals(1, cleanup_count); @@ -66,7 +66,7 @@ assertEquals(wc, cleanup_cells[0]); gc(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); // Next turn. assertEquals(2, cleanup_count); diff --git a/implementation-contributed/v8/mjsunit/mjsunit.status b/implementation-contributed/v8/mjsunit/mjsunit.status index 1901aded6259e21711e2446fb1f15f33768a7e98..76b22d8467c8f3efa70ca93540698ca7a4f25243 100644 --- a/implementation-contributed/v8/mjsunit/mjsunit.status +++ b/implementation-contributed/v8/mjsunit/mjsunit.status @@ -32,6 +32,7 @@ 'modules-skip*': [SKIP], 'harmony/modules-skip*': [SKIP], 'regress/modules-skip*': [SKIP], + 'wasm/exceptions-utils': [SKIP], 'wasm/wasm-constants': [SKIP], 'wasm/wasm-module-builder': [SKIP], @@ -569,6 +570,10 @@ 'regress/regress-752764': [SKIP], 'regress/regress-779407': [SKIP], 'harmony/bigint/regressions': [SKIP], + + # Pre-r6 MIPS32 doesn't have instructions needed to properly handle 64-bit + # atomic instructions. + 'wasm/atomics64-stress': [PASS, ['mips_arch_variant != r6', SKIP]], }], # 'arch == mipsel or arch == mips' ############################################################################## @@ -623,6 +628,11 @@ 'regress/regress-779407': [SKIP], }], # 'arch == mips64el or arch == mips64' +['(arch == mips64el or arch == mips64) and simulator_run', { + # Slow tests which have flaky timeout on simulator. + 'wasm/atomics64-stress': [SKIP], +}], # '(arch == mips64el or arch == mips64) and simulator_run' + ############################################################################## ['system == windows', { # TODO(mstarzinger): Too slow with turbo fan. diff --git a/implementation-contributed/v8/mjsunit/regress/regress-5405.js b/implementation-contributed/v8/mjsunit/regress/regress-5405.js index eeab479384e5d72326a90f91f512636fb9a1c4d1..e21818c880eeab62af83c0eff4f142a9e5256c45 100644 --- a/implementation-contributed/v8/mjsunit/regress/regress-5405.js +++ b/implementation-contributed/v8/mjsunit/regress/regress-5405.js @@ -11,7 +11,7 @@ let log = []; return 10; } })(); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); (function() { with ({get ['.new.target']() { log.push('new.target') }}) { diff --git a/implementation-contributed/v8/mjsunit/regress/regress-5691.js b/implementation-contributed/v8/mjsunit/regress/regress-5691.js index 6cda92ca79329acd0d7a950a40a9a1929147ae72..b460ac4b991b075aed20d6904caf879474bff0fd 100644 --- a/implementation-contributed/v8/mjsunit/regress/regress-5691.js +++ b/implementation-contributed/v8/mjsunit/regress/regress-5691.js @@ -18,6 +18,6 @@ Promise.resolve(Promise.resolve()).then(() => log += "|fast-resolve"); (class extends Promise {}).resolve(Promise.resolve()).then(() => log += "|slow-resolve"); log += "|start"; - %RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals("|start|turn1|fast-resolve|turn2|turn3|slow-resolve|turn4\n\ |start|turn1|fast-resolve|turn2|turn3|slow-resolve|turn4", result); diff --git a/implementation-contributed/v8/mjsunit/regress/regress-682349.js b/implementation-contributed/v8/mjsunit/regress/regress-682349.js index d94e0691d631b4fbd90b8e8af564e1c20885f803..f82f242f0387b53bcc862be49853cb158bfb6182 100644 --- a/implementation-contributed/v8/mjsunit/regress/regress-682349.js +++ b/implementation-contributed/v8/mjsunit/regress/regress-682349.js @@ -9,5 +9,5 @@ function f() { success = (f.caller === null); } Promise.resolve().then(f); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(success); diff --git a/implementation-contributed/v8/mjsunit/regress/regress-740694.js b/implementation-contributed/v8/mjsunit/regress/regress-740694.js index f07eb1b3a7b0d707d759faef0e39cfc8ab1e7115..6f31fef0c7d679531bd7ba6454739ce0be5ce381 100644 --- a/implementation-contributed/v8/mjsunit/regress/regress-740694.js +++ b/implementation-contributed/v8/mjsunit/regress/regress-740694.js @@ -17,6 +17,6 @@ var error; var promise = __f_0(); promise.then(assertUnreachable, err => { done = true; error = err }); -%RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertTrue(error.startsWith('Error reading')); assertTrue(done); diff --git a/implementation-contributed/v8/mjsunit/regress/regress-797581.js b/implementation-contributed/v8/mjsunit/regress/regress-797581.js index eb87e67128c91a0bc335d49600c8825b2433a5ec..3dfad4c463064ed8a9511b17a41754011cc96571 100644 --- a/implementation-contributed/v8/mjsunit/regress/regress-797581.js +++ b/implementation-contributed/v8/mjsunit/regress/regress-797581.js @@ -17,7 +17,7 @@ function TryToLoadModule(filename, expect_error, token) { } import(filename).catch(SetError); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); if (expect_error) { assertTrue(caught_error instanceof SyntaxError); diff --git a/implementation-contributed/v8/mjsunit/regress/regress-800651.js b/implementation-contributed/v8/mjsunit/regress/regress-800651.js index c6410f702eefbd82c3dec62026ece280de242ec5..05e31fe4ca14e0e18aa249aee5c64658ee6e5426 100644 --- a/implementation-contributed/v8/mjsunit/regress/regress-800651.js +++ b/implementation-contributed/v8/mjsunit/regress/regress-800651.js @@ -27,5 +27,5 @@ function g() { let namespace = Promise.resolve().then(importUndefined); } g(); - %RunMicrotasks(); +%PerformMicrotaskCheckpoint(); assertEquals(list, [1,2]); diff --git a/implementation-contributed/v8/mjsunit/regress/regress-crbug-911416.js b/implementation-contributed/v8/mjsunit/regress/regress-crbug-911416.js new file mode 100644 index 0000000000000000000000000000000000000000..60d7ae892ac3d084cd989053f95b8d92a0d095f2 --- /dev/null +++ b/implementation-contributed/v8/mjsunit/regress/regress-crbug-911416.js @@ -0,0 +1,5 @@ +// Copyright 2018 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +assertEquals(7, ({[Symbol.hasInstance.description]:7})["Symbol.hasInstance"]); diff --git a/implementation-contributed/v8/mjsunit/regress/wasm/regress-8533.js b/implementation-contributed/v8/mjsunit/regress/wasm/regress-8533.js new file mode 100644 index 0000000000000000000000000000000000000000..5d782b747c5d464001703cd25994ead6e2fe4c30 --- /dev/null +++ b/implementation-contributed/v8/mjsunit/regress/wasm/regress-8533.js @@ -0,0 +1,85 @@ +// Copyright 2018 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Flags: --wasm-shared-engine --no-wasm-disable-structured-cloning --allow-natives-syntax --experimental-wasm-threads + +load('test/mjsunit/wasm/wasm-constants.js'); +load('test/mjsunit/wasm/wasm-module-builder.js'); + + +// In this test we start a worker which enters wasm and stays there in a loop. +// The main thread stays in JS and checks that its thread-in-wasm flag is not +// set. The main thread calls setTimeout after every check to give the worker a +// chance to be scheculed. +const sync_address = 12; +(function TestPostModule() { + let builder = new WasmModuleBuilder(); + let sig_index = builder.addType(kSig_v_v); + let import_id = builder.addImport('m', 'func', sig_index); + builder.addFunction('wait', kSig_v_v) + .addBody([ + // Calling the imported function sets the thread-in-wasm flag of the + // main thread. + kExprCallFunction, import_id, // -- + kExprLoop, kWasmStmt, // -- + kExprI32Const, sync_address, // -- + kExprI32LoadMem, 0, 0, // -- + kExprI32Eqz, + kExprBrIf, 0, // -- + kExprEnd, + ]) + .exportFunc(); + + builder.addFunction('signal', kSig_v_v) + .addBody([ + kExprI32Const, sync_address, // -- + kExprI32Const, 1, // -- + kExprI32StoreMem, 0, 0, // -- + ]) + .exportFunc(); + builder.addImportedMemory("m", "imported_mem", 0, 1, "shared"); + + let module = builder.toModule(); + let memory = new WebAssembly.Memory({initial: 1, maximum: 1, shared: true}); + + let workerScript = ` + onmessage = function(msg) { + try { + let worker_instance = new WebAssembly.Instance(msg.module, + {m: {imported_mem: msg.memory, + func: _ => 5}}); + postMessage("start running"); + worker_instance.exports.wait(); + postMessage("finished"); + } catch(e) { + postMessage('ERROR: ' + e); + } + } + `; + + let worker = new Worker(workerScript, {type: 'string'}); + worker.postMessage({module: module, memory: memory}); + + let main_instance = new WebAssembly.Instance( + module, {m: {imported_mem: memory, func: _ => 7}}); + + let counter = 0; + function CheckThreadNotInWasm() { + // We check the thread-in-wasm flag many times and reschedule ourselves in + // between to increase the chance that we read the flag set by the worker. + assertFalse(%IsThreadInWasm()); + counter++; + if (counter < 100) { + setTimeout(CheckThreadNotInWasm, 0); + } else { + main_instance.exports.signal(sync_address); + assertEquals('finished', worker.getMessage()); + worker.terminate(); + } + } + + assertFalse(%IsThreadInWasm()); + assertEquals('start running', worker.getMessage()); + CheckThreadNotInWasm(); +})(); diff --git a/implementation-contributed/v8/mjsunit/test-async.js b/implementation-contributed/v8/mjsunit/test-async.js index d4fee9bfb9587ac751a21b6a5674c3577259b29a..8f7b553988a8a91e3ca8230b5680c725ba657de3 100644 --- a/implementation-contributed/v8/mjsunit/test-async.js +++ b/implementation-contributed/v8/mjsunit/test-async.js @@ -80,7 +80,7 @@ var testAsync; } drainMicrotasks() { - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); } done_() { @@ -111,7 +111,7 @@ var testAsync; testAsync = function(test, name) { let assert = new AsyncAssertion(test, name); test(assert); - %RunMicrotasks(); + %PerformMicrotaskCheckpoint(); assert.done_(); } })(); diff --git a/implementation-contributed/v8/test262/test262.status b/implementation-contributed/v8/test262/test262.status index 26acc1257096c97492aa0fd584bc03a67f71b925..ecab026c989c44d8fb8dbd96b0563dba6604d4ae 100644 --- a/implementation-contributed/v8/test262/test262.status +++ b/implementation-contributed/v8/test262/test262.status @@ -562,9 +562,6 @@ 'built-ins/Object/internals/DefineOwnProperty/consistent-value-function-caller': [FAIL_SLOPPY], 'built-ins/Object/internals/DefineOwnProperty/consistent-value-function-arguments': [FAIL_SLOPPY], - # https://bugs.chromium.org/p/v8/issues/detail?id=7874 - 'built-ins/Reflect/ownKeys/return-on-corresponding-order-large-index': [FAIL], - # https://bugs.chromium.org/p/v8/issues/detail?id=6776 'built-ins/Proxy/ownKeys/return-duplicate-entries-throws': [FAIL], 'built-ins/Proxy/ownKeys/return-duplicate-symbol-entries-throws': [FAIL], @@ -666,6 +663,16 @@ 'language/expressions/await/for-await-of-interleaved': ['--harmony-await-optimization'], 'language/expressions/await/async-await-interleaved': ['--harmony-await-optimization'], + # https://bugs.chromium.org/p/v8/issues/detail?id=6891 + 'intl402/Segmenter/iterator/following': [FAIL], + 'intl402/Segmenter/iterator/granularity': [FAIL], + 'intl402/Segmenter/iterator/preceding': [FAIL], + 'intl402/Segmenter/prototype/segment/segment-line': [FAIL], + 'intl402/Segmenter/prototype/segment/segment-sentence': [FAIL], + 'intl402/Segmenter/prototype/segment/segment-word': [FAIL], + + # https://bugs.chromium.org/p/v8/issues/detail?id=8021 + 'built-ins/Object/fromEntries/requires-argument': [FAIL], ######################## NEEDS INVESTIGATION ########################### # These test failures are specific to the intl402 suite and need investigation diff --git a/implementation-contributed/v8/test262/testcfg.py b/implementation-contributed/v8/test262/testcfg.py index e62759885a5b85a44caa50ac43abccdcdf36ec6c..9052aab12fa8d3c20fbeae4bb4dd88c8a6b1925b 100644 --- a/implementation-contributed/v8/test262/testcfg.py +++ b/implementation-contributed/v8/test262/testcfg.py @@ -63,7 +63,8 @@ FEATURE_FLAGS = { SKIPPED_FEATURES = set(['class-fields-private', 'class-static-fields-private', 'class-methods-private', - 'class-static-methods-private']) + 'class-static-methods-private', + 'Intl.NumberFormat-unified']) DATA = os.path.join(os.path.dirname(os.path.abspath(__file__)), "data") diff --git a/implementation-contributed/v8/wasm-js/wasm-js.status b/implementation-contributed/v8/wasm-js/wasm-js.status index 2f3111aa3a672d4d2775abfa209df9a42540cf47..fe74ca47f54e8515035a9ee41e90564e0e845573 100644 --- a/implementation-contributed/v8/wasm-js/wasm-js.status +++ b/implementation-contributed/v8/wasm-js/wasm-js.status @@ -5,7 +5,6 @@ [ [ALWAYS, { # https://bugs.chromium.org/p/v8/issues/detail?id=8319 - 'interface': [FAIL], 'memory/grow': [FAIL], 'memory/constructor': [FAIL], 'table/grow': [FAIL],