From: Rusty Russell Date: Mon, 26 Mar 2018 05:02:55 +0000 (+1030) Subject: configurator: add tests for other popcount variants. X-Git-Url: http://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=d872b7f22bc98092cad2aa4a456973bdbdb2c8fb configurator: add tests for other popcount variants. Signed-off-by: Rusty Russell --- diff --git a/tools/configurator/configurator.c b/tools/configurator/configurator.c index ff9f6490..ecf8f9f5 100644 --- a/tools/configurator/configurator.c +++ b/tools/configurator/configurator.c @@ -159,8 +159,12 @@ static struct test tests[] = { "return __builtin_ffsl(0L) == 0 ? 0 : 1;" }, { "HAVE_BUILTIN_FFSLL", INSIDE_MAIN, NULL, NULL, "return __builtin_ffsll(0LL) == 0 ? 0 : 1;" }, + { "HAVE_BUILTIN_POPCOUNT", INSIDE_MAIN, NULL, NULL, + "return __builtin_popcount(255) == 8 ? 0 : 1;" }, { "HAVE_BUILTIN_POPCOUNTL", INSIDE_MAIN, NULL, NULL, "return __builtin_popcountl(255L) == 8 ? 0 : 1;" }, + { "HAVE_BUILTIN_POPCOUNTLL", INSIDE_MAIN, NULL, NULL, + "return __builtin_popcountll(255LL) == 8 ? 0 : 1;" }, { "HAVE_BUILTIN_TYPES_COMPATIBLE_P", INSIDE_MAIN, NULL, NULL, "return __builtin_types_compatible_p(char *, int) ? 1 : 0;" }, { "HAVE_ICCARM_INTRINSICS", DEFINES_FUNC, NULL, NULL,