22 std::vector<std::byte> key(32, {});
25 std::vector<std::byte> in(buffersize, {});
26 std::vector<std::byte>
out(buffersize, {});
34 std::vector<std::byte> key(32);
36 std::vector<std::byte> in(buffersize);
37 std::vector<std::byte> aad;
static const uint64_t BUFFER_SIZE_LARGE
BENCHMARK(CHACHA20_64BYTES, benchmark::PriorityLevel::HIGH)
static void FSCHACHA20POLY1305(benchmark::Bench &bench, size_t buffersize)
static void CHACHA20_256BYTES(benchmark::Bench &bench)
static void CHACHA20(benchmark::Bench &bench, size_t buffersize)
static const uint64_t BUFFER_SIZE_TINY
static void CHACHA20_1MB(benchmark::Bench &bench)
static void CHACHA20_64BYTES(benchmark::Bench &bench)
static void FSCHACHA20POLY1305_64BYTES(benchmark::Bench &bench)
static const uint64_t BUFFER_SIZE_SMALL
static void FSCHACHA20POLY1305_1MB(benchmark::Bench &bench)
static void FSCHACHA20POLY1305_256BYTES(benchmark::Bench &bench)
Unrestricted ChaCha20 cipher.
Forward-secure wrapper around AEADChaCha20Poly1305.
static constexpr auto EXPANSION
Expansion when encrypting.
void Encrypt(Span< const std::byte > plain, Span< const std::byte > aad, Span< std::byte > cipher) noexcept
Encrypt a message with a specified aad.
Main entry point to nanobench's benchmarking facility.
Bench & run(char const *benchmarkName, Op &&op)
Repeatedly calls op() based on the configuration, and performs measurements.
Bench & batch(T b) noexcept
Sets the batch size.
Bench & unit(char const *unit)
Sets the operation unit.