[PATCH] config/x86: config support for AMD EPYC processors
Sivaprasad Tummala
sivaprasad.tummala at amd.com
Mon Sep 25 17:10:27 CEST 2023
From: Sivaprasad Tummala <Sivaprasad.Tummala at 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 at 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
More information about the dev
mailing list