This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig standard library. Private Constant
cipher_suites
Private Constant
std.crypto.tls.Client.cipher_suites
constcipher_suites = if (crypto.core.aes.has_hardware_support)
array(u16, tls.CipherSuite, .
The priority order here is chosen based on what crypto algorithms Zig has available in the standard library as well as what is faster. Following are a few data points on the relative performance of these algorithms.
Measurement taken with 0.11.0-dev.810+c2f5848fe on x86_64-linux Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz: zig run .lib/std/crypto/benchmark.zig -OReleaseFast aegis-128l: 15382 MiB/s aegis-256: 9553 MiB/s aes128-gcm: 3721 MiB/s aes256-gcm: 3010 MiB/s chacha20Poly1305: 597 MiB/s
Measurement taken with 0.11.0-dev.810+c2f5848fe on x86_64-linux Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz: zig run .lib/std/crypto/benchmark.zig -OReleaseFast -mcpu=baseline aegis-128l: 629 MiB/s chacha20Poly1305: 529 MiB/s aegis-256: 461 MiB/s aes128-gcm: 138 MiB/s aes256-gcm: 120 MiB/s
The priority order here is chosen based on what crypto algorithms Zig has available in the standard library as well as what is faster. Following are a few data points on the relative performance of these algorithms.
Measurement taken with 0.11.0-dev.810+c2f5848fe on x86_64-linux Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz: zig run .lib/std/crypto/benchmark.zig -OReleaseFast aegis-128l: 15382 MiB/s aegis-256: 9553 MiB/s aes128-gcm: 3721 MiB/s aes256-gcm: 3010 MiB/s chacha20Poly1305: 597 MiB/s
Measurement taken with 0.11.0-dev.810+c2f5848fe on x86_64-linux Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz: zig run .lib/std/crypto/benchmark.zig -OReleaseFast -mcpu=baseline aegis-128l: 629 MiB/s chacha20Poly1305: 529 MiB/s aegis-256: 461 MiB/s aes128-gcm: 138 MiB/s aes256-gcm: 120 MiB/s