/string/ |
A D | test-memcpy-large.c | 46 size_t i, j; in test_main() local 59 for (j = 64; j <= 1024; j <<= 1) in test_main() 61 do_test1 (0, j, i); in test_main() 62 do_test1 (4095, j, i); in test_main() 63 do_test1 (4096 - j, 0, i); in test_main() 65 do_test1 (0, j - 1, i); in test_main() 66 do_test1 (4095, j - 1, i); in test_main() 69 do_test1 (0, j + 1, i); in test_main() 70 do_test1 (4095, j + 1, i); in test_main() 73 do_test1 (0, j, i + 1); in test_main() [all …]
|
A D | str-two-way.h | 139 j = 0; in critical_factorization() 148 j += k; in critical_factorization() 159 j += p; in critical_factorization() 174 j = 0; in critical_factorization() 183 j += k; in critical_factorization() 194 j += p; in critical_factorization() 246 j = 0; in two_way_short_needle() 292 j = 0; in two_way_short_needle() 316 ++j; in two_way_short_needle() 422 j = 0; in two_way_long_needle() [all …]
|
A D | test-memcpy.c | 82 j = align1 + len + 256; in do_random_tests() 83 if (j > size1) in do_random_tests() 84 j = size1; in do_random_tests() 85 for (i = 0; i < j; ++i) in do_random_tests() 91 if (j > size2) in do_random_tests() 92 j = size2; in do_random_tests() 93 memset (p2, c, j); in do_random_tests() 141 size_t i, j; in test_main() local 191 for (j = 1; j <= 1024; j <<= 1) in test_main() 193 do_test1 (0, j, i); in test_main() [all …]
|
A D | test-memccpy.c | 132 j = align1; in do_random_tests() 134 align2 = j; in do_random_tests() 151 j = align1; in do_random_tests() 152 if (align2 > j) in do_random_tests() 153 j = align2; in do_random_tests() 167 j = 512; in do_random_tests() 196 for (j = 0; j < align2 + 64; ++j) in do_random_tests() 209 for (; j < 512; ++j) in do_random_tests() 219 j = len + 1; in do_random_tests() 220 if (size < j) in do_random_tests() [all …]
|
A D | strfry.c | 42 int32_t j; in strfry() local 43 __random_r (&rdata, &j); in strfry() 44 j = j % (len - i) + i; in strfry() 47 string[i] = string[j]; in strfry() 48 string[j] = c; in strfry()
|
A D | test-strncpy.c | 216 j = align1; in do_random_tests() 235 j = align1; in do_random_tests() 237 j = align2; in do_random_tests() 251 j = 512; in do_random_tests() 276 for (j = 0; j < align2 + 64; ++j) in do_random_tests() 289 for (; j < 512; ++j) in do_random_tests() 299 for (j = align2 + len + 1; j < align2 + size; ++j) in do_random_tests() 300 if (p2[j]) in do_random_tests() 307 j = len + 1; in do_random_tests() 308 if (size < j) in do_random_tests() [all …]
|
A D | test-strncat.c | 146 for (j = 0; j < 200; ++j) in do_overflow_tests() 147 s2[j] = 32 + 23 * j % (BIG_CHAR - 32); in do_overflow_tests() 150 for (j = 0; j < i; ++j) in do_overflow_tests() 151 s1[j] = 32 + 23 * j % (BIG_CHAR - 32); in do_overflow_tests() 169 for (j = 8 * sizeof(size_t) - 1; j ; --j) in do_overflow_tests() 220 j = align1; in do_random_tests() 230 if (j > 0 && j < 512) in do_random_tests() 231 align1 += j; in do_random_tests() 235 j = 512; in do_random_tests() 270 for (j = 0; j < align2 + 64; ++j) in do_random_tests() [all …]
|
A D | test-strcpy.c | 144 j = align1; in do_random_tests() 145 if (align2 > j) in do_random_tests() 146 j = align2; in do_random_tests() 147 if (len + j >= 511) in do_random_tests() 149 j = len + align1 + 64; in do_random_tests() 150 if (j > 512) in do_random_tests() 151 j = 512; in do_random_tests() 152 for (i = 0; i < j; i++) in do_random_tests() 175 for (j = 0; j < align2 + 64; ++j) in do_random_tests() 185 for (j = align2 + len + 1; j < 512; ++j) in do_random_tests() [all …]
|
A D | test-strcat.c | 146 j = align1; in do_random_tests() 147 if (align2 + len2 > j) in do_random_tests() 148 j = align2 + len2; in do_random_tests() 149 if (len1 + j >= 511) in do_random_tests() 156 if (j > 0 && j < 512) in do_random_tests() 157 align1 += j; in do_random_tests() 160 if (j > 512) in do_random_tests() 161 j = 512; in do_random_tests() 195 for (j = 0; j < align2 + 64; ++j) in do_random_tests() 211 for (j = align2 + len1 + len2 + 1; j < 512; ++j) in do_random_tests() [all …]
|
A D | test-memchr.c | 112 size_t i, j, len; in do_overflow_tests() local 125 for (j = 8 * sizeof(size_t) - 1; j ; --j) in do_overflow_tests() 127 len |= one << j; in do_overflow_tests() 144 size_t i, j, n, align, pos, len; in do_random_tests() local 161 j = len + align + 64; in do_random_tests() 162 if (j > 512) in do_random_tests() 163 j = 512; in do_random_tests() 165 for (i = 0; i < j; i++) in do_random_tests() 202 size_t i, j; in test_main() local 235 for (j = 1; j < 64; j++) in test_main() [all …]
|
A D | test-strcspn.c | 69 size_t i, j; in STUPID_STRCSPN() local 72 for (j = 0; j < nrej; ++j) in STUPID_STRCSPN() 73 if (s[i] == rej[j]) in STUPID_STRCSPN()
|
A D | test-strcasecmp.c | 121 size_t i, j, n, align1, align2, pos, len1, len2; in do_random_tests() local 135 j = align1 > align2 ? align1 : align2; in do_random_tests() 136 if (pos + j >= 511) in do_random_tests() 137 pos = 510 - j - (random () & 7); in do_random_tests() 141 if (len1 + j >= 512) in do_random_tests() 142 len1 = 511 - j - (random () & 7); in do_random_tests() 146 len2 = len1 + (len1 != 511 - j ? random () % (511 - j - len1) : 0); in do_random_tests() 148 if (j > 512) in do_random_tests() 149 j = 512; in do_random_tests() 150 for (i = 0; i < j; ++i) in do_random_tests() [all …]
|
A D | test-strspn.c | 79 size_t i, j; in STUPID_STRSPN() local 83 for (j = 0; j < nacc; ++j) in STUPID_STRSPN() 84 if (s[i] == acc[j]) in STUPID_STRSPN() 86 if (j == nacc) in STUPID_STRSPN() 147 size_t i, j, n, align, pos, alen, len; in do_random_tests() local 177 j = (pos > len ? pos : len) + align + 64; in do_random_tests() 178 if (j > 512) in do_random_tests() 179 j = 512; in do_random_tests() 181 for (i = 0; i < j; i++) in do_random_tests()
|
A D | strcasestr.c | 39 #define AVAILABLE(h, h_l, j, n_l) \ argument 40 (((j) + (n_l) <= (h_l)) \ 42 (j) + (n_l) <= (h_l)))
|
A D | test-strnlen.c | 94 size_t i, j, len; in do_overflow_tests() local 107 for (j = 8 * sizeof(size_t) - 1; j ; --j) in do_overflow_tests() 109 len |= one << j; in do_overflow_tests() 121 do_test (0, i, j - buf_addr, BIG_CHAR); in do_overflow_tests() 122 do_test (0, i, -buf_addr - j, BIG_CHAR); in do_overflow_tests() 130 size_t i, j, n, align, len; in do_random_tests() local 139 j = len + align + 64; in do_random_tests() 140 if (j > 512) in do_random_tests() 141 j = 512; in do_random_tests() 143 for (i = 0; i < j; i++) in do_random_tests()
|
A D | test-strcmp.c | 223 if (pos + j >= 511) in do_random_tests() 224 pos = 510 - j - (random () & 7); in do_random_tests() 228 if (len1 + j >= 512) in do_random_tests() 234 len2 = len1 + (len1 != 511 - j ? random () % (511 - j - len1) : 0); in do_random_tests() 236 if (j > 512) in do_random_tests() 237 j = 512; in do_random_tests() 238 for (size_t i = 0; i < j; ++i) in do_random_tests() 248 for (size_t i = 0; i < j; ++i) in do_random_tests() 346 for (size_t j = 0; j < i; j++) in check() local 348 s1[j] = val; in check() [all …]
|
A D | test-strncasecmp.c | 184 size_t i, j, n, align1, align2, pos, len1, len2; in do_random_tests() local 198 j = align1 > align2 ? align1 : align2; in do_random_tests() 199 if (pos + j >= 511) in do_random_tests() 200 pos = 510 - j - (random () & 7); in do_random_tests() 204 if (len1 + j >= 512) in do_random_tests() 205 len1 = 511 - j - (random () & 7); in do_random_tests() 209 len2 = len1 + (len1 != 511 - j ? random () % (511 - j - len1) : 0); in do_random_tests() 211 if (j > 512) in do_random_tests() 212 j = 512; in do_random_tests() 213 for (i = 0; i < j; ++i) in do_random_tests() [all …]
|
A D | test-strcasestr.c | 42 size_t j; in stupid_strcasestr() local 43 for (j = 0; j < s2len; ++j) in stupid_strcasestr() 44 if (tolower (s1[i + j]) != tolower (s2[j])) in stupid_strcasestr() 46 if (j == s2len) in stupid_strcasestr()
|
A D | test-strpbrk.c | 83 size_t i, j; in STUPID_STRPBRK() local 86 for (j = 0; j < nrej; ++j) in STUPID_STRPBRK() 87 if (s[i] == rej[j]) in STUPID_STRPBRK() 160 size_t i, j, n, align, pos, len, rlen; in do_random_tests() local 194 j = (pos > len ? pos : len) + align + 64; in do_random_tests() 195 if (j > 512) in do_random_tests() 196 j = 512; in do_random_tests() 198 for (i = 0; i < j; i++) in do_random_tests()
|
A D | test-rawmemchr.c | 84 size_t i, j, n, align, pos, len; in do_random_tests() local 101 j = len + align + 64; in do_random_tests() 102 if (j > 512) in do_random_tests() 103 j = 512; in do_random_tests() 105 for (i = 0; i < j; i++) in do_random_tests()
|
A D | test-strlen.c | 97 size_t i, j, n, align, len; in do_random_tests() local 106 j = len + align + 64; in do_random_tests() 107 if (j > 512) in do_random_tests() 108 j = 512; in do_random_tests() 110 for (i = 0; i < j; i++) in do_random_tests()
|
A D | test-memrchr.c | 89 size_t i, j, n, align, pos, len; in do_random_tests() local 106 j = len + align + 64; in do_random_tests() 107 if (j > 512) in do_random_tests() 108 j = 512; in do_random_tests() 110 for (i = 0; i < j; i++) in do_random_tests()
|
A D | test-memcmp.c | 163 j = align1; in do_random_tests() 164 if (align2 > j) in do_random_tests() 165 j = align2; in do_random_tests() 166 if (pos + j >= 512) in do_random_tests() 167 pos = 511 - j - (random () & 7); in do_random_tests() 169 if (len + j >= 512) in do_random_tests() 170 len = 511 - j - (random () & 7); in do_random_tests() 171 j = len + align1 + 64; in do_random_tests() 172 if (j > 512) j = 512; in do_random_tests() 173 for (i = 0; i < j; ++i) in do_random_tests() [all …]
|
A D | test-strstr.c | 41 size_t j; in stupid_strstr() local 42 for (j = 0; j < s2len; ++j) in stupid_strstr() 43 if (s1[i + j] != s2[j]) in stupid_strstr() 45 if (j == s2len) in stupid_strstr()
|
A D | test-strncmp.c | 284 j = align1 > align2 ? align1 : align2; in do_random_tests() 285 if (pos + j >= 511) in do_random_tests() 286 pos = 510 - j - (random () & 7); in do_random_tests() 290 if (len1 + j >= 512) in do_random_tests() 291 len1 = 511 - j - (random () & 7); in do_random_tests() 295 len2 = len1 + (len1 != 511 - j ? random () % (511 - j - len1) : 0); in do_random_tests() 296 j = (pos > len2 ? pos : len2) + align1 + 64; in do_random_tests() 297 if (j > 512) in do_random_tests() 298 j = 512; in do_random_tests() 299 for (i = 0; i < j; ++i) in do_random_tests() [all …]
|