Skip to content
New issue

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

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

Already on GitHub? # to your account

lib/x86/crc32: target pclmul,sse4.1 instead of pclmul #397

Merged
merged 1 commit into from
Oct 26, 2024
Merged

Conversation

ebiggers
Copy link
Owner

In practice, all CPUs that support PCLMULQDQ also support SSE4.1:

Intel: Westmere and later + Silvermont and later
AMD: Bulldozer and later

Therefore, make crc32_x86_pclmulqdq() use SSE4.1 instructions.

To be safe, add an explicit check for SSE4.1 support. Though as per the above, this is unnecessary in practice (as far as I can tell).

In practice, all CPUs that support PCLMULQDQ also support SSE4.1:

    Intel: Westmere and later + Silvermont and later
    AMD: Bulldozer and later

Therefore, make crc32_x86_pclmulqdq() use SSE4.1 instructions.

To be safe, add an explicit check for SSE4.1 support.  Though as per the
above, this is unnecessary in practice (as far as I can tell).
@ebiggers ebiggers merged commit 677d924 into master Oct 26, 2024
25 checks passed
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant