Unexpected Increase in Latency with More Readers in Multi-threaded Circular Queue Implementation in C++
I have implemented a circular queue using an array in C++. The queue uses two atomic variables, front and rear, to manage enqueue and dequeue operations. When an element is enqueued, rear is incremented, and when an element is dequeued, front is incremented.