DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] malloc: enhance NUMA affinity heuristic
@ 2022-12-21 10:48 David Marchand
  2022-12-21 11:16 ` Bruce Richardson
                   ` (5 more replies)
  0 siblings, 6 replies; 41+ messages in thread
From: David Marchand @ 2022-12-21 10:48 UTC (permalink / raw)
  To: dev; +Cc: olivier.matz, ferruh.yigit, kaisenx.you, Anatoly Burakov

Trying to allocate memory on the first detected numa node has less
chance to find some memory actually available rather than on the main
lcore numa node (especially when the DPDK application is started only
on one numa node).

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 lib/eal/common/malloc_heap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/eal/common/malloc_heap.c b/lib/eal/common/malloc_heap.c
index d7c410b786..08f965a525 100644
--- a/lib/eal/common/malloc_heap.c
+++ b/lib/eal/common/malloc_heap.c
@@ -717,7 +717,7 @@ malloc_get_numa_socket(void)
 			return socket_id;
 	}
 
-	return rte_socket_id_by_idx(0);
+	return rte_lcore_to_socket_id(rte_get_main_lcore());
 }
 
 void *
-- 
2.38.1


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

end of thread, other threads:[~2023-06-12  9:37 UTC | newest]

Thread overview: 41+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-21 10:48 [PATCH] malloc: enhance NUMA affinity heuristic David Marchand
2022-12-21 11:16 ` Bruce Richardson
2022-12-21 13:50   ` Ferruh Yigit
2022-12-21 14:57 ` David Marchand
2022-12-27  9:00   ` zhoumin
2023-01-03 10:56     ` David Marchand
2023-01-03 10:58 ` [PATCH v2] " David Marchand
2023-01-03 13:32 ` [PATCH v3] " David Marchand
2023-01-31  3:23   ` You, KaisenX
2023-01-31 15:05 ` [PATCH v4] net/iavf:enhance " Kaisen You
2023-01-31 16:05   ` Thomas Monjalon
2023-02-01  5:32     ` You, KaisenX
2023-02-01 12:20 ` [PATCH v5] enhance " Kaisen You
2023-02-01 10:52   ` Jiale, SongX
2023-02-15 14:22   ` Burakov, Anatoly
2023-02-15 14:47     ` Burakov, Anatoly
2023-02-16  2:50     ` You, KaisenX
2023-03-03 14:07       ` Thomas Monjalon
2023-03-09  1:58         ` You, KaisenX
2023-04-13  0:56           ` You, KaisenX
2023-04-19 12:16             ` Thomas Monjalon
2023-04-21  2:34               ` You, KaisenX
2023-04-21  8:12                 ` Thomas Monjalon
2023-04-23  6:52                   ` You, KaisenX
2023-04-23  8:57                     ` You, KaisenX
2023-04-23 13:19                       ` Thomas Monjalon
2023-04-25  5:16   ` [PATCH v6] " Kaisen You
2023-04-27  6:57     ` Thomas Monjalon
2023-05-16  5:19       ` You, KaisenX
2023-05-23  2:50     ` [PATCH v7] " Kaisen You
2023-05-23 10:44       ` Burakov, Anatoly
2023-05-26  6:44         ` You, KaisenX
2023-05-23 12:45       ` Burakov, Anatoly
2023-05-26  6:50       ` [PATCH v8] " Kaisen You
2023-05-26  8:45       ` Kaisen You
2023-05-26 14:44         ` Burakov, Anatoly
2023-05-26 17:50           ` Stephen Hemminger
2023-05-29 10:37             ` Burakov, Anatoly
2023-06-01 14:42         ` David Marchand
2023-06-06 14:04           ` Thomas Monjalon
2023-06-12  9:36           ` Burakov, Anatoly

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).