Add SpMcRingBuffer to base class StimulusBuffer

This will hopefully genericise the interface for Stimbuffs.
This commit is contained in:
2025-11-01 00:06:42 -04:00
parent 5af7e531b6
commit cdade17905
4 changed files with 29 additions and 5 deletions
+8
View File
@@ -20,6 +20,14 @@ public:
: sequenceNo(0)
{}
~SequenceLock() = default;
// Non-copyable, non-movable (std::atomic is neither copyable nor movable)
SequenceLock(const SequenceLock&) = delete;
SequenceLock& operator=(const SequenceLock&) = delete;
SequenceLock(SequenceLock&&) = delete;
SequenceLock& operator=(SequenceLock&&) = delete;
/* Atomically increments sequenceNo and issues a release barrier.
* Makes the sequence number odd, indicating a write is in progress.
*/