[dpdk-dev] [PATCH v2] malloc: fix malloc and free linear complexity
Robert Sanford
rsanford2 at gmail.com
Tue Jun 17 18:29:06 CEST 2014
Hi Pablo,
> Overall patch looks OK, but malloc unit tests fail on the last test
(test_multi_alloc_statistics).
> Apparently, the biggest free chunk size changes as it allocates some
memory, whereas in
> the previous implementation, this size did not change. I wonder if unit
test is wrong or if there
> is actually an issue here. Could you look at this as well?
Thanks for your comments. Yes, I will investigate problems with the malloc
unit tests.
BTW, I intend to make one other adjustment to the previous (v2) set of
changes:
--- a/lib/librte_malloc/malloc_elem.c
+++ b/lib/librte_malloc/malloc_elem.c
@@ -143,7 +143,7 @@ split_elem(struct malloc_elem *elem, struct malloc_elem
*split_pt)
size_t
malloc_elem_free_list_index(size_t size)
{
-#define MALLOC_MINSIZE_LOG2 7
+#define MALLOC_MINSIZE_LOG2 8
#define MALLOC_LOG2_INCREMENT 2
--
Robert
More information about the dev
mailing list