Skip to content

net/mlx5: insertion rate optimization

Suanming Mou dpdk-dev 5 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest26 patches 1 replyIn review
  2. v526 patches 2 repliesSuperseded
  3. v426 patches 0 repliesSuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v322 patches0 repliesSuperseded
v222 patches0 repliesSuperseded

v4 from the cover letter

- split the list utility to commom patch
- fix one ipool crash issue in mlx5_ipool_get_cache() function.
- reorganize the common and mlx5 patches.
- split the doc update to an individual patch.
- update and rebase to the latest version.

Patches in v6 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/26net/mlx5: allow limiting the index pool maximum indexdrivers/net/mlx5/mlx5_utils.c drivers/net/mlx5/mlx5_utils.h+13 -20 replies
2/26net/mlx5: add indexed pool local cachedrivers/net/mlx5/mlx5_utils.c drivers/net/mlx5/mlx5_utils.h+372 -150 replies
3/26net/mlx5: add index pool foreach definedrivers/net/mlx5/mlx5_utils.c drivers/net/mlx5/mlx5_utils.h+104 -00 replies
4/26net/mlx5: support index pool non-lcore operationsdrivers/net/mlx5/mlx5_utils.c drivers/net/mlx5/mlx5_utils.h+56 -220 replies
5/26net/mlx5: replace flow list with index pooldrivers/net/mlx5/linux/mlx5_os.c drivers/net/mlx5/mlx5.c drivers/net/mlx5/mlx5.h +5 more+127 -1120 replies
6/26net/mlx5: optimize modify header action memorydrivers/common/mlx5/linux/mlx5_glue.h drivers/net/mlx5/linux/mlx5_flow_os.h drivers/net/mlx5/mlx5_flow.h +1 more+12 -110 replies
7/26net/mlx5: remove cache term from the list utilitydrivers/net/mlx5/linux/mlx5_os.c drivers/net/mlx5/mlx5.c drivers/net/mlx5/mlx5.h +7 more+456 -4610 replies
8/26net/mlx5: add per lcore cache to the list utilitydrivers/net/mlx5/linux/mlx5_os.c drivers/net/mlx5/mlx5.h drivers/net/mlx5/mlx5_flow.h +6 more+451 -1350 replies
9/26net/mlx5: minimize list critical sectionsdrivers/net/mlx5/mlx5_utils.c drivers/net/mlx5/mlx5_utils.h+48 -430 replies
10/26net/mlx5: manage list cache entries releasedrivers/net/mlx5/mlx5_utils.c drivers/net/mlx5/mlx5_utils.h+54 -270 replies
11/26net/mlx5: relax the list utility atomic operationsdrivers/net/mlx5/mlx5_utils.c+6 -60 replies
12/26net/mlx5: allocate list memory by the create APIdrivers/net/mlx5/linux/mlx5_os.c drivers/net/mlx5/mlx5.c drivers/net/mlx5/mlx5.h +6 more+139 -830 replies
13/26common/mlx5: move list utility to commondrivers/common/mlx5/mlx5_common.h drivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h +3 more+464 -4480 replies
14/26common/mlx5: add list lcore sharedrivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h drivers/net/mlx5/linux/mlx5_os.c +2 more+56 -230 replies
15/26common/mlx5: call list callbacks with contextdrivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h drivers/net/mlx5/mlx5_flow.h +3 more+132 -2030 replies
16/26common/mlx5: add per-lcore cache to hash list utilitydrivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h drivers/net/mlx5/linux/mlx5_os.c +5 more+482 -4820 replies
17/26common/mlx5: allocate cache list memory individuallydrivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h+45 -190 replies
18/26common/mlx5: optimize cache list object memorydrivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h+201 -1390 replies
19/26common/mlx5: support list non-lcore operationsdrivers/common/mlx5/mlx5_common_utils.c drivers/common/mlx5/mlx5_common_utils.h+71 -300 replies
20/26net/mlx5: move modify header allocator to ipooldrivers/net/mlx5/mlx5.c drivers/net/mlx5/mlx5.h drivers/net/mlx5/mlx5_flow.h +1 more+86 -250 replies
21/26net/mlx5: adjust the hash bucket sizedrivers/net/mlx5/linux/mlx5_os.c drivers/net/mlx5/mlx5.c drivers/net/mlx5/mlx5_defs.h +1 more+7 -80 replies
22/26net/mlx5: enable index pool per-core cachedrivers/net/mlx5/mlx5.c drivers/net/mlx5/mlx5.h drivers/net/mlx5/mlx5_flow_dv.c+6 -20 replies
23/26net/mlx5: optimize hash list table allocate on demanddrivers/net/mlx5/linux/mlx5_os.c drivers/net/mlx5/mlx5_defs.h drivers/net/mlx5/mlx5_flow_dv.c +1 more+82 -490 replies
24/26net/mlx5: change memory release configurationdrivers/net/mlx5/mlx5.c+2 -00 replies
25/26net/mlx5: optimize Rx queue matchdrivers/net/mlx5/mlx5_rxq.c+7 -110 replies
26/26doc: add mlx5 multiple-thread flow insertion optimizationdoc/guides/nics/mlx5.rst doc/guides/rel_notes/release_21_08.rst+6 -00 replies

Reviews trailers per patch

All 26 patches have a Reviewed-by or Acked-by.

PatchMatan AzradSuanming Mou
1/26A-b
2/26A-b
3/26A-b
4/26A-b
5/26A-b
6/26A-b
7/26A-b
8/26A-b
9/26A-b
10/26A-b
11/26A-b
12/26A-b
13/26A-b
14/26A-b
15/26A-b
16/26A-b
17/26A-b
18/26A-b
19/26A-b
20/26A-b
21/26A-b
22/26A-b
23/26A-b
24/26A-b
25/26A-b
26/26A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v6 thread

Cover letter [dpdk-dev] [PATCH v6 00/26] net/mlx5: insertion rate optimization

This patch series optimize the flow insertion rate with adding local cache to index pool and list.

For object which wants efficient index allocate and free, local cache will be very helpful.

For index pool, two level cache is added, one as local and another as global. The global cache is able to save all the allocated index. That means all the allocated index will not be freed. Once the local cache is full, the extra index will be flushed to the global cache. Once local cache is empty, first try to fetch more index from global, if global is still empty, allocate new trunk and more index.

For list, sub local core list is introduced. The allocated objects will be added and released only from local list without any locks. Only the objects need to be shared will be synced from global list.

---

v6: fix compilation issue in "common/mlx5: add list lcore share" patch.

v5: code rebase to the latest version.

v4:
- split the list utility to commom patch
- fix one ipool crash issue in mlx5_ipool_get_cache() function.
- reorganize the common and mlx5 patches.
- split the doc update to an individual patch.
- update and rebase to the latest version.

v3: fix Windows compilation issue

v2: add the list per-lcore cache optimization

---

Matan Azrad (9):
net/mlx5: optimize modify header action memory net/mlx5: remove cache term from the list utility net/mlx5: add per lcore cache to the list utility net/mlx5: minimize list critical sections net/mlx5: manage list cache entries release net/mlx5: relax the list utility atomic operations net/mlx5: allocate list memory by the create API common/mlx5: add per-lcore cache to hash list utility net/mlx5: move modify header allocator to ipool

Suanming Mou (17):
net/mlx5: allow limiting the index pool maximum index net/mlx5: add indexed pool local cache
net/mlx5: add index pool foreach define net/mlx5: support index pool non-lcore operations net/mlx5: replace flow list with index pool common/mlx5: move list utility to common common/mlx5: add list lcore share
common/mlx5: call list callbacks with context common/mlx5: allocate cache list memory individually common/mlx5: optimize cache list object memory common/mlx5: support list non-lcore operations net/mlx5: adjust the hash bucket size
net/mlx5: enable index pool per-core cache net/mlx5: optimize hash list table allocate on demand net/mlx5: change memory release configuration net/mlx5: optimize Rx queue match
doc: add mlx5 multiple-thread flow insertion optimization

 doc/guides/nics/mlx5.rst                |    5 +
 doc/guides/rel_notes/release_21_08.rst  |    1 +
 drivers/common/mlx5/linux/mlx5_glue.h   |    1 +
 drivers/common/mlx5/mlx5_common.h       |    2 +
 drivers/common/mlx5/mlx5_common_utils.c |  569 ++++++++---
 drivers/common/mlx5/mlx5_common_utils.h |  294 ++++--
 drivers/common/mlx5/version.map         |    7 +
 drivers/net/mlx5/linux/mlx5_flow_os.h   |    3 +-
 drivers/net/mlx5/linux/mlx5_os.c        |  209 ++--
 drivers/net/mlx5/mlx5.c                 |   34 +-
 drivers/net/mlx5/mlx5.h                 |   46 +-
 drivers/net/mlx5/mlx5_defs.h            |   12 +-
 drivers/net/mlx5/mlx5_flow.c            |  308 +++---
 drivers/net/mlx5/mlx5_flow.h            |  209 ++--
 drivers/net/mlx5/mlx5_flow_dv.c         | 1206 +++++++++++++++--------
 drivers/net/mlx5/mlx5_rx.h              |   14 +-
 drivers/net/mlx5/mlx5_rxq.c             |  136 ++-
 drivers/net/mlx5/mlx5_trigger.c         |    8 +-
 drivers/net/mlx5/mlx5_utils.c           |  627 ++++++++----
 drivers/net/mlx5/mlx5_utils.h           |  255 ++---
 drivers/net/mlx5/windows/mlx5_os.c      |   11 +-
 21 files changed, 2543 insertions(+), 1414 deletions(-)
Signature · 1 line
2.25.1