diff options
author | Jean-Philippe Aumasson <jeanphilippe.aumasson@gmail.com> | 2019-09-13 20:40:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-13 20:40:30 +0200 |
commit | 1512ba4576e6167196d8d14cad898e563af3f83b (patch) | |
tree | 341fa5f8d011756778a1932c0325b958ada0041f /README.md | |
parent | Merge pull request #13 from altendky/use_UINTxx_C_macros (diff) | |
parent | Make *c* and *d* rounds less intrusively configurable (diff) | |
download | siphash-1512ba4576e6167196d8d14cad898e563af3f83b.tar.gz siphash-1512ba4576e6167196d8d14cad898e563af3f83b.tar.xz |
Merge pull request #15 from altendky/makefile_rounds_parameters
Make *c* and *d* rounds less intrusively configurable
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 17 |
1 files changed, 12 insertions, 5 deletions
@@ -42,13 +42,20 @@ verifies 64 test vectors, and does the same and prints intermediate values. The code can be adapted to implement SipHash-*c*-*d*, the version of SipHash -with *c* compression rounds and *d* finalization rounds, by tweaking the -lines -```C -#define cROUNDS 2 -#define dROUNDS 4 +with *c* compression rounds and *d* finalization rounds, by defining `cROUNDS` +or `dROUNDS` when compiling. This can be done with `-D` command line arguments +to many compilers such as below. + +```sh +gcc -Wall --std=c99 -DcROUNDS=2 -DdROUNDS=4 siphash.c halfsiphash.c test.c -o test ``` +The `makefile` also takes *c* and *d* rounds values as parameters. + +```sh +make cROUNDS=2 dROUNDS=4 +``` + Obviously, if the number of rounds is modified then the test vectors won't verify. |