|
| CHECKASM_API void | checkasm_randomize (void *buf, size_t bytes) |
| | Fill a buffer with uniformly chosen random bytes.
|
| |
| CHECKASM_API void | checkasm_randomize_mask8 (uint8_t *buf, int width, uint8_t mask) |
| | Fill a uint8_t buffer with random values chosen uniformly within a mask.
|
| |
| CHECKASM_API void | checkasm_randomize_mask16 (uint16_t *buf, int width, uint16_t mask) |
| | Fill a uint16_t buffer with random values chosen uniformly within a mask.
|
| |
| CHECKASM_API void | checkasm_randomize_range (double *buf, int width, double range) |
| | Fill a double buffer with random values chosen uniformly below a limit.
|
| |
| CHECKASM_API void | checkasm_randomize_rangef (float *buf, int width, float range) |
| | Fill a float buffer with random values chosen uniformly below a limit.
|
| |
| CHECKASM_API void | checkasm_randomize_interval (double *buf, int width, double low, double high) |
| | Fill a double buffer with random values chosen uniformly from an interval.
|
| |
| CHECKASM_API void | checkasm_randomize_intervalf (float *buf, int width, float low, float high) |
| | Fill a float buffer with random values chosen uniformly from an interval.
|
| |
| CHECKASM_API void | checkasm_randomize_dist (double *buf, int width, CheckasmDist dist) |
| | Fill a double buffer with normally distributed random values.
|
| |
| CHECKASM_API void | checkasm_randomize_distf (float *buf, int width, CheckasmDist dist) |
| | Fill a float buffer with normally distributed random values.
|
| |
| CHECKASM_API void | checkasm_randomize_norm (double *buf, int width) |
| | Fill a double buffer with values from a standard normal distribution.
|
| |
| CHECKASM_API void | checkasm_randomize_normf (float *buf, int width) |
| | Fill a float buffer with values from a standard normal distribution.
|
| |
| CHECKASM_API void | checkasm_clear (void *buf, size_t bytes) |
| | Clear a buffer to a pre-determined pattern (currently 0xAA)
|
| |
| CHECKASM_API void | checkasm_clear8 (uint8_t *buf, int width, uint8_t val) |
| | Fill a uint8_t buffer with a constant value.
|
| |
| CHECKASM_API void | checkasm_clear16 (uint16_t *buf, int width, uint16_t val) |
| | Fill a uint16_t buffer with a constant value.
|
| |
| CHECKASM_API void | checkasm_init (void *buf, size_t bytes) |
| | Initialize a buffer with pathological test patterns.
|
| |
| CHECKASM_API void | checkasm_init_mask8 (uint8_t *buf, int width, uint8_t mask) |
| | Initialize a uint8_t buffer with pathological values within a mask.
|
| |
| CHECKASM_API void | checkasm_init_mask16 (uint16_t *buf, int width, uint16_t mask) |
| | Initialize a uint16_t buffer with pathological values within a mask.
|
| |
Functions for filling buffers with various patterns of data.
A collection of functions to initialize memory buffers with random data, constant values, or pathological test patterns. These are useful for setting up input/output data buffers for checkasm tests.
| CHECKASM_API void checkasm_init |
( |
void * | buf, |
|
|
size_t | bytes ) |
Initialize a buffer with pathological test patterns.
Fills a buffer with a random mixture of edge cases, test patterns, and random data designed to trigger potential bugs. The exact pattern depends on the random seed and may include a mix of low values, high values, alternating bits, random bytes, and so on.
- Parameters
-
| [out] | buf | Buffer to initialize |
| [in] | bytes | Number of bytes to initialize |
Definition at line 431 of file utils.c.
Referenced by check_lut_3d().