Optimize performance for non-amd64 architectures #3

Open
opened 2025-12-28 18:13:28 +00:00 by sami · 0 comments
Owner

Originally created by @fyrchik on GitHub (Jun 28, 2021).

Currently we have optimized versions only for AVX/AVX2-enabled architectures. While pure Go implementation also exists, we might want to optimize implementation for ARM or RISC-V architectures. Note that reference implementation from https://github.com/srijs/hwsl2-core deliberately implements only AVX* optimisations, so we must craft ARM/RISC-V code ourselves.

The first step is to optimize GF127 code (with our modulo) in isolation.
Comparing assembly output for pure Go and C version might be helpful.

Some links to study:
https://www.ssrc.ucsc.edu/Papers/greenan-mascots08.pdf

RISC-V has crypto-extensions as well, some of them might be useful:
https://riscv.org/wp-content/uploads/2017/12/Wed-1354-RISCV-CryptoExtensions-RichardNewell.pdf

Originally created by @fyrchik on GitHub (Jun 28, 2021). Currently we have optimized versions only for AVX/AVX2-enabled architectures. While pure Go implementation also exists, we might want to optimize implementation for ARM or RISC-V architectures. Note that reference implementation from https://github.com/srijs/hwsl2-core deliberately implements only AVX* optimisations, so we must craft ARM/RISC-V code ourselves. The first step is to optimize GF127 code (with our modulo) in isolation. Comparing assembly output for pure Go and C version might be helpful. Some links to study: https://www.ssrc.ucsc.edu/Papers/greenan-mascots08.pdf RISC-V has crypto-extensions as well, some of them might be useful: https://riscv.org/wp-content/uploads/2017/12/Wed-1354-RISCV-CryptoExtensions-RichardNewell.pdf
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
nspcc-dev/tzhash#3
No description provided.