Home
last modified time | relevance | path

Searched refs:CONST_LOG2ULL (Results 1 – 2 of 2) sorted by relevance

/systemd-251/src/test/
Dtest-util.c31 TEST(CONST_LOG2ULL) { in TEST() argument
32 assert_se(CONST_LOG2ULL(0) == 0); in TEST()
33 assert_se(CONST_LOG2ULL(1) == 0); in TEST()
34 assert_se(CONST_LOG2ULL(8) == 3); in TEST()
35 assert_se(CONST_LOG2ULL(9) == 3); in TEST()
36 assert_se(CONST_LOG2ULL(15) == 3); in TEST()
37 assert_se(CONST_LOG2ULL(16) == 4); in TEST()
38 assert_se(CONST_LOG2ULL(1024*1024) == 20); in TEST()
39 assert_se(CONST_LOG2ULL(1024*1024+5) == 20); in TEST()
/systemd-251/src/basic/
Dutil.h31 #define CONST_LOG2ULL(x) ((x) > 1 ? (unsigned) __builtin_clzll(x) ^ 63U : 0) macro
36 #define LOG2ULL(x) __builtin_choose_expr(__builtin_constant_p(x), CONST_LOG2ULL(x), NONCONST_LOG2UL…