Lines Matching refs:ptr

316 a0idalloc(void *ptr, bool is_metadata)  in a0idalloc()  argument
319 idalloctm(NULL, ptr, false, is_metadata); in a0idalloc()
330 a0dalloc(void *ptr) in a0dalloc() argument
333 a0idalloc(ptr, true); in a0dalloc()
367 bootstrap_free(void *ptr) in bootstrap_free() argument
370 if (unlikely(ptr == NULL)) in bootstrap_free()
373 a0idalloc(ptr, false); in bootstrap_free()
1728 ifree(tsd_t *tsd, void *ptr, tcache_t *tcache) in ifree() argument
1733 assert(ptr != NULL); in ifree()
1737 usize = isalloc(ptr, config_prof); in ifree()
1738 prof_free(tsd, ptr, usize); in ifree()
1740 usize = isalloc(ptr, config_prof); in ifree()
1744 rzsize = p2rz(ptr); in ifree()
1745 iqalloc(tsd, ptr, tcache); in ifree()
1746 JEMALLOC_VALGRIND_FREE(ptr, rzsize); in ifree()
1750 isfree(tsd_t *tsd, void *ptr, size_t usize, tcache_t *tcache) in isfree() argument
1754 assert(ptr != NULL); in isfree()
1758 prof_free(tsd, ptr, usize); in isfree()
1762 rzsize = p2rz(ptr); in isfree()
1763 isqalloc(tsd, ptr, usize, tcache); in isfree()
1764 JEMALLOC_VALGRIND_FREE(ptr, rzsize); in isfree()
1770 je_realloc(void *ptr, size_t size) in je_realloc() argument
1779 if (ptr != NULL) { in je_realloc()
1781 UTRACE(ptr, 0, 0); in je_realloc()
1783 ifree(tsd, ptr, tcache_get(tsd, false)); in je_realloc()
1789 if (likely(ptr != NULL)) { in je_realloc()
1794 old_usize = isalloc(ptr, config_prof); in je_realloc()
1796 old_rzsize = config_prof ? p2rz(ptr) : u2rz(old_usize); in je_realloc()
1801 ptr, old_usize, usize); in je_realloc()
1806 ret = iralloc(tsd, ptr, old_usize, size, 0, false); in je_realloc()
1826 UTRACE(ptr, size, ret); in je_realloc()
1827 JEMALLOC_VALGRIND_REALLOC(true, ret, usize, true, ptr, old_usize, in je_realloc()
1833 je_free(void *ptr) in je_free() argument
1836 UTRACE(ptr, 0, 0); in je_free()
1837 if (likely(ptr != NULL)) { in je_free()
1839 ifree(tsd, ptr, tcache_get(tsd, false)); in je_free()
1897 JEMALLOC_EXPORT void (*__free_hook)(void *ptr) = je_free;
1899 JEMALLOC_EXPORT void *(*__realloc_hook)(void *ptr, size_t size) = je_realloc;
2155 je_rallocx(void *ptr, size_t size, int flags) in je_rallocx() argument
2167 assert(ptr != NULL); in je_rallocx()
2189 old_usize = isalloc(ptr, config_prof); in je_rallocx()
2196 p = irallocx_prof(tsd, ptr, old_usize, size, alignment, &usize, in je_rallocx()
2201 p = iralloct(tsd, ptr, old_usize, size, alignment, zero, in je_rallocx()
2214 UTRACE(ptr, size, p); in je_rallocx()
2215 JEMALLOC_VALGRIND_REALLOC(true, p, usize, false, ptr, old_usize, in je_rallocx()
2223 UTRACE(ptr, size, 0); in je_rallocx()
2228 ixallocx_helper(void *ptr, size_t old_usize, size_t size, size_t extra, in ixallocx_helper() argument
2233 if (ixalloc(ptr, old_usize, size, extra, alignment, zero)) in ixallocx_helper()
2235 usize = isalloc(ptr, config_prof); in ixallocx_helper()
2241 ixallocx_prof_sample(void *ptr, size_t old_usize, size_t size, size_t extra, in ixallocx_prof_sample() argument
2248 usize = ixallocx_helper(ptr, old_usize, size, extra, alignment, zero); in ixallocx_prof_sample()
2254 ixallocx_prof(tsd_t *tsd, void *ptr, size_t old_usize, size_t size, in ixallocx_prof() argument
2262 old_tctx = prof_tctx_get(ptr); in ixallocx_prof()
2274 usize = ixallocx_prof_sample(ptr, old_usize, size, extra, in ixallocx_prof()
2277 usize = ixallocx_helper(ptr, old_usize, size, extra, alignment, in ixallocx_prof()
2284 prof_realloc(tsd, ptr, usize, tctx, prof_active, false, ptr, old_usize, in ixallocx_prof()
2291 je_xallocx(void *ptr, size_t size, size_t extra, int flags) in je_xallocx() argument
2299 assert(ptr != NULL); in je_xallocx()
2306 old_usize = isalloc(ptr, config_prof); in je_xallocx()
2322 usize = ixallocx_prof(tsd, ptr, old_usize, size, extra, in je_xallocx()
2325 usize = ixallocx_helper(ptr, old_usize, size, extra, alignment, in je_xallocx()
2335 JEMALLOC_VALGRIND_REALLOC(false, ptr, usize, false, ptr, old_usize, in je_xallocx()
2338 UTRACE(ptr, size, ptr); in je_xallocx()
2344 je_sallocx(const void *ptr, int flags) in JEMALLOC_ATTR()
2352 usize = ivsalloc(ptr, config_prof); in JEMALLOC_ATTR()
2354 usize = isalloc(ptr, config_prof); in JEMALLOC_ATTR()
2360 je_dallocx(void *ptr, int flags) in je_dallocx() argument
2365 assert(ptr != NULL); in je_dallocx()
2377 UTRACE(ptr, 0, 0); in je_dallocx()
2378 ifree(tsd_fetch(), ptr, tcache); in je_dallocx()
2395 je_sdallocx(void *ptr, size_t size, int flags) in je_sdallocx() argument
2401 assert(ptr != NULL); in je_sdallocx()
2404 assert(usize == isalloc(ptr, config_prof)); in je_sdallocx()
2415 UTRACE(ptr, 0, 0); in je_sdallocx()
2416 isfree(tsd, ptr, usize, tcache); in je_sdallocx()
2473 je_malloc_usable_size(JEMALLOC_USABLE_SIZE_CONST void *ptr) in je_malloc_usable_size() argument
2481 ret = ivsalloc(ptr, config_prof); in je_malloc_usable_size()
2483 ret = (ptr == NULL) ? 0 : isalloc(ptr, config_prof); in je_malloc_usable_size()