From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 94990A0542; Thu, 13 Feb 2020 02:19:40 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8BF235B3C; Thu, 13 Feb 2020 02:19:40 +0100 (CET) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 233402BFA for ; Thu, 13 Feb 2020 02:19:38 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Feb 2020 17:19:37 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,434,1574150400"; d="scan'208";a="313578974" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga001.jf.intel.com with ESMTP; 12 Feb 2020 17:19:37 -0800 Received: from fmsmsx116.amr.corp.intel.com (10.18.116.20) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 12 Feb 2020 17:19:37 -0800 Received: from shsmsx105.ccr.corp.intel.com (10.239.4.158) by fmsmsx116.amr.corp.intel.com (10.18.116.20) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 12 Feb 2020 17:19:37 -0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.222]) by SHSMSX105.ccr.corp.intel.com ([169.254.11.138]) with mapi id 14.03.0439.000; Thu, 13 Feb 2020 09:19:35 +0800 From: "Tu, Lijuan" To: "Ma, LihongX" , "dts@dpdk.org" CC: "Ma, LihongX" Thread-Topic: [dts] [PATCH V1] tests/unit_tests_pmd_perf: modify app cmd according to dpdk change Thread-Index: AQHV4XdZP71LCnK21EWLmAKa8b9+W6gYVFsQ Date: Thu, 13 Feb 2020 01:19:35 +0000 Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BBC670B@SHSMSX101.ccr.corp.intel.com> References: <1581493388-86904-1-git-send-email-lihongx.ma@intel.com> In-Reply-To: <1581493388-86904-1-git-send-email-lihongx.ma@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dts] [PATCH V1] tests/unit_tests_pmd_perf: modify app cmd according to dpdk change X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" Applied, thanks > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of malihong > Sent: Wednesday, February 12, 2020 3:43 PM > To: dts@dpdk.org > Cc: Ma, LihongX > Subject: [dts] [PATCH V1] tests/unit_tests_pmd_perf: modify app cmd > according to dpdk change >=20 > Signed-off-by: malihong > --- > tests/TestSuite_unit_tests_pmd_perf.py | 29 +++++++------------------- > 1 file changed, 7 insertions(+), 22 deletions(-) >=20 > diff --git a/tests/TestSuite_unit_tests_pmd_perf.py > b/tests/TestSuite_unit_tests_pmd_perf.py > index 6ecd993..2c932bb 100644 > --- a/tests/TestSuite_unit_tests_pmd_perf.py > +++ b/tests/TestSuite_unit_tests_pmd_perf.py > @@ -85,29 +85,14 @@ class TestUnitTestsPmdPerf(TestCase): > """ > pass >=20 > - def get_core_from_socket(self): > - """ > - select the port and lcores from same socket. > - """ > - > - out =3D self.dut.send_expect("./usertools/cpu_layout.py", "#", 10= ) > - k =3D re.search("Core 0 (.*)", out) > - socket_id =3D self.dut.ports_info[0]['port'].socket > - if socket_id =3D=3D 0 or socket_id =3D=3D -1: > - result =3D re.findall("(\d+)", k.group()) > - return int(result[0]) > - else: > - result =3D re.findall("(\d+),", k.group()) > - return int(result[1]) > - > def test_pmd_burst(self): > """ > Run pmd stream control mode burst test case. > """ >=20 > - self.core =3D self.get_core_from_socket() > - eal_params =3D self.dut.create_eal_parameters() > - self.dut.send_expect("./app/test/test %s --lcores=3D'%d-%d'" % > (eal_params,self.core, self.core + 1), "R.*T.*E.*>.*>", 60) > + socket_id =3D self.dut.ports_info[0]['port'].socket > + eal_params =3D self.dut.create_eal_parameters(socket=3Dsocket_id= ) > + self.dut.send_expect("./app/test/test %s" % (eal_params), > + "R.*T.*E.*>.*>", 60) > for mode in self.burst_ctlmodes: > self.dut.send_expect("set_rxtx_sc %s" % mode, "RTE>>", 10) > out =3D self.dut.send_expect("pmd_perf_autotest", "RTE>>", 1= 20) @@ - > 124,18 +109,18 @@ class TestUnitTestsPmdPerf(TestCase): > Run pmd stream control mode continues test case. > """ >=20 > - self.core =3D self.get_core_from_socket() > self.table_header =3D ['Mode'] > self.table_header +=3D self.anchors > self.result_table_create(self.table_header) > - eal_params =3D self.dut.create_eal_parameters() > + socket_id =3D self.dut.ports_info[0]['port'].socket > + eal_params =3D self.dut.create_eal_parameters(socket=3Dsocket_id= ) > print((self.table_header)) >=20 > for mode in self.rxtx_modes: > if mode is "scalar": > - self.dut.send_expect("./app/test/test_scalar %s --lcores= =3D'%d-%d'" % > (eal_params,self.core, self.core + 1), "R.*T.*E.*>.*>", 60) > + self.dut.send_expect("./app/test/test_scalar %s " % > + (eal_params), "R.*T.*E.*>.*>", 60) > else: > - self.dut.send_expect("./app/test/test %s --lcores=3D'%d-= %d'" % > (eal_params,self.core, self.core + 1), "R.*T.*E.*>.*>", 60) > + self.dut.send_expect("./app/test/test %s " % > + (eal_params), "R.*T.*E.*>.*>", 60) >=20 > table_row =3D [mode] > self.dut.send_expect("set_rxtx_sc continuous", "RTE>>", 10) > -- > 2.17.2