diff options
author | Siddhesh Poyarekar <siddhesh@sourceware.org> | 2017-08-11 12:17:24 +0530 |
---|---|---|
committer | Siddhesh Poyarekar <siddhesh@sourceware.org> | 2017-08-11 12:19:26 +0530 |
commit | 61c982910da9b60f7ac48eb1caaac1f4b013dbb1 (patch) | |
tree | 511ff18d802d82610ec60a40a49e5daef8681446 /benchtests/bench-memchr.c | |
parent | 925733a913ff7087e56f6ffebd2998f683212e78 (diff) | |
download | glibc-61c982910da9b60f7ac48eb1caaac1f4b013dbb1.tar.gz glibc-61c982910da9b60f7ac48eb1caaac1f4b013dbb1.tar.xz glibc-61c982910da9b60f7ac48eb1caaac1f4b013dbb1.zip |
benchtests: Remove verification runs from benchmark tests
The test run is unnecessary and interferes with the benchmark. The tests are done during make check, so they're unnecessary here. * benchtests/bench-memccpy.c (do_one_test): Remove checks. * benchtests/bench-memchr.c (do_one_test): Likewise. * benchtests/bench-memcpy-large.c (do_one_test): Likewise. * benchtests/bench-memcpy.c (do_one_test): Likewise. * benchtests/bench-memmove-large.c (do_one_test): Likewise. * benchtests/bench-memmove.c (do_one_test): Likewise. * benchtests/bench-memset-large.c (do_one_test): Likewise. * benchtests/bench-memset.c (do_one_test): Likewise. * benchtests/bench-string.h (test_init): Remove memsets.
Diffstat (limited to 'benchtests/bench-memchr.c')
-rw-r--r-- | benchtests/bench-memchr.c | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/benchtests/bench-memchr.c b/benchtests/bench-memchr.c index 92b5b7f986..59d6eab203 100644 --- a/benchtests/bench-memchr.c +++ b/benchtests/bench-memchr.c @@ -59,20 +59,11 @@ SIMPLE_MEMCHR (const CHAR *s, int c, size_t n) #endif /* !USE_AS_MEMRCHR */ static void -do_one_test (impl_t *impl, const CHAR *s, int c, size_t n, CHAR *exp_res) +do_one_test (impl_t *impl, const CHAR *s, int c, size_t n) { - CHAR *res = CALL (impl, s, c, n); size_t i, iters = INNER_LOOP_ITERS; timing_t start, stop, cur; - if (res != exp_res) - { - error (0, 0, "Wrong result in function %s %p %p", impl->name, - res, exp_res); - ret = 1; - return; - } - TIMING_NOW (start); for (i = 0; i < iters; ++i) { @@ -89,7 +80,6 @@ static void do_test (size_t align, size_t pos, size_t len, int seek_char) { size_t i; - CHAR *result; align &= 7; if ((align + len) * sizeof (CHAR) >= page_size) @@ -109,11 +99,9 @@ do_test (size_t align, size_t pos, size_t len, int seek_char) { buf[align + pos] = seek_char; buf[align + len] = -seek_char; - result = (CHAR *) (buf + align + pos); } else { - result = NULL; buf[align + len] = seek_char; } @@ -121,7 +109,7 @@ do_test (size_t align, size_t pos, size_t len, int seek_char) len, pos, align); FOR_EACH_IMPL (impl, 0) - do_one_test (impl, (CHAR *) (buf + align), seek_char, len, result); + do_one_test (impl, (CHAR *) (buf + align), seek_char, len); putchar ('\n'); } |