Accessing TLS for EAL threads
Stephen Hemminger
stephen at networkplumber.org
Thu Nov 18 17:26:37 CET 2021
On Tue, 16 Nov 2021 17:38:43 +0000
Antonio Di Bacco <antonio.di-bacco at keysight.com> wrote:
> I need to emulate the pthread_setspecific and pthread_getspecific for EAL threads. I don't find any suitable APIs in the DPDK to access the TLS and get and set keys.
>
> I launched a number of threads using the rte_eal_remote launch but I don't find any API that allows me to access the TLS for those threads.
There is not an API for a thread to access another threads local storage directly.
The DPDK TLS is wrapper around the glibc (and Windows) implementation of TLS.
For particular data structures, you can create a global data structure that is an
array of pointers indexed by lcore, and each lcore fills in itself.
Or do a more complex API via message passing.
More information about the users
mailing list