Skip to content

Conversation

@dbaarda
Copy link
Member

@dbaarda dbaarda commented May 14, 2020

Use const local variables for the tmask and ktable to avoid dereferencing them from the hashtable with t->tmask and t->ktable repeatedly in the tight probing loop.

This doesn't make much difference when optimizing gcc with -O3, but it does with lower levels of optimizing, and is highly visible when profiling. So this will presumably help a fair bit on platforms that don't have highly optimizing compilers.

@dbaarda dbaarda merged commit 31a8fdf into librsync:master May 14, 2020
@dbaarda dbaarda deleted the opt/hashtable4 branch May 14, 2020 16:03
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