Skip to content

test(search): time a search beside its reference, three tries - #739

Merged
vyncint merged 1 commit into
mainfrom
test/0119-search-timing
Nov 10, 2026
Merged

vyncint merged 1 commit into
mainfrom
test/0119-search-timing

Conversation

@vyncint

@vyncint vyncint commented Nov 10, 2026

Copy link
Copy Markdown
Owner

The search-cost test flaked on a Windows stress shard at 16 threads (run 42836205989, iteration 18 of 25): find_all took 9.1 ms against a 0.89 ms reference, 10.2 times where the bound is 10. It timed the reference once and each search from two runs, so a scheduler that parked the search failed it.

Each search is now timed beside its reference (the fastest of three runs of each), and the pair is timed again, up to three times, before the bound is called broken. The regression the test exists for (#584) was hundreds of times, every time. A mutation check, find_all made 20 times slower, still fails it: 23 times, three times over.

Test-only, so no CHANGELOG entry.

every_search_costs_a_small_multiple_of_the_work_it_cannot_avoid timed
the reference once and each search from two runs, so a scheduler that
parked the search on a loaded runner failed it: a Windows stress shard
at 16 threads (run 42836205989, iteration 18 of 25) saw find_all at
9.1 ms against an 0.89 ms reference, 10.2 times where the bound is 10.

Each search is now timed beside its reference, the fastest of three
runs of each, and the pair is timed again, up to three times, before the
bound is called broken. The regression the test exists for (#584) was
hundreds of times, every time, and it still fails: with find_all made
20 times slower the test fails at 23 times, three times over.

Signed-off-by: Vyncint Ng <115854244+vyncint@users.noreply.github.com>
@vyncint
vyncint merged commit 4af5ebd into main Nov 10, 2026
16 checks passed
@vyncint
vyncint deleted the test/0119-search-timing branch November 10, 2026 23:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant