Switch Lotus formats to bitslice implementation
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 13.6k
- Forks
- 2.6k
- PR merge metrics
- No merged PRs in 30d
Description
Sovyn Y. has just generated the corresponding S-box expressions, which we should make use of. The gate counts are large (because the S-boxes are large), but going from 8-bit to 512-bit I expect good speedup anyway. Scalar 32- and 64-bit and maybe even 128-bit SIMD could still be faster with the current explicit 8-bit lookups - so we could potentially need to keep the old code as well? - but we should implement and benchmark first.
The affected files are:
src/DOMINOSEC8_fmt_plug.c
src/DOMINOSEC_fmt_plug.c
src/lotus5_fmt_plug.c
src/lotus85_fmt_plug.c
run/opencl/lotus5_kernel.cl
I set this to the "definitely" milestone because it'd be a pity not to make use of the already started work, but I'm actually not sure we'll take care of all 5 above.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the five affected files: the four C format plug-ins and run/opencl/lotus5_kernel.cl, then locate the existing Lotus S-box implementations and the generated bitslice expressions. Implement and benchmark the bitslice versions across the listed formats, comparing them with the current explicit 8-bit lookups to determine whether both implementations are needed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- cryptography, performance
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100