|WARNING| [v5, 2/2] dts: add pvp multi paths virtio performance testsuite

dpdklab at iol.unh.edu dpdklab at iol.unh.edu
Tue Nov 10 23:53:50 CET 2026


Test-Label: ai-code-review
Test-Status: WARNING
https://dpdk.org/patch/172811

_AI Code Review_

=== Patch Review: series.patch (via Claude) ===
Review date: 2026-11-10

**Patch 1/2: dts: add pvp multi paths vhost performance testsuite**

**Errors**

1. The 1518-byte default frame size builds a packet the SUT drops at the default MTU.
   ```python
   / Raw(load="x" * (frame_size - 14 - 20))
   ```
   This subtracts only the Ethernet and IP headers and does not account for the 4-byte FCS. A `frame_size` of 1518 gives a 1504-byte IP datagram, which exceeds MTU 1500, and a 1522-byte untagged frame on the wire. The NIC will drop or truncate it, so the `PerfSuiteConfig(frame_size=1518, ...)` default always fails. Every other size is also 4 bytes larger on the wire than the configured value.
   Fix: subtract the CRC as well, e.g. `frame_size - 14 - 20 - 4`, or use named constants for the header and CRC lengths. The same code appears in patch 2/2.

**Warnings**

1. `test_perf_vhost_single_core_virtio_nonmergeable` exercises the same path as `test_perf_vhost_single_core_virtio_vectorized`.
   ```python
   ring_format=0,
   buffers=0,
   in_order=0,
   vectorized=1,
   ```
   This duplicates the vectorized case (only `extra_args` differs), so the scalar split-ring non-mergeable path is never tested. It also looks like a copy-paste error, since the docstring also says "vectorized=1". Use `vectorized=0` here and fix the docstring. The same issue exists in patch 2/2.

2. `PerfSuiteConfig.passing` is typed as `float` but is assigned and compared as a bool.
   ```python
   passing: float | None = None
   ...
   params.passing = float(performance_delta) >= -self.config.delta_tolerance
   ```
   The model is declared `strict=True`, but `validate_assignment` is not enabled, so the wrong type is never caught. If the model is ever re-validated, a bool will be rejected. Declare it as `passing: bool | None = None`.

**Info**

1. The fallbacks are dead code, because `num_descriptors` and `expected_mpps` are required fields of `PerfSuiteConfig`:
   ```python
   num_descriptors = params.num_descriptors if params.num_descriptors else 1024
   expected_mpps = params.expected_mpps if params.expected_mpps else 1.00
   ```
   Also, `int(num_descriptors)` and `int(frame_size)` are redundant because the fields are already `int`.

2. The check `verify(expected_mpps > 0, ...)` runs only after both TestPmd instances are launched. Validate the configuration before starting the shells, or add a field validator (`gt=0`) on `PerfSuiteConfig`.

3. `_produce_stats_table()` writes results with `print()`. Consider using the suite logger so the output is captured in the DTS logs.

4. `PerfSuiteConfig` is a generic performance-suite model unrelated to testpmd parameters. A more appropriate home is `api/test_suite.py` or a perf-specific module rather than `api/testpmd/config.py`.

5. The example YAML adds a `pvp_multi_paths_virtio_single_core_perf` entry in this patch, but that suite is added in patch 2/2. The entry belongs in patch 2/2.

6. `cast(RSSSetting, RSSSetting.SetIPOnly())` is repeated in nearly every test. If the cast is needed for typing, consider a module-level constant or a helper.

**Patch 2/2: dts: add pvp multi paths virtio performance testsuite**

**Warnings**

1. All test case names in the virtio suite are copied from the vhost suite, e.g. `test_perf_vhost_single_core_virtio11_mergeable`. This makes results and JSON output from the two suites indistinguishable by test name. Rename them to `test_perf_virtio_single_core_*`.

2. The input validation uses a bare `assert`, which is stripped under `python -O` and gives no DTS-formatted failure:
   ```python
   assert expected_mpps > 0, "Invalid expected mpps, must be greater than 0."
   ```
   Patch 1/2 uses `verify()` for the same check. Use `verify()` here too.

3. The patch includes an unrelated documentation change in `dts/api/test_suite.py`, removing "cryptodev" from the `make_decorator` docstring. It does not belong in a patch adding a test suite. Drop it, or split it into its own patch with justification.

**Info**

1. The `Config` docstring is copied from the vhost suite and names the wrong suite:
   ```python
   """Test configuration for pvp_multi_paths_vhost_single_core_perf test suite."""
   ```

2. `test_perf_vhost_single_core_virtio11_vectorized` passes `queues=2`, which differs from the equivalent test in patch 1/2 and from every other case. Neither testpmd instance is given matching `rx_queues`/`tx_queues` or `nb_cores` for two queues. If two queues are intended, document why and configure testpmd accordingly; otherwise drop the argument.

3. The 4-byte FCS sizing issue and the duplicated `virtio_nonmergeable`/`virtio_vectorized` parameters reported in patch 1/2 also apply to this file.

Review-Result: ERROR


More information about the test-report mailing list