You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit adds the missing sections regarding ACVP testing and benchmarking
to the README.
With that addition we meet the standards set by the PQCP.
Fixes#1289
Signed-off-by: Matthias J. Kannwischer <matthias@kannwischer.eu>
Copy file name to clipboardExpand all lines: README.md
+44Lines changed: 44 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -96,6 +96,49 @@ Our AArch64 assembly is developed using the [SLOTHY](https://github.com/slothy-o
96
96
We write 'clean' assembly by hand and automate micro-optimizations (e.g. see the [clean](dev/aarch64_clean/src/ntt.S) vs [optimized](dev/aarch64_opt/src/ntt.S) AArch64 NTT).
97
97
See [dev/README.md](dev/README.md) for more details.
98
98
99
+
## ACVP Testing
100
+
101
+
mlkem-native is tested against all official ACVP ML-KEM test vectors[^ACVP].
102
+
103
+
You can run ACVP tests using the [`tests`](./scripts/tests) script or the [ACVP client](./test/acvp_client.py) directly:
104
+
105
+
```bash
106
+
# Using the tests script
107
+
./scripts/tests acvp
108
+
# Using a specific ACVP release
109
+
./scripts/tests acvp --version v1.1.0.40
110
+
111
+
# Using the ACVP client directly
112
+
python3 ./test/acvp_client.py
113
+
python3 ./test/acvp_client.py --version v1.1.0.40
114
+
115
+
# Using specific ACVP test vector files (downloaded from the ACVP-Server)
You can measure performance, memory usage, and binary size using the [`tests`](./scripts/tests) script:
126
+
127
+
```bash
128
+
# Speed benchmarks (-c selects cycle counter: NO, PMU, PERF, or MAC)
129
+
# Note: PERF/MAC may require the -r flag to run benchmarking binaries using sudo
130
+
./scripts/tests bench -c PMU
131
+
./scripts/tests bench -c PERF -r
132
+
133
+
# Stack usage analysis
134
+
./scripts/tests stack
135
+
136
+
# Binary size measurement
137
+
./scripts/tests size
138
+
```
139
+
140
+
For CI benchmark results and historical performance data, see the [benchmarking page](https://pq-code-package.github.io/mlkem-native/dev/bench/).
141
+
99
142
## Usage
100
143
101
144
If you want to use mlkem-native, import [mlkem](mlkem) into your project's source tree and build using your favourite build system. See [mlkem](mlkem) for more information, and
@@ -143,6 +186,7 @@ If you want to help us build mlkem-native, please reach out. You can contact the
143
186
through the [PQCA Discord](https://discord.com/invite/xyVnwzfg5R). See also [CONTRIBUTING.md](CONTRIBUTING.md).
144
187
145
188
<!--- bibliography --->
189
+
[^ACVP]: National Institute of Standards and Technology: Automated Cryptographic Validation Protocol (ACVP) Server, [https://github.com/usnistgov/ACVP-Server](https://github.com/usnistgov/ACVP-Server)
146
190
[^FIPS202]: National Institute of Standards and Technology: FIPS202 SHA-3 Standard: Permutation-Based Hash and Extendable-Output Functions, [https://csrc.nist.gov/pubs/fips/202/final](https://csrc.nist.gov/pubs/fips/202/final)
147
191
[^FIPS203]: National Institute of Standards and Technology: FIPS 203 Module-Lattice-Based Key-Encapsulation Mechanism Standard, [https://csrc.nist.gov/pubs/fips/203/final](https://csrc.nist.gov/pubs/fips/203/final)
148
192
[^HYBRID]: Becker, Kannwischer: Hybrid scalar/vector implementations of Keccak and SPHINCS+ on AArch64, [https://eprint.iacr.org/2022/1243](https://eprint.iacr.org/2022/1243)
0 commit comments