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

faster crc32 of last <8 bytes on aarch64 #9

Merged
merged 2 commits into from
Mar 18, 2018
Merged

faster crc32 of last <8 bytes on aarch64 #9

merged 2 commits into from
Mar 18, 2018

Conversation

landfillbaby
Copy link

instead of up to 7 individual bytes, process it as a word, a halfword, and a byte, and don't bother modifying the length counter

crc32.c Outdated
crc = __crc32h(crc, *buf);
buf += 2;
}
if (len & 1)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I prefer a curly brace even on single line if :)

crc32.c Outdated
crc = __crc32b(crc, *buf);
len--;
buf++;
if (len & 4) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I now see that I used > in the loop, do you mind changing that to >= while you are at it?

@vkrasnov vkrasnov merged commit 9465261 into cloudflare:gcc.amd64 Mar 18, 2018
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.

2 participants