<div dir="ltr"><div><br><br>On 18 March 2016 at 09:43, Sebastian Huber <<a href="mailto:sebastian.huber@embedded-brains.de">sebastian.huber@embedded-brains.de</a>> wrote:<br>><br>><br>> On 16/03/16 22:11, Chris Johns wrote:<br>>><br>>> On 16/03/2016 23:01, Darshit Shah wrote:<br>>>><br>>>> I have updated my draft proposal with a basic timeline for things that<br>>>> need to be done. The link is shared on the tracking page and has been<br>>>> submitted via the program website as well. I'm sharing it here as well:<br>>>> <a href="https://goo.gl/UmgS61">https://goo.gl/UmgS61</a><br>>>><br>>>> Since this is a draft proposal, it may not be completely polished yet.<br>>>> I'd appreciate any comments on it, especially the project description<br>>>> and timeline.<br>>>><br>><br>> " POSIX mandated processor affinityAPI"<br>><br>> This is actually not defined in POSIX. Its a non-portable Linux/BSD<br>> extension.<br>><br>That is true. I've fixed the documentation for this.<br><br>> "schedulable task sets would miss their deadlines since it does not consider<br>> migrating high priority tasks"<br>><br>> I think this is not correct. The current APA scheduler should implement<br>> strong APA. However, it may iterate several times over all (!) ready tasks.<br>> This is the actual problem.<br>><br>I may be wrong, but I think the current implementation does indeed not consider strong APA guarantees.<br><br>The `_Scheduler_priority_affinity_SMP_Get_lowest_scheduled` method tries to find a thread that needs to be migrated to another core in order to schedule the selected thread. In this method, on line 274 is the comment:<br><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex" class="gmail_quote">    /*<br>     * If we didn't find a thread which is of equal or lower importance<br>     * than filter thread is, then we can't schedule the filter thread<br>     * to execute.<br>     */<br><br></blockquote><br></div>If I understand this comment correctly, the scheduler does not consider threads for migration if they are not of "equal or lower importance" than the filter thread.<br><br><div><div><br>> I would use the name "APA" for the new scheduler, e.g. schedulerapasmp.c.<br><br></div><div>I kept it as "priorityapa" based on the existing naming convention. How about "Strong APA" to clearly state that this scheduler provides the Strong APA guarantees?<br><br></div><div>><br>> We already have a ticket for this work:<br>><br>> <a href="https://devel.rtems.org/ticket/2510">https://devel.rtems.org/ticket/2510</a><br><br></div><div>Yes, I've looked at the ticket and referenced to it. I shall update the draft to state that I will be using this ticket itself to discuss the ideas.<br><br></div><div>><br>> With respect to the tests. In addition to worst case task sets, we have to<br>> define task sets that cover the basic operations and the corner cases. I<br>> suggest to use test driven development once the data structures and<br>> algorithm is clear. Start with a simple test and implement everything so<br>> that this test passes. Continue until everything is fine.<br>><br></div><div>I agree. Though my understanding was that we already have test cases that can be used to test any scheduler implementation. I'll add a section about writing new test cases for the scheduler.<br></div><div>>><br>>> Looking good.<br>>><br>>> Could you please add something about the method of testing you plan to<br>>> use? Not the tests just the set up details, eg is this with the scheduler<br>>> simulator, qemu, or real hardware or all listed plus also which<br>>> architectures?<br>><br>><br>> We can use Qemu and the hardware here in our office.<br><br></div><div>That would be perfect. I can test via QEMU here while we can run some bare metal tests at a later stage.<br></div><div>><br>> --<br>> Sebastian Huber, embedded brains GmbH<br>><br>> Address : Dornierstr. 4, D-82178 Puchheim, Germany<br>> Phone   : +49 89 189 47 41-16<br>> Fax     : +49 89 189 47 41-09<br>> E-Mail  : <a href="mailto:sebastian.huber@embedded-brains.de">sebastian.huber@embedded-brains.de</a><br>><br>> PGP     : Public key available on request.<br>><br>> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.<br>><br><br><br><br>-- <br>Thanking You,<br>Darshit Shah</div></div></div>