Messages in this thread |
<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div><span></span></div><div><br><div><br>On Jul 29, 2018, at 5:00 AM, Rik van Riel <<a href="mailto:riel@surriel.com">riel@surriel.com</a>> wrote:<br><br></div><blockquote type="cite"><div><span>On Sat, 2018-07-28 at 19:57 -0700, Andy Lutomirski wrote:</span><br><blockquote type="cite"><span>On Sat, Jul 28, 2018 at 2:53 PM, Rik van Riel <<a href="mailto:riel@surriel.com">riel@surriel.com</a>></span><br></blockquote><blockquote type="cite"><span>wrote:</span><br></blockquote><blockquote type="cite"><blockquote type="cite"><span>Introduce a variant of on_each_cpu_cond that iterates only over the</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>CPUs in a cpumask, in order to avoid making callbacks for every</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>single</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>CPU in the system when we only need to test a subset.</span><br></blockquote></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>Nice.</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>Although, if you want to be really fancy, you could optimize this (or</span><br></blockquote><blockquote type="cite"><span>add a variant) that does the callback on the local CPU in parallel</span><br></blockquote><blockquote type="cite"><span>with the remote ones. That would give a small boost to TLB flushes.</span><br></blockquote><span></span><br><span>The test_func callbacks are not run remotely, but on</span><br><span>the local CPU, before deciding who to send callbacks</span><br><span>to.</span><br><span></span><br><span>The actual IPIs are sent in parallel, if the cpumask</span><br><span>allocation succeeds (it always should in many kernel</span><br><span>configurations, and almost always in the rest).</span><br><span></span><br></div></blockquote><div><br></div><div>What I meant is that on_each_cpu_mask does:</div><div><br></div><div><pre style="padding: 0px; margin-top: 0px; margin-bottom: 0px;"><code style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><font face="UICTFontTextStyleBody"><span class="hl kwd">smp_call_function_many</span><span class="hl opt">(</span>mask<span class="hl opt">,</span> func<span class="hl opt">,</span> info<span class="hl opt">,</span> wait<span class="hl opt">);</span></font></code></pre><pre style="padding: 0px; margin-top: 0px; margin-bottom: 0px;"><code style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><font face="UICTFontTextStyleBody"> | ||||||||||||
Last update: 2018-07-29 17:37 [W:0.328 / U:0.760 seconds] ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site |