+2016-12-19 Adhemerval Zanella <adhemerval.zanella@linaro.org>
+
+ * benchtests/bench-string.h (TEST_FUNCTION): Use name without
+ parenthesis.
+ (CMDLINE_PROCESS): Define using function instead of macro.
+ * benchtests/bench-memccpy.c: Include <support/test-driver.c> instead
+ of test-skeleton.
+ * benchtests/bench-memchr.c: Likewise.
+ * benchtests/bench-memcmp.c: Likewise.
+ * benchtests/bench-memcpy-large.c: Likewise.
+ * benchtests/bench-memcpy.c: Likewise.
+ * benchtests/bench-memmem.c: Likewise.
+ * benchtests/bench-memmove-large.c: Likewise.
+ * benchtests/bench-memmove.c: Likewise.
+ * benchtests/bench-memset-large.c: Likewise.
+ * benchtests/bench-memset.c: Likewise.
+ * benchtests/bench-rawmemchr.c: Likewise.
+ * benchtests/bench-strcasecmp.c: Likewise.
+ * benchtests/bench-strcasestr.c: Likewise.
+ * benchtests/bench-strcat.c: Likewise.
+ * benchtests/bench-strchr.c: Likewise.
+ * benchtests/bench-strcmp.c: Likewise.
+ * benchtests/bench-strcpy.c: Likewise.
+ * benchtests/bench-strcpy_chk.c: Likewise.
+ * benchtests/bench-strlen.c: Likewise.
+ * benchtests/bench-strncasecmp.c: Likewise.
+ * benchtests/bench-strncmp.c: Likewise.
+ * benchtests/bench-strncpy.c: Likewise.
+ * benchtests/bench-strnlen.c: Likewise.
+ * benchtests/bench-strpbrk.c: Likewise.
+ * benchtests/bench-strrchr.c: Likewise.
+ * benchtests/bench-strsep.c: Likewise.
+ * benchtests/bench-strspn.c: Likewise.
+ * benchtests/bench-strstr.c: Likewise.
+ * benchtests/bench-strtok.c: Likewise.
+
2016-12-19 Andrew Senkevich <andrew.senkevich@intel.com>
* sysdeps/x86/cpu-features.c (get_common_indeces): Add
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
putchar ('\n');
}
-int
+static int
test_main (void)
{
size_t i;
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
#include <setjmp.h>
#include <signal.h>
-static int test_main (void);
-#include "../test-skeleton.c"
+#include <support/support.h>
volatile int chk_fail_ok;
jmp_buf chk_fail_buf;
return 0;
}
+
+#include <support/test-driver.c>
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
+#include <getopt.h>
#include <sys/cdefs.h>
typedef struct
# include "bench-timing.h"
-# define TEST_FUNCTION test_main ()
+# define TEST_FUNCTION test_main
# ifndef TIMEOUT
# define TIMEOUT (4 * 60)
# endif
# define CMDLINE_OPTIONS ITERATIONS_OPTIONS \
{ "random", no_argument, NULL, OPT_RANDOM }, \
{ "seed", required_argument, NULL, OPT_SEED },
-# define CMDLINE_PROCESS ITERATIONS_PROCESS \
- case OPT_RANDOM: \
- { \
- int fdr = open ("/dev/urandom", O_RDONLY); \
- \
- if (fdr < 0 || read (fdr, &seed, sizeof(seed)) != sizeof (seed)) \
- seed = time (NULL); \
- if (fdr >= 0) \
- close (fdr); \
- do_srandom = 1; \
- break; \
- } \
- \
- case OPT_SEED: \
- seed = strtoul (optarg, NULL, 0); \
- do_srandom = 1; \
- break;
+static void __attribute__ ((used))
+cmdline_process_function (int c)
+{
+ switch (c)
+ {
+ ITERATIONS_PROCESS
+ case OPT_RANDOM:
+ {
+ int fdr = open ("/dev/urandom", O_RDONLY);
+ if (fdr < 0 || read (fdr, &seed, sizeof(seed)) != sizeof (seed))
+ seed = time (NULL);
+ if (fdr >= 0)
+ close (fdr);
+ do_srandom = 1;
+ break;
+ }
+
+ case OPT_SEED:
+ seed = strtoul (optarg, NULL, 0);
+ do_srandom = 1;
+ break;
+ }
+}
+# define CMDLINE_PROCESS cmdline_process_function
# define CALL(impl, ...) \
(* (proto_t) (impl)->fn) (__VA_ARGS__)
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
putchar ('\n');
}
-int
+static int
test_main (void)
{
size_t i;
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>
return ret;
}
-#include "../test-skeleton.c"
+#include <support/test-driver.c>