DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] test/table: skip when not enough memory is available
@ 2019-07-05  9:19 David Marchand
  2019-07-05 17:54 ` Dumitrescu, Cristian
  0 siblings, 1 reply; 3+ messages in thread
From: David Marchand @ 2019-07-05  9:19 UTC (permalink / raw)
  To: dev; +Cc: Cristian Dumitrescu

Following empirical tries, this test wants at least 3300M of memory to
run.

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 app/test/test_table.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/app/test/test_table.c b/app/test/test_table.c
index a4b0ed6..dca1b33 100644
--- a/app/test/test_table.c
+++ b/app/test/test_table.c
@@ -134,6 +134,13 @@ uint32_t pipeline_test_hash_cuckoo(const void *key,
 {
 	int status, ret;
 	unsigned i;
+	void *p;
+
+	/* empirical value, please refine when updating this test */
+	p = rte_malloc("enough_memory_for_test", (size_t)3300 << 20, 0);
+	if (!p)
+		return TEST_SKIPPED;
+	rte_free(p);
 
 	ret = TEST_SUCCESS;
 
-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-07-05 20:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-05  9:19 [dpdk-dev] [PATCH] test/table: skip when not enough memory is available David Marchand
2019-07-05 17:54 ` Dumitrescu, Cristian
2019-07-05 20:47   ` Thomas Monjalon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).