From a0d3b1cf6a396bab0fac939d1abc190cf7e74128 Mon Sep 17 00:00:00 2001 From: webbrain-one <295484252+webbrain-one@users.noreply.github.com> Date: Sun, 23 Aug 2026 13:30:52 +0300 Subject: [PATCH] docs: improve README --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e4f1c74..07c740d 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ + + # MPSC_queue [![C++](https://img.shields.io/badge/C++-17-blue.svg?logo=cplusplus)](https://isocpp.org/) @@ -149,7 +151,7 @@ This scenario tests the throughput when multiple producers write to the queue co | Queue | P (Producers) | C (Consumer) | **Throughput (M int/s)** | Notes | | :--- | :--- | :--- | :--- | :--- | -| **daking** | 1 | 1 | **150.146** | **SPSC Baseline (Fast Path)** | +| **daking** | 1 | 1 | **150.14646** | **SPSC Baseline (Fast Path)** | | daking | 2 | 1 | 46.9628 | | | daking | 4 | 1 | 58.246 | Peak under uniform contention | | daking | 8 | 1 | 49.686 | | @@ -320,7 +322,7 @@ queue.enqueue_bulk(input.begin(), 3); int max_fetch = 3; std::vector output; -// try_dequeue_bulk is likely intended here, but using 'results' from previous context for consistency with the prompt. +// Dequeues up to max_fetch elements into output. size_t count = queue.try_dequeue_bulk(std::back_inserter(output), max_fetch); // Returns the number of successfully dequeued elements (not exceeding max_fetch). // Supports both Forward Iterators (e.g., output.begin()) and Output Iterators (e.g., back_inserter).