test suite reviews and discussions
 help / color / Atom feed
* [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes
@ 2020-11-04  9:21 Haiyang Zhao
  2020-11-04  9:21 ` [dts] [PATCH V1 1/3] framework/dts: optimize code Haiyang Zhao
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Haiyang Zhao @ 2020-11-04  9:21 UTC (permalink / raw)
  To: Lijuan.Tu, dts; +Cc: Haiyang Zhao

*.add eal parameters for rx mode novector/sse/avx2/avx512,
  and print warning if DUT cpu do not support avx512 test.

Haiyang Zhao (3):
  framework/dts: optimize code *.save rx_mode with lower case.
  framework/project_dpdk: add check if cpu support avx512 *.add warning
    info and reset rx_mode to default   if DUT cpu do not support
    avx512.
  framework/dut: add eal parameters for different rx_mode *.add eal
    parameters for novector/sse/avx2/avx512.

 framework/dts.py          | 2 +-
 framework/dut.py          | 9 +++++++++
 framework/project_dpdk.py | 9 ++++++++-
 3 files changed, 18 insertions(+), 2 deletions(-)

-- 
2.17.1


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

* [dts] [PATCH V1 1/3] framework/dts: optimize code
  2020-11-04  9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
@ 2020-11-04  9:21 ` Haiyang Zhao
  2020-11-04  9:21 ` [dts] [PATCH V1 2/3] framework/project_dpdk: add check if cpu support avx512 Haiyang Zhao
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Haiyang Zhao @ 2020-11-04  9:21 UTC (permalink / raw)
  To: Lijuan.Tu, dts; +Cc: Haiyang Zhao

*.save rx_mode with lower case.

Signed-off-by: Haiyang Zhao <haiyangx.zhao@intel.com>
---
 framework/dts.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/framework/dts.py b/framework/dts.py
index e4cc53f..8a3790e 100644
--- a/framework/dts.py
+++ b/framework/dts.py
@@ -160,7 +160,7 @@ def dts_parse_config(config, section):
     test_suites = [suite.strip()
                    for suite in config.get(section, 'test_suites').split(',')]
     try:
-        rx_mode = config.get(section, 'rx_mode').strip()
+        rx_mode = config.get(section, 'rx_mode').strip().lower()
     except:
         rx_mode = 'default'
 
-- 
2.17.1


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

* [dts] [PATCH V1 2/3] framework/project_dpdk: add check if cpu support avx512
  2020-11-04  9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
  2020-11-04  9:21 ` [dts] [PATCH V1 1/3] framework/dts: optimize code Haiyang Zhao
@ 2020-11-04  9:21 ` Haiyang Zhao
  2020-11-04  9:21 ` [dts] [PATCH V1 3/3] framework/dut: add eal parameters for different rx_mode Haiyang Zhao
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Haiyang Zhao @ 2020-11-04  9:21 UTC (permalink / raw)
  To: Lijuan.Tu, dts; +Cc: Haiyang Zhao

*.add warning info and reset rx_mode to default
  if DUT cpu do not support avx512.

Signed-off-by: Haiyang Zhao <haiyangx.zhao@intel.com>
---
 framework/project_dpdk.py | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/framework/project_dpdk.py b/framework/project_dpdk.py
index d45ce47..1711d86 100644
--- a/framework/project_dpdk.py
+++ b/framework/project_dpdk.py
@@ -32,7 +32,7 @@
 import os
 import re
 
-from settings import NICS, load_global_setting, accepted_nic
+from settings import NICS, load_global_setting, save_global_setting, accepted_nic
 from settings import DPDK_RXMODE_SETTING, HOST_DRIVER_SETTING, HOST_DRIVER_MODE_SETTING, HOST_BUILD_TYPE_SETTING
 from settings import HOST_SHARED_LIB_SETTING, HOST_SHARED_LIB_PATH
 from ssh_connection import SSHConnection
@@ -41,6 +41,7 @@ from dut import Dut
 from tester import Tester
 from logger import getLogger
 from settings import IXIA, DRIVERS
+from utils import RED
 
 
 class DPDKdut(Dut):
@@ -217,6 +218,12 @@ class DPDKdut(Dut):
             self.set_build_options({'RTE_IXGBE_INC_VECTOR': 'n',
                                     'RTE_LIBRTE_I40E_INC_VECTOR': 'n',
                                     'RTE_LIBRTE_FM10K_INC_VECTOR': 'n'})
+        if mode == 'avx512':
+            out = self.send_expect('lscpu | grep avx512', '#')
+            if 'avx512f' not in out or 'no-avx512f' in out:
+                self.logger.warning(RED('*********The DUT CPU do not support AVX512 test!!!********'))
+                self.logger.warning(RED('*********Now set the rx_mode to default!!!**********'))
+                save_global_setting(DPDK_RXMODE_SETTING, 'default')
 
     def set_package(self, pkg_name="", patch_list=[]):
         self.package = pkg_name
-- 
2.17.1


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

* [dts] [PATCH V1 3/3] framework/dut: add eal parameters for different rx_mode
  2020-11-04  9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
  2020-11-04  9:21 ` [dts] [PATCH V1 1/3] framework/dts: optimize code Haiyang Zhao
  2020-11-04  9:21 ` [dts] [PATCH V1 2/3] framework/project_dpdk: add check if cpu support avx512 Haiyang Zhao
@ 2020-11-04  9:21 ` Haiyang Zhao
  2020-11-04  9:29 ` [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Zhao, HaiyangX
  2020-11-05  2:51 ` Tu, Lijuan
  4 siblings, 0 replies; 6+ messages in thread
From: Haiyang Zhao @ 2020-11-04  9:21 UTC (permalink / raw)
  To: Lijuan.Tu, dts; +Cc: Haiyang Zhao

*.add eal parameters for novector/sse/avx2/avx512.

Signed-off-by: Haiyang Zhao <haiyangx.zhao@intel.com>
---
 framework/dut.py | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/framework/dut.py b/framework/dut.py
index bef0d15..656cb59 100644
--- a/framework/dut.py
+++ b/framework/dut.py
@@ -229,6 +229,15 @@ class Dut(Crb):
         shared_lib_path = settings.load_global_setting(settings.HOST_SHARED_LIB_PATH)
         if use_shared_lib == 'true' and shared_lib_path and 'Virt' not in str(self):
             eal_str = eal_str + ' -d {} '.format(shared_lib_path)
+        rx_mode = settings.load_global_setting(settings.DPDK_RXMODE_SETTING)
+        if rx_mode == 'novector':
+            eal_str = eal_str + ' --force-max-simd-bitwidth=64 '
+        elif rx_mode == 'sse':
+            eal_str = eal_str + ' --force-max-simd-bitwidth=128 '
+        elif rx_mode == 'avx2':
+            eal_str = eal_str + ' --force-max-simd-bitwidth=256 '
+        elif rx_mode == 'avx512':
+            eal_str = eal_str + ' --force-max-simd-bitwidth=512 '
 
         return eal_str
 
-- 
2.17.1


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

* Re: [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes
  2020-11-04  9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
                   ` (2 preceding siblings ...)
  2020-11-04  9:21 ` [dts] [PATCH V1 3/3] framework/dut: add eal parameters for different rx_mode Haiyang Zhao
@ 2020-11-04  9:29 ` Zhao, HaiyangX
  2020-11-05  2:51 ` Tu, Lijuan
  4 siblings, 0 replies; 6+ messages in thread
From: Zhao, HaiyangX @ 2020-11-04  9:29 UTC (permalink / raw)
  To: Tu, Lijuan, dts

[-- Attachment #1: Type: text/plain, Size: 394 bytes --]

Tested-by: Haiyang Zhao <haiyangx.zhao@intel.com>

Best Regards,
Zhao Haiyang

> -----Original Message-----
> From: Haiyang Zhao <haiyangx.zhao@intel.com>
> Sent: Wednesday, November 4, 2020 17:21
> To: Tu, Lijuan <lijuan.tu@intel.com>; dts@dpdk.org
> Cc: Zhao, HaiyangX <haiyangx.zhao@intel.com>
> Subject: [dts][PATCH V1 0/3] framework: add eal paramters for different rx
> modes

[-- Attachment #2: TestChecksumOffload.log --]
[-- Type: application/octet-stream, Size: 30630 bytes --]

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

* Re: [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes
  2020-11-04  9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
                   ` (3 preceding siblings ...)
  2020-11-04  9:29 ` [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Zhao, HaiyangX
@ 2020-11-05  2:51 ` Tu, Lijuan
  4 siblings, 0 replies; 6+ messages in thread
From: Tu, Lijuan @ 2020-11-05  2:51 UTC (permalink / raw)
  To: Zhao, HaiyangX, dts; +Cc: Zhao, HaiyangX

> *.add eal parameters for rx mode novector/sse/avx2/avx512,
>   and print warning if DUT cpu do not support avx512 test.
> 
> Haiyang Zhao (3):
>   framework/dts: optimize code *.save rx_mode with lower case.
>   framework/project_dpdk: add check if cpu support avx512 *.add warning
>     info and reset rx_mode to default   if DUT cpu do not support
>     avx512.
>   framework/dut: add eal parameters for different rx_mode *.add eal
>     parameters for novector/sse/avx2/avx512.
> 
>  framework/dts.py          | 2 +-
>  framework/dut.py          | 9 +++++++++
>  framework/project_dpdk.py | 9 ++++++++-
>  3 files changed, 18 insertions(+), 2 deletions(-)
> 
Applied


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

end of thread, back to index

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-04  9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
2020-11-04  9:21 ` [dts] [PATCH V1 1/3] framework/dts: optimize code Haiyang Zhao
2020-11-04  9:21 ` [dts] [PATCH V1 2/3] framework/project_dpdk: add check if cpu support avx512 Haiyang Zhao
2020-11-04  9:21 ` [dts] [PATCH V1 3/3] framework/dut: add eal parameters for different rx_mode Haiyang Zhao
2020-11-04  9:29 ` [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Zhao, HaiyangX
2020-11-05  2:51 ` Tu, Lijuan

test suite reviews and discussions

Archives are clonable:
	git clone --mirror http://inbox.dpdk.org/dts/0 dts/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dts dts/ http://inbox.dpdk.org/dts \
		dts@dpdk.org
	public-inbox-index dts


Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dts


AGPL code for this site: git clone https://public-inbox.org/ public-inbox