/string/ |
A D | test-rawmemchr.c | 59 align &= 7; in do_test() 60 if (align + len >= page_size) in do_test() 67 buf1[align + i] = seek_char + 1; in do_test() 69 buf1[align + len] = 0; in do_test() 73 buf1[align + pos] = seek_char; in do_test() 74 buf1[align + len] = -seek_char; in do_test() 91 align = random () & 15; in do_random_tests() 93 if (pos + align >= 512) in do_random_tests() 96 if (len + align >= 512) in do_random_tests() 101 j = len + align + 64; in do_random_tests() [all …]
|
A D | test-memrchr.c | 58 align &= 7; in do_test() 59 if (align + len >= page_size) in do_test() 68 buf1[align + len] = 0; in do_test() 72 buf1[align + pos] = seek_char; in do_test() 79 buf1[align + len] = seek_char; in do_test() 89 size_t i, j, n, align, pos, len; in do_random_tests() local 96 align = random () & 15; in do_random_tests() 98 if (pos + align >= 512) in do_random_tests() 103 if (len + align >= 512) in do_random_tests() 106 j = len + align + 64; in do_random_tests() [all …]
|
A D | test-strrchr.c | 85 align &= 7; in do_test() 92 if (!buf[align + i]) in do_test() 94 if (!buf[align + i]) in do_test() 95 buf[align + i] = 1; in do_test() 99 buf[align + len] = 0; in do_test() 132 if (pos + align >= 511) in do_random_tests() 139 if (len + align >= 512) in do_random_tests() 149 j = len + align + 64; in do_random_tests() 155 if (i == pos + align) in do_random_tests() 157 else if (i == len + align) in do_random_tests() [all …]
|
A D | test-strchr.c | 131 align &= 127; in do_test() 139 buf[align + i] = seek_char + 1; in do_test() 141 buf[align + i] = 1; in do_test() 143 buf[align + len] = 0; in do_test() 148 result = buf + align + pos; in do_test() 151 result = buf + align + len; in do_test() 171 align = random () & 15; in do_random_tests() 174 if (pos + align >= 511) in do_random_tests() 182 if (len + align >= 512) in do_random_tests() 192 if (i == pos + align) in do_random_tests() [all …]
|
A D | test-strlen.c | 76 do_test (size_t align, size_t len) in do_test() argument 87 buf[align + i] = 1 + 11111 * i % MAX_CHAR; in do_test() 88 buf[align + len] = 0; in do_test() 97 size_t i, j, n, align, len; in do_random_tests() local 102 align = random () & 15; in do_random_tests() 104 if (len + align > 510) in do_random_tests() 105 len = 511 - align - (random () & 7); in do_random_tests() 106 j = len + align + 64; in do_random_tests() 112 if (i == len + align) in do_random_tests() 117 if (i >= align && i < len + align && !p[i]) in do_random_tests() [all …]
|
A D | test-memset.c | 140 align &= 4095; in do_test() 169 if (align > size) in do_random_tests() 170 align = size - len; in do_random_tests() 172 align &= ~63; in do_random_tests() 180 j = len + align + 128; in do_random_tests() 183 if (align >= 128) in do_random_tests() 184 k = align - 128; in do_random_tests() 196 p[i + align] = p2[i]; in do_random_tests() 198 p[i + align] = o; in do_random_tests() 201 if (res != p + align) in do_random_tests() [all …]
|
A D | test-memchr.c | 89 buf[align + i] = seek_char + 1; in do_test() 91 buf[align + len] = 0; in do_test() 95 buf[align + pos] = seek_char; in do_test() 96 buf[align + len] = -seek_char; in do_test() 102 buf[align + len] = seek_char; in do_test() 144 size_t i, j, n, align, pos, len; in do_random_tests() local 151 align = random () & 15; in do_random_tests() 153 if (pos + align >= 512) in do_random_tests() 158 if (len + align >= 512) in do_random_tests() 161 j = len + align + 64; in do_random_tests() [all …]
|
A D | test-strnlen.c | 77 align &= 63; in do_test() 85 buf[align + len] = 0; in do_test() 130 size_t i, j, n, align, len; in do_random_tests() local 135 align = random () & 15; in do_random_tests() 137 if (len + align > 510) in do_random_tests() 139 j = len + align + 64; in do_random_tests() 145 if (i == len + align) in do_random_tests() 150 if (i >= align && i < len + align && !p[i]) in do_random_tests() 161 n, impl->name, align, in do_random_tests() 168 n, impl->name, align, in do_random_tests() [all …]
|
A D | test-strspn.c | 111 align &= 7; in do_test() 116 s = (CHAR *) (buf1) + align; in do_test() 153 align = random () & 15; in do_random_tests() 162 if (pos + align >= 511) in do_random_tests() 163 pos = 510 - align - (random () & 7); in do_random_tests() 165 if (len + align >= 512) in do_random_tests() 166 len = 511 - align - (random () & 7); in do_random_tests() 183 if (i == len + align) in do_random_tests() 185 else if (i == pos + align) in do_random_tests() 191 else if (i < align || i > pos + align) in do_random_tests() [all …]
|
A D | test-strpbrk.c | 114 align &= 7; in do_test() 119 s = (CHAR *) (buf1) + align; in do_test() 160 size_t i, j, n, align, pos, len, rlen; in do_random_tests() local 168 align = random () & 15; in do_random_tests() 170 if (pos + align >= 511) in do_random_tests() 171 pos = 510 - align - (random () & 7); in do_random_tests() 175 if (len + align >= 512) in do_random_tests() 176 len = 511 - align - (random () & 7); in do_random_tests() 200 if (i == len + align) in do_random_tests() 202 else if (i == pos + align) in do_random_tests() [all …]
|
A D | tester.c | 725 long align, len, i, pos, n = 9; in test_memrchr() local 727 for (align = 0; align < (long) sizeof (long); ++align) { in test_memrchr() 730 buf[align + i] = 'x'; /* don't depend on memset... */ in test_memrchr() 734 printf("align %d, len %d, pos %d\n", align, len, pos); in test_memrchr() 736 check(memrchr(buf + align, 'x', len) == buf + align + pos, n++); in test_memrchr() 739 buf[align + pos] = '-'; in test_memrchr() 1144 long align, len, i, pos; in test_memchr() local 1146 for (align = 0; align < (long) sizeof (long); ++align) { in test_memchr() 1155 check(memchr(buf + align, 'x', len) == buf + align + pos, 10); in test_memchr() 1156 check(memchr(buf + align, 'x', pos) == NULL, 11); in test_memchr() [all …]
|