jemalloc/include/jemalloc/internal/large.h
Slobodan Predolac fb92d8a916 Consolidate simple component headers (large, background_thread, bin)
Folds several historical *_types/_structs/_externs/_inlines splits where
the layering is no longer load-bearing.

- large_externs.h -> large.h: renamed; it was a single-purpose
  function-prototype file.
- background_thread_structs.h + background_thread_externs.h ->
  background_thread.h: merged.  background_thread_inlines.h is kept
  separate because it depends on arena_inlines_a.h.
- bin_inlines.h folded into bin.h, along with BIN_SHARDS_MAX /
  N_BIN_SHARDS_DEFAULT from bin_types.h.  bin.h carries a forward decl
  of arena_binind_div_info (declared in arena_externs.h) so it stays
  hermetic without re-introducing the bin.h <-> arena_externs.h cycle.
- tsd_binshards.h (new): houses tsd_binshards_t and its zero
  initializer.  Keeping these out of bin.h lets tsd_internals.h pull in
  just what it needs during X-macro expansion, avoiding bin.h's mutex.h
  dependency (mutex.h itself depends on TSD machinery, so routing it
  through tsd_internals.h forms a chicken-and-egg).

jemalloc_internal_includes.h: drops the now-redundant references to
the deleted/merged headers.
2026-05-29 08:53:23 -07:00

23 lines
1,002 B
C

#ifndef JEMALLOC_INTERNAL_LARGE_H
#define JEMALLOC_INTERNAL_LARGE_H
#include "jemalloc/internal/jemalloc_preamble.h"
#include "jemalloc/internal/edata.h"
void *large_malloc(tsdn_t *tsdn, arena_t *arena, size_t usize, bool zero);
void *large_palloc(
tsdn_t *tsdn, arena_t *arena, size_t usize, size_t alignment, bool zero);
bool large_ralloc_no_move(tsdn_t *tsdn, edata_t *edata, size_t usize_min,
size_t usize_max, bool zero);
void *large_ralloc(tsdn_t *tsdn, arena_t *arena, void *ptr, size_t usize,
size_t alignment, bool zero, tcache_t *tcache);
void large_dalloc_prep_locked(tsdn_t *tsdn, edata_t *edata);
void large_dalloc_finish(tsdn_t *tsdn, edata_t *edata);
void large_dalloc(tsdn_t *tsdn, edata_t *edata);
void large_prof_info_get(
tsd_t *tsd, edata_t *edata, prof_info_t *prof_info, bool reset_recent);
void large_prof_tctx_reset(edata_t *edata);
void large_prof_info_set(edata_t *edata, prof_tctx_t *tctx, size_t size);
#endif /* JEMALLOC_INTERNAL_LARGE_H */