summaryrefslogtreecommitdiffstats
path: root/jemalloc/src/chunk_dss.c
diff options
context:
space:
mode:
Diffstat (limited to 'jemalloc/src/chunk_dss.c')
-rw-r--r--jemalloc/src/chunk_dss.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/jemalloc/src/chunk_dss.c b/jemalloc/src/chunk_dss.c
index d9bd63c..5c0e290 100644
--- a/jemalloc/src/chunk_dss.c
+++ b/jemalloc/src/chunk_dss.c
@@ -200,6 +200,22 @@ chunk_dealloc_dss_record(void *chunk, size_t size)
}
bool
+chunk_in_dss(void *chunk)
+{
+ bool ret;
+
+ malloc_mutex_lock(&dss_mtx);
+ if ((uintptr_t)chunk >= (uintptr_t)dss_base
+ && (uintptr_t)chunk < (uintptr_t)dss_max)
+ ret = true;
+ else
+ ret = false;
+ malloc_mutex_unlock(&dss_mtx);
+
+ return (ret);
+}
+
+bool
chunk_dealloc_dss(void *chunk, size_t size)
{
bool ret;