MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / MallocUsage

Function MallocUsage

src/memusage.h:48–60  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

46 */
47
48static inline size_t MallocUsage(size_t alloc)
49{
50 // Measured on libc6 2.19 on Linux.
51 if (alloc == 0) {
52 return 0;
53 } else if (sizeof(void*) == 8) {
54 return ((alloc + 31) >> 4) << 4;
55 } else if (sizeof(void*) == 4) {
56 return ((alloc + 15) >> 3) << 3;
57 } else {
58 assert(0);
59 }
60}
61
62// STL data structures
63

Callers 4

DynamicMemoryUsageMethod · 0.85
DynamicUsageFunction · 0.85
IncrementalDynamicUsageFunction · 0.85
DynamicMemoryUsageMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected