MCPcopy Create free account
hub / github.com/F-Stack/f-stack / test_clz64

Function test_clz64

dpdk/app/test/test_bitcount.c:30–43  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28}
29
30static int
31test_clz64(void)
32{
33 size_t leading;
34 uint64_t v = 0xffffffffffffffff;
35
36 for (leading = 0; v; leading++) {
37 RTE_TEST_ASSERT(rte_clz64(v) == leading,
38 "Unexpected count.");
39 v >>= 1;
40 }
41
42 return 0;
43}
44
45static int
46test_ctz32(void)

Callers

nothing calls this directly

Calls 1

rte_clz64Function · 0.85

Tested by

no test coverage detected