From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavan Nikhilesh Subject: [PATCH v7 13/15] doc: add pipeline queue test in eventdev test guide Date: Tue, 16 Jan 2018 23:16:05 +0530 Message-ID: <20180116174607.10821-13-pbhagavatula@caviumnetworks.com> References: <20171130072406.15605-1-pbhagavatula@caviumnetworks.com> <20180116174607.10821-1-pbhagavatula@caviumnetworks.com> Mime-Version: 1.0 Content-Type: text/plain Cc: dev@dpdk.org, Pavan Nikhilesh To: jerin.jacob@caviumnetworks.com, santosh.shukla@caviumnetworks.com, harry.van.haaren@intel.com, gage.eads@intel.com, hemant.agrawal@nxp.com, nipun.gupta@nxp.com, liang.j.ma@intel.com Return-path: Received: from NAM03-DM3-obe.outbound.protection.outlook.com (mail-dm3nam03on0058.outbound.protection.outlook.com [104.47.41.58]) by dpdk.org (Postfix) with ESMTP id D71E71B303 for ; Tue, 16 Jan 2018 18:48:46 +0100 (CET) In-Reply-To: <20180116174607.10821-1-pbhagavatula@caviumnetworks.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Signed-off-by: Pavan Nikhilesh --- .../img/eventdev_pipeline_queue_test_generic.svg | 3548 ++++++++++++++++++ .../img/eventdev_pipeline_queue_test_lockfree.svg | 3826 ++++++++++++++++++++ doc/guides/tools/testeventdev.rst | 106 + 3 files changed, 7480 insertions(+) create mode 100644 doc/guides/tools/img/eventdev_pipeline_queue_test_generic.svg create mode 100644 doc/guides/tools/img/eventdev_pipeline_queue_test_lockfree.svg diff --git a/doc/guides/tools/img/eventdev_pipeline_queue_test_generic.svg b/doc/guides/tools/img/eventdev_pipeline_queue_test_generic.svg new file mode 100644 index 000000000..732d48867 --- /dev/null +++ b/doc/guides/tools/img/eventdev_pipeline_queue_test_generic.svg @@ -0,0 +1,3548 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + producer 0 + + q0 + q1 + qs-1 + + port n+2 + + + test: pipeline_queue + + + + producer 1 + qs + qs+1 + q2s-1 + + port n+3 + + + + + + + producer m-1 + q2s + q2s+1 + q3s-1 + + port n+m + + + + + + total queues = (number of stages * number of ethernet dev) + 1 + All workers are linked to all stage queues + eth port 1 Rxq 0 + eth port q Rxq 0 + eth port 0 Rxq 0 + Event ethRx adptr 0 + Event ethRx adptr 1 + Event ethRx adptr q + + + + worker 0 + worker 1 + worker n + port 0 + port 1 + port n + + + eth port 1 Txq 0 + + + + eth port 0 Txq 0 + + + + eth port q Txq 0 + + + + Tx Serviceport n + 1 + + + + + + SingleLink Q + + + + + + + + (Tx Generic) + + diff --git a/doc/guides/tools/img/eventdev_pipeline_queue_test_lockfree.svg b/doc/guides/tools/img/eventdev_pipeline_queue_test_lockfree.svg new file mode 100644 index 000000000..c0a365c7b --- /dev/null +++ b/doc/guides/tools/img/eventdev_pipeline_queue_test_lockfree.svg @@ -0,0 +1,3826 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + producer 0 + + q0 + q1 + qs-2 + + port n+1 + + + test: pipeline_queue + + + + producer 1 + qs + qs+1 + q2s-2 + + port n+2 + + + + + + + producer m-1 + q2s + q2s+1 + q3s-2 + + port n+m + + + + + + total queues = (number of stages * number of ethernet dev) + number of ethernet dev + eth port 1 Rxq 0 + eth port q Rxq 0 + eth port 0 Rxq 0 + Event ethRx adptr 0 + Event ethRx adptr 1 + Event ethRx adptr q + + + + worker 0 + worker 1 + worker n + port 0 + port 1 + port n + + + eth port 1 Txq 0 + + + + eth port 0 Txq 0 + + + + eth port q Txq 0 + + + + + + + + + + + + + + qs-1 + q2s-1 + q3s-1 + Atomic Q + Atomic Q + Atomic Q + Stage0 Q + Stage1 Q + Stage2 Q + + + + + + + (Tx Lock free) + All workers are linked to all queues + + diff --git a/doc/guides/tools/testeventdev.rst b/doc/guides/tools/testeventdev.rst index 9785e8431..33fe5e730 100644 --- a/doc/guides/tools/testeventdev.rst +++ b/doc/guides/tools/testeventdev.rst @@ -441,3 +441,109 @@ Example command to run perf ``all types queue`` test: sudo build/app/dpdk-test-eventdev --vdev=event_octeontx -- \ --test=perf_atq --plcores=2 --wlcore=3 --stlist=p --nb_pkts=0 + + +PIPELINE_QUEUE Test +~~~~~~~~~~~~~~~~~~~ + +This is a pipeline test case that aims at testing the following: + +#. Measure the end-to-end performance of an event dev with a ethernet dev. +#. Maintain packet ordering from Rx to Tx. + +.. _table_eventdev_pipeline_queue_test: + +.. table:: Pipeline queue test eventdev configuration. + + +---+--------------+----------------+-----------------------------------------+ + | # | Items | Value | Comments | + | | | | | + +===+==============+================+=========================================+ + | 1 | nb_queues | (nb_producers | Queues will be configured based on the | + | | | * nb_stages) + | user requested sched type list(--stlist)| + | | | x | Here value of x is 1 in generic pipeline| + | | | | and nb_producers in lockfree pipeline | + +---+--------------+----------------+-----------------------------------------+ + | 2 | nb_producers | >= 1 | Producers will be configured based on | + | | | | the number of detected ethernet devices.| + | | | | Each ethdev will be configured as an Rx | + | | | | adapter. | + +---+--------------+----------------+-----------------------------------------+ + | 3 | nb_workers | >= 1 | Selected through --wlcores command line | + | | | | argument | + +---+--------------+----------------+-----------------------------------------+ + | 4 | nb_ports | nb_workers + | Workers use port 0 to port n. | + | | | nb_producers | Producers use port n+1 to port n+m, | + | | | | depending on the Rx adapter capability. | + +---+--------------+----------------+-----------------------------------------+ + +.. _figure_eventdev_pipeline_queue_test_generic: + +.. figure:: img/eventdev_pipeline_queue_test_generic.* + +.. _figure_eventdev_pipeline_queue_test_lockfree: + +.. figure:: img/eventdev_pipeline_queue_test_lockfree.* + + pipeline queue test operation. + +The pipeline queue test configures the eventdev with Q queues and P ports, +where Q and P is a function of the number of workers, the number of producers +and number of stages as mentioned in :numref:`table_eventdev_pipeline_queue_test`. + +The user can choose the number of workers and number of stages through the +``--wlcores`` and the ``--stlist`` application command line arguments +respectively. + +The number of producers depends on the number of ethernet devices detected and +each ethernet device is configured as a event_eth_rx_adapter that acts as a +producer. + +The producer(s) injects the events to eventdev based the first stage sched type +list requested by the user through ``--stlist`` the command line argument. + +Based on the number of stages to process(selected through ``--stlist``), +The application forwards the event to next upstream queue and when it reaches +the last stage in the pipeline if the event type is ``atomic`` it is enqueued +onto ethdev Tx queue else to maintain ordering the event type is set to +``atomic`` and enqueued onto the last stage queue. + +If the ethernet has ``DEV_TX_OFFLOAD_MT_LOCKFREE`` capability then the worker +cores transmit the packets directly. Else the worker cores enqueue the packet +onto the ``SINGLE_LINK_QUEUE`` that is managed by a Tx service. The Tx service +dequeues the packet and transmits it. + +On packet Tx, application increments the number events processed and print +periodically in one second to get the number of events processed in one +second. + + +Application options +^^^^^^^^^^^^^^^^^^^ + +Supported application command line options are following:: + + --verbose + --dev + --test + --socket_id + --pool_sz + --wlcores + --stlist + --worker_deq_depth + --prod_type_ethdev + + +.. Note:: + + * The ``--prod_type_ethdev`` is mandatory for running this test. + +Example +^^^^^^^ + +Example command to run pipeline queue test: + +.. code-block:: console + + sudo build/app/dpdk-test-eventdev -c 0xf -s 0x8 --vdev=event_sw0 -- \ + --test=pipeline_queue --wlcore=1 --prod_type_ethdev --stlist=a -- 2.14.1