Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't pass around references to the scrach buffer #90

Merged
merged 1 commit into from
Jan 15, 2024

Conversation

brantburnett
Copy link
Owner

Motivation

The scratch buffer is primarily used on cold paths (split reads during streaming or handling the last few tags in a block). Therefore, the value in reducing range checks, etc, by passing the reference around is minimal. This is mostly a holdover from when we pinned the reference, which was more important due to pinning cost.

Modifications

Stop passing the reference to the subroutines, just make a reference as needed.

Motivation
----------
The scratch buffer is primarily used on cold paths (split reads during
streaming or handling the last few tags in a block). Therefore, the
value in reducing range checks, etc, by passing the reference around is
minimal. This is mostly a holdover from when we pinned the reference,
which was more important due to pinning cost.

Modifications
-------------
Stop passing the reference to the subroutines, just make a reference as
needed.
@brantburnett brantburnett merged commit e4eb986 into main Jan 15, 2024
30 checks passed
@brantburnett brantburnett deleted the no-scratch-ref branch January 15, 2024 04:13
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