From 8c099a534044bf7182e04f250e342aab76bc3e54 Mon Sep 17 00:00:00 2001 From: Casey Bodley Date: Sun, 5 Mar 2023 11:58:43 -0500 Subject: [PATCH] asan: add qa/lsan.supp for leak sanitizer suppressions any executable that links against the heap_profiler leaks 8 bytes for a singleton: > ----------------------------------------------------- > Suppressions used: > count bytes template > 1 8 ^MallocExtension::Register > ----------------------------------------------------- the python script bin/ceph has a lot of leaks: > ----------------------------------------------------- > Suppressions used: > count bytes template > 205 294983 ^PyObject_Malloc > 10 6216 ^_PyObject_Realloc > 1 568 ^PyMem_Calloc > 2 2 ^PyMem_Malloc > 63 58935 ^PyUnicode_New > 10 7294 ^_PyBytes_FromSize > 166 149904 ^_PyObject_GC_Alloc > 5 3360 ^_PyObject_GC_Resize > ----------------------------------------------------- Signed-off-by: Casey Bodley --- qa/lsan.supp | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 qa/lsan.supp diff --git a/qa/lsan.supp b/qa/lsan.supp new file mode 100644 index 0000000000000..545e76ad1fa27 --- /dev/null +++ b/qa/lsan.supp @@ -0,0 +1,26 @@ +# leak suppressions needed to run vstart.sh with WITH_ASAN=ON +# to enable, add this to the environment: +# LSAN_OPTIONS="suppressions=../qa/lsan.supp" + +# from perfglue/heap_profiler.cc +# gperftools allocates a singleton and never frees it +leak:^MallocExtension::Register + +# from src/ceph.in +# python3.6 +leak:^_PyObject_Alloc +leak:^_PyObject_GC_Resize +leak:^PyBytes_FromStringAndSize +leak:^PyType_GenericAlloc +leak:^set_table_resize +# python3.7 +leak:^_PyObject_Realloc +leak:^PyObject_Malloc +# python3.8 +leak:^_PyBytes_FromSize +leak:^_PyObject_GC_Alloc +leak:^PyMem_Calloc +leak:^PyUnicode_New +# python3.9, 3.10, 3.11 +leak:^PyMem_Malloc +# python3.12 doesn't leak anything -- 2.39.5