Debian Codegraph @

fiat-amd64/Readme.md

raw symbols SCIP
1 # Structure
2
3 This folder is structured as follows:
4
5 ## Meta
6 - `Readme.md` This file
7 - `gentest.py` Test generation script to create commands to formally verify the correctness of the assembly files.
8 - `test.sh` Helper script to manually call and run the tests. Uses `./gentest.py`.
9
10 ## Assembly files
11
12 All those assembly files have been generated by [CryptOpt](https://github.com/0xADE1A1DE/CryptOpt) on ten different CPUs.
13
14 The structure is `./fiat_<CURVE>_<METHOD>/seed<SEED>_ratio<RATIO>.asm`.
15 Every folder contains optimized and proven correct implementations of the respective function using the CryptOpt Framework.
16 The `<CURVE>` is one of Fiat Cryptography's main supported curves: `curve25519` `curve25519_solinas` `p224` `p256` `p384` `p434` `p448_solinas` `p521` `poly1305` `secp256k1_dettman` `secp256k1_montgomery`
17 The `<METHOD>` is one of the respective `multiply` or `square` (carry) if it is based on the solinas primes.
18
19 The `<SEED>` value is the seed that CryptOpt was called with to create this file, the `<RATIO>` is an indication of the measured performance during optimization.
20 Specifically, a `<RATIO>`-value of `abbbb` corresponds to a performance ratio of `a.bbbb`x compared to the assembly that `clang-15 -O3 -march=native -mtune=native` would have produces on the system.
21 Hence, the higher the value the faster the code.
22 Every `asm` file contains a footer comment with some metadata on which CPU it was produced.
23
24 All assembly files use the *Linux System-V ABI* and require the CPU flags `-adx` and `-bmi2` (Supported at least from Intel Cores since the 6th generation (Skylake), released in 2016).
25 The files are written using Intel assembly syntax.