Bug 175225 - Create a new JavaScript RegExp benchmark
Summary: Create a new JavaScript RegExp benchmark
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Michael Saboff
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-08-04 15:57 PDT by Michael Saboff
Modified: 2017-08-07 14:40 PDT (History)
7 users (show)

See Also:


Attachments
Patch (12.64 MB, patch)
2017-08-04 16:08 PDT, Michael Saboff
jfbastien: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Saboff 2017-08-04 15:57:30 PDT
The current common JavaScript benchmarks have spotty and outdated coverage of Regular Expression processing performance.  We should create a new benchmark that measures RegExp performance on likely real world web use of ES6 Regular Expressions.  This should include uses of RegExp's for parsing, complicated captured patterns, and use of the unicode flag.
Comment 1 Michael Saboff 2017-08-04 15:58:11 PDT
<rdar://problem/33183181>
Comment 2 Michael Saboff 2017-08-04 16:08:40 PDT
Created attachment 317305 [details]
Patch
Comment 3 Michael Saboff 2017-08-04 16:11:00 PDT
This patch is big primarily due one large JavaScript data file, waypoints.js used in the FlightPlanner test.
Comment 4 Build Bot 2017-08-04 16:14:09 PDT
Attachment 317305 [details] did not pass style-queue:


ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:78:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:160:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:166:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:168:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:219:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:225:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:232:  multiple statements on one line (semicolon)  [pep8/E702] [5]
ERROR: PerformanceTests/RexBench/FlightPlanner/convert-nfdc.py:236:  multiple statements on one line (semicolon)  [pep8/E702] [5]
Total errors found: 8 in 37 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 5 JF Bastien 2017-08-04 16:26:33 PDT
Comment on attachment 317305 [details]
Patch

Bugzilla seriously craps itself on this patch! Can't review inline...

Took a glance at what seems important, looks good overall. A few comments then r=me

PerformanceTests/RexBench/about.html

"help compete and win". Always be winning.

“Flight Planner Unicode” should be in Unicode instead!

“ equivolents” typo

PerformanceTests/RexBench/basic_benchmark.js

Copyright is 2016 here (check others too…)

“I'd call this arguments but we're in strict mode.” :-)
Comment 6 Michael Saboff 2017-08-04 17:20:25 PDT
Committed r220307: <http://trac.webkit.org/changeset/220307>
Comment 7 Saam Barati 2017-08-04 19:24:59 PDT
For some reason Bugzilla isn't letting me leave a comment on the patch, but you have a commented out line like:
//  print("Benchmark   .........

It's probably worth removing.
Comment 8 Ryan Haddad 2017-08-06 19:49:06 PDT
(In reply to Michael Saboff from comment #6)
> Committed r220307: <http://trac.webkit.org/changeset/220307>
This change introduced failures on the perf bot:

Running RexBench (162 of 183)
ERROR: layer at (0,0) size 785x1688
FAILED
Finished: 1.651345 s

Running RexBench/about.html (163 of 183)
ERROR: layer at (0,0) size 785x1306
FAILED
Finished: 1.587763 s

https://build.webkit.org/builders/Apple%20El%20Capitan%20Release%20WK2%20%28Perf%29/builds/966
Comment 9 Michael Saboff 2017-08-07 14:40:09 PDT
(In reply to Ryan Haddad from comment #8)
> (In reply to Michael Saboff from comment #6)
> > Committed r220307: <http://trac.webkit.org/changeset/220307>
> This change introduced failures on the perf bot:
> 
> Running RexBench (162 of 183)
> ERROR: layer at (0,0) size 785x1688
> FAILED
> Finished: 1.651345 s
> 
> Running RexBench/about.html (163 of 183)
> ERROR: layer at (0,0) size 785x1306
> FAILED
> Finished: 1.587763 s
> 
> https://build.webkit.org/builders/
> Apple%20El%20Capitan%20Release%20WK2%20%28Perf%29/builds/966

This is tracked in <https://bugs.webkit.org/show_bug.cgi?id=175289>