lotabout.skim/src
juneboku 29ca6f22bd
fix: preserve input order with --no-sort (#1115)
* fix: preserve input order with --no-sort

Workers grab 4096-item chunks from a shared queue, so the order in
which worker results are concatenated is nondeterministic. With
--no-sort the merged list was left in that arrival order, which
scrambles the display order once the item count exceeds
num_workers * chunk_size (~24k items on a 10-core machine) and makes
--filter output nondeterministic for large inputs.

Sort matched items by rank.index (the original input position) when
no_sort is set: each worker sorts its accumulator in prepare, and the
final merge exploits the k sorted runs, mirroring the sorted path.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* avoid extra sorts by exploiting the thread_pool stability

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: Loric ANDRE <loric.andre@pm.me>
2026-07-17 12:16:46 +00:00
..
bin feat!: feature-gate listen and image to allow opting out (#1103) 2026-06-29 15:35:50 +02:00
engine feat: bump frizbee to 0.10.0, thread local matcher (#1105) 2026-07-03 16:20:05 +00:00
fuzzy_matcher chore(deps): bump the cargo-prod group with 3 updates (#1109) 2026-07-16 10:01:35 +02:00
helper tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
popup tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
tui ci: fix fixed viewport resize test in non-interactive env (#1114) 2026-07-16 21:30:34 +00:00
binds.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
binds_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
field.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
field_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
item.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
item_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
lib.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
lib_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
manpage.rs feat!: feature-gate listen and image to allow opting out (#1103) 2026-06-29 15:35:50 +02:00
matcher.rs fix: preserve input order with --no-sort (#1115) 2026-07-17 12:16:46 +00:00
options.rs fix: unknown border values fallback to plain (closes #1107) 2026-07-09 13:58:59 +02:00
options_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
output.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
prelude.rs chore: format imports 2026-06-17 13:58:44 +02:00
reader.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
shell.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
shell_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
skim.rs feat!: feature-gate listen and image to allow opting out (#1103) 2026-06-29 15:35:50 +02:00
skim_item.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
skim_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
spinlock.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
theme.rs feat(theme): add a themeable scrollbar color for the item list (#1101) 2026-06-28 18:48:28 +02:00
theme_tests.rs feat(theme): add a themeable scrollbar color for the item list (#1101) 2026-06-28 18:48:28 +02:00
thread_pool.rs fix: preserve input order with --no-sort (#1115) 2026-07-17 12:16:46 +00:00
thread_pool_tests.rs fix: preserve input order with --no-sort (#1115) 2026-07-17 12:16:46 +00:00
util.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00
util_tests.rs tests: improve coverage to 90% (#1099) 2026-06-25 19:12:49 +00:00