External API for System Stress Testing (ESST)
This section provides documentation for the external functions available in the ESST (Extreme System Stress Testing) library. These functions allow for programmatic initiation and control of various system stress tests, offering flexibility for integration into automated testing environments or custom benchmarking tools.
sha256
Executes SHA256 hash computations for a specified number of iterations, stressing the CPU's cryptographic capabilities.
long
iterations
: The number of SHA256 computations to perform.initGPU
Initializes and executes the full suite of GPU stress tests, including memory, computational, and atomic operation tests. This is the primary entry point for triggering a comprehensive GPU stress evaluation.
int
iterations
: Specifies the number of iterations each GPU stress test kernel will run.p3np1E
Performs computations related to the 3n+1 problem (Collatz conjecture) for a given starting number, stressing integer arithmetic and branching.
unsigned long
a
: The starting number for the 3n+1 computation.unsigned long *
steps
: A pointer to an unsigned long where the number of steps taken will be stored.primes
Calculates prime numbers up to a given limit, stressing integer arithmetic and basic logic.
unsigned long
a
: The upper limit for prime number calculation.unsigned long *
steps
: A pointer to an unsigned long where the number of operations or primes found will be stored.avx
Performs AVX (Advanced Vector Extensions) operations on floating-point arrays, stressing SIMD (Single Instruction, Multiple Data) capabilities.
float *
a
: Pointer to the first input float array.float *
b
: Pointer to the second input float array.float *
c
: Pointer to the third input float array.floodL1L2
Floods and stresses the CPU's L1 and L2 caches by performing rapid memory accesses within a specified buffer.
void*
buffer
: A pointer to the memory buffer to be used for cache flooding.unsigned long *
iterations_ptr
: A pointer to an unsigned long that controls the number of iterations and stores the actual iterations performed.size_t
buffer1_size
: The size of the buffer in bytes.floodMemory
Continuously accesses a large memory buffer to stress the system's main memory (RAM) bandwidth and latency.
void*
buffer
: A pointer to the memory buffer to be flooded.unsigned long *
iterations_ptr
: A pointer to an unsigned long that controls the number of iterations and stores the actual iterations performed.size_t
buffer_size
: The size of the buffer in bytes.rowhammerAttack
Attempts to trigger the Rowhammer vulnerability by repeatedly accessing specific memory rows.
void*
buffer
: A pointer to the memory buffer to be used for the attack.unsigned long *
iterations_ptr
: A pointer to an unsigned long that controls the number of iterations and stores the actual iterations performed.size_t
buffer_size
: The size of the buffer in bytes.floodNt
Likely a memory flooding routine targeting NT (Non-Temporal) memory accesses, aiming to bypass caches and stress memory controllers directly.
void *
buffer
: A pointer to the memory buffer for non-temporal access.unsigned long *
iterations_ptr
: A pointer to an unsigned long that controls the number of iterations and stores the actual iterations performed.size_t
buffer_size
: The size of the buffer in bytes.aes128EncryptBlock
Encrypts a single 128-bit block using AES-128 encryption.
void *
out
: Pointer to the output buffer for the encrypted block.const void *
in
: Pointer to the input buffer containing the 128-bit plaintext block.const void *
key
: Pointer to the 128-bit AES key.aes256Keygen
Generates an expanded key for AES-256 encryption/decryption from a 256-bit initial key.
void*
expanded_key
: Pointer to the buffer where the generated expanded key will be stored.aesXtsEncrypt
Encrypts multiple blocks using AES XTS (XEX-based tweaked-codebook mode with ciphertext stealing) mode.
void *
out
: Pointer to the output buffer for encrypted data.const void *
in
: Pointer to the input buffer containing plaintext data.const void*
key
: Pointer to the AES key.const void *
tweak
: Pointer to the tweak value for XTS mode.size_t
blocks
: The number of 128-bit blocks to encrypt.aes128DecryptBlock
Decrypts a single 128-bit block using AES-128 decryption.
void *
out
: Pointer to the output buffer for the decrypted block.const void *
in
: Pointer to the input buffer containing the 128-bit ciphertext block.const void *
key
: Pointer to the 128-bit AES key.aesXtsDecrypt
Decrypts multiple blocks using AES XTS (XEX-based tweaked-codebook mode with ciphertext stealing) mode.
void *
out
: Pointer to the output buffer for decrypted data.const void *
in
: Pointer to the input buffer containing ciphertext data.const void*
key
: Pointer to the AES key.const void *
tweak
: Pointer to the tweak value for XTS mode.size_t
blocks
: The number of 128-bit blocks to decrypt.diskWrite
Performs write operations to a specified disk file, designed to stress storage I/O performance.
const char *
name
: A C-style string specifying the name or path of the file to write to.This library function is typically called from an external C++ or C application after linking against the compiled ESST library. Ensure your environment is correctly set up for the respective operations (e.g., HIP/CUDA for GPU functions, appropriate libraries for AES, etc.) if you intend to integrate this into your own projects.