iceoryx icon indicating copy to clipboard operation
iceoryx copied to clipboard

Some questions about IndexQueue.

Open Xcliu opened this issue 1 month ago • 10 comments

Brief description

In my application, I've used the lock-free queue in iceoryx and noticed that the push operation is taking approximately 2 seconds to complete in some cases. Upon reviewing the lock-free queue's implementation, I've observed that the pop function within the IndexQueue could potentially lead to an infinite loop scenario when multiple threads are attempting to pop items simultaneously without any threads pushing new items. Am I correct in this assessment, or could there be other factors at play that I might have overlooked?

I would greatly appreciate any advice or insights on this matter.

Detailed information

https://github.com/eclipse-iceoryx/iceoryx/blob/cb2608a77f362d86e705269ae6bf6ba3340e6ddf/iceoryx_hoofs/concurrent/buffer/include/iox/detail/mpmc_lockfree_queue/mpmc_index_queue.inl#L139

Xcliu avatar May 30 '24 12:05 Xcliu