MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / extent_alloc_default

Function extent_alloc_default

deps/jemalloc/src/extent.c:1250–1266  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1248}
1249
1250static void *
1251extent_alloc_default(extent_hooks_t *extent_hooks, void *new_addr, size_t size,
1252 size_t alignment, bool *zero, bool *commit, unsigned arena_ind) {
1253 tsdn_t *tsdn;
1254 arena_t *arena;
1255
1256 tsdn = tsdn_fetch();
1257 arena = arena_get(tsdn, arena_ind, false);
1258 /*
1259 * The arena we're allocating on behalf of must have been initialized
1260 * already.
1261 */
1262 assert(arena != NULL);
1263
1264 return extent_alloc_default_impl(tsdn, arena, new_addr, size,
1265 ALIGNMENT_CEILING(alignment, PAGE), zero, commit);
1266}
1267
1268static void
1269extent_hook_pre_reentrancy(tsdn_t *tsdn, arena_t *arena) {

Callers

nothing calls this directly

Calls 3

tsdn_fetchFunction · 0.50
arena_getFunction · 0.50

Tested by

no test coverage detected