ashvardanian / StringZilla

Up to 10x faster strings for C, C++, Python, Rust, and Swift, leveraging NEON, AVX2, AVX-512, and SWAR to accelerate search, sort, edit distances, alignment scores, etc 🦖
https://ashvardanian.com/posts/stringzilla/
Apache License 2.0
2.15k stars 73 forks source link

Add benchmarks for bulk-replace operations against Boost or STL #81

Open ashvardanian opened 8 months ago

ashvardanian commented 8 months ago

The C++ class implements a replace_all operation, that can be used to replace all occurrences of a substring or a character with a different string. The implementation is designed to minimize memory allocations and should be faster than boost::algorithm::replace_all in Boost and Python's str.replace. That intuition should be supported by evidence, so new benchmarks should be added.