aboutsummaryrefslogtreecommitdiffstats
path: root/doc/guides/tools/testeventdev.rst
diff options
context:
space:
mode:
authorLuca Boccassi <luca.boccassi@gmail.com>2018-02-19 11:16:57 +0000
committerLuca Boccassi <luca.boccassi@gmail.com>2018-02-19 11:17:28 +0000
commitca33590b6af032bff57d9cc70455660466a654b2 (patch)
tree0b68b090bd9b4a78a3614b62400b29279d76d553 /doc/guides/tools/testeventdev.rst
parent169a9de21e263aa6599cdc2d87a45ae158d9f509 (diff)
New upstream version 18.02upstream/18.02
Change-Id: I89ed24cb2a49b78fe5be6970b99dd46c1499fcc3 Signed-off-by: Luca Boccassi <luca.boccassi@gmail.com>
Diffstat (limited to 'doc/guides/tools/testeventdev.rst')
-rw-r--r--doc/guides/tools/testeventdev.rst237
1 files changed, 208 insertions, 29 deletions
diff --git a/doc/guides/tools/testeventdev.rst b/doc/guides/tools/testeventdev.rst
index 5aa2237b..77480ffe 100644
--- a/doc/guides/tools/testeventdev.rst
+++ b/doc/guides/tools/testeventdev.rst
@@ -1,32 +1,5 @@
-.. BSD LICENSE
- Copyright(c) 2017 Cavium, Inc. All rights reserved.
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions
- are met:
-
- * Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- * Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in
- the documentation and/or other materials provided with the
- distribution.
- * Neither the name of Cavium, Inc nor the names of its
- contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+.. SPDX-License-Identifier: BSD-3-Clause
+ Copyright(c) 2017 Cavium, Inc
dpdk-test-eventdev Application
==============================
@@ -146,6 +119,9 @@ The following are the application command-line options:
Enable queue priority.
+* ``--prod_type_ethdev``
+
+ Use ethernet device as producer.
Eventdev Tests
--------------
@@ -348,6 +324,10 @@ the timestamp in the event on the first stage and then on termination, it
updates the number of cycles to forward a packet. The application uses this
value to compute the average latency to a forward packet.
+When ``--prod_type_ethdev`` command line option is selected, the application
+uses the probed ethernet devices as producers by configuring them as Rx
+adapters instead of using synthetic producers.
+
Application options
^^^^^^^^^^^^^^^^^^^
@@ -366,6 +346,7 @@ Supported application command line options are following::
--worker_deq_depth
--fwd_latency
--queue_priority
+ --prod_type_ethdev
Example
^^^^^^^
@@ -377,6 +358,12 @@ Example command to run perf queue test:
sudo build/app/dpdk-test-eventdev -c 0xf -s 0x1 --vdev=event_sw0 -- \
--test=perf_queue --plcores=2 --wlcore=3 --stlist=p --nb_pkts=0
+Example command to run perf queue test with ethernet ports:
+
+.. code-block:: console
+
+ sudo build/app/dpdk-test-eventdev --vdev=event_sw0 -- \
+ --test=perf_queue --plcores=2 --wlcore=3 --stlist=p --prod_type_ethdev
PERF_ATQ Test
~~~~~~~~~~~~~~~
@@ -443,6 +430,7 @@ Supported application command line options are following::
--nb_pkts
--worker_deq_depth
--fwd_latency
+ --prod_type_ethdev
Example
^^^^^^^
@@ -453,3 +441,194 @@ 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
+
+
+PIPELINE_ATQ Test
+~~~~~~~~~~~~~~~~~~~
+
+This is a pipeline test case that aims at testing the following with
+``all types queue`` eventdev scheme.
+
+#. Measure the end-to-end performance of an event dev with a ethernet dev.
+#. Maintain packet ordering from Rx to Tx.
+
+.. _table_eventdev_pipeline_atq_test:
+
+.. table:: Pipeline atq test eventdev configuration.
+
+ +---+--------------+----------------+-----------------------------------------+
+ | # | Items | Value | Comments |
+ | | | | |
+ +===+==============+================+=========================================+
+ | 1 | nb_queues | nb_producers + | Queues will be configured based on the |
+ | | | x | user requested sched type list(--stlist)|
+ | | | | where x = 1 in generic pipeline and 0 |
+ | | | | 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_atq_test_generic:
+
+.. figure:: img/eventdev_pipeline_atq_test_generic.*
+
+.. _figure_eventdev_pipeline_atq_test_lockfree:
+
+.. figure:: img/eventdev_pipeline_atq_test_lockfree.*
+
+ pipeline atq test operation.
+
+The pipeline atq 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_atq_test`.
+
+The atq queue test functions as same as ``pipeline_queue`` test. The difference
+is, It uses, ``all type queue scheme`` instead of separate queues for each
+stage and thus reduces the number of queues required to realize the use case.
+
+
+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_atq --wlcore=1 --prod_type_ethdev --stlist=a