From: Ondrej Lichtner <olichtne(a)redhat.com>
Adding the same changes that were made on the master branch to the
original ovs_dpdk_pvp.xml recipe to significantly improve the stability
of measured results. This includes:
* fixing use of hugepages by the guest
* setting hugepages as memory backing
* increasing the number of hugepages on host2 to enable full memory
backing of the guest RAM
* configuring pmd coremask of testpmd in the guest - this tells which
cpus should the testpmd process use for pmd threads that handle NICs
Signed-off-by: Ondrej Lichtner <olichtne(a)redhat.com>
---
lnst/Recipes/ENRT/OvS_DPDK_PvP.py | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/lnst/Recipes/ENRT/OvS_DPDK_PvP.py b/lnst/Recipes/ENRT/OvS_DPDK_PvP.py
index 1f963f6..860f060 100644
--- a/lnst/Recipes/ENRT/OvS_DPDK_PvP.py
+++ b/lnst/Recipes/ENRT/OvS_DPDK_PvP.py
@@ -60,12 +60,13 @@ class OvSDPDKPvPRecipe(PingTestAndEvaluate, PerfTestAndEvaluate):
guest_cpus = StrParam(mandatory=True)
guest_emulatorpin_cpu = StrParam(mandatory=True)
guest_dpdk_cores = StrParam(mandatory=True)
+ guest_testpmd_cores = StrParam(mandatory=True)
guest_mem_size = IntParam(default=16777216)
host1_dpdk_cores = StrParam(mandatory=True)
host2_pmd_cores = StrParam(mandatory=True)
host2_l_cores = StrParam(mandatory=True)
- nr_hugepages = IntParam(default=2048)
+ nr_hugepages = IntParam(default=13000)
socket_mem = IntParam(default=2048)
dev_intr_cpu = IntParam(default=0)
@@ -164,7 +165,8 @@ class OvSDPDKPvPRecipe(PingTestAndEvaluate, PerfTestAndEvaluate):
config.guest.testpmd = guest.run(
TestPMD(
- coremask=self.params.guest_dpdk_cores,
+ coremask=self.params.guest_testpmd_cores,
+ pmd_coremask=self.params.guest_dpdk_cores,
nics=[nic.bus_info for nic in config.guest.nics],
peer_macs=[nic.hwaddr for nic in config.generator.nics]),
bg=True)
@@ -318,6 +320,10 @@ class OvSDPDKPvPRecipe(PingTestAndEvaluate, PerfTestAndEvaluate):
"emulatorpin",
cpuset=str(self.params.guest_emulatorpin_cpu))
+ memoryBacking = ET.SubElement(guest_xml, "memoryBacking")
+ hugepages = ET.SubElement(memoryBacking, "hugepages")
+ ET.SubElement(hugepages, "page", size="2",
unit="M", nodeset="0")
+
return guest_xml
def ovs_dpdk_bridge_vm_configuration(self, host_conf, guest_conf):
--
2.19.1