[dpdk-dev] [PATCH 0/7] Register external threads as lcore
Jerin Jacob
jerinjacobk at gmail.com
Wed Jun 10 17:09:30 CEST 2020
On Wed, Jun 10, 2020 at 8:15 PM David Marchand
<david.marchand at redhat.com> wrote:
>
> OVS and some other applications have been hacking into DPDK internals to
> fake EAL threads and avoid performance penalty of only having non-EAL
> threads.
>
> This series proposes to add a new type of lcores and maps those external
> threads to such lcores.
> Those threads won't run the DPDK eal mainloop and as a consequence part of
> the EAL threads API cannot work.
>
> Having new lcores appearing during the process lifetime is not expected
> by some DPDK components. This is addressed by notifying of such lcore
> hotplug.
>
> This patchset has still some more work (like refusing new lcore type in
> incompatible EAL threads API, updating the documentation and adding unit
> tests) but I am sending it anyway as I would like to get this in for
> 20.08.
Cool feature.
Is mempool's lcore local cache working for external cores with this scheme?
>
> For the interested parties, I have a patch [1] against dpdk-latest OVS
> branch that makes use of this series.
>
> 1: https://github.com/david-marchand/ovs/commit/dpdk-latest-external-lcores
Usage is clear from the example code,
Looking forward to having documentation and UT for the new API
in the next version.
>
> --
> David Marchand
>
> David Marchand (7):
> eal: relocate per thread symbols to common
> eal: fix multiple definition of per lcore thread id
> eal: introduce thread init helper
> eal: introduce thread uninit helper
> eal: register non-EAL threads as lcore
> eal: dump lcores
> eal: add lcore hotplug notifications
>
> doc/guides/howto/debug_troubleshoot.rst | 5 +-
> lib/librte_eal/common/eal_common_lcore.c | 167 +++++++++++++++++++++-
> lib/librte_eal/common/eal_common_thread.c | 143 ++++++++++++++----
> lib/librte_eal/common/eal_common_trace.c | 49 ++++++-
> lib/librte_eal/common/eal_private.h | 43 ++++++
> lib/librte_eal/common/eal_thread.h | 26 +++-
> lib/librte_eal/common/eal_trace.h | 1 +
> lib/librte_eal/freebsd/eal.c | 16 ++-
> lib/librte_eal/freebsd/eal_thread.c | 38 +----
> lib/librte_eal/include/rte_eal.h | 12 +-
> lib/librte_eal/include/rte_lcore.h | 112 +++++++++++++--
> lib/librte_eal/linux/eal.c | 17 ++-
> lib/librte_eal/linux/eal_thread.c | 38 +----
> lib/librte_eal/rte_eal_version.map | 14 ++
> lib/librte_eal/windows/eal.c | 3 +-
> lib/librte_eal/windows/eal_thread.c | 14 +-
> 16 files changed, 536 insertions(+), 162 deletions(-)
>
> --
> 2.23.0
>
More information about the dev
mailing list