SIMD Implementation for Aho-Corasick on AArch64
The main purpose of this PR is to add a SIMD implementation for Teddy (a key data structure) on AArch64. Previously, Teddy utilized x86-64 SIMD instructions, specifically SSSE3 and AVX2.
This PR reorganizes Teddy’s main implementation into a new Vector trait and provides implementations of the Vector trait for both x86-64 and AArch64 vector types.
This significantly accelerates the speed of automatic pattern searching on AArch64 (i.e., on Apple’s new M1 and M2 chips).
Additionally, this PR replaces criterion with rebar for benchmarking and showcases a comparison of Aho-Corasick benchmarks before and after the changes. Overall, improvements range from 2 to 10 times in various aspects. For x86_64, there may be some minor latency improvements.
PR link: Aho-Corasick repository address: https://github.com/BurntSushi/aho-corasick
Nushell + Uutils = ❤️
The Nushell team announced the integration of uutils/coreutils into Nushell in the upcoming version 0.85.0, scheduled for release on September 19, 2023. The first command to be integrated is cp, which is located in ucp during testing. Therefore, when you use ucp in this version, you are actually using the same code as that in coreutils.
The Nushell team believes that there is no need to reinvent the wheel. Keeping Nushell’s features, parsing parameters, providing good command completion, and offering aesthetically pleasing help and error messages while integrating crates from top developers is a better approach.
Thus, the Nushell team collaborated with the Uutils team to discuss their goals and implement them.
From this collaboration, we can draw the following insights:
- Both projects benefit from the collaboration between the Nushell and Uutils teams. This partnership sets a great example for the open-source community.
- Not reinventing the wheel: The authors’ decision highlights a core principle of the open-source community, which is that there is no need to reinvent what already exists. By integrating existing solutions, we can provide value to users more quickly.
Nushell repository address: https://github.com/nushell/nushell
Uutils/coreutils repository address: https://github.com/uutils/coreutils
Reflections on Rust’s Core Principle of “Stability Without Stagnation”
One of Rust’s core principles is: “Stability without stagnation.” Rust adopts a “release train” model, releasing a new version every six weeks. This model makes the release of new versions smooth rather than feature-based.
Niko observed that despite this release model, stabilizing a feature in Rust can still be a stressful process. The blog further explores why this is the case and how we can adjust our processes and habits to address this issue.
Niko summarizes his main points in the article:
- The stabilization design of Rust is a source of stress because it conflates two different things: whether a feature works as intended (semver-stability) and whether a feature is ready for all expected use cases (recommended-for-use).
- Open-source work is incremental: To achieve the completeness we desire, we need users to encounter the feature; incremental milestones help us achieve this.
- Nightly versions are effective for obtaining certain types of feedback, but not all; especially production users and library authors typically do not use it. This leaves us with less data available for making high-risk decisions, which is a problem.
- We should modify our processes to distinguish four stages: Accepted RFC, Preview, Stable, and Recommended.
Original link: https://smallcultfollowing.com/babysteps/blog/2023/09/18/stability-without-stressing-the-out/
— From the Daily Report Team RustPlumber
Community Learning and Exchange Platform Subscription:
- Rust.cc Forum: Supports RSS
- WeChat Official Account: Rust Language Chinese Community