ARAL optimal alloc size (#13804)
aral optimal alloc size
Costa Tsaousis committed
Oct 10, 2022 at 21:21 UTC
bd38daa40cd21f2f357b2930f529b68d96523102
1 file changed
+3
-1
libnetdata/arrayalloc/arrayalloc.c
+3
-1
@@ -6,7 +6,9 @@
6
#define ARAL_MAX_PAGE_SIZE_MMAP (1*1024*1024*1024)
7
8
// max malloc size
9
-#define ARAL_MAX_PAGE_SIZE_MALLOC (10*1024*1024)
9
+// optimal at current versions of libc is up to 256k
10
+// ideal to have the same overhead as libc is 4k
11
+#define ARAL_MAX_PAGE_SIZE_MALLOC (64*1024)
12
13
typedef struct arrayalloc_free {
14
size_t size;