From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on0084.outbound.protection.outlook.com [104.47.33.84]) by dpdk.org (Postfix) with ESMTP id BC2BEFB45 for ; Fri, 3 Mar 2017 18:31:19 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=tl8P7lzTVlzfoJgQxAKCbXBjYAPJy5MnzRvI6G7hEgE=; b=ay+elRtapRqUr27s8ydbho6jwMHN9cLTWMcS3wevMmFwf/MuWEWkqfuDP9gaAr14IhJepGLBPAgz925Z8JvH1f7k442P4NDYfmgwZiEO5AdwFXT2SIkiy3y+dw1EPOcHNbk1I5C+Np4U35uAGWtQ+i6ClX58Z8mlpsxzQBbdULo= Authentication-Results: dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=none action=none header.from=caviumnetworks.com; Received: from localhost.localdomain.localdomain (14.140.2.178) by BN3PR0701MB1719.namprd07.prod.outlook.com (10.163.39.18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.933.12; Fri, 3 Mar 2017 17:31:15 +0000 From: Jerin Jacob To: dev@dpdk.org Cc: thomas.monjalon@6wind.com, bruce.richardson@intel.com, harry.van.haaren@intel.com, hemant.agrawal@nxp.com, gage.eads@intel.com, nipun.gupta@nxp.com, santosh.shukla@caviumnetworks.com, Jerin Jacob Date: Fri, 3 Mar 2017 22:58:17 +0530 Message-Id: <1488562101-6658-36-git-send-email-jerin.jacob@caviumnetworks.com> X-Mailer: git-send-email 2.5.5 In-Reply-To: <1488562101-6658-1-git-send-email-jerin.jacob@caviumnetworks.com> References: <1488562101-6658-1-git-send-email-jerin.jacob@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.140.2.178] X-ClientProxiedBy: BMXPR01CA0021.INDPRD01.PROD.OUTLOOK.COM (10.174.214.159) To BN3PR0701MB1719.namprd07.prod.outlook.com (10.163.39.18) X-MS-Office365-Filtering-Correlation-Id: a22caa06-3e16-4f93-f8f8-08d4625b1a16 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:BN3PR0701MB1719; X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1719; 3:ErJOQ6EmytHnv6pCFR9YdbB/Wa6Gpo0gzItJfvLo2jElVYYU18PS5bl9fbsHPHULaejtKYOrCKDCjXZBWpFmhu5QIRPi5H2BBoNKrXrM6ln/JOK1iHxn192Q4nOoHPN2ybonVnbyjiym6hvL0N78kvMuyysrQcBQLutpRiBI324zQwv/BBObEKGN2oKMVSLic9OeK0in+sQfpt+BJopTYqnIlJAEsmTcOPZtF08yRbF7icgFxbu42XoWTyPoxCDqAQxLV0cBAA6SDoh31UETWA==; 25:yG8zse79QnZGiCWKk2vLz6IC44HGRWEJ9UEd0ontPNX3JU8qo9+SjMBEGI9eySP5JLSYYvRwkqDHBxzQQ4wixAhQRWwxPtz2E75sxP9L/2SRBwqqmB45UNyh/xQFpNlWakiGa3u7rJP8rUDrITbQZwEw8xTfH5eTtxnd9T51vDVLIQ5Yd8SfslNE7zBU2BPHjBYfXykq3lat34+M6x95WYbbQUL7sGDkAPiQ00fdIsnHu58p0HoRwXQ8nOkj0vlHabp8kWsjAyeDvXVGvxWIJBuFg8l4zwGsMFYdJmm4ruh63hVwiA3mQNBqFdcKJBb+3mxwNnd00/eREfJLDiuY8v8qX1hOl9SldxIVKkk20pzKwJ8Dpt4XQpph3GabFCp/QDdq0pPcCZnLnI9CWyp+OriX5R7afNZSPB9PA6Y+z4bk+7DIzODKL2qjom/Iudb0yhaT2c8WMzCjIr30kfPRMQ== X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1719; 31:nZbO4PhKlFAepOmZVnimlfVy02JeJLQlsEOKEMVEDNapNM9w3Op3ReEZPwx6owfhrFweBrBR2U3fwMQAx20n9DlHkDCzvi7NppalM9c3Y3UbBLyv29/JAr7jcH9dwE/m/G58JXgppLfezh76rrn6HYtdWdGEj8tn0tFU/Ji8GRbul19PlgxaB1Gs70qd1vztlS8/0NkCAdU3s157N1kfhHEvqJ1olutcHdaWRaB3odZb1tNrxGyf2i77YgDf1Obz; 20:ZSmwjmYnyxXX6Ka6r4GmDnBcMzLrUt+Jn71Zr65La9j0SYTR3LoOW556g+qlSyt6bAso7yMyh1uTGoqIJx6H9P81Nw3Y0gFaG2TFsPC0dV2uESv+srBVa1P3PIeAc2LLGbmtZcZ14hCh3oNHpAWIv17AGcMf8pYGLnqBE40INiGXMv/3gF3Uuh4LG6fibu/R599tCwD7lJprPBdtig2gBRFqfB4+KzcLFrY7+OEsfAIz+JoTgkXOrxbtMECH0cMAdWEsd6cNMOSXHsvY7Hp9iYnwH6dcXAASP1qnElVImOokO4b3LJO5odK9bYHcDX4jlZVC8Viqxc0uFDaw/IYBALQIZnHhWC2Tv0cUxJnVGBiOkgPWW/ZV9ff6LVxOK4Fwjjc2HzahcTWflRM39h2V6uMMaXYlEqB2pmIiF/qhEZkVwPJiDonsGgj4VxsPP0MwAG9vg1kfwKgvA8WWX2nbPQlYf9hS6iuJs3r515ewsnx0nWbiC4WDcyk21mnR4bHcdu9Q+puslXn4P7wXFDt1ydwGPrXcCB1sDwKr+Hwq3iyhUMEqS2kVmhghfwyCOkiID6cw7L3DeeTdOt6DkBYmZZ/ba+mSWgdHYPo+mjPurSo= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001)(6041248)(20161123555025)(20161123560025)(20161123562025)(20161123558025)(20161123564025)(6072148); SRVR:BN3PR0701MB1719; BCL:0; PCL:0; RULEID:; SRVR:BN3PR0701MB1719; X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1719; 4:dbKUIVAFJlfzdCMchNk3zId2Tv7U9Ou7Ii93VCUOwczt2vSXiQOgeH7q5fiMme7DZp+b2fyiAGieVSXyTG18XhyEgEMnBW3247W645aISqJs0084FGrkF2vcAcKApUPzKMcN9XjMlION39EX55SQfincNadc6yiDk3MH3YSNQO9SZ5yLrLr6mmwDf+LzPttNcIWdtXc9lnhG6fcKpBcjePqlEKk05Cn4ES3Us5ZNAkUwJU1eHRVBoq+AiXvcz+974vxLHqCDq5gJyV9Wz635SuM8gd3g7727o0e8llS+yjO+UTLFqhjPq7NiJZ00ym0F403jt7quIoGupyk3dZCssdUnqF2mLcPh6r1CACHK6p6ausvzJ9813/kANoVIIruToGN8Pjhh4Q2fPCcUai5rVKLkflCmcrvnHKIyxdtQ4BRnRGvToLnljwoc2nMi9kiC+nUhdxLv5lBlarmptC0wN2ftWODj6XPrkSjDgmj4EyHxZGrO9PXUoLvLhB4tHqX3T+lYy63L+CUjYJVHGi7jckJt7vuFHs7AuCPBSFrV38A5ELZ+iqpPpFWRbN2F5kPjhmSrkuKTAl7IKUw0oCvk8RhzO64QBh3sFxT/8o91Nak= X-Forefront-PRVS: 0235CBE7D0 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6069001)(6009001)(7916002)(39450400003)(3846002)(50986999)(6116002)(36756003)(81166006)(6512007)(97736004)(2361001)(2351001)(6506006)(5660300001)(42186005)(50226002)(8676002)(106356001)(8656002)(2950100002)(2906002)(25786008)(47776003)(6486002)(76176999)(33646002)(7736002)(107886003)(42882006)(66066001)(110136004)(4326008)(38730400002)(6916009)(305945005)(48376002)(92566002)(5009440100003)(5003940100001)(50466002)(189998001)(53936002)(7099028)(110426004); DIR:OUT; SFP:1101; SCL:1; SRVR:BN3PR0701MB1719; H:localhost.localdomain.localdomain; FPR:; SPF:None; MLV:nov; PTR:InfoNoRecords; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; B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ticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1719; 7:ZAOtmeLQ0fFW3Hcw5k0aRytJ3fGAtmK80rbEHHlE6+klqu9o3KHXWvaXPZYh0Qj6uMux0K+otF/p89XeVazWLwft+Ciq9xzpFpuLAej34OZJgpMsju433SsHI2NA3NrLHjGOgtLxMn4GLh23FmHsTQM+vRfKvVooreTpSsV+l+Q/PVbJDwOUvhKD56DXkEGntdzhbva0LSDllhIQoXv5jqk0CV8ziH50dWpBL7C6Cz40QVbKGDlZK4CizlBH6MwvRFvF+cROEvPE+f5wPigXQkMKY2HcjxBWH6FvScsv1k9pbQUbUamMMg1Z+FqWlVNnfxnzwaXw3d+iqEONx7ynrw== X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Mar 2017 17:31:15.0340 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3PR0701MB1719 Subject: [dpdk-dev] [PATCH 35/39] app/test: octeontx queue based maximum stage pipeline X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Mar 2017 17:31:20 -0000 Add queue based pipeline test with maximum number of stages available in the device. Signed-off-by: Jerin Jacob --- app/test/test_eventdev_octeontx.c | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/app/test/test_eventdev_octeontx.c b/app/test/test_eventdev_octeontx.c index da1da62..f477bf2 100644 --- a/app/test/test_eventdev_octeontx.c +++ b/app/test/test_eventdev_octeontx.c @@ -1171,6 +1171,43 @@ test_multi_port_flow_max_stages_random_sched_type(void) worker_flow_based_pipeline_max_stages_rand_sched_type); } +static int +worker_queue_based_pipeline_max_stages_rand_sched_type(void *arg) +{ + struct test_core_param *param = arg; + struct rte_event ev; + uint16_t valid_event; + uint8_t port = param->port; + uint8_t nr_queues = rte_event_queue_count(evdev); + rte_atomic32_t *total_events = param->total_events; + + while (rte_atomic32_read(total_events) > 0) { + valid_event = rte_event_dequeue_burst(evdev, port, &ev, 1, 0); + if (!valid_event) + continue; + + if (ev.queue_id == nr_queues - 1) { /* last stage */ + rte_pktmbuf_free(ev.mbuf); + rte_atomic32_sub(total_events, 1); + } else { + ev.event_type = RTE_EVENT_TYPE_CPU; + ev.queue_id++; + ev.sched_type = + rte_rand() % (RTE_SCHED_TYPE_PARALLEL + 1); + ev.op = RTE_EVENT_OP_FORWARD; + rte_event_enqueue_burst(evdev, port, &ev, 1); + } + } + return 0; +} + +/* Queue based pipeline with maximum stages with random sched type */ +static int +test_multi_port_queue_max_stages_random_sched_type(void) +{ + return launch_multi_port_max_stages_random_sched_type( + worker_queue_based_pipeline_max_stages_rand_sched_type); +} static struct unit_test_suite eventdev_octeontx_testsuite = { .suite_name = "eventdev octeontx unit test suite", .setup = testsuite_setup, @@ -1230,6 +1267,8 @@ static struct unit_test_suite eventdev_octeontx_testsuite = { test_multi_port_queue_parallel_to_parallel), TEST_CASE_ST(eventdev_setup, eventdev_teardown, test_multi_port_flow_max_stages_random_sched_type), + TEST_CASE_ST(eventdev_setup, eventdev_teardown, + test_multi_port_queue_max_stages_random_sched_type), TEST_CASES_END() /**< NULL terminate unit test array */ } }; -- 2.5.5