<html><head></head><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px"><div id="yui_3_16_0_ym19_1_1465244153514_3520"><span id="yui_3_16_0_ym19_1_1465244153514_3576">Ah, so even the wfcqueue is a linked list under the covers? No ring buffer or other cache-friendly data structure types available?</span></div><div class="qtdSeparateBR" id="yui_3_16_0_ym19_1_1465244153514_3526"><br><br></div><div class="yahoo_quoted" id="yui_3_16_0_ym19_1_1465244153514_3524" style="display: block;">  <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;" id="yui_3_16_0_ym19_1_1465244153514_3523"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;" id="yui_3_16_0_ym19_1_1465244153514_3522"> <div dir="ltr" id="yui_3_16_0_ym19_1_1465244153514_3521"> <font size="2" face="Arial" id="yui_3_16_0_ym19_1_1465244153514_3549"> <hr size="1" id="yui_3_16_0_ym19_1_1465244153514_3548"> <b><span style="font-weight:bold;">From:</span></b> Mathieu Desnoyers <mathieu.desnoyers@efficios.com><br> <b><span style="font-weight: bold;">To:</span></b> "Mark E. Dawson, Jr." <medawsonjr@yahoo.com> <br><b><span style="font-weight: bold;">Cc:</span></b> lttng-dev <lttng-dev@lists.lttng.org><br> <b><span style="font-weight: bold;">Sent:</span></b> Monday, June 6, 2016 3:08 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [lttng-dev] SPMC Queue in URCU<br> </font> </div> <div class="y_msg_container" id="yui_3_16_0_ym19_1_1465244153514_3554"><br><div id="yiv8190243793"><div id="yui_3_16_0_ym19_1_1465244153514_3553"><div style="font-family:arial, helvetica, sans-serif;font-size:12pt;color:#000000;" id="yui_3_16_0_ym19_1_1465244153514_3552"><div id="yui_3_16_0_ym19_1_1465244153514_3551"><br clear="none"></div><div class="yiv8190243793yqt5593141440" id="yiv8190243793yqt24330"><div id="yui_3_16_0_ym19_1_1465244153514_3556"><span id="yiv8190243793zwchr">----- On Jun 6, 2016, at 2:48 PM, Mark E. Dawson, Jr. <medawsonjr@yahoo.com> wrote:<br clear="none"></span></div><div id="yui_3_16_0_ym19_1_1465244153514_3608"><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica, Arial, sans-serif;font-size:12pt;" id="yui_3_16_0_ym19_1_1465244153514_3607"><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px;" id="yui_3_16_0_ym19_1_1465244153514_3606"><div id="yiv8190243793yui_3_16_0_ym19_1_1465238402299_6084">All,</div><div id="yiv8190243793yui_3_16_0_ym19_1_1465238402299_6084"><br clear="none"></div><div id="yiv8190243793yui_3_16_0_ym19_1_1465238402299_6084">Is there a data structure offered by Userspace RCU that provides a bounded single producer multiple consumer queue? Or are we better off just using the linked list URCU data structure despite the cpu cache implications?</div></div></blockquote><div id="yui_3_16_0_ym19_1_1465244153514_3609"><br clear="none"></div><div id="yui_3_16_0_ym19_1_1465244153514_3611"><div id="yui_3_16_0_ym19_1_1465244153514_3610">Hi,</div><div id="yui_3_16_0_ym19_1_1465244153514_3612"><br clear="none"></div><div id="yui_3_16_0_ym19_1_1465244153514_3613">What we have in URCU is an unbounded SPMC queue (wfcqueue.h).</div><div id="yui_3_16_0_ym19_1_1465244153514_3614">You could theoretically use it with a counter to make it bounded, but</div><div>it might not be as efficient as a bounded SPMC queue, since we use</div><div>a linked list rather than a circular buffer. It would be interesting to</div><div>compare the performance of the two approaches.</div><div><br clear="none"></div><div>Note that wfcqueue is wait-free on the enqueue, blocking on the<br clear="none"></div><div>dequeue. It is used internally by URCU to implement the call_rcu<br clear="none"></div><div>scheme.<br clear="none"></div><div><br clear="none"></div><div>Thanks,</div><div><br clear="none"></div><div>Mathieu</div><div><br clear="none"></div></div><div><br clear="none"></div><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica, Arial, sans-serif;font-size:12pt;"><br clear="none">_______________________________________________<br clear="none">lttng-dev mailing list<br clear="none">lttng-dev@lists.lttng.org<br clear="none">https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev<br clear="none"></blockquote></div></div><div><br clear="none"></div><div>-- <br clear="none"></div><div>Mathieu Desnoyers<br clear="none">EfficiOS Inc.<br clear="none">http://www.efficios.com</div></div></div></div><br><br></div> </div> </div>  </div></div></body></html>