iPXE
|
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <ipxe/test.h>
#include <ipxe/profile.h>
Go to the source code of this file.
Macros | |
#define | PROFILE_COUNT 16 |
Number of sample iterations for profiling. More... | |
#define | MEMCPY_TEST_CONSTANT(...) |
Perform a constant-length memcpy() test. More... | |
Functions | |
FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
void | memcpy_0 (void *dest, void *src) |
void | memcpy_1 (void *dest, void *src) |
void | memcpy_2 (void *dest, void *src) |
void | memcpy_3 (void *dest, void *src) |
void | memcpy_4 (void *dest, void *src) |
void | memcpy_5 (void *dest, void *src) |
void | memcpy_6 (void *dest, void *src) |
void | memcpy_7 (void *dest, void *src) |
void | memcpy_8 (void *dest, void *src) |
void | memcpy_9 (void *dest, void *src) |
void | memcpy_10 (void *dest, void *src) |
void | memcpy_11 (void *dest, void *src) |
void | memcpy_12 (void *dest, void *src) |
void | memcpy_13 (void *dest, void *src) |
void | memcpy_14 (void *dest, void *src) |
void | memcpy_15 (void *dest, void *src) |
void | memcpy_16 (void *dest, void *src) |
void | memcpy_17 (void *dest, void *src) |
void | memcpy_18 (void *dest, void *src) |
void | memcpy_19 (void *dest, void *src) |
void | memcpy_20 (void *dest, void *src) |
void | memcpy_21 (void *dest, void *src) |
void | memcpy_22 (void *dest, void *src) |
void | memcpy_23 (void *dest, void *src) |
void | memcpy_24 (void *dest, void *src) |
void | memcpy_25 (void *dest, void *src) |
void | memcpy_26 (void *dest, void *src) |
void | memcpy_27 (void *dest, void *src) |
void | memcpy_28 (void *dest, void *src) |
void | memcpy_29 (void *dest, void *src) |
void | memcpy_30 (void *dest, void *src) |
void | memcpy_31 (void *dest, void *src) |
void * | memcpy_var (void *dest, const void *src, size_t len) |
Force a call to the variable-length implementation of memcpy() More... | |
static void | memcpy_test_speed (unsigned int dest_offset, unsigned int src_offset, size_t len) |
Test memcpy() speed. More... | |
static void | memcpy_test_exec (void) |
Perform memcpy() self-tests. More... | |
Variables | |
struct self_test memcpy_test | __self_test |
memcpy() self-test More... | |
memcpy() self-tests
Definition in file memcpy_test.c.
#define PROFILE_COUNT 16 |
Number of sample iterations for profiling.
Definition at line 42 of file memcpy_test.c.
#define MEMCPY_TEST_CONSTANT | ( | ... | ) |
Perform a constant-length memcpy() test.
... Data to copy
Definition at line 97 of file memcpy_test.c.
FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
void memcpy_0 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 46 of file memcpy_test.c.
void memcpy_1 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 47 of file memcpy_test.c.
void memcpy_2 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 48 of file memcpy_test.c.
void memcpy_3 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 49 of file memcpy_test.c.
void memcpy_4 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 50 of file memcpy_test.c.
void memcpy_5 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 51 of file memcpy_test.c.
void memcpy_6 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 52 of file memcpy_test.c.
void memcpy_7 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 53 of file memcpy_test.c.
void memcpy_8 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 54 of file memcpy_test.c.
void memcpy_9 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 55 of file memcpy_test.c.
void memcpy_10 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 56 of file memcpy_test.c.
void memcpy_11 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 57 of file memcpy_test.c.
void memcpy_12 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 58 of file memcpy_test.c.
void memcpy_13 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 59 of file memcpy_test.c.
void memcpy_14 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 60 of file memcpy_test.c.
void memcpy_15 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 61 of file memcpy_test.c.
void memcpy_16 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 62 of file memcpy_test.c.
void memcpy_17 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 63 of file memcpy_test.c.
void memcpy_18 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 64 of file memcpy_test.c.
void memcpy_19 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 65 of file memcpy_test.c.
void memcpy_20 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 66 of file memcpy_test.c.
void memcpy_21 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 67 of file memcpy_test.c.
void memcpy_22 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 68 of file memcpy_test.c.
void memcpy_23 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 69 of file memcpy_test.c.
void memcpy_24 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 70 of file memcpy_test.c.
void memcpy_25 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 71 of file memcpy_test.c.
void memcpy_26 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 72 of file memcpy_test.c.
void memcpy_27 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 73 of file memcpy_test.c.
void memcpy_28 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 74 of file memcpy_test.c.
void memcpy_29 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 75 of file memcpy_test.c.
void memcpy_30 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 76 of file memcpy_test.c.
void memcpy_31 | ( | void * | dest, |
void * | src | ||
) |
Definition at line 77 of file memcpy_test.c.
void* memcpy_var | ( | void * | dest, |
const void * | src, | ||
size_t | len | ||
) |
Force a call to the variable-length implementation of memcpy()
dest | Destination address |
src | Source address |
len | Length of data |
dest | Destination address |
Definition at line 87 of file memcpy_test.c.
|
static |
Test memcpy() speed.
dest_offset | Destination alignment offset |
src_offset | Source alignment offset |
len | Length of data to copy |
Definition at line 128 of file memcpy_test.c.
References assert(), DBG, dest, free, len, malloc(), memcmp(), memcpy(), memset(), NULL, ok, PROFILE_COUNT, profile_mean(), profile_start(), profile_stddev(), profile_stop(), random(), and src.
Referenced by memcpy_test_exec().
|
static |
Perform memcpy() self-tests.
Definition at line 171 of file memcpy_test.c.
References MEMCPY_TEST_CONSTANT, and memcpy_test_speed().
struct self_test memcpy_test __self_test |
memcpy() self-test
Definition at line 270 of file memcpy_test.c.