-
Notifications
You must be signed in to change notification settings - Fork 9.1k
HADOOP-19666. Add hardware-accelerated CRC32 support for riscv64 using the v,zbc,zvbc extension #7912
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
base: trunk
Are you sure you want to change the base?
Conversation
|
💔 -1 overall
This message was automatically generated. |
67c832e to
be2c9c5
Compare
|
💔 -1 overall
This message was automatically generated. |
|
@steveloughran @ayushtkn Hi, this PR has been open for a while. Could you please take a look when you have time? Thanks! |
|
It's been a long time since I did C code, I'll have to stare at this a while. In #7903 that creation of the file bulk_crc32_riscv.c should be what the new code goes into; work with @PeterPtroc to get something you are both happy with and tested. Having two people who are set up to build and test this on riscv hardware is exactly what we need to get this done |
This PR implements vector-accelerated CRC32 using the RISC-V V, Zbc and Zvbc
instruction sets, with full functional verification and performance testing completed.
The implementation uses the vclmul.v and vclmulh.v (carry-less multiply) instructions for data folding and computes the final checksum via Barrett reduction.
Key Features:
Runtime Hardware Detection
The PR uses kernel hardware probing and cpuinfo parsing to dynamically detect hardware support for CRC32 acceleration (via v, zbc, and zvbc extensions) at runtime.
Performance Improvement
Hardware-accelerated CRC32 achieves a performance boost of over 3X compared to the software implementation.
Description of PR
How was this patch tested?
For code changes:
LICENSE,LICENSE-binary,NOTICE-binaryfiles?