-
Notifications
You must be signed in to change notification settings - Fork 836
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
RISC-V 64: Add assembly code for SHA-512 #7833
Conversation
9043e5f
to
0761a18
Compare
I've rebased and force pushed to resolve the GitHub CI issues. Testing results:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SHA2-512 is 42% faster. Nice work! SHA2-256 is basically the same.
ed32ec7
to
05a5dd2
Compare
Cleanup RISC-V 64 SHA-256 by removing unused rev_idx.
05a5dd2
to
4062b94
Compare
Changed loading of W which should have improved things slightly. |
Latest benchmarks for SHA2-512 are about 1% faster:
I'll approve and merge. Thank you |
Description
Implementation of SHA-512 using RISC-V 64 instructions.
Cleanup RISC-V 64 SHA-256 by removing unused rev_idx.
Testing
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zbb'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zbb,zbkb'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zkn,zbb'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zkn,zbb,zbkb'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zvbb'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zvbb,zbb'
./configure '--disable-shared' '--enable-sha384' '--enable-sha512' 'LDFLAGS=--static' '--host=riscv64' 'CC=riscv64-linux-gnu-gcc' '--enable-riscv-asm=zvkned,zvbb'
Checklist