Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Benchmark Showcase - coregex vs stdlib Performance #4

kolkov started this conversation in Show and tell
Discussion options

Benchmark Results: coregex vs Go stdlib

This thread showcases real-world benchmark comparisons between coregex and Go's standard library regexp.

Test Environment

  • Go 1.23+
  • AMD64 with AVX2 support
  • All benchmarks run with -benchmem -benchtime=3s

Overall Performance Summary

Category Pattern Example stdlib coregex Speedup
Case-insensitive (?i)sherlock 1.6 ms 7 us 233x
Suffix matching .*\.txt 27 ms 21 us 1,314x
Capture groups (\d+)-(\d+) 700 ns 70 ns 10x
Simple literal hello 688 ns 196 ns 3.5x

How to Run Your Own Benchmarks

# Clone the repository
git clone https://github.com/coregx/coregex.git
cd coregex
# Run comparison benchmarks
go test -bench=. -benchmem ./benchmark/comparison/
# Run specific pattern test
go test -bench=BenchmarkReverseSuffix -benchmem ./meta/

Share Your Results!

Have you tested coregex with your patterns? Share your benchmark results in the comments!

What to include:

  • Pattern used
  • Input size
  • stdlib vs coregex times
  • Your use case (log parsing, data extraction, etc.)

We'll periodically update this post with community-submitted benchmarks.

You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /