[Issue 18114] New: dmd 2.078-beta1: regex performance regression
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri Dec 22 20:27:55 UTC 2017
https://issues.dlang.org/show_bug.cgi?id=18114
Issue ID: 18114
Summary: dmd 2.078-beta1: regex performance regression
Product: D
Version: D2
Hardware: x86
OS: Mac OS X
Status: NEW
Severity: enhancement
Priority: P1
Component: phobos
Assignee: nobody at puremagic.com
Reporter: jrdemail2000-dlang at yahoo.com
My standard performance benchmarks show a regex regression moving from DMD
2.077.1 to DMD 2.078.0-beta1. The benchmark is the one described here:
https://github.com/eBay/tsv-utils-dlang/blob/master/docs/Performance.md#regular-expression-filter-benchmark.
No other performance regressions were seen, leading me to believe it is likely
specific to regex, rather than some other element of the program.
This program takes a user supplied regex as a command line argument. It creates
a Regex!char instance from the command line arg. Then it reads a file
line-by-line, searching each line for presence of the regex using matchFirst.
It's a fielded-search, so the matchFirst call is limited to a portion of the
line.
The benchmark times (MacBook Pro, OS X, 16GB ram, SSD drives):
- DMD 2.077.1: 11.40 seconds
- DMD 2.078.0-beta1: 15.10 seconds
Approximately a 30% increase. I ran it about 10 times, with very consistent
results.
If it would be helpful, I could produce a small standalone program to validate
the behavior.
--
More information about the Digitalmars-d-bugs
mailing list