Commit 408dddc5 authored by Frank Tang's avatar Frank Tang Committed by Commit Bot

[Intl] Add perf tests for case insensitive test

This is in preparation for the removal of Unibrow.

Bug: v8:8362
Change-Id: Icb969457e71d64d765eaf0fd1d0b8b9c6b6eb388
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1490572
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
Reviewed-by: 's avatarSathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: 's avatarMathias Bynens <mathias@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60042}
parent 6d1913fa
......@@ -23,6 +23,7 @@
"base_split.js",
"base_test.js",
"base.js",
"case_test.js",
"ctor.js",
"exec.js",
"flags.js",
......@@ -42,6 +43,7 @@
],
"results_regexp": "^%s\\-RegExp\\(Score\\): (.+)$",
"tests": [
{"name": "CaseInsensitiveTest"},
{"name": "Ctor"},
{"name": "Exec"},
{"name": "Flags"},
......
......@@ -13,6 +13,7 @@
"path": ["."],
"main": "run.js",
"resources": [
"case_test.js",
"base_ctor.js",
"base_exec.js",
"base_flags.js",
......@@ -41,6 +42,7 @@
],
"results_regexp": "^%s\\-RegExp\\(Score\\): (.+)$",
"tests": [
{"name": "CaseInsensitiveTest"},
{"name": "Ctor"},
{"name": "Exec"},
{"name": "Flags"},
......
// Copyright 2019 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.
function ConstCaseInsensitiveTest() {
/[a-t]/i.test("abCdefgzabCdefgzabCdefgzabCdefgzabCdefgzabCdefgzabCdefgzabCdefgz");
}
function ConstCaseInsensitiveNonLatin1Test() {
/[α-ζ]/i.test("βκςΑφabcdeβκEFGαοςερκ");
}
const icre = /[a-t]/i;
function GlobalConstCaseInsensitiveRegExpTest() {
icre.test("abCdefgzabCdefgzabCdefgzabCdefgzabCdefgzabCdefgzabCdefgzabCdefgz");
}
const icre2 = /[α-ζ]/i;
function GlobalConstCaseInsensitiveNonLatin1RegExpTest() {
icre2.test("βκςΑφabcdeβκEFGαοςερκ");
}
benchmarks = [ [ConstCaseInsensitiveTest, () => {}],
[ConstCaseInsensitiveNonLatin1Test, () => {}],
[GlobalConstCaseInsensitiveRegExpTest, () => {}],
[GlobalConstCaseInsensitiveNonLatin1RegExpTest, () => {}],
];
createBenchmarkSuite("CaseInsensitiveTest");
......@@ -9,6 +9,7 @@ load('ctor.js');
load('exec.js');
load('flags.js');
load('inline_test.js')
load('case_test.js');
load('match.js');
load('replace.js');
load('search.js');
......
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