8 ms·
Interesting, I've never heard about anybody using this. Maybe a bit unreadable? But yeah, should work :)
by dalvrosa 7mo ago
Interesting, I've never heard about anybody using this. Maybe a bit unreadable? But yeah, should work :)
- mandarax8 7mo agoSee https://fgiesen.wordpress.com/2012/07/21/the-magic-ring-buffer/ https://fgiesen.wordpress.com/2012/07/21/the-magic-ring-buff... which takes it even further :)
- dalvrosa 7mo agoNice one!
- loeg 7mo agoI believe ConcurrencyKit's impl does this. https://github.com/concurrencykit/ck/blob/master/include/ck_ring.h#L124 https://github.com/concurrencykit/ck/blob/master/include/ck_...