public inbox for gentoo-embedded@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-embedded] Looking for low-latency docs
@ 2009-03-30 16:16 wireless
  2009-03-30 16:25 ` Ahmed Ammar
  2009-03-30 18:06 ` Karl Hiramoto
  0 siblings, 2 replies; 12+ messages in thread
From: wireless @ 2009-03-30 16:16 UTC (permalink / raw
  To: gentoo-embedded

Hello,


I'd be curious to see any discussions/links others
have related to the various options for low-latency
(kernels &) techniques, either legacy or current,
that are available/recommended for embedded
gentoo. Any other embedded linux distros
discussions/links  related to low latency
are of interest too.


Any discussion of experiences
with your low-latency efforts are also of
interest to me, specific the the kernel or
otherwise.


A treatise or technical doc (discussion)
would be keen. My googling has produced many
"low quality" urls.... out of the morass of
links.... (so I'm missing something on my
searches).


James



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 16:16 [gentoo-embedded] Looking for low-latency docs wireless
@ 2009-03-30 16:25 ` Ahmed Ammar
  2009-03-30 18:06 ` Karl Hiramoto
  1 sibling, 0 replies; 12+ messages in thread
From: Ahmed Ammar @ 2009-03-30 16:25 UTC (permalink / raw
  To: gentoo-embedded

You might want to check out the rt linux patches:

http://rt.wiki.kernel.org

AA




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 16:16 [gentoo-embedded] Looking for low-latency docs wireless
  2009-03-30 16:25 ` Ahmed Ammar
@ 2009-03-30 18:06 ` Karl Hiramoto
  2009-03-30 19:57   ` wireless
  1 sibling, 1 reply; 12+ messages in thread
From: Karl Hiramoto @ 2009-03-30 18:06 UTC (permalink / raw
  To: gentoo-embedded

wireless wrote:
> Hello,
>
>
> I'd be curious to see any discussions/links others
> have related to the various options for low-latency
> (kernels &) techniques, either legacy or current,
> that are available/recommended for embedded
> gentoo. Any other embedded linux distros
> discussions/links  related to low latency
> are of interest too.
>
>
> Any discussion of experiences
> with your low-latency efforts are also of
> interest to me, specific the the kernel or
> otherwise.
>
>
> A treatise or technical doc (discussion)
> would be keen. My googling has produced many
> "low quality" urls.... out of the morass of
> links.... (so I'm missing something on my
> searches)
> Some man pages to set the scheduler:
>   
You might want to explain what you are doing, or what you are trying to achive.

1ms-5ms latency in a user space process should be very easy to achieve on a fast machine.   If you want 10s of  micro-second latency your going to have tough time.

It all depends on what your trying to do as to what the best strategy may be. 

If your writing C code  see:

man sched_setscheduler
man setpriority(int

check out sched.h

remember real_time != fast



--
Karl Hiramoto  http://karl.hiramoto.org/




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 18:06 ` Karl Hiramoto
@ 2009-03-30 19:57   ` wireless
  2009-03-30 20:27     ` Arkadi Shishlov
  2009-03-31  0:31     ` Peter Stuge
  0 siblings, 2 replies; 12+ messages in thread
From: wireless @ 2009-03-30 19:57 UTC (permalink / raw
  To: gentoo-embedded

Karl Hiramoto wrote:
> wireless wrote:
>> Hello,
>>
>>
>> I'd be curious to see any discussions/links others
>> have related to the various options for low-latency
>> (kernels &) techniques, either legacy or current,
>> that are available/recommended for embedded
>> gentoo. Any other embedded linux distros
>> discussions/links  related to low latency
>> are of interest too.
>>
>>
>> Any discussion of experiences
>> with your low-latency efforts are also of
>> interest to me, specific the the kernel or
>> otherwise.
>>
>>
>> A treatise or technical doc (discussion)
>> would be keen. My googling has produced many
>> "low quality" urls.... out of the morass of
>> links.... (so I'm missing something on my
>> searches)
>> Some man pages to set the scheduler:
>>   
> You might want to explain what you are doing, or what you are trying to achive.

Researching how close an embedded (linux) system, on a given processor
can get to a state machine or a commercial Rtos.

What mechanisms are theoretically possible. Mechanisms that work
and actually exist.

Published latency result (verifiable or not) base on a variety of
kernel gymnastics.

> 
> 1ms-5ms latency in a user space process should be very easy to achieve 
> >on a fast machine.   If you want 10s of  micro-second latency your
going
>to have tough time.

Ok, what is practical for which technique? Guesstimates or published
data if ok.

> 
> It all depends on what your trying to do as to what the best strategy may be. 

Agreed. That why I ask for a discussion on what anyone has done, not
trying to pry too deeply where folks are uncomfortable. So a
theoretical or practical example is fine.

For (mythical) example has anyone used a (hardware) interrupt in a
very fast method where it is not available to the linux kernel but, an
assembler routine could access it directly? Possible? been tried? Any
other wild ideas?

Or for another (mythical) example:
We used 2 processors, one running a state machine for directly reading
an array of 20 bit D/A in sub microsecond fashion, and then passed the
data (like this) to another processor running RT_linux (windRiver or
embedded-gentoo).....



> If your writing C code  see:

Eventually C or target assembler (This research before processor
selection). It's not a question of how fast (low latency) or
such, but a research effort into here's how fast one can service an
A/D ( merely for example) with this amount of bandwidth (data per
second) under embedded (low latency linux). A discussion of trade-offs
preferable real examples but theoretical is OK too. Whats the
best that is published and believable? What tricks have any
gentoo folks used?

(another mythical example)
Maybe somebody use an OMAP chip and use the D/A under the DSP
to pass low latency data to the embedded linux running on
the Arm core of the OMAP SOC?

It's research into what is possible, claimed or otherwise
but most importantly what anyone in embedded gentoo is
willing to share, what they did. Just a 10,000 foot view,
not any sort of sensitive code, only what anyone is
willing to share.


> man sched_setscheduler
> man setpriority(int
> 
> check out sched.h
> 
> remember real_time != fast


Not to argue, but, I'm one that does not believe in the whole
RealTime semantic. There is only functions of Latency and  functions
of Determinism. So such euphemisms such as "soft" and "hard"
RT  are really nebulous constructs for me. But that does
not stop me from reading what others have published
or discussed, in terms of RT or under other  related monikers.

IMHO:
"RT" is for academics and MBAs. RT means faster than human
perception, traditionally, which is sporadic and varied, at best. Hard
vs soft is also a poorly conceived concept used to attempt to extend
"RT" terminology; breaks down upon inspection of specific minutia.


But again, it's not about what I know, or believe, it's about what is
claimed and what is documented related to embedded linux, in its
many colors (i.e. kernel and other places), particular embedded
gentoo.


I'm not looking to solve any specific problem (yet) just wanting to
see what is published and what folks can verify or some practical
examples of what somebody does to achieve their balance
of low-latency with whatever measure of determinism that
they chose. However my experience is without some measure
of determinism, low-latency is pointless. ymmv, and I'd like
to here why is was not a priority in your low-latency, gentoo,
example.

I hope this *research* and discussion is specific and related to
embedded gentoo, but, certainly other embedded linux materials are of
interest to me too. Suggestions of other lists is cool too.
Google and not been fruitful for me on this, so if you find
great gentoo examples, please include what (keywords) you
used to find material.


Maybe, it as simple as, "with embedded linux (even gentoo)
nothing below 100 ms is practical, and here is why....


James



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 19:57   ` wireless
@ 2009-03-30 20:27     ` Arkadi Shishlov
  2009-03-30 20:46       ` Wolfgang Denk
  2009-03-31  0:31     ` Peter Stuge
  1 sibling, 1 reply; 12+ messages in thread
From: Arkadi Shishlov @ 2009-03-30 20:27 UTC (permalink / raw
  To: gentoo-embedded

wireless wrote:
<snip>

If you want to get some real job done using free tools, there is excellent RTAI 
Linux - www.rtai.org - available to everyone free of charge. The documentation 
is sufficient to get started and samples have extensive subject coverage. The 
latencies are of microseconds scale and jitter is low. And it has both hard and 
soft realtime, whenever believe you or not, as well as tools and friendly projects.
And theirs mailing list will deliver your question directly to the authors, in 
case you're interested to dig into details.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 20:27     ` Arkadi Shishlov
@ 2009-03-30 20:46       ` Wolfgang Denk
  2009-03-30 21:37         ` Arkadi Shishlov
  0 siblings, 1 reply; 12+ messages in thread
From: Wolfgang Denk @ 2009-03-30 20:46 UTC (permalink / raw
  To: gentoo-embedded, Arkadi Shishlov

Dear Arkadi Shishlov,

In message <49D12B4A.6060307@gmail.com> you wrote:
> 
> If you want to get some real job done using free tools, there is excellent RTAI 
> Linux - www.rtai.org - available to everyone free of charge. The documentation 

Umm... may I suggest that you update your information? 

RTAI is a dead horse, and has been dead for several years, at least
for all non-x86 systems (and even on x86 there is only a tiny fraction
of the former community left).

All the rest of the world has moved on and is using Xenomai instead,
see www.xenomai.org 

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Do not simplify the design of a program if a way can be found to make
it complex and wonderful.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 20:46       ` Wolfgang Denk
@ 2009-03-30 21:37         ` Arkadi Shishlov
  2009-03-30 22:32           ` Wolfgang Denk
  0 siblings, 1 reply; 12+ messages in thread
From: Arkadi Shishlov @ 2009-03-30 21:37 UTC (permalink / raw
  To: gentoo-embedded

Wolfgang Denk wrote:
> Dear Arkadi Shishlov,
> In message <49D12B4A.6060307@gmail.com> you wrote:
>> If you want to get some real job done using free tools, there is excellent RTAI 
>> Linux - www.rtai.org - available to everyone free of charge. The documentation 
> 
> Umm... may I suggest that you update your information? 
> 
> RTAI is a dead horse, and has been dead for several years, at least
> for all non-x86 systems (and even on x86 there is only a tiny fraction
> of the former community left).
> 
> All the rest of the world has moved on and is using Xenomai instead,
> see www.xenomai.org 

Well, I shared what I know works for me well.
As for being dead horse, world moved on and other claims - I will not flame on 
this, but your opinion seems to be an over-generalization.
Both RTAI and Xenomai are fine pieces of software, there is no need to discredit 
another project to make your favorite look good.
As original poster asked about applied theory, the RTAI site is still good 
starting point to research for more information.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 21:37         ` Arkadi Shishlov
@ 2009-03-30 22:32           ` Wolfgang Denk
  2009-03-31  7:47             ` Mike Frysinger
  0 siblings, 1 reply; 12+ messages in thread
From: Wolfgang Denk @ 2009-03-30 22:32 UTC (permalink / raw
  To: gentoo-embedded, Arkadi Shishlov

Dear Arkadi,

In message <49D13B7C.8030002@gmail.com> you wrote:
>
> As for being dead horse, world moved on and other claims - I will not flame on 
> this, but your opinion seems to be an over-generalization.

I don't think so. This is an embedded list, so x86 is just one among
many architectures here.

> Both RTAI and Xenomai are fine pieces of software, there is no need to discredit 
> another project to make your favorite look good.
> As original poster asked about applied theory, the RTAI site is still good 
> starting point to research for more information.

Well, did you actually try using RTAI on, say, any  PowerPC  or  MIPS
system lately? With a somewhat recent Linux kernel? Running real-time
aaplications  in  user-space? With a standard API (POSIX) ? And being
able to debug these? [And please note that I did not ask for  any  of
the  more  advanced features, like working FPU support, or SMP, or 64
bit systems, ...]

All this (and much more) is working out of the box in Xenomai.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
In the realm of scientific observation, luck is granted only to those
who are prepared.                                     - Louis Pasteur



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 19:57   ` wireless
  2009-03-30 20:27     ` Arkadi Shishlov
@ 2009-03-31  0:31     ` Peter Stuge
  2009-03-31 18:31       ` wireless
  1 sibling, 1 reply; 12+ messages in thread
From: Peter Stuge @ 2009-03-31  0:31 UTC (permalink / raw
  To: gentoo-embedded

wireless wrote:
> Or for another (mythical) example:
> We used 2 processors, one running a state machine for directly
> reading an array of 20 bit D/A in sub microsecond fashion, and then
> passed the data (like this) to another processor running RT_linux
> (windRiver or embedded-gentoo).....

People plug FPGAs into HyperTransport (FSB used by AMD64) - does that
count?


//Peter



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-30 22:32           ` Wolfgang Denk
@ 2009-03-31  7:47             ` Mike Frysinger
  0 siblings, 0 replies; 12+ messages in thread
From: Mike Frysinger @ 2009-03-31  7:47 UTC (permalink / raw
  To: gentoo-embedded

[-- Attachment #1: Type: text/plain, Size: 1232 bytes --]

On Monday 30 March 2009 18:32:21 Wolfgang Denk wrote:
> In message Arkadi wrote:
> > As for being dead horse, world moved on and other claims - I will not
> > flame on this, but your opinion seems to be an over-generalization.
>
> I don't think so. This is an embedded list, so x86 is just one among
> many architectures here.
>
> > Both RTAI and Xenomai are fine pieces of software, there is no need to
> > discredit another project to make your favorite look good.
> > As original poster asked about applied theory, the RTAI site is still
> > good starting point to research for more information.
>
> Well, did you actually try using RTAI on, say, any  PowerPC  or  MIPS
> system lately? With a somewhat recent Linux kernel? Running real-time
> aaplications  in  user-space? With a standard API (POSIX) ? And being
> able to debug these? [And please note that I did not ask for  any  of
> the  more  advanced features, like working FPU support, or SMP, or 64
> bit systems, ...]
>
> All this (and much more) is working out of the box in Xenomai.

indeed.  this is the solution we use on Blackfin systems when people want hard 
realtime.  and we havent had a problem with it being up to date at all.
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-31  0:31     ` Peter Stuge
@ 2009-03-31 18:31       ` wireless
  2009-03-31 18:46         ` Peter Stuge
  0 siblings, 1 reply; 12+ messages in thread
From: wireless @ 2009-03-31 18:31 UTC (permalink / raw
  To: gentoo-embedded

Peter Stuge wrote:
> wireless wrote:
>> Or for another (mythical) example:
>> We used 2 processors, one running a state machine for directly
>> reading an array of 20 bit D/A in sub microsecond fashion, and then
>> passed the data (like this) to another processor running RT_linux
>> (windRiver or embedded-gentoo).....
> 
> People plug FPGAs into HyperTransport (FSB used by AMD64) - does that
> count?


Yes. Any thing you can share is great. Timing/latency data,
issues, pseudo code, system architecture...... what decisions
where made and why.....


My focus is on the "low latency" aspect and what can be done
(how fast) directly under embedded linux (rt, rtai, xeno...
whatever tricks) control or by bypassing the rtos all together
and bringing in the data via another port/interface. why?

and also where folks have had to bypass the rtos because of
critical timing/bandwidth issues, or just simple to build
a system that is difficult to reverse engineer (FPGA
or SOC or asic)....


Again, I'm not after sensitive information, just performance
numbers and any technical details you can or are willing to
share.

tia,
James




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [gentoo-embedded] Looking for low-latency docs
  2009-03-31 18:31       ` wireless
@ 2009-03-31 18:46         ` Peter Stuge
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Stuge @ 2009-03-31 18:46 UTC (permalink / raw
  To: gentoo-embedded

wireless wrote:
> > People plug FPGAs into HyperTransport (FSB used by AMD64) - does
> > that count?
> 
> Yes. Any thing you can share is great. Timing/latency data,
> issues, pseudo code, system architecture...... what decisions
> where made and why.....
..
> Again, I'm not after sensitive information, just performance
> numbers and any technical details you can or are willing to
> share.

Come talk on the coreboot mailing list, you should find the German
university guys there who have done this.

http://www.coreboot.org/Mailinglist

(They needed coreboot because factory BIOS would not start when
something else than a CPU was in the socket.)


//Peter



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2009-03-31 18:46 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-30 16:16 [gentoo-embedded] Looking for low-latency docs wireless
2009-03-30 16:25 ` Ahmed Ammar
2009-03-30 18:06 ` Karl Hiramoto
2009-03-30 19:57   ` wireless
2009-03-30 20:27     ` Arkadi Shishlov
2009-03-30 20:46       ` Wolfgang Denk
2009-03-30 21:37         ` Arkadi Shishlov
2009-03-30 22:32           ` Wolfgang Denk
2009-03-31  7:47             ` Mike Frysinger
2009-03-31  0:31     ` Peter Stuge
2009-03-31 18:31       ` wireless
2009-03-31 18:46         ` Peter Stuge

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox