GithubHelp home page GithubHelp logo

Add RegEx support about stringzilla HOT 5 CLOSED

ashvardanian avatar ashvardanian commented on July 3, 2024 1
Add RegEx support

from stringzilla.

Comments (5)

dmbaggett avatar dmbaggett commented on July 3, 2024

If you plan to add support for regexes I strongly suggest using Hyperscan/Vectorscan as a back end. Note however that pure Hyperscan has limitations -- e.g., no capturing group support -- but there is an alternative implementation shipped alongside it called Chimera that offers full pcre-style regex support.

Like your library, HS does a lot of really cool stuff with SIMD to massively speed things up.

from stringzilla.

ashvardanian avatar ashvardanian commented on July 3, 2024

I'm very familiar with HS and have been using it for years, but the core idea of this library is to be as minimalistic as possible and to work on "all" platforms. HS implementation is quite long and complex, so I was considering a simpler hack to solve common RegEx tasks without the need for DFA or advanced SIMD.

from stringzilla.

dmbaggett avatar dmbaggett commented on July 3, 2024

Take a look at tre as well; much more compact than HS and NFA-based.

https://github.com/laurikari/tre/

It's used in the magic library (what powers the file command).

from stringzilla.

dmbaggett avatar dmbaggett commented on July 3, 2024

Oh and you might also consider supporting glob syntax. Full-bore regexes are insane but I could see a very high performance glob matching implementation being super useful in many cases.

from stringzilla.

ashvardanian avatar ashvardanian commented on July 3, 2024

@dmbaggett, that’s a great suggestion! Will do!

from stringzilla.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.