DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] config/x86: config support for AMD EPYC processors
@ 2023-09-25 15:10 Sivaprasad Tummala
  2023-10-06  7:50 ` David Marchand
                   ` (2 more replies)
  0 siblings, 3 replies; 20+ messages in thread
From: Sivaprasad Tummala @ 2023-09-25 15:10 UTC (permalink / raw)
  To: bruce.richardson, konstantin.v.ananyev; +Cc: dev, Sivaprasad Tummala

From: Sivaprasad Tummala <Sivaprasad.Tummala@amd.com>

By default, max lcores are limited to 128 for x86 platforms.
On AMD EPYC processors, this limit needs to be increased to
leverage all the cores.

The patch adjusts the limit specifically for native compilation
on AMD EPYC CPUs.

Signed-off-by: Sivaprasad Tummala <Sivaprasad.Tummala@amd.com>
---
 config/x86/meson.build | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/config/x86/meson.build b/config/x86/meson.build
index d8ef50fb40..5355731cef 100644
--- a/config/x86/meson.build
+++ b/config/x86/meson.build
@@ -83,4 +83,21 @@ endif
 
 dpdk_conf.set('RTE_CACHE_LINE_SIZE', 64)
 dpdk_conf.set('RTE_MAX_LCORE', 128)
+
+epyc_zen_cores = {
+    '__znver4__':512,
+    '__znver3__':256,
+    '__znver2__':256,
+    '__znver1__':128
+    }
+
+if get_option('platform') == 'native'
+    foreach m:epyc_zen_cores.keys()
+        if cc.get_define(m, args: machine_args) != ''
+            dpdk_conf.set('RTE_MAX_LCORE', epyc_zen_cores[m])
+            break
+        endif
+    endforeach
+endif
+
 dpdk_conf.set('RTE_MAX_NUMA_NODES', 32)
-- 
2.34.1


^ permalink raw reply	[flat|nested] 20+ messages in thread
* [PATCH] config/x86: config support for AMD EPYC processors
@ 2023-12-20  7:10 Sivaprasad Tummala
  2023-12-20  7:27 ` Morten Brørup
  0 siblings, 1 reply; 20+ messages in thread
From: Sivaprasad Tummala @ 2023-12-20  7:10 UTC (permalink / raw)
  To: mb, david.marchand, ktraynor, thomas, konstantin.ananyev,
	konstantin.v.ananyev, bruce.richardson, maxime.coquelin, aconole,
	ferruh.yigit
  Cc: dev

On x86 platforms, max lcores are limited to 128 by default.

On AMD EPYC processors, this limit was adjusted for native
builds in the previous patch.
https://patches.dpdk.org/project/dpdk/patch/
20230925151027.558546-1-sivaprasad.tummala@amd.com/

As agreed earlier in mailing list, this patch adjusts the limit
for specific AMD EPYC target/cross builds.

Signed-off-by: Sivaprasad Tummala <sivaprasad.tummala@amd.com>
---
 config/x86/meson.build | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/config/x86/meson.build b/config/x86/meson.build
index 5355731cef..f2df4c2003 100644
--- a/config/x86/meson.build
+++ b/config/x86/meson.build
@@ -91,13 +91,21 @@ epyc_zen_cores = {
     '__znver1__':128
     }
 
-if get_option('platform') == 'native'
+cpu_instruction_set = get_option('cpu_instruction_set')
+if cpu_instruction_set == 'native'
     foreach m:epyc_zen_cores.keys()
         if cc.get_define(m, args: machine_args) != ''
             dpdk_conf.set('RTE_MAX_LCORE', epyc_zen_cores[m])
             break
         endif
     endforeach
+else
+    foreach m:epyc_zen_cores.keys()
+        if m.contains(cpu_instruction_set)
+            dpdk_conf.set('RTE_MAX_LCORE', epyc_zen_cores[m])
+	    break
+        endif
+    endforeach
 endif
 
 dpdk_conf.set('RTE_MAX_NUMA_NODES', 32)
-- 
2.25.1


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

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

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-25 15:10 [PATCH] config/x86: config support for AMD EPYC processors Sivaprasad Tummala
2023-10-06  7:50 ` David Marchand
2023-10-16  5:14   ` Tummala, Sivaprasad
2023-10-16  5:20     ` Tummala, Sivaprasad
2023-10-17  9:45       ` Kevin Traynor
2023-10-17 10:27         ` Morten Brørup
2023-11-06 21:05           ` Thomas Monjalon
2023-11-06 22:17             ` Morten Brørup
2023-11-07 13:13               ` Konstantin Ananyev
2023-11-07 13:30                 ` Morten Brørup
2023-11-07 14:32                   ` Konstantin Ananyev
2023-11-08 12:24                     ` Tummala, Sivaprasad
2023-11-08 13:06                       ` Morten Brørup
2023-11-09 16:43                       ` Konstantin Ananyev
2023-10-17 10:58         ` Ferruh Yigit
2023-11-07 12:59 ` Konstantin Ananyev
2023-11-12 13:48 ` Thomas Monjalon
2023-12-20  7:10 Sivaprasad Tummala
2023-12-20  7:27 ` Morten Brørup
2023-12-20  9:22   ` Tummala, Sivaprasad

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