-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Perf] Regression in Perf_Regex.Uri_IsNotMatch(IgnoreCase, Compiled) #61786
Comments
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label. |
Seems related to #61490. This is the only regression we detected, but it is fairly large (80%) |
I'm actually pleased it's the only one detected. I expected and accepted this one in exchange for gains elsewhere. Though looking at it again there's probably somethings we can do to improve it. |
The issue here actually isn't what I thought it was. The core of the issue is: runtime/src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexNode.cs Lines 1828 to 1832 in 6ff57f1
This test has this sequence:
Previously we'd use this CanBeMadeAtomic to check whether The good news is the problem will just go away with #61048. There are workarounds we could put in place in the interim, but I'm tempted to say we should just prioritize fully addressing that issue asap rather than trying to patch things like this. @joperezr, thoughts? |
Let me make sure I understand correctly. The reason why fixing issue #61048 would fix this is because now |
@joperezr, exactly. (For this one specific case, it's further interesting because we recognize \w as being case-sensitive even under IgnoreCase, because the categories it maps to already includes both upper and lower. But because of how the parser works, even though [\w] and \w are 100% identical sets, the case-sensitive \w gets added to the set and [\w] ends up as case-insensitive.) |
Tagging subscribers to this area: @eerhardt, @dotnet/area-system-text-regularexpressions Issue DetailsRun Information
Regressions in System.Text.RegularExpressions.Tests.Perf_Regex_Common
Reprogit clone https://github.com/dotnet/performance.git
py .\performance\scripts\benchmarks_ci.py -f net6.0 --filter 'System.Text.RegularExpressions.Tests.Perf_Regex_Common*' PayloadsHistogramSystem.Text.RegularExpressions.Tests.Perf_Regex_Common.Uri_IsNotMatch(Options: IgnoreCase, Compiled)
DocsProfiling workflow for dotnet/runtime repository
|
Run Information
Regressions in System.Text.RegularExpressions.Tests.Perf_Regex_Common
Test Report
Repro
Payloads
Baseline
Compare
Histogram
System.Text.RegularExpressions.Tests.Perf_Regex_Common.Uri_IsNotMatch(Options: IgnoreCase, Compiled)
Docs
Profiling workflow for dotnet/runtime repository
Benchmarking workflow for dotnet/runtime repository
The text was updated successfully, but these errors were encountered: