<div dir="ltr"><div>Hi all,</div><div> </div><div>I also hit this bug in the recent developer version (checkout date is June 8).</div><div> </div><div>The scheduler plugin is Reduction to UNiprocessor (RUN), which is developed by me.</div>
<div>I believe that other scheduler plugins also hit this bug when bheap_delete() is called.</div><div> </div><div>When hitting this bug, is_queued(task) is true but the task is not in the ready queue.</div><div>I think that the task is in the release heap queue and is not merged into the ready queue.</div>
<div> </div><div>For example,</div><div>CPU1: call release_jobs() but not get lock.</div><div>CPU2: call bheap_delete() but the task is not in the ready queue and is in the release heap queue.</div><div> </div><div>One of the solutions is to check if the task is in the ready queue and not in the release heap queue</div>
<div>when bheap_delete() is called.</div><div> </div><div>Are there better solutions?</div><div> </div><div> </div><div>- Hiro</div><div> <br></div><div class="gmail_extra"><div class="gmail_quote">On Thu, Feb 21, 2013 at 10:57 AM, Jonathan Herman <span dir="ltr"><<a href="mailto:hermanjl@cs.unc.edu" target="_blank">hermanjl@cs.unc.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid"><div dir="ltr">The race is caused by:<div>1. Userspace completion of task on CPU 1</div>
<div>2. Kernelspace requeue() of task on CPU 2</div><div>3. Kernelspace reschedule and job_completion of task on CPU 1</div>
<div><br></div><div>Shouldn't the other plugins be vulnerable to the same race condition? I also encountered this in C-EDF (on a KVM, only with CONFIG_..._AFFINITY), but I can see the same sequence of calls occurring under other plugins.</div>
</div><div class="gmail_extra"><div><div class="h5"><br><br><div class="gmail_quote">On Tue, Jan 29, 2013 at 9:47 AM, Björn Brandenburg <span dir="ltr"><<a href="mailto:bbb@mpi-sws.org" target="_blank">bbb@mpi-sws.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid"><div><br>
On Jan 29, 2013, at 2:02 PM, Glenn Elliott <<a href="mailto:gelliott@cs.unc.edu" target="_blank">gelliott@cs.unc.edu</a>> wrote:<br>
<br>
> Can you say why I was only hitting this bug in a C-EDF partitioned case? Did it only make this race condition more likely?<br>
<br>
</div>I believe that race always existed, but we only started hitting it with the new synchronous release code under certain configurations. I never saw it in KVM, for instance, and not on all physical machines.<br>
<span><font color="#888888"><br>
- Björn<br>
</font></span><div><div><br>
<br>
_______________________________________________<br>
litmus-dev mailing list<br>
<a href="mailto:litmus-dev@lists.litmus-rt.org" target="_blank">litmus-dev@lists.litmus-rt.org</a><br>
<a href="https://lists.litmus-rt.org/listinfo/litmus-dev" target="_blank">https://lists.litmus-rt.org/listinfo/litmus-dev</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div></div></div><span class="HOEnZb"><font color="#888888">-- <br>Jonathan Herman<br>Department of Computer Science at UNC Chapel Hill
</font></span></div>
<br>_______________________________________________<br>
litmus-dev mailing list<br>
<a href="mailto:litmus-dev@lists.litmus-rt.org">litmus-dev@lists.litmus-rt.org</a><br>
<a href="https://lists.litmus-rt.org/listinfo/litmus-dev" target="_blank">https://lists.litmus-rt.org/listinfo/litmus-dev</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br><p style="margin:0px;color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">Hiroyuki Chishiro</p><p style="margin:0px;color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">
Visiting Scholar</p><p style="margin:0px;color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">Department of Computer Science</p><p style="margin:0px;color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">
The University of North Carolina at Chapel Hill</p>
</div></div>