ringbuffer icon indicating copy to clipboard operation
ringbuffer copied to clipboard

Add a try_reserve_read() method to avoid extra copies on read

Open bslatkin opened this issue 8 years ago • 0 comments

Similar idea to #1 except for readers. The idea is you'd quickly get a handle on a slot. Then you could have a ctypes.Structure map to it using from_buffer(). You'd read out everything you need quickly, and then call read_finished() on the slot when you were done.

Other readers would be able to read the same slot and do the same thing. The writer wouldn't be able to overwrite that slot until all readers had called read_finished() on it.

bslatkin avatar Aug 08 '16 05:08 bslatkin