<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">2013/4/25 Joel Sherrill <span dir="ltr"><<a href="mailto:joel.sherrill@oarcorp.com" target="_blank">joel.sherrill@oarcorp.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class=""><div class="h5">On 4/25/2013 9:40 AM, Gedare Bloom wrote:<br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
On Thu, Apr 25, 2013 at 10:34 AM, Joel Sherrill<br>
<<a href="mailto:joel.sherrill@oarcorp.com" target="_blank">joel.sherrill@oarcorp.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
On 4/25/2013 9:26 AM, yangwei weiyang wrote:<br>
<br>
<br>
2013/4/25 Pavel Pisa <<a href="mailto:ppisa4lists@pikron.com" target="_blank">ppisa4lists@pikron.com</a>><br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Hello Deng Hengyi,<br>
<br>
On Thursday 25 April 2013 07:27:20 wei.a.yang wrote:<br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Hi, Pavel. Thank you for your advice. And in my former mail my proposal<br>
is<br>
very similar with the mechanism in the Linux. But the different is that<br>
I<br>
use two min-heap instead of two plist because of good algorithm<br>
complexity<br>
of min-heap.<br>
</blockquote>
It worth to evaluate what is better algorithm - RB-tree or min-heap.<br>
RB tree allows to use "static" nodes which are part of the task<br>
structure. The classic array base heap tree with 2n and 2n+1 children<br>
requires per queue array allocation and result in the limited/compile<br>
time defined depth or requires reallocations. But may it be you have<br>
other algorithm on mind.<br>
<br>
</blockquote>
Yeah, now in my opinion the algorithm candidates are RB tree and min-heap.<br>
But just as you said the disadvantage of min-heap is its size allocation. So<br>
i will<br>
evalutate the two and select a more suitable for RTEMS. If you have any more<br>
better way please comment freely.<br>
<br>
Gedare and I have been discussing the idea of Thread Sets which are<br>
ordered by priority. We currently have three implementations of this<br>
functionality in RTEMS:<br>
<br>
+ Deterministic Priority Scheduler's bitmaps and FIFO set<br>
+ Simple Priority Scheduler single list<br>
+ Thread Queue Priority Blocking Block2N structure<br>
<br>
</blockquote>
There is also the rbtree ready queue in EDF/CBS.<br>
</blockquote></div></div>
Forgot that one. :(<div class="im"><br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I would like to see these all use "classes" which implement the Thread Set.<br>
The choice of which algorithm to use is determined by O(space) and O(time).<br>
The decision can vary based on use case in RTEMS or application<br>
requirements.<br>
<br>
</blockquote>
The Thread Set for scheduling is being proposed by a different<br>
student. We should avoid overlap/dependency here. Weiy is looking at<br>
synchronization problems in SMP along with the atomic operations code<br>
improvements. We can refactor the approach taken into a thread set<br>
later if it makes sense and we have solved the Thread Set design and<br>
implementation issues.<br>
</blockquote></div>
Agreed. But if his project ends up creating another one or duplicating one<br>
that that student would end up doing, then it needs to follow the Thread Set<br>
model rather than creating another problem.<br>
<br>
At that point, it is just a matter of who implements one class first. It is just<br>
packaging but better to do it in the right form. If he ends up creating the<br>
rbtree Thread Set the same as the EDF/CBS schedulers, then the other<br>
student just has to move the schedulers to using that.<br>
<br>
I don't want to add that work to this project. Just avoid creating work<br>
to be redone later.</blockquote><div><span id="result_box" class="" lang="en"><span class="">From the IRC log of talking about the "thread set" i got the core of "thread set" is to implement a class framework of how to operate the threads blocked by acquiring resources according to different schedulers. </span></span>I do know whether i really understand the <span id="result_box" class="" lang="en"><span class="">mechanism of "thread set", if wrong please correct me. <br>
<br></span></span></div><div><span id="result_box" class="" lang="en"><span class="">The key to solve this </span></span>priority inheritance algorithms is also to find a suitable method or algorithms to operate the threads blocked by mutex, so if the "thread set" is proposaled by another student i think this problem can be solved after the design of "thread set" is done. Because if this priority inheritance algorithms is solved now it also should be modified to adapt the "thread set".<br>
<br></div><div>But i think the "thread set" does not impact the choice of algorithms. I understand the "thread set" is just a framework, different algorithms to manage the priority ordered thread can be exsit in the "thread set", is it right?<br>
</div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class=""><div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
If we need another set managed by another structure, that is fine. But I<br>
think this set of helper classes is important to have.<br>
<br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I have done some testing of RTEMS and Linux PI implementations.<br>
You can find my test code cor RTEMS classic API<br>
and POSIX RTEMS and Linux in the repo<br>
</blockquote>
Good work. But I want to know the mechanism of RTEMS test. You know<br>
there<br>
are two PI algorithms in RTEMS. One is used by default, the other one<br>
should define __RTEMS_STRICT_ORDER_MUTEX__ to use it. You test two<br>
algorithms all?<br>
</blockquote>
I have tested default one. The __RTEMS_STRICT_ORDER_MUTEX__ should<br>
behave as expected but there is risk that some code/libray we use<br>
does not access mutexes in the strict LIFO order.<br>
<br>
Best wishes,<br>
<br>
Pavel<br>
</blockquote>
<br>
<br>
<br>
--<br>
Wei Yang<br>
Best Regards<br>
<br>
wei.a.yang at <a href="http://gmail.com" target="_blank">gmail.com</a><br>
<br>
<br>
<br>
--<br>
Joel Sherrill, Ph.D. Director of Research & Development<br>
joel.sherrill@OARcorp.com On-Line Applications Research<br>
Ask me about RTEMS: a free RTOS Huntsville AL 35805<br>
Support Available (256) 722-9985<br>
<br>
<br>
______________________________<u></u>_________________<br>
rtems-devel mailing list<br>
<a href="mailto:rtems-devel@rtems.org" target="_blank">rtems-devel@rtems.org</a><br>
<a href="http://www.rtems.org/mailman/listinfo/rtems-devel" target="_blank">http://www.rtems.org/mailman/<u></u>listinfo/rtems-devel</a><br>
<br>
</blockquote></blockquote>
<br>
<br>
-- <br>
Joel Sherrill, Ph.D. Director of Research & Development<br>
joel.sherrill@OARcorp.com On-Line Applications Research<br>
Ask me about RTEMS: a free RTOS Huntsville AL 35805<br>
Support Available (256) 722-9985<br>
<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Wei Yang<br>Best Regards<br><br>wei.a.yang at <a href="http://gmail.com" target="_blank">gmail.com</a> <br><br>
</div></div>