MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / Log2Ceiling64

Function Log2Ceiling64

tensorflow/core/lib/core/bits.h:87–93  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

85}
86
87inline int Log2Ceiling64(uint64 n) {
88 int floor = Log2Floor64(n);
89 if (n == (n & ~(n - 1))) // zero or a power of two
90 return floor;
91 else
92 return floor + 1;
93}
94
95inline uint32 NextPowerOfTwo(uint32 value) {
96 int exponent = Log2Ceiling(value);

Callers 2

FillUniqueMethod · 0.85
RoundUpMethod · 0.85

Calls 1

Log2Floor64Function · 0.70

Tested by

no test coverage detected