On mer, 2013-11-27 at 02:36 +0000, Simon Martin wrote:
>
> Is there any chance that you can share/show it? At least the
> relevant
> chunks...
No problems, I can share the complete code it you want, there is
nothing proprietary in there yet. What's the best way to do it? Put it
on github? Send a tarball?
Well, I think a repo somewhere would be preferrable over a tarball,
espacially if you have it in a (although private) repo already, so that
we gt to see the history, the commit changelogs, etc.
> Some questions:
> - "looking at the statistics", what statistics? How do you collect
> them?
At every cycle I compare the current time with the expected time and
calculate latency (time from when I expect the event to when it
actually happens) and period.
Sure, that part I got. I was more asking how you get these numbers out,
i.e., you print them online, store somewhere and print later/on request,
etc. (I guess I could have specified this more clearly, sorry about
that
)
Here's an example. There are 2 lines per sample. Line 0 has format <time> <ticks per second>, line 1 has <latency min/max>,<period min/max>
timeofday=12:56:41 - 1000
1043,47287,955121,2001800
timeofday=12:56:42 - 1000
1024,30989,970082,2000885
timeofday=12:56:43 - 1000
1042,30888,970167,2000947
timeofday=12:56:44 - 1000
1042,30910,970661,2001063
timeofday=12:56:45 - 1000
1043,30909,970162,2000057
timeofday=12:56:46 - 1000
1043,30883,970183,2000049
timeofday=12:56:47 - 1000
1066,30923,970160,2001268
timeofday=12:56:48 - 1000
1048,30922,970140,2000031
timeofday=12:56:49 - 1000
1041,30864,970211,2001090
timeofday=12:56:50 - 1000
1043,30898,970162,2000880
timeofday=12:56:51 - 1000
1042,30948,970106,2000947
timeofday=12:56:52 - 1000
1044,30777,970752,2000058
> - you say you get latencies in some range and periods in some
> other
> range. It may be my fault, but I'm not sure I understand what
> you
> mean with these two terms in this context, could you clarify?
>
Latency = difference between expected time and actual time of the
event.
Period = time between two consecutive events.
Ok, I think I see now. Just to confirm that I do, this means that the
values/ranges you get by measuring both are related, i.e., not
completely independent, right? Again, I'm not saying it's not useful to
have both, just trying to double check I understood what you're doing.
They're not really related. Period is time between events, Latency is time from event to handler.
> I'm not sure if fits your exact needs, and you probably know it
> already,
> but, just in case, have you looked at xentrace and xenalyze? There's
> a
> blog post that could be a nice introduction to them:
>
I hadn't read that. I'll look at it tomorrow (it's almost midnight
here).
Ask again if you need anything.
I will
! Thanks.
Regards.