diff mbox

[dpdk-dev] app/test: fix memory needs after RTE_MAX_LCORE was increased to 128

Message ID 1417696834-21354-1-git-send-email-pablo.de.lara.guarch@intel.com (mailing list archive)
State Changes Requested, archived
Headers show

Commit Message

De Lara Guarch, Pablo Dec. 4, 2014, 12:40 p.m. UTC
Since commit b91c67e5a693211862aa7dc3b78630b4e856c2af,
maximum number of cores is 128, which has increase
the total memory necessary for a rte_mempool structure,
as the per-lcore local cache has been doubled in size.
Therefore, eal_flags unit test was broken since it needed
to use more hugepages.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 app/test/test_eal_flags.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Thomas Monjalon Dec. 4, 2014, 1:20 p.m. UTC | #1
> Since commit b91c67e5a693211862aa7dc3b78630b4e856c2af,
> maximum number of cores is 128, which has increase
> the total memory necessary for a rte_mempool structure,
> as the per-lcore local cache has been doubled in size.
> Therefore, eal_flags unit test was broken since it needed
> to use more hugepages.
> 
> Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>

When I check it in a VM, I still have a memory issue in test_invalid_vdev_flag().
Do you have an idea of the problem?
De Lara Guarch, Pablo Dec. 5, 2014, 3:57 p.m. UTC | #2
> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]
> Sent: Thursday, December 04, 2014 1:21 PM
> To: De Lara Guarch, Pablo
> Cc: dev@dpdk.org
> Subject: Re: [dpdk-dev] [PATCH] app/test: fix memory needs after
> RTE_MAX_LCORE was increased to 128
> 
> > Since commit b91c67e5a693211862aa7dc3b78630b4e856c2af,
> > maximum number of cores is 128, which has increase
> > the total memory necessary for a rte_mempool structure,
> > as the per-lcore local cache has been doubled in size.
> > Therefore, eal_flags unit test was broken since it needed
> > to use more hugepages.
> >
> > Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
> 
> When I check it in a VM, I still have a memory issue in
> test_invalid_vdev_flag().
> Do you have an idea of the problem?

Sorry I did not have a VM by that time. Now I do :)
Apparently it needs more memory, as first thing DPDK does is 
reserving space in rte_malloc heap, which size is bigger in the VM.
By changing the memory needed to 18M, we can fix the unit test.
I am still not sure why within a VM we need more memory, though.

Thanks,
Pablo
> 
> --
> Thomas
diff mbox

Patch

diff --git a/app/test/test_eal_flags.c b/app/test/test_eal_flags.c
index 6e2a8f2..0683041 100644
--- a/app/test/test_eal_flags.c
+++ b/app/test/test_eal_flags.c
@@ -55,7 +55,7 @@ 
 #ifdef RTE_LIBRTE_XEN_DOM0
 #define DEFAULT_MEM_SIZE "30"
 #else
-#define DEFAULT_MEM_SIZE "8"
+#define DEFAULT_MEM_SIZE "14"
 #endif
 #define mp_flag "--proc-type=secondary"
 #define no_hpet "--no-hpet"