mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 23:04:33 +00:00
e393f56d37
Refactor the code in the `convert_while_ascii` helper function to make it more suitable for auto-vectorization and also process the full ascii prefix of the string. The generic case conversion logic will only be invoked starting from the first non-ascii character. The runtime on microbenchmarks with ascii-only inputs improves between 1.5x for short and 4x for long inputs on x86_64 and aarch64. The new implementation also encapsulates all unsafe inside the `convert_while_ascii` function. Fixes #123712 |
||
---|---|---|
.. | ||
btree | ||
binary_heap.rs | ||
lib.rs | ||
linked_list.rs | ||
slice.rs | ||
str.rs | ||
string.rs | ||
vec_deque_append.rs | ||
vec_deque.rs | ||
vec.rs |