Extent -> Ehooks: Move alloc hook.

This commit is contained in:
David Goldblatt
2019-12-02 16:42:44 -08:00
committed by David Goldblatt
parent 703fbc0ff5
commit dc8b4e6e13
4 changed files with 105 additions and 99 deletions

View File

@@ -43,12 +43,8 @@ base_map(tsdn_t *tsdn, ehooks_t *ehooks, unsigned ind, size_t size) {
pages_set_thp_state(addr, size);
}
} else {
/* No arena context as we are creating new arenas. */
tsd_t *tsd = tsdn_null(tsdn) ? tsd_fetch() : tsdn_tsd(tsdn);
pre_reentrancy(tsd, NULL);
addr = ehooks_alloc(ehooks, NULL, size, alignment, &zero,
addr = ehooks_alloc(tsdn, ehooks, NULL, size, alignment, &zero,
&commit, ind);
post_reentrancy(tsd);
}
return addr;