1f714a188SAmr Mokhtar.. SPDX-License-Identifier: BSD-3-Clause 2f714a188SAmr Mokhtar Copyright(c) 2017 Intel Corporation 3f714a188SAmr Mokhtar 4f714a188SAmr Mokhtardpdk-test-bbdev Application 5f714a188SAmr Mokhtar=========================== 6f714a188SAmr Mokhtar 7f714a188SAmr MokhtarThe ``dpdk-test-bbdev`` tool is a Data Plane Development Kit (DPDK) utility that 8f714a188SAmr Mokhtarallows measuring performance parameters of PMDs available in the bbdev framework. 9f714a188SAmr MokhtarAvailable tests available for execution are: latency, throughput, validation and 10f714a188SAmr Mokhtarsanity tests. Execution of tests can be customized using various parameters 11f714a188SAmr Mokhtarpassed to a python running script. 12f714a188SAmr Mokhtar 13f714a188SAmr MokhtarCompiling the Application 14f714a188SAmr Mokhtar------------------------- 15f714a188SAmr Mokhtar 16f714a188SAmr Mokhtar**Step 1: PMD setting** 17f714a188SAmr Mokhtar 18f714a188SAmr MokhtarThe ``dpdk-test-bbdev`` tool depends on crypto device drivers PMD which 19f714a188SAmr Mokhtarare disabled by default in the build configuration file ``common_base``. 20f714a188SAmr MokhtarThe bbdevice drivers PMD which should be tested can be enabled by setting 21f714a188SAmr Mokhtar 22f714a188SAmr Mokhtar ``CONFIG_RTE_LIBRTE_PMD_<name>=y`` 23f714a188SAmr Mokhtar 247ce00bf3SKamil ChalupnikSetting example for (*baseband_turbo_sw*) PMD 25f714a188SAmr Mokhtar 26f714a188SAmr Mokhtar ``CONFIG_RTE_LIBRTE_PMD_BBDEV_TURBO_SW=y`` 27f714a188SAmr Mokhtar 28f714a188SAmr Mokhtar**Step 2: Build the application** 29f714a188SAmr Mokhtar 30f714a188SAmr MokhtarExecute the ``dpdk-setup.sh`` script to build the DPDK library together with the 31f714a188SAmr Mokhtar``dpdk-test-bbdev`` application. 32f714a188SAmr Mokhtar 33f714a188SAmr MokhtarInitially, the user must select a DPDK target to choose the correct target type 34f714a188SAmr Mokhtarand compiler options to use when building the libraries. 35f714a188SAmr MokhtarThe user must have all libraries, modules, updates and compilers installed 36f714a188SAmr Mokhtarin the system prior to this, as described in the earlier chapters in this 37f714a188SAmr MokhtarGetting Started Guide. 38f714a188SAmr Mokhtar 39f714a188SAmr MokhtarRunning the Application 40f714a188SAmr Mokhtar----------------------- 41f714a188SAmr Mokhtar 42f714a188SAmr MokhtarThe tool application has a number of command line options: 43f714a188SAmr Mokhtar 44f714a188SAmr Mokhtar.. code-block:: console 45f714a188SAmr Mokhtar 46f714a188SAmr Mokhtar python test-bbdev.py [-h] [-p TESTAPP_PATH] [-e EAL_PARAMS] [-t TIMEOUT] 47f714a188SAmr Mokhtar [-c TEST_CASE [TEST_CASE ...]] 48f714a188SAmr Mokhtar [-v TEST_VECTOR [TEST_VECTOR...]] [-n NUM_OPS] 49f714a188SAmr Mokhtar [-b BURST_SIZE [BURST_SIZE ...]] [-l NUM_LCORES] 50f714a188SAmr Mokhtar 51f714a188SAmr Mokhtarcommand-line Options 52f714a188SAmr Mokhtar~~~~~~~~~~~~~~~~~~~~ 53f714a188SAmr Mokhtar 54f714a188SAmr MokhtarThe following are the command-line options: 55f714a188SAmr Mokhtar 56f714a188SAmr Mokhtar``-h, --help`` 57f714a188SAmr Mokhtar Shows help message and exit. 58f714a188SAmr Mokhtar 59f714a188SAmr Mokhtar``-p TESTAPP_PATH, --testapp_path TESTAPP_PATH`` 60f714a188SAmr Mokhtar Indicates the path to the bbdev test app. If not specified path is set based 61f714a188SAmr Mokhtar on *$RTE_SDK* environment variable concatenated with "*/build/app/testbbdev*". 62f714a188SAmr Mokhtar 63f714a188SAmr Mokhtar``-e EAL_PARAMS, --eal_params EAL_PARAMS`` 64f714a188SAmr Mokhtar Specifies EAL arguments which are passed to the test app. For more details, 65*43d162bcSThomas Monjalon refer to DPDK documentation at 66*43d162bcSThomas Monjalon http://doc.dpdk.org/guides/linux_gsg/linux_eal_parameters.html. 67f714a188SAmr Mokhtar 68f714a188SAmr Mokhtar``-t TIMEOUT, --timeout TIMEOUT`` 69f714a188SAmr Mokhtar Specifies timeout in seconds. If not specified timeout is set to 300 seconds. 70f714a188SAmr Mokhtar 71f714a188SAmr Mokhtar``-c TEST_CASE [TEST_CASE ...], --test_cases TEST_CASE [TEST_CASE ...]`` 72f714a188SAmr Mokhtar Defines test cases to run. If not specified all available tests are run. 73f714a188SAmr Mokhtar 74f714a188SAmr Mokhtar **Example usage:** 75f714a188SAmr Mokhtar 76f714a188SAmr Mokhtar ``./test-bbdev.py -c validation`` 77f714a188SAmr Mokhtar Runs validation test suite 78f714a188SAmr Mokhtar 79f714a188SAmr Mokhtar ``./test-bbdev.py -c latency throughput`` 80f714a188SAmr Mokhtar Runs latency and throughput test suites 81f714a188SAmr Mokhtar 82f714a188SAmr Mokhtar``-v TEST_VECTOR [TEST_VECTOR ...], --test_vector TEST_VECTOR [TEST_VECTOR ...]`` 83f714a188SAmr Mokhtar Specifies paths to the test vector files. If not specified path is set based 84f714a188SAmr Mokhtar on *$RTE_SDK* environment variable concatenated with 85ae828b8cSKamil Chalupnik "*/app/test-bbdev/test_vectors/bbdev_null.data*" and indicates default 86f714a188SAmr Mokhtar data file. 87f714a188SAmr Mokhtar 88f714a188SAmr Mokhtar **Example usage:** 89f714a188SAmr Mokhtar 90ae828b8cSKamil Chalupnik ``./test-bbdev.py -v app/test-bbdev/test_vectors/turbo_dec_test1.data`` 91ae828b8cSKamil Chalupnik Fills vector based on turbo_dec_test1.data file and runs all tests 92f714a188SAmr Mokhtar 93ae828b8cSKamil Chalupnik ``./test-bbdev.py -v turbo_dec_test1.data turbo_enc_test2.data`` 94f714a188SAmr Mokhtar The bbdev test app is executed twice. First time vector is filled based on 95ae828b8cSKamil Chalupnik *turbo_dec_test1.data* file and second time based on 96ae828b8cSKamil Chalupnik *turb_enc_test2.data* file. For both executions all tests are run. 97f714a188SAmr Mokhtar 98f714a188SAmr Mokhtar``-n NUM_OPS, --num_ops NUM_OPS`` 99f714a188SAmr Mokhtar Specifies number of operations to process on device. If not specified num_ops 100f714a188SAmr Mokhtar is set to 32 operations. 101f714a188SAmr Mokhtar 102f714a188SAmr Mokhtar``-l NUM_LCORES, --num_lcores NUM_LCORES`` 103f714a188SAmr Mokhtar Specifies number of lcores to run. If not specified num_lcores is set 104f714a188SAmr Mokhtar according to value from RTE configuration (EAL coremask) 105f714a188SAmr Mokhtar 106f714a188SAmr Mokhtar``-b BURST_SIZE [BURST_SIZE ...], --burst-size BURST_SIZE [BURST_SIZE ...]`` 107f714a188SAmr Mokhtar Specifies operations enqueue/dequeue burst size. If not specified burst_size is 108f714a188SAmr Mokhtar set to 32. Maximum is 512. 109f714a188SAmr Mokhtar 1108723590eSKamil ChalupnikTest Cases 1118723590eSKamil Chalupnik~~~~~~~~~~ 112f714a188SAmr Mokhtar 1138723590eSKamil ChalupnikThere are 6 main test cases that can be executed using testbbdev tool: 1148723590eSKamil Chalupnik 1158723590eSKamil Chalupnik* Sanity checks [-c unittest] 1168723590eSKamil Chalupnik - Performs sanity checks on BBDEV interface, validating basic functionality 1178723590eSKamil Chalupnik 1188723590eSKamil Chalupnik* Validation tests [-c validation] 1198723590eSKamil Chalupnik - Performs full operation of enqueue and dequeue 1208723590eSKamil Chalupnik - Compares the dequeued data buffer with a expected values in the test 1218723590eSKamil Chalupnik vector (TV) being used 1228723590eSKamil Chalupnik - Fails if any dequeued value does not match the data in the TV 1238723590eSKamil Chalupnik 1248723590eSKamil Chalupnik* Offload Cost measurement [-c offload] 1258723590eSKamil Chalupnik - Measures the CPU cycles consumed from the receipt of a user enqueue 1268723590eSKamil Chalupnik until it is put on the device queue 1278723590eSKamil Chalupnik - The test measures 4 metrics 1288723590eSKamil Chalupnik (a) *SW Enq Offload Cost*: Software only enqueue offload cost, the cycle 1298723590eSKamil Chalupnik counts and time (us) from the point the enqueue API is called until 1308723590eSKamil Chalupnik the point the operation is put on the accelerator queue. 1318723590eSKamil Chalupnik (b) *Acc Enq Offload Cost*: The cycle count and time (us) from the 1328723590eSKamil Chalupnik point the operation is put on the accelerator queue until the return 1338723590eSKamil Chalupnik from enqueue. 1348723590eSKamil Chalupnik (c) *SW Deq Offload Cost*: Software dequeue cost, the cycle counts and 1358723590eSKamil Chalupnik time (us) consumed to dequeue one operation. 1368723590eSKamil Chalupnik (d) *Empty Queue Enq Offload Cost*: The cycle count and time (us) 1378723590eSKamil Chalupnik consumed to dequeue from an empty queue. 1388723590eSKamil Chalupnik 1398723590eSKamil Chalupnik* Latency measurement [-c latency] 1408723590eSKamil Chalupnik - Measures the time consumed from the first enqueue until the first 1418723590eSKamil Chalupnik appearance of a dequeued result 1428723590eSKamil Chalupnik - This measurment represents the full latency of a bbdev operation 1438723590eSKamil Chalupnik (encode or decode) to execute 1448723590eSKamil Chalupnik 1458723590eSKamil Chalupnik* Poll-mode Throughput measurement [-c throughput] 1468723590eSKamil Chalupnik - Performs full operation of enqueue and dequeue 1478723590eSKamil Chalupnik - Executes in poll mode 1488723590eSKamil Chalupnik - Measures the achieved throughput on a subset or all available CPU cores 1498723590eSKamil Chalupnik - Dequeued data is not validated against expected values stored in TV 1508723590eSKamil Chalupnik - Results are printed in million operations per second and million bits 1518723590eSKamil Chalupnik per second 1528723590eSKamil Chalupnik 1538723590eSKamil Chalupnik* Interrupt-mode Throughput [-c interrupt] 1548723590eSKamil Chalupnik - Similar to Throughput test case, but using interrupts. No polling. 1558723590eSKamil Chalupnik 1568723590eSKamil Chalupnik 1578723590eSKamil ChalupnikParameter Globbing 158f714a188SAmr Mokhtar~~~~~~~~~~~~~~~~~~ 159f714a188SAmr Mokhtar 160f714a188SAmr MokhtarThanks to the globbing functionality in python test-bbdev.py script allows to 161f714a188SAmr Mokhtarrun tests with different set of vector files without giving all of them explicitly. 162f714a188SAmr Mokhtar 163f714a188SAmr Mokhtar**Example usage:** 164f714a188SAmr Mokhtar 165f714a188SAmr Mokhtar.. code-block:: console 166f714a188SAmr Mokhtar 167ae828b8cSKamil Chalupnik ./test-bbdev.py -v app/test-bbdev/test_vectors/turbo_<enc/dec>_c<c>_k<k>_r<r>_e<e>_<extra-info>.data 168f714a188SAmr Mokhtar 169f714a188SAmr MokhtarIt runs all tests with following vectors: 170f714a188SAmr Mokhtar 171ae828b8cSKamil Chalupnik- ``bbdev_null.data`` 172f714a188SAmr Mokhtar 17343b767f6SKamil Chalupnik- ``turbo_dec_c1_k6144_r0_e34560_sbd_negllr.data`` 17447d5a049SKamil Chalupnik 17547d5a049SKamil Chalupnik- ``turbo_enc_c1_k40_r0_e1196_rm.data`` 17647d5a049SKamil Chalupnik 17743b767f6SKamil Chalupnik- ``turbo_enc_c2_k5952_r0_e17868_crc24b.data`` 17843b767f6SKamil Chalupnik 17943b767f6SKamil Chalupnik- ``turbo_dec_c1_k40_r0_e17280_sbd_negllr.data`` 18043b767f6SKamil Chalupnik 18143b767f6SKamil Chalupnik- ``turbo_dec_c1_k6144_r0_e34560_sbd_posllr.data`` 18243b767f6SKamil Chalupnik 18347d5a049SKamil Chalupnik- ``turbo_enc_c1_k40_r0_e272_rm.data`` 184f714a188SAmr Mokhtar 18543b767f6SKamil Chalupnik- ``turbo_enc_c3_k4800_r2_e14412_crc24b.data`` 18643b767f6SKamil Chalupnik 18743b767f6SKamil Chalupnik- ``turbo_dec_c1_k6144_r0_e10376_crc24b_sbd_negllr_high_snr.data`` 18843b767f6SKamil Chalupnik 18943b767f6SKamil Chalupnik- ``turbo_dec_c2_k3136_r0_e4920_sbd_negllr_crc24b.data`` 19043b767f6SKamil Chalupnik 19143b767f6SKamil Chalupnik- ``turbo_enc_c1_k6144_r0_e120_rm_rvidx.data`` 19243b767f6SKamil Chalupnik 19343b767f6SKamil Chalupnik- ``turbo_enc_c4_k4800_r2_e14412_crc24b.data`` 19443b767f6SKamil Chalupnik 19543b767f6SKamil Chalupnik- ``turbo_dec_c1_k6144_r0_e10376_crc24b_sbd_negllr_low_snr.data`` 19643b767f6SKamil Chalupnik 19743b767f6SKamil Chalupnik- ``turbo_dec_c2_k3136_r0_e4920_sbd_negllr.data`` 19843b767f6SKamil Chalupnik 19943b767f6SKamil Chalupnik- ``turbo_enc_c1_k6144_r0_e18444.data`` 20043b767f6SKamil Chalupnik 20143b767f6SKamil Chalupnik- ``turbo_dec_c1_k6144_r0_e34560_negllr.data`` 20243b767f6SKamil Chalupnik 20343b767f6SKamil Chalupnik- ``turbo_enc_c1_k40_r0_e1190_rm.data`` 20443b767f6SKamil Chalupnik 20543b767f6SKamil Chalupnik- ``turbo_enc_c1_k6144_r0_e18448_crc24a.data`` 20643b767f6SKamil Chalupnik 20743b767f6SKamil Chalupnik- ``turbo_dec_c1_k6144_r0_e34560_posllr.data`` 20843b767f6SKamil Chalupnik 20943b767f6SKamil Chalupnik- ``turbo_enc_c1_k40_r0_e1194_rm.data`` 21043b767f6SKamil Chalupnik 211ae828b8cSKamil Chalupnik- ``turbo_enc_c1_k6144_r0_e32256_crc24b_rm.data`` 212ae828b8cSKamil Chalupnik 213f714a188SAmr Mokhtar.. code-block:: console 214f714a188SAmr Mokhtar 215ae828b8cSKamil Chalupnik ./test-bbdev.py -v app/test-bbdev/turbo_*_default.data 216f714a188SAmr Mokhtar 217ae828b8cSKamil ChalupnikIt runs all tests with "default" vectors. 218f714a188SAmr Mokhtar 219ae828b8cSKamil Chalupnik* ``turbo_dec_default.data`` is a soft link to 220ae828b8cSKamil Chalupnik ``turbo_dec_c1_k6144_r0_e10376_crc24b_sbd_negllr_high_snr.data`` 221f714a188SAmr Mokhtar 222ae828b8cSKamil Chalupnik* ``turbo_enc_default.data`` is a soft link to 223ae828b8cSKamil Chalupnik ``turbo_enc_c1_k6144_r0_e32256_crc24b_rm.data`` 224f714a188SAmr Mokhtar 225f714a188SAmr Mokhtar 226f714a188SAmr MokhtarRunning Tests 227f714a188SAmr Mokhtar------------- 228f714a188SAmr Mokhtar 229f714a188SAmr MokhtarShortened tree of isg_cid-wireless_dpdk_ae with dpdk compiled for 230f714a188SAmr Mokhtarx86_64-native-linuxapp-icc target: 231f714a188SAmr Mokhtar 232f714a188SAmr Mokhtar:: 233f714a188SAmr Mokhtar 234f714a188SAmr Mokhtar |-- app 235f714a188SAmr Mokhtar |-- test-bbdev 236f714a188SAmr Mokhtar |-- test_vectors 237ae828b8cSKamil Chalupnik |-- bbdev_null.data 23843b767f6SKamil Chalupnik |-- turbo_dec_c1_k6144_r0_e34560_sbd_negllr.data 239ae828b8cSKamil Chalupnik |-- turbo_enc_c1_k40_r0_e1196_rm.data 24043b767f6SKamil Chalupnik |-- turbo_enc_c2_k5952_r0_e17868_crc24b.data 24143b767f6SKamil Chalupnik |-- turbo_dec_c1_k40_r0_e17280_sbd_negllr.data 24243b767f6SKamil Chalupnik |-- turbo_dec_c1_k6144_r0_e34560_sbd_posllr.data 243ae828b8cSKamil Chalupnik |-- turbo_enc_c1_k40_r0_e272_rm.data 24443b767f6SKamil Chalupnik |-- turbo_enc_c3_k4800_r2_e14412_crc24b.data 24543b767f6SKamil Chalupnik |-- turbo_dec_c1_k6144_r0_e10376_crc24b_sbd_negllr_high_snr.data 24643b767f6SKamil Chalupnik |-- turbo_dec_c2_k3136_r0_e4920_sbd_negllr_crc24b.data 24743b767f6SKamil Chalupnik |-- turbo_enc_c1_k6144_r0_e120_rm_rvidx.data 24843b767f6SKamil Chalupnik |-- turbo_enc_c4_k4800_r2_e14412_crc24b.data 24943b767f6SKamil Chalupnik |-- turbo_dec_c1_k6144_r0_e10376_crc24b_sbd_negllr_low_snr.data 25043b767f6SKamil Chalupnik |-- turbo_dec_c2_k3136_r0_e4920_sbd_negllr.data 25143b767f6SKamil Chalupnik |-- turbo_enc_c1_k6144_r0_e18444.data 25243b767f6SKamil Chalupnik |-- turbo_dec_c1_k6144_r0_e34560_negllr.data 25343b767f6SKamil Chalupnik |-- turbo_enc_c1_k40_r0_e1190_rm.data 25443b767f6SKamil Chalupnik |-- turbo_enc_c1_k6144_r0_e18448_crc24a.data 25543b767f6SKamil Chalupnik |-- turbo_dec_c1_k6144_r0_e34560_posllr.data 25643b767f6SKamil Chalupnik |-- turbo_enc_c1_k40_r0_e1194_rm.data 257ae828b8cSKamil Chalupnik |-- turbo_enc_c1_k6144_r0_e32256_crc24b_rm.data 258f714a188SAmr Mokhtar 259f714a188SAmr Mokhtar |-- x86_64-native-linuxapp-icc 260f714a188SAmr Mokhtar |-- app 261f714a188SAmr Mokhtar |-- testbbdev 262f714a188SAmr Mokhtar 263f714a188SAmr MokhtarAll bbdev devices 264f714a188SAmr Mokhtar~~~~~~~~~~~~~~~~~ 265f714a188SAmr Mokhtar 266f714a188SAmr Mokhtar.. code-block:: console 267f714a188SAmr Mokhtar 268f714a188SAmr Mokhtar ./test-bbdev.py -p ../../x86_64-native-linuxapp-icc/app/testbbdev 269ae828b8cSKamil Chalupnik -v turbo_dec_default.data 270f714a188SAmr Mokhtar 271f714a188SAmr MokhtarIt runs all available tests using the test vector filled based on 272ae828b8cSKamil Chalupnik*turbo_dec_default.data* file. 273f714a188SAmr MokhtarBy default number of operations to process on device is set to 32, timeout is 274f714a188SAmr Mokhtarset to 300s and operations enqueue/dequeue burst size is set to 32. 2757ce00bf3SKamil ChalupnikMoreover a bbdev (*baseband_null*) device will be created. 276f714a188SAmr Mokhtar 2777ce00bf3SKamil Chalupnikbaseband turbo_sw device 2787ce00bf3SKamil Chalupnik~~~~~~~~~~~~~~~~~~~~~~~~ 279f714a188SAmr Mokhtar 280f714a188SAmr Mokhtar.. code-block:: console 281f714a188SAmr Mokhtar 282f714a188SAmr Mokhtar ./test-bbdev.py -p ../../x86_64-native-linuxapp-icc/app/testbbdev 2837ce00bf3SKamil Chalupnik -e="--vdev=baseband_turbo_sw" -t 120 -c validation 284ae828b8cSKamil Chalupnik -v ./test_vectors/turbo_* -n 64 -b 8 32 285f714a188SAmr Mokhtar 286f714a188SAmr MokhtarIt runs **validation** test for each vector file that matches the given pattern. 287f714a188SAmr MokhtarNumber of operations to process on device is set to 64 and operations timeout is 288f714a188SAmr Mokhtarset to 120s and enqueue/dequeue burst size is set to 8 and to 32. 2897ce00bf3SKamil ChalupnikMoreover a bbdev (*baseband_turbo_sw*) device will be created. 290f714a188SAmr Mokhtar 291f714a188SAmr Mokhtar 292f714a188SAmr Mokhtarbbdev null device 293f714a188SAmr Mokhtar~~~~~~~~~~~~~~~~~ 294f714a188SAmr Mokhtar 295ae828b8cSKamil ChalupnikExecuting bbdev null device with *bbdev_null.data* helps in measuring the 296f714a188SAmr Mokhtaroverhead introduced by the bbdev framework. 297f714a188SAmr Mokhtar 298f714a188SAmr Mokhtar.. code-block:: console 299f714a188SAmr Mokhtar 3007ce00bf3SKamil Chalupnik ./test-bbdev.py -e="--vdev=baseband_null0" 301ae828b8cSKamil Chalupnik -v ./test_vectors/bbdev_null.data 302f714a188SAmr Mokhtar 303f714a188SAmr Mokhtar**Note:** 304f714a188SAmr Mokhtar 3057ce00bf3SKamil Chalupnikbaseband_null device does not have to be defined explicitly as it is created by default. 306f714a188SAmr Mokhtar 307f714a188SAmr Mokhtar 308f714a188SAmr Mokhtar 309f714a188SAmr MokhtarTest Vector files 310f714a188SAmr Mokhtar================= 311f714a188SAmr Mokhtar 312f714a188SAmr MokhtarTest Vector files contain the data which is used to set turbo decoder/encoder 313f714a188SAmr Mokhtarparameters and buffers for validation purpose. New test vector files should be 314f714a188SAmr Mokhtarstored in ``app/test-bbdev/test_vectors/`` directory. Detailed description of 315f714a188SAmr Mokhtarthe syntax of the test vector files is in the following section. 316f714a188SAmr Mokhtar 317f714a188SAmr Mokhtar 318f714a188SAmr MokhtarBasic principles for test vector files 319f714a188SAmr Mokhtar-------------------------------------- 320f714a188SAmr MokhtarLine started with ``#`` is treated as a comment and is ignored. 321f714a188SAmr Mokhtar 322f714a188SAmr MokhtarIf variable is a chain of values, values should be separated by a comma. If 323f714a188SAmr Mokhtarassignment is split into several lines, each line (except the last one) has to 324f714a188SAmr Mokhtarbe ended with a comma. 325f714a188SAmr MokhtarThere is no comma after last value in last line. Correct assignment should 326f714a188SAmr Mokhtarlook like the following: 327f714a188SAmr Mokhtar 328f714a188SAmr Mokhtar.. parsed-literal:: 329f714a188SAmr Mokhtar 330f714a188SAmr Mokhtar variable = 331f714a188SAmr Mokhtar value, value, value, value, 332f714a188SAmr Mokhtar value, value 333f714a188SAmr Mokhtar 334f714a188SAmr MokhtarIn case where variable is a single value correct assignment looks like the 335f714a188SAmr Mokhtarfollowing: 336f714a188SAmr Mokhtar 337f714a188SAmr Mokhtar.. parsed-literal:: 338f714a188SAmr Mokhtar 339f714a188SAmr Mokhtar variable = 340f714a188SAmr Mokhtar value 341f714a188SAmr Mokhtar 342f714a188SAmr MokhtarLength of chain variable is calculated by parser. Can not be defined 343f714a188SAmr Mokhtarexplicitly. 344f714a188SAmr Mokhtar 345f714a188SAmr MokhtarVariable op_type has to be defined as a first variable in file. It specifies 346f714a188SAmr Mokhtarwhat type of operations will be executed. For decoder op_type has to be set to 347f714a188SAmr Mokhtar``RTE_BBDEV_OP_TURBO_DEC`` and for encoder to ``RTE_BBDEV_OP_TURBO_ENC``. 348f714a188SAmr Mokhtar 349f714a188SAmr MokhtarFull details of the meaning and valid values for the below fields are 350f714a188SAmr Mokhtardocumented in *rte_bbdev_op.h* 351f714a188SAmr Mokhtar 352f714a188SAmr Mokhtar 353f714a188SAmr MokhtarTurbo decoder test vectors template 354f714a188SAmr Mokhtar----------------------------------- 355f714a188SAmr Mokhtar 356f714a188SAmr MokhtarFor turbo decoder it has to be always set to ``RTE_BBDEV_OP_TURBO_DEC`` 357f714a188SAmr Mokhtar 358f714a188SAmr Mokhtar.. parsed-literal:: 359f714a188SAmr Mokhtar 360f714a188SAmr Mokhtar op_type = 361f714a188SAmr Mokhtar RTE_BBDEV_OP_TURBO_DEC 362f714a188SAmr Mokhtar 363f714a188SAmr MokhtarChain of uint32_t values. Note that it is possible to define more than one 364f714a188SAmr Mokhtarinput/output entries which will result in chaining two or more data structures 365f714a188SAmr Mokhtarfor *segmented Transport Blocks* 366f714a188SAmr Mokhtar 367f714a188SAmr Mokhtar.. parsed-literal:: 368f714a188SAmr Mokhtar 369f714a188SAmr Mokhtar input0 = 370f714a188SAmr Mokhtar 0x00000000, 0x7f817f00, 0x7f7f8100, 0x817f8100, 0x81008100, 0x7f818100, 0x81817f00, 0x7f818100, 371f714a188SAmr Mokhtar 0x81007f00, 0x7f818100, 0x817f8100, 0x81817f00, 0x81008100, 0x817f7f00, 0x7f7f8100, 0x81817f00 372f714a188SAmr Mokhtar 373f714a188SAmr MokhtarChain of uint32_t values 374f714a188SAmr Mokhtar 375f714a188SAmr Mokhtar.. parsed-literal:: 376f714a188SAmr Mokhtar 377f714a188SAmr Mokhtar input1 = 378f714a188SAmr Mokhtar 0x7f7f0000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 379f714a188SAmr Mokhtar 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000 380f714a188SAmr Mokhtar 381f714a188SAmr MokhtarChain of uint32_t values 382f714a188SAmr Mokhtar 383f714a188SAmr Mokhtar.. parsed-literal:: 384f714a188SAmr Mokhtar 385f714a188SAmr Mokhtar input2 = 386f714a188SAmr Mokhtar 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 387f714a188SAmr Mokhtar 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000 388f714a188SAmr Mokhtar 389f714a188SAmr MokhtarChain of uint32_t values 390f714a188SAmr Mokhtar 391f714a188SAmr Mokhtar.. parsed-literal:: 392f714a188SAmr Mokhtar 393f714a188SAmr Mokhtar hard_output0 = 394f714a188SAmr Mokhtar 0xa7d6732e 395f714a188SAmr Mokhtar 396f714a188SAmr MokhtarChain of uint32_t values 397f714a188SAmr Mokhtar 398f714a188SAmr Mokhtar.. parsed-literal:: 399f714a188SAmr Mokhtar 400f714a188SAmr Mokhtar hard_output1 = 401f714a188SAmr Mokhtar 0xa61 402f714a188SAmr Mokhtar 403f714a188SAmr MokhtarChain of uint32_t values 404f714a188SAmr Mokhtar 405f714a188SAmr Mokhtar.. parsed-literal:: 406f714a188SAmr Mokhtar 407f714a188SAmr Mokhtar soft_output0 = 408f714a188SAmr Mokhtar 0x817f817f, 0x7f817f7f, 0x81818181, 0x817f7f81, 0x7f818181, 0x8181817f, 0x817f817f, 0x8181817f 409f714a188SAmr Mokhtar 410f714a188SAmr MokhtarChain of uint32_t values 411f714a188SAmr Mokhtar 412f714a188SAmr Mokhtar.. parsed-literal:: 413f714a188SAmr Mokhtar 414f714a188SAmr Mokhtar soft_output1 = 415f714a188SAmr Mokhtar 0x817f7f81, 0x7f7f7f81, 0x7f7f8181 416f714a188SAmr Mokhtar 417f714a188SAmr Mokhtaruint32_t value 418f714a188SAmr Mokhtar 419f714a188SAmr Mokhtar.. parsed-literal:: 420f714a188SAmr Mokhtar 421f714a188SAmr Mokhtar e = 422f714a188SAmr Mokhtar 44 423f714a188SAmr Mokhtar 424f714a188SAmr Mokhtaruint16_t value 425f714a188SAmr Mokhtar 426f714a188SAmr Mokhtar.. parsed-literal:: 427f714a188SAmr Mokhtar 428f714a188SAmr Mokhtar k = 429f714a188SAmr Mokhtar 40 430f714a188SAmr Mokhtar 431f714a188SAmr Mokhtaruint8_t value 432f714a188SAmr Mokhtar 433f714a188SAmr Mokhtar.. parsed-literal:: 434f714a188SAmr Mokhtar 435f714a188SAmr Mokhtar rv_index = 436f714a188SAmr Mokhtar 0 437f714a188SAmr Mokhtar 438f714a188SAmr Mokhtaruint8_t value 439f714a188SAmr Mokhtar 440f714a188SAmr Mokhtar.. parsed-literal:: 441f714a188SAmr Mokhtar 442f714a188SAmr Mokhtar iter_max = 443f714a188SAmr Mokhtar 8 444f714a188SAmr Mokhtar 445f714a188SAmr Mokhtaruint8_t value 446f714a188SAmr Mokhtar 447f714a188SAmr Mokhtar.. parsed-literal:: 448f714a188SAmr Mokhtar 449f714a188SAmr Mokhtar iter_min = 450f714a188SAmr Mokhtar 4 451f714a188SAmr Mokhtar 452f714a188SAmr Mokhtaruint8_t value 453f714a188SAmr Mokhtar 454f714a188SAmr Mokhtar.. parsed-literal:: 455f714a188SAmr Mokhtar 456f714a188SAmr Mokhtar expected_iter_count = 457f714a188SAmr Mokhtar 8 458f714a188SAmr Mokhtar 459f714a188SAmr Mokhtaruint8_t value 460f714a188SAmr Mokhtar 461f714a188SAmr Mokhtar.. parsed-literal:: 462f714a188SAmr Mokhtar 463f714a188SAmr Mokhtar ext_scale = 464f714a188SAmr Mokhtar 15 465f714a188SAmr Mokhtar 466f714a188SAmr Mokhtaruint8_t value 467f714a188SAmr Mokhtar 468f714a188SAmr Mokhtar.. parsed-literal:: 469f714a188SAmr Mokhtar 470f714a188SAmr Mokhtar num_maps = 471f714a188SAmr Mokhtar 0 472f714a188SAmr Mokhtar 473f714a188SAmr MokhtarChain of flags for turbo decoder operation. Following flags can be used: 474f714a188SAmr Mokhtar 475f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE`` 476f714a188SAmr Mokhtar 477f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_CRC_TYPE_24B`` 478f714a188SAmr Mokhtar 479f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_EQUALIZER`` 480f714a188SAmr Mokhtar 481f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_SOFT_OUT_SATURATE`` 482f714a188SAmr Mokhtar 483f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_HALF_ITERATION_EVEN`` 484f714a188SAmr Mokhtar 485f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH`` 486f714a188SAmr Mokhtar 487f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_SOFT_OUTPUT`` 488f714a188SAmr Mokhtar 489f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_EARLY_TERMINATION`` 490f714a188SAmr Mokhtar 491f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_DEC_INTERRUPTS`` 492f714a188SAmr Mokhtar 493f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_POS_LLR_1_BIT_IN`` 494f714a188SAmr Mokhtar 495f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN`` 496f714a188SAmr Mokhtar 497f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_POS_LLR_1_BIT_SOFT_OUT`` 498f714a188SAmr Mokhtar 499f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT`` 500f714a188SAmr Mokhtar 501f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_MAP_DEC`` 502f714a188SAmr Mokhtar 503f714a188SAmr MokhtarExample: 504f714a188SAmr Mokhtar 505f714a188SAmr Mokhtar .. parsed-literal:: 506f714a188SAmr Mokhtar 507f714a188SAmr Mokhtar op_flags = 508f714a188SAmr Mokhtar RTE_BBDEV_TURBO_SUBBLOCK_DEINTERLEAVE, RTE_BBDEV_TURBO_EQUALIZER, 509f714a188SAmr Mokhtar RTE_BBDEV_TURBO_SOFT_OUTPUT 510f714a188SAmr Mokhtar 511f714a188SAmr MokhtarChain of operation statuses that are expected after operation is performed. 512f714a188SAmr MokhtarFollowing statuses can be used: 513f714a188SAmr Mokhtar 514f714a188SAmr Mokhtar- ``DMA`` 515f714a188SAmr Mokhtar 516f714a188SAmr Mokhtar- ``FCW`` 517f714a188SAmr Mokhtar 518f714a188SAmr Mokhtar- ``CRC`` 519f714a188SAmr Mokhtar 520f714a188SAmr Mokhtar- ``OK`` 521f714a188SAmr Mokhtar 522f714a188SAmr Mokhtar``OK`` means no errors are expected. Cannot be used with other values. 523f714a188SAmr Mokhtar 524f714a188SAmr Mokhtar.. parsed-literal:: 525f714a188SAmr Mokhtar 526f714a188SAmr Mokhtar expected_status = 527f714a188SAmr Mokhtar FCW, CRC 528f714a188SAmr Mokhtar 529f714a188SAmr Mokhtar 530f714a188SAmr MokhtarTurbo encoder test vectors template 531f714a188SAmr Mokhtar----------------------------------- 532f714a188SAmr Mokhtar 533f714a188SAmr MokhtarFor turbo encoder it has to be always set to ``RTE_BBDEV_OP_TURBO_ENC`` 534f714a188SAmr Mokhtar 535f714a188SAmr Mokhtar.. parsed-literal:: 536f714a188SAmr Mokhtar 537f714a188SAmr Mokhtar op_type = 538f714a188SAmr Mokhtar RTE_BBDEV_OP_TURBO_ENC 539f714a188SAmr Mokhtar 540f714a188SAmr MokhtarChain of uint32_t values 541f714a188SAmr Mokhtar 542f714a188SAmr Mokhtar.. parsed-literal:: 543f714a188SAmr Mokhtar 544f714a188SAmr Mokhtar input0 = 545f714a188SAmr Mokhtar 0x11d2bcac, 0x4d 546f714a188SAmr Mokhtar 547f714a188SAmr MokhtarChain of uint32_t values 548f714a188SAmr Mokhtar 549f714a188SAmr Mokhtar.. parsed-literal:: 550f714a188SAmr Mokhtar 551f714a188SAmr Mokhtar output0 = 552f714a188SAmr Mokhtar 0xd2399179, 0x640eb999, 0x2cbaf577, 0xaf224ae2, 0x9d139927, 0xe6909b29, 553f714a188SAmr Mokhtar 0xa25b7f47, 0x2aa224ce, 0x79f2 554f714a188SAmr Mokhtar 555f714a188SAmr Mokhtaruint32_t value 556f714a188SAmr Mokhtar 557f714a188SAmr Mokhtar.. parsed-literal:: 558f714a188SAmr Mokhtar 559f714a188SAmr Mokhtar e = 560f714a188SAmr Mokhtar 272 561f714a188SAmr Mokhtar 562f714a188SAmr Mokhtaruint16_t value 563f714a188SAmr Mokhtar 564f714a188SAmr Mokhtar.. parsed-literal:: 565f714a188SAmr Mokhtar 566f714a188SAmr Mokhtar k = 567f714a188SAmr Mokhtar 40 568f714a188SAmr Mokhtar 569f714a188SAmr Mokhtaruint16_t value 570f714a188SAmr Mokhtar 571f714a188SAmr Mokhtar.. parsed-literal:: 572f714a188SAmr Mokhtar 573f714a188SAmr Mokhtar ncb = 574f714a188SAmr Mokhtar 192 575f714a188SAmr Mokhtar 576f714a188SAmr Mokhtaruint8_t value 577f714a188SAmr Mokhtar 578f714a188SAmr Mokhtar.. parsed-literal:: 579f714a188SAmr Mokhtar 580f714a188SAmr Mokhtar rv_index = 581f714a188SAmr Mokhtar 0 582f714a188SAmr Mokhtar 583f714a188SAmr MokhtarChain of flags for turbo encoder operation. Following flags can be used: 584f714a188SAmr Mokhtar 585f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_RV_INDEX_BYPASS`` 586f714a188SAmr Mokhtar 587f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_RATE_MATCH`` 588f714a188SAmr Mokhtar 589f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_CRC_24B_ATTACH`` 590f714a188SAmr Mokhtar 591f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_CRC_24A_ATTACH`` 592f714a188SAmr Mokhtar 593f714a188SAmr Mokhtar- ``RTE_BBDEV_TURBO_ENC_SCATTER_GATHER`` 594f714a188SAmr Mokhtar 595f714a188SAmr Mokhtar``RTE_BBDEV_TURBO_ENC_SCATTER_GATHER`` is used to indicate the parser to 596f714a188SAmr Mokhtarforce the input data to be memory split and formed as a segmented mbuf. 597f714a188SAmr Mokhtar 598f714a188SAmr Mokhtar 599f714a188SAmr Mokhtar.. parsed-literal:: 600f714a188SAmr Mokhtar 601f714a188SAmr Mokhtar op_flags = 602f714a188SAmr Mokhtar RTE_BBDEV_TURBO_RATE_MATCH 603f714a188SAmr Mokhtar 604f714a188SAmr MokhtarChain of operation statuses that are expected after operation is performed. 605f714a188SAmr MokhtarFollowing statuses can be used: 606f714a188SAmr Mokhtar 607f714a188SAmr Mokhtar- ``DMA`` 608f714a188SAmr Mokhtar 609f714a188SAmr Mokhtar- ``FCW`` 610f714a188SAmr Mokhtar 611f714a188SAmr Mokhtar- ``OK`` 612f714a188SAmr Mokhtar 613f714a188SAmr Mokhtar``OK`` means no errors are expected. Cannot be used with other values. 614f714a188SAmr Mokhtar 615f714a188SAmr Mokhtar.. parsed-literal:: 616f714a188SAmr Mokhtar 617f714a188SAmr Mokhtar expected_status = 618f714a188SAmr Mokhtar OK 619