benchmark-action / benchmark-action/github-action-benchmark

Golang regex matching is slow

Open
#166 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1.3k
Forks
184
PR merge metrics
No merged PRs in 30d

Description

Example repro:

```
line = 'BenchmarkRangeQuery/rate_with_large_number_of_series,_1m_range-16 \t 1\t1313564639 ns/op\t1360919864 B/op\t 3697144 allocs/op'
const reExtract = /^(Benchmark\w+(?:\/?[\w()$%^&*-]*?)*?)(-\d+)?\s+(\d+)\s+([0-9.]+)\s+(.+)$/;

line.match(reExtract);
```

Matching is very, very slow. Takes >1min. Probably due to backtracking. Needs investigation.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.