Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/AliveToolkit/alive2
/ ilog2
Function
ilog2
util/compiler.cpp:28–30 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
26
namespace util {
27
28
unsigned ilog2(uint64_t n) {
29
return n == 0 ? 0 : bit_width(n) - 1;
30
}
31
32
unsigned ilog2_ceil(uint64_t n, bool up_power2) {
33
auto log = ilog2(n);
Callers
7
mkAxioms
Method · 0.85
alloc
Method · 0.85
zeroBitsShortOffset
Method · 0.85
isBlockAligned
Method · 0.85
isAligned
Method · 0.85
ilog2_ceil
Function · 0.85
is_power2
Function · 0.85
Calls
1
bit_width
Function · 0.85
Tested by
no test coverage detected