DEV Community

Cover image for Improve Your Python Regex Performance Using Rust
Adarsh
Adarsh

Posted on

Improve Your Python Regex Performance Using Rust

I've made a wrapper over the Rust regex crate using PyO3 and maturin. I've named it flpc because it is short and easier to write. It works blazingly fast ⚡
(Only problem is that, it is not a full drop-in replacement for native re module)

pip install flpc
Enter fullscreen mode Exit fullscreen mode

Here's the link to the repository

Top comments (2)

Collapse
 
fennr profile image
Viktor Merkurev

Do you have performance comparisons?

Collapse
 
itsmeadarsh profile image
Adarsh

Not, till now. I made a benchmark script before (I'm unsure whether the script is written properly. Can you make a pull request for measuring the benchmark?)
github.com/itsmeadarsh2008/flpc/bl...