OpenGrok
Home
Sort by relevance
Sort by last modified time
Full Search
Definition
Symbol
File Path
History
|
|
Help
Searched
refs:Log2Floor
(Results
1 - 2
of
2
) sorted by null
/external/chromium/base/
bits_unittest.cc
13
TEST(BitsTest,
Log2Floor
) {
14
EXPECT_EQ(-1,
Log2Floor
(0));
15
EXPECT_EQ(0,
Log2Floor
(1));
16
EXPECT_EQ(1,
Log2Floor
(2));
17
EXPECT_EQ(1,
Log2Floor
(3));
18
EXPECT_EQ(2,
Log2Floor
(4));
21
EXPECT_EQ(i,
Log2Floor
(value));
22
EXPECT_EQ(i,
Log2Floor
(value + 1));
23
EXPECT_EQ(i,
Log2Floor
(value + 2));
24
EXPECT_EQ(i - 1,
Log2Floor
(value - 1))
[
all
...]
bits.h
18
inline int
Log2Floor
(uint32 n) {
40
//
Log2Floor
returns -1 for 0, so the following works correctly for n=1.
41
return 1 +
Log2Floor
(n - 1);
Completed in 801 milliseconds