Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/facebook/CacheLib
/ getNumPages
Function
getNumPages
cachelib/common/Utils.cpp:225–227 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
223
}
224
225
size_t getNumPages(size_t len) noexcept {
226
return (len + getPageSize() - 1) / getPageSize();
227
}
228
229
bool isPageAlignedAddr(const void* addr) noexcept {
230
return reinterpret_cast<uintptr_t>(addr) % getPageSize() == 0;
Callers
6
lockMemoryAsync
Method · 0.85
SlabAllocator.cpp
File · 0.85
TEST_F
Function · 0.85
testAdvise
Function · 0.85
testRestoreAndAdvise
Function · 0.85
getNumResidentPages
Function · 0.85
Calls
1
getPageSize
Function · 0.70
Tested by
3
TEST_F
Function · 0.68
testAdvise
Function · 0.68
testRestoreAndAdvise
Function · 0.68