Home | History | Annotate | Download | only in crosstest

Lines Matching refs:length

3  * (fixed length buffers, variable length buffers, etc.)
16 * Reset buf to the sequence of bytes: n, n+1, n+2 ... length - 1
19 reset_buf(uint8_t *buf, uint8_t init, SizeT length) {
22 for (i = 0; i < length; ++i)
31 fletcher_checksum(uint8_t *buf, SizeT length) {
36 for (i = 0; i < length; ++i) {
43 int memcpy_test(uint8_t *buf, uint8_t *buf2, uint8_t init, SizeT length) {
44 reset_buf(buf, init, length);
45 memcpy((void *)buf2, (void *)buf, length);
46 return fletcher_checksum(buf2, length);
49 int memmove_test(uint8_t *buf, uint8_t *buf2, uint8_t init, SizeT length) {
53 if (length <= overlap_bytes)
56 SizeT reduced_length = length - overlap_bytes;
57 reset_buf(buf, init, length);
63 memmove((void *)buf2, (void *)buf, length);
64 sum2 = fletcher_checksum(buf2, length);
68 int memset_test(uint8_t *buf, uint8_t *buf2, uint8_t init, SizeT length) {
69 memset((void *)buf, init, length);
70 memset((void *)buf2, init + 4, length);
71 return fletcher_checksum(buf, length) + fletcher_checksum(buf2, length);