All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul <paul@crubille.lautre.net>
To: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] Linux port to ARM Allwinner A13
Date: Mon, 11 Mar 2013 23:47:37 +0100	[thread overview]
Message-ID: <513E5F09.30600@crubille.lautre.net> (raw)
In-Reply-To: <513D8C24.4010009@xenomai.org>

Some precision and 2 small examples about a preempt test:

On 11/03/2013 08:47, Gilles Chanteperdrix wrote:
> On 03/11/2013 10:15 AM, Paul wrote:
>
>> Hello,
>>
>> ... ... ...
>>
>> I check the priority masking with a preempt test which is derived
>> from the latency test: The real time task loop for 1/4 of its period
>> reading and rereading the clock, so i get the min, avg and worst case
>> that the task can be preempted while it is running.
>
>> If you are interested in this test, i can post it when I have
>> modified the output messages.
>
>
> I do not really understand. Why would it be more preempted in the first
> 1/4 of its period?
>
>
No reason sure but -
  It can be preempted only while it is running, so between the time it 
is restarted after sleeping and before it go to sleep again.
Let it running 1/4 of the period is enough to catch lots of events if 
there is lots of irqs but not too much so linux, dohell or even xenomai 
tasks can run just a bit slower.


Here are some result i get (yes with the priority interrupt masking, and 
i am pretty sure it work - but the watchdog is on).
There is a dohell at the same time in the whole experiment and i start 
X11, stop it , restart it  ...


root@debian:/usr/xenomai/bin# 
/usr/src/build_xenomai/src/testsuite/preempt/preempt -p 111
== Sampling period: 111 us
== Test mode: periodic user-mode task
== All results in microseconds
warming up...
RTT|  00:00:01  (periodic user-mode task, 111 us period, priority 99)
RTH|----pre min|----pre avg|----pre max|-overrun|---msw|---pre 
best|--pre worst
RTD|      0.333|      0.374|      3.333|       0|     0|      
0.333|      3.333
RTD|      0.333|      0.374|     15.666|       0|     0|      0.333|     
15.666
---|-----------|-----------|-----------|--------|------|-------------------------

RTH|----pre min|----pre avg|----pre max|-overrun|---msw|---pre 
best|--pre worst
RTD|      0.333|      0.374|      3.708|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.874|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.541|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.916|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.541|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.583|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.499|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.833|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.791|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.666|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.833|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.749|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.749|       0|     0|      0.333|     
23.333
RTD|      0.333|      0.374|      3.624|       0|     0|      0.333|     
23.333
^C---|-----------|-----------|-----------|--------|------|-------------------------
RTS|      0.333|      0.374|     23.333|       0|     0|    
00:13:33/00:13:33


A second experiment, just setting the period to 100 (and the period for 
the watchdog is a multiple so 3/4 it never preempt the task:

/usr/src/build_xenomai/src/testsuite/preempt/preempt -p 100 -h
== Sampling period: 100 us
== Test mode: periodic user-mode task
== All results in microseconds
warming up...
RTT|  00:00:01  (periodic user-mode task, 100 us period, priority 99)
RTH|----lat min|----lat avg|----lat max|-overrun|---msw|---lat 
best|--lat worst
RTD|      0.333|      0.374|      0.749|       0|     0|      
0.333|      0.749
RTD|      0.333|      0.374|      2.749|       0|     0|      
0.333|      2.749
RTD|      0.333|      0.374|      0.708|       0|     0|      
0.333|      2.749
RTD|      0.333|      0.374|      0.833|       0|     0|      
0.333|      2.749
RTD|      0.333|      0.374|      0.708|       0|     0|      
0.333|      2.749
RTD|      0.333|      0.374|      0.833|       0|     0|      
0.333|      2.749
... ... ...
RTD|      0.333|      0.374|      3.749|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      4.166|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      3.541|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      3.791|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      3.666|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      4.416|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      3.791|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      3.874|       0|     0|      
0.333|      4.541
RTD|      0.333|      0.374|      3.749|       0|     0|      
0.333|      4.541
RTT|  00:04:13  (periodic user-mode task, 100 us period, priority 99)
RTH|----lat min|----lat avg|----lat max|-overrun|---msw|---lat 
best|--lat worst
RTD|      0.333|      0.374|      4.124|       0|     0|      
0.333|      4.541
^C---|--param|----range-|--samples
HSD|    min|   0 -  1 |      253
---|--param|----range-|--samples
HSD|    avg|   0 -  1 |  2530149
---|--param|----range-|--samples
HSD|    max|   0 -  1 |        3
HSD|    max|   1 -  2 |        1
HSD|    max|   2 -  3 |        3
HSD|    max|   3 -  4 |      186
HSD|    max|   4 -  5 |       60
HSH|--param|--samples-|--average--|---stddev--
HSS|    min|       253|      0.000|      0.000
HSS|    avg|   2530149|      0.000|      0.000
HSS|    max|       253|      3.182|      0.583
---|-----------|-----------|-----------|--------|------|-------------------------
RTS|      0.333|      0.374|      4.541|       0|     0|    
00:04:13/00:04:13







  parent reply	other threads:[~2013-03-11 22:47 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-26  0:11 [Xenomai] Linux port to ARM Allwinner A13 Paul
2013-02-25 22:28 ` Gilles Chanteperdrix
2013-03-11  9:15   ` Paul
2013-03-11  7:47     ` Gilles Chanteperdrix
2013-03-11  8:15       ` Gilles Chanteperdrix
2013-03-11 22:29       ` Paul
2013-04-09 22:05         ` Gilles Chanteperdrix
2013-03-11 22:47       ` Paul [this message]
2013-03-12  4:56         ` Gilles Chanteperdrix
2013-03-12  5:06           ` Gilles Chanteperdrix
  -- strict thread matches above, loose matches on Subject: below --
2013-05-06 12:56 kunming yang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=513E5F09.30600@crubille.lautre.net \
    --to=paul@crubille.lautre.net \
    --cc=gilles.chanteperdrix@xenomai.org \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.