From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0069.outbound.protection.outlook.com [104.47.38.69]) by dpdk.org (Postfix) with ESMTP id 9E8C57CE7 for ; Thu, 7 Dec 2017 21:39: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=/Mc5s6yHOwOhk57yuye6q9u7hsS7PuDVtY0Hh5vaqi8=; b=gKJI7IcxGnJ9LkaLrTFhhdXPAWG1ZcBE8PF97/JWQytzxab4MnM+GlKhSaQXulQSqtarEsIUNc4eSJUcY93teW9V+Bs0DtGSlEB+DR6Su869Y5Kj5sEH/nyVvO0cBTJlZTnJpKeVVT6SZzWshyy6iw3DuKNxzAp+Am5MR6JRHyM= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from localhost.localdomain (111.93.218.67) by DM5PR07MB3468.namprd07.prod.outlook.com (10.164.153.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.282.5; Thu, 7 Dec 2017 20:39:09 +0000 From: Pavan Nikhilesh To: gage.eads@intel.com, jerin.jacobkollanukkaran@cavium.com, harry.van.haaren@intel.com, nikhil.rao@intel.com, hemant.agrawal@nxp.com, liang.j.ma@intel.com Cc: dev@dpdk.org, Pavan Nikhilesh Date: Fri, 8 Dec 2017 02:07:01 +0530 Message-Id: <20171207203705.25020-10-pbhagavatula@caviumnetworks.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20171207203705.25020-1-pbhagavatula@caviumnetworks.com> References: <20171207203705.25020-1-pbhagavatula@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: PS1PR0601CA0101.apcprd06.prod.outlook.com (10.170.176.155) To DM5PR07MB3468.namprd07.prod.outlook.com (10.164.153.23) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e0660907-2c64-4c4b-e911-08d53db2958a X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(5600026)(4604075)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(2017052603304); SRVR:DM5PR07MB3468; X-Microsoft-Exchange-Diagnostics: 1; DM5PR07MB3468; 3:Vh67IAk4aGVPlteJM4LBFLwM7SPWHrXE4NuYinsM0NXBJq0uz27FbY5r8FSeadUKt5GaI0fthSWu4HI1+7e04XDohS9BnewZr2GL81HmWnFOYovPzvn+A02cgMfNpBMXeDYiAPLL/GnwU1F0VZIomkW+/ITtau4j1dYVvWGOcwFPjOHwBv9oNY3q7EXKEhBjJ+Uo6gvBQXb3M38NTi1uiLZrkmk6NTFnverHjJ3HTltuCybsMXOJ2Pd1N5vyZLF4; 25:1a8zXW7yAktiIVGtYPYDUFfk4tiRlmiIy697maV7inJWnfEmNgvzcsYi4lWtQ2LFKA1oK+ETXXeIuLXmLUet9KdLTvHoGEdAvNXeM9EB9HNiLdhhRXWDU7K6KjRq2UzI8yaEbXbUYVf1dXFfrAeqDBhBHq8gP2rYl1xT+kyEt8966BhkvK6BL8jMu7nQmhuA368Rm4Vhx1kcroS9MernoBvXnPHbWqse+F6oGeY2W8Y5P2w9E3h+xA2zTqcd3W9wOjFiE2Ir/oTzKQNfmAU6l9OLZn8Poj6rfIGd/ANF8a1aIu6dm5tSoxAtPgXU3sg4tQ5ySOOOiVFehgxEU8n38w==; 31:M0h29vkQUbN7cXVfP07I3vg8tQy1MP5uzCxU8RiF7KQaHAmNhGZeXWE746FqCBZzgAVtYLhqVcYHJrud7X+S2748D7Mixek18ZI5rzub/PWAvNDG4XnPUxerCjrx5h+av246VkmbAA31SbCpDlQqgROTOU85JPPQSC5gMruAFeRDDZ36rtSauvc21n05NZl0FGHqHyvhCRrCIoSPPpOkSxG0rt6afGutE0Ubp3vD2Rk= X-MS-TrafficTypeDiagnostic: DM5PR07MB3468: X-Microsoft-Exchange-Diagnostics: 1; DM5PR07MB3468; 20:uDj6kFbF2ZsHY3TQJGZheOQk81vs6ZWBedIByoouavUU0D+C6N0YS0zoxvZJWS9zbmHyfY8CXlegMjfEVdf8TfFpEuvXdcBHPtt168NF9BuNnwGjS0eTdjpCyGJ8ayQT9NBTtDXMGJ1/P0XO6iADESE8lTlBJOX7CXOOaeRzrKhSKxNPLxNWigPaEFSF1be8fFkB4mdtf4Btx4vDXh2DLK4Ygtl3Dl1SR77Xyovc1bYXCQE6VC+TdF40N3zf5N+iQsggBMKTbbWadOMeKO1HLNbAya23hEEd2YzoaumgsaWHlLxZBJEjnuiD+nQGpKzr0YQ/qWThz9qKOZqnyBkSwIij+Yujo40DRf/v1eOnrL+dcRfub2bIubcxIxxV2kaIarkhf1vGGowtOGbTTNl911tsg5AtHCyEEpTPdEkK/TufYBo2XLz3Yczff0lostzR/OI5oE185pRk0RtOxiKmngaYOjISS4CzDkomjGRFsX548XK7abYkpQMqyZUzybnaUF57Lf/4hiP0KPvFhWREKtu5/XmDzJK5ecRtY7LIeUsnWj7SOISheANI6BcwUTKy/2ZOcJCMzk0ImDfskAMGnVHyf9JnRpLw+jHMf6hh8Bk=; 4:TYxMGJsOntpN0rkdusaG5GMnguDyj4DR20f02JRI0uakdJrrzBfHoouOmvDMimHRNKbVlWxVDXq0sL/JzS6GUv39vOWzh/WBVJxw4qo7oRJSJu1Pf+uAax7WppUy6m48Xe9DQ6mZCRXagibw5VdxxA6w4ywsPCQoyDnvLH8OJMwZ9PJAajioycJWJrN2g5CrG+aygbpj0HfMeFFKbB+tri3qCTBq6Yn1unaKVy2EujUYs9BtQK7YJHlOZqy6s3N5uaymR5yvMtzD7DpWxn5ocw== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(2401047)(5005006)(8121501046)(93006095)(3002001)(10201501046)(3231022)(6041248)(20161123560025)(20161123564025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123558100)(20161123555025)(6072148)(201708071742011); SRVR:DM5PR07MB3468; BCL:0; PCL:0; RULEID:(100000803101)(100110400095); SRVR:DM5PR07MB3468; X-Forefront-PRVS: 05143A8241 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(979002)(6069001)(376002)(366004)(346002)(199004)(189003)(6666003)(8676002)(2950100002)(42882006)(2906002)(50226002)(5009440100003)(305945005)(81156014)(8936002)(97736004)(5660300001)(101416001)(33646002)(478600001)(7736002)(81166006)(68736007)(107886003)(4326008)(25786009)(16526018)(50466002)(16586007)(48376002)(106356001)(6506006)(6486002)(6116002)(105586002)(3846002)(51416003)(76176011)(47776003)(72206003)(52116002)(8656006)(316002)(66066001)(1076002)(53936002)(6512007)(36756003)(42262002)(969003)(989001)(999001)(1009001)(1019001); DIR:OUT; SFP:1101; SCL:1; SRVR:DM5PR07MB3468; H:localhost.localdomain; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM5PR07MB3468; 23:9pN4PG1s8xZHGKDGHfzO0MvtR73diep8h932NpEVY?= =?us-ascii?Q?MeWbQvBpdqMsD+mXnME4TgZTylmxmnE2ZpqdeZQiK0H9iQetsxj3BeH2m/Vp?= =?us-ascii?Q?LVm9nd9Ibd7UsyzZ/EenyjaaMUXpYlohWAMTyvocYCQP++x8Ir5z/ZNQuvs8?= =?us-ascii?Q?SMLDmGk7oEeQlHKx1U09npmqxgcEYbOurkenuviu87DFJDYtRmOp0Ls7A4yI?= =?us-ascii?Q?YE6CK0Q9IHVtWdIMWDxXo7nffNRjo61aGVw/Ob8xYDTNanPsTi040E45/0Ze?= =?us-ascii?Q?+bQwYXmmES9Aa73WG6y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 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Dec 2017 20:39:09.4549 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: e0660907-2c64-4c4b-e911-08d53db2958a X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR07MB3468 Subject: [dpdk-dev] [PATCH 09/13] examples/eventdev: add all type queue option 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: Thu, 07 Dec 2017 20:39:20 -0000 Added configurable option to make queue type as all type queues i.e. RTE_EVENT_QUEUE_CFG_ALL_TYPES based on event dev capability RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES. This can be enabled by supplying '-a' as a cmdline argument. Signed-off-by: Pavan Nikhilesh --- examples/eventdev_pipeline_sw_pmd/main.c | 7 +- .../eventdev_pipeline_sw_pmd/pipeline_common.h | 1 + .../pipeline_worker_generic.c | 5 + .../eventdev_pipeline_sw_pmd/pipeline_worker_tx.c | 134 +++++++++++++++++++-- 4 files changed, 139 insertions(+), 8 deletions(-) diff --git a/examples/eventdev_pipeline_sw_pmd/main.c b/examples/eventdev_pipeline_sw_pmd/main.c index 3be981c15..289f7204d 100644 --- a/examples/eventdev_pipeline_sw_pmd/main.c +++ b/examples/eventdev_pipeline_sw_pmd/main.c @@ -149,6 +149,7 @@ static struct option long_options[] = { {"parallel", no_argument, 0, 'p'}, {"ordered", no_argument, 0, 'o'}, {"quiet", no_argument, 0, 'q'}, + {"use-atq", no_argument, 0, 'a'}, {"dump", no_argument, 0, 'D'}, {0, 0, 0, 0} }; @@ -172,6 +173,7 @@ usage(void) " -o, --ordered Use ordered scheduling\n" " -p, --parallel Use parallel scheduling\n" " -q, --quiet Minimize printed output\n" + " -a, --use-atq Use all type queues\n" " -D, --dump Print detailed statistics before exit" "\n"; fprintf(stderr, "%s", usage_str); @@ -192,7 +194,7 @@ parse_app_args(int argc, char **argv) int i; for (;;) { - c = getopt_long(argc, argv, "r:t:e:c:w:n:f:s:poPqDW:", + c = getopt_long(argc, argv, "r:t:e:c:w:n:f:s:paoPqDW:", long_options, &option_index); if (c == -1) break; @@ -225,6 +227,9 @@ parse_app_args(int argc, char **argv) case 'p': cdata.queue_type = RTE_SCHED_TYPE_PARALLEL; break; + case 'a': + cdata.all_type_queues = 1; + break; case 'q': cdata.quiet = 1; break; diff --git a/examples/eventdev_pipeline_sw_pmd/pipeline_common.h b/examples/eventdev_pipeline_sw_pmd/pipeline_common.h index 0b27d1eb0..62755f6d0 100644 --- a/examples/eventdev_pipeline_sw_pmd/pipeline_common.h +++ b/examples/eventdev_pipeline_sw_pmd/pipeline_common.h @@ -106,6 +106,7 @@ struct config_data { int quiet; int dump_dev; int dump_dev_signal; + int all_type_queues; unsigned int num_stages; unsigned int worker_cq_depth; unsigned int rx_stride; diff --git a/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c b/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c index 5998aae95..908d64c87 100644 --- a/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c +++ b/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c @@ -525,6 +525,11 @@ generic_opt_check(void) memset(&eventdev_info, 0, sizeof(struct rte_event_dev_info)); rte_event_dev_info_get(0, &eventdev_info); + if (cdata.all_type_queues && !(eventdev_info.event_dev_cap & + RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES)) + rte_exit(EXIT_FAILURE, + "Event dev doesn't support all type queues\n"); + for (i = 0; i < rte_eth_dev_count(); i++) { ret = rte_event_eth_rx_adapter_caps_get(0, i, &cap); if (ret) diff --git a/examples/eventdev_pipeline_sw_pmd/pipeline_worker_tx.c b/examples/eventdev_pipeline_sw_pmd/pipeline_worker_tx.c index a824f1f49..e25a06027 100644 --- a/examples/eventdev_pipeline_sw_pmd/pipeline_worker_tx.c +++ b/examples/eventdev_pipeline_sw_pmd/pipeline_worker_tx.c @@ -119,6 +119,51 @@ worker_do_tx(void *arg) return 0; } +static int +worker_do_tx_atq(void *arg) +{ + struct rte_event ev; + + struct worker_data *data = (struct worker_data *)arg; + const uint8_t dev = data->dev_id; + const uint8_t port = data->port_id; + const uint8_t lst_qid = cdata.num_stages - 1; + size_t fwd = 0, received = 0, tx = 0; + + while (!fdata->done) { + + if (!rte_event_dequeue_burst(dev, port, &ev, 1, 0)) { + rte_pause(); + continue; + } + + received++; + const uint8_t cq_id = ev.queue_id % cdata.num_stages; + + if (cq_id == lst_qid) { + if (ev.sched_type == RTE_SCHED_TYPE_ATOMIC) { + worker_tx_pkt(ev.mbuf); + tx++; + continue; + } + worker_fwd_event(&ev, RTE_SCHED_TYPE_ATOMIC); + } else { + ev.queue_id = cdata.next_qid[ev.queue_id]; + worker_fwd_event(&ev, cdata.queue_type); + } + work(ev.mbuf); + + worker_event_enqueue(dev, port, &ev); + fwd++; + } + + if (!cdata.quiet) + printf(" worker %u thread done. RX=%zu FWD=%zu TX=%zu\n", + rte_lcore_id(), received, fwd, tx); + + return 0; +} + static int worker_do_tx_burst(void *arg) { @@ -178,6 +223,61 @@ worker_do_tx_burst(void *arg) return 0; } +static int +worker_do_tx_burst_atq(void *arg) +{ + struct rte_event ev[BATCH_SIZE]; + + struct worker_data *data = (struct worker_data *)arg; + uint8_t dev = data->dev_id; + uint8_t port = data->port_id; + uint8_t lst_qid = cdata.num_stages - 1; + size_t fwd = 0, received = 0, tx = 0; + + while (!fdata->done) { + uint16_t i; + + const uint16_t nb_rx = rte_event_dequeue_burst(dev, port, + ev, BATCH_SIZE, 0); + + if (nb_rx == 0) { + rte_pause(); + continue; + } + received += nb_rx; + + for (i = 0; i < nb_rx; i++) { + const uint8_t cq_id = ev[i].queue_id % cdata.num_stages; + + if (cq_id == lst_qid) { + if (ev[i].sched_type == + RTE_SCHED_TYPE_ATOMIC) { + worker_tx_pkt(ev[i].mbuf); + tx++; + ev[i].op = RTE_EVENT_OP_RELEASE; + continue; + } + worker_fwd_event(&ev[i], + RTE_SCHED_TYPE_ATOMIC); + } else { + ev[i].queue_id = cdata.next_qid[ + ev[i].queue_id]; + worker_fwd_event(&ev[i], + cdata.queue_type); + } + } + + worker_event_enqueue_burst(dev, port, ev, nb_rx); + fwd += nb_rx; + } + + if (!cdata.quiet) + printf(" worker %u thread done. RX=%zu FWD=%zu TX=%zu\n", + rte_lcore_id(), received, fwd, tx); + + return 0; +} + static int setup_eventdev_w(struct prod_data *prod_data, struct cons_data *cons_data, @@ -186,10 +286,12 @@ setup_eventdev_w(struct prod_data *prod_data, RTE_SET_USED(prod_data); RTE_SET_USED(cons_data); uint8_t i; + const uint8_t atq = cdata.all_type_queues ? 1 : 0; const uint8_t dev_id = 0; const uint8_t nb_ports = cdata.num_workers; uint8_t nb_slots = 0; uint8_t nb_queues = rte_eth_dev_count() * cdata.num_stages; + nb_queues += atq ? 0 : rte_eth_dev_count(); struct rte_event_dev_config config = { .nb_event_queues = nb_queues, @@ -241,12 +343,19 @@ setup_eventdev_w(struct prod_data *prod_data, printf(" Stages:\n"); for (i = 0; i < nb_queues; i++) { - uint8_t slot; + if (atq) { + + nb_slots = cdata.num_stages; + wkr_q_conf.event_queue_cfg = + RTE_EVENT_QUEUE_CFG_ALL_TYPES; + } else { + uint8_t slot; - nb_slots = cdata.num_stages + 1; - slot = i % nb_slots; - wkr_q_conf.schedule_type = slot == cdata.num_stages ? - RTE_SCHED_TYPE_ATOMIC : cdata.queue_type; + nb_slots = cdata.num_stages + 1; + slot = i % nb_slots; + wkr_q_conf.schedule_type = slot == cdata.num_stages ? + RTE_SCHED_TYPE_ATOMIC : cdata.queue_type; + } if (rte_event_queue_setup(dev_id, i, &wkr_q_conf) < 0) { printf("%d: error creating qid %d\n", __LINE__, i); @@ -464,6 +573,11 @@ opt_check(void) memset(&eventdev_info, 0, sizeof(struct rte_event_dev_info)); rte_event_dev_info_get(0, &eventdev_info); + if (cdata.all_type_queues && !(eventdev_info.event_dev_cap & + RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES)) + rte_exit(EXIT_FAILURE, + "Event dev doesn't support all type queues\n"); + for (i = 0; i < rte_eth_dev_count(); i++) { ret = rte_event_eth_rx_adapter_caps_get(0, i, &cap); if (ret) @@ -494,9 +608,15 @@ opt_check(void) void set_worker_tx_setup_data(struct setup_data *caps, bool burst) { - if (burst) + uint8_t atq = cdata.all_type_queues ? 1 : 0; + + if (burst && atq) + caps->worker_loop = worker_do_tx_burst_atq; + if (burst && !atq) caps->worker_loop = worker_do_tx_burst; - if (!burst) + if (!burst && atq) + caps->worker_loop = worker_do_tx_atq; + if (!burst && !atq) caps->worker_loop = worker_do_tx; caps->opt_check = opt_check; -- 2.14.1