-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Open
Labels
Description
Especially after #8031 (pending PR), number parsing is a significant component of sort -g
runtime (and possibly of other modes as well), maybe around ~70% of the runtime, as that part is single-threaded, while the sorting operation runs on multiple cores.
However, parallelizing chunks.rs
parse_lines
is challenging as there are side effects in line_data
and we still need the data to be in the correct order. This might required extensive refactoring. We should find a way to make it parallel without sacrificing single-thread performance (at least not too much).
Testing setup:
seq 100 -0.000258 0 | sort -R > tmp/floatdata
cargo build --profile profiling -p uu_sort && samply record -r 10000 target/profiling/sort -g tmp/floatdata > /dev/null