diff options
author | Paul Duncan <pabs@pablotron.org> | 2024-05-03 22:20:56 -0400 |
---|---|---|
committer | Paul Duncan <pabs@pablotron.org> | 2024-05-03 22:20:56 -0400 |
commit | 1a6d29a92333b2b0ab0e1bd363fb0243e2c030f0 (patch) | |
tree | e71bdae02f3bd5814482946846fba542d93f8bfc /examples/05-python/README.md | |
parent | 8b2d0fef4e9c264f6ec0a6cc122c3e242ffbfd09 (diff) | |
download | sha3-1a6d29a92333b2b0ab0e1bd363fb0243e2c030f0.tar.bz2 sha3-1a6d29a92333b2b0ab0e1bd363fb0243e2c030f0.zip |
sha3.c: refactor backends so they only implement permute_n()
i verified that (gcc, at least) does constant propagation and inlines
permute_n_<backend> and that this change does not affect performance.
bench results, before:
pabs@flex:~/git/sha3/tests/bench> ./bench
info: cpucycles: version=20240318 implementation=amd64-pmc persecond=4800000000
info: backend=avx512 num_trials=100000 src_lens=64,256,1024,4096,16384 dst_lens=32
function,dst_len,64,256,1024,4096,16384
sha3_224,28,15.4,7.8,7.8,7.1,7.0
sha3_256,32,15.5,7.8,7.8,7.6,7.4
sha3_384,48,15.5,11.7,9.8,9.8,9.7
sha3_512,64,15.6,15.5,14.6,13.9,13.9
shake128,32,15.5,7.8,6.9,6.2,6.1
shake256,32,15.5,7.8,7.9,7.6,7.4
bench results, after change:
pabs@flex:~/git/sha3/tests/bench> ./bench
info: cpucycles: version=20240318 implementation=amd64-pmc persecond=4800000000
info: backend=avx512 num_trials=100000 src_lens=64,256,1024,4096,16384 dst_lens=32
function,dst_len,64,256,1024,4096,16384
sha3_224,28,15.4,7.8,7.8,7.1,7.0
sha3_256,32,15.6,7.8,7.8,7.6,7.4
sha3_384,48,15.6,11.7,9.8,9.8,9.7
sha3_512,64,15.6,15.5,14.6,13.8,13.8
shake128,32,15.6,7.9,6.9,6.2,6.1
shake256,32,15.7,7.9,7.9,7.6,7.4
Diffstat (limited to 'examples/05-python/README.md')
0 files changed, 0 insertions, 0 deletions