Decision Workspace
subslice vs twoway vs memchr
Side-by-side comparison of Rust crates
44
subslice
growingv0.2.3
Fast subslice search
54
twoway
growingv0.2.2
(Deprecated - use crate memchr instead.) Fast substring search for strings and byte strings. Optional SSE4.2 acceleration (if detected at runtime) using pcmpestri. Memchr is the only mandatory dependency. The two way algorithm is also used by rust's libstd itself, but here it is exposed both for byte strings, using memchr, and optionally using a SSE4.2 accelerated version.
72
memchr
stablev2.8.0
Provides extremely fast (uses SIMD on x86_64, aarch64 and wasm32) routines for 1, 2 or 3 byte search and single substring search.
Core Metrics
| subslice | twoway | memchr | |
|---|---|---|---|
| Health Score | 44 | 54 | 72 |
| Total Downloads | 434.2K | 23.2M | 842.6M |
| 30d Downloads | 13.0K | 659.8K | 58.6M |
| Dependents | 99 | 674 | 17.1K |
| Releases | 5 | 12 | 44 |
| Last Updated | 1719d ago | 1773d ago | 49d ago |
| Age | 7y 8m | 10y 3m | 10y 9m |
Health Breakdown
subslice
Maintenance
3
Quality
15
Community
11
Popularity
7
Documentation
8
twoway
Maintenance
5
Quality
16
Community
14
Popularity
8
Documentation
11
memchr
Maintenance
15
Quality
22
Community
12
Popularity
8
Documentation
15
Technical Details
| subslice | twoway | memchr | |
|---|---|---|---|
| Version | 0.2.3 | 0.2.2 | 2.8.0 |
| Stable (≥1.0) | ✗ No | ✗ No | ✓ Yes |
| License | MIT/Apache-2.0 | MIT/Apache-2.0 | Unlicense OR MIT |
| Dependencies | 10 | 10 | 3 |
| Crate Size | 26KB | 30KB | 98KB |
| Features | 4 | 5 | 7 |
| Yanked % | 0.0% | 0.0% | 2.3% |
| Edition | — | — | 2021 |
| MSRV | — | — | 1.61 |
| Owners | 1 | 1 | 1 |
Links
Quick Verdict
- •memchr leads with a health score of 72/100, but none of the options score above 80.
- •memchr is depended on by 17.1K crates — strongest ecosystem trust.
- •⚠ subslice, twoway have not been updated in over a year.
- •subslice, twoway are pre-1.0 — API may change.