Repository navigation
perf(gpu): a heap's dynamic slots are bits, searched a word at a time - #467
Merged
pragyaangaur merged 1 commit intoNov 27, 2026
Merged
Conversation
The slots taken by lists not yet reset were one bool each, searched a slot at a time under the heap's lock by every fresh table. As bits they take an eighth of the memory, and the search reads whole words. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The dynamic-slot set of a view heap is one bit a slot instead of one byte, and
dynamiclooks for a free run a word at a time; its results, and whatreleaseclears, are unchanged. It matters only where many slots are taken at once; how manydynamicsearches run per frame, and how full the region gets, are unmeasured.dynamicsearch, 262,144-slot regionmodel)model)model)model)model)model)model)model, slower)counted from the code)counted from the code)Tested: Windows clippy x2 clean; new unit test
free_runs_are_found_across_wordsonly type-checked here (CI runs it, no GPU needed); old and new logic agree in a standalone model (113 M single searches on heaps of 1-200 slots, 1.2 M allocate/release ops with arbitrary releases), not run under CrossOver. Merges cleanly with the open PRs touching this file (#444, #404, #439, #409).🤖 Generated with Claude Code