DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] doc/eal: add caveat about spinlocks from non-pinned threads
@ 2022-06-10 15:28 Stephen Hemminger
  2022-06-10 23:45 ` Tyler Retzlaff
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Stephen Hemminger @ 2022-06-10 15:28 UTC (permalink / raw)
  To: dev; +Cc: anatoly.burakov, Stephen Hemminger

Need to warn users of DPDK spinlocks from non-pinned threads.
This is similar wording to Linux documentation in pthread_spin_init.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 doc/guides/prog_guide/env_abstraction_layer.rst | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/doc/guides/prog_guide/env_abstraction_layer.rst b/doc/guides/prog_guide/env_abstraction_layer.rst
index 5f0748fba1c0..45d3de8d84f6 100644
--- a/doc/guides/prog_guide/env_abstraction_layer.rst
+++ b/doc/guides/prog_guide/env_abstraction_layer.rst
@@ -797,6 +797,16 @@ Known Issues
 
   The debug statistics of rte_ring, rte_mempool and rte_timer are not supported in an unregistered non-EAL pthread.
 
++ locking
+
+  If a pthread, that is not pinned to an lcore acquires a lock such as a
+  DPDK based lock (rte_spinlock, rte_rwlock, rte_ticketlock, rte_mcslock)
+  then there is a possibility of large application delays.
+  The problem is that if a thread is scheduled off the CPU while it holds
+  a lock, then other threads will waste time spinning on the lock until
+  the lock holder is once more rescheduled and releases the lock.
+
+
 cgroup control
 ~~~~~~~~~~~~~~
 
-- 
2.35.1


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-06-11 16:41 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-10 15:28 [PATCH] doc/eal: add caveat about spinlocks from non-pinned threads Stephen Hemminger
2022-06-10 23:45 ` Tyler Retzlaff
2022-06-10 23:48 ` Tyler Retzlaff
2022-06-11  0:00   ` Stephen Hemminger
2022-06-11  1:55 ` fengchengwen
2022-06-11  3:33   ` Stephen Hemminger
2022-06-11 16:41 ` Mattias Rönnblom

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).