All of lore.kernel.org
 help / color / mirror / Atom feed
* [Xenomai-help] problems solved
@ 2008-02-28 14:53 Steven Seeger
  0 siblings, 0 replies; 11+ messages in thread
From: Steven Seeger @ 2008-02-28 14:53 UTC (permalink / raw)
  To: xenomai

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

So, my CPU usage problems with tasks were due to my heavy use of mutex
recursion. I got it for free in the kernel, so it made sense to do the
same in userspace. But, syscall overhead was a big problem so I wrapped
them with a simple class that seems to have solved the issue.

 

The reason I have a lot of mutex recursion is that there are many layers
of functions that talk to certain pieces of hardware, and you may call
them at the top or at the bottom. So, the mutex must be protected at
every step.

 

This change reduced a 2ms periodic task from 25% cpu usage down to about
16.7%. A 22% usage 500 us periodic task was reduced to 15%. These two
tasks work together to move and control a stepper motor and read all of
its sensors and inputs. The same functionality in the old system with
RTAI used about 25% of the CPU as measured by RTAI's stats stuff.
(Perhaps this wasn't very accurate.) So I'm very pleased with the
results, and feel there can probably be further optimization. (Obviously
we expect some overhead in userspace.) This usage is down from over 50%
CPU usage between the two tasks.

 

Steven

 

 


[-- Attachment #2: Type: text/html, Size: 3439 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread
[parent not found: <17407.11690.884325.678202@domain.hid>]
* [Xenomai-help] problems solved
@ 2006-02-23 23:01 Steven Seeger
  2006-02-23 23:44 ` Jan Kiszka
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Steven Seeger @ 2006-02-23 23:01 UTC (permalink / raw)
  To: xenomai@xenomai.org

Well, I solved my problems by getting rid of the geode. On a 400 mhz celeron
board, everything works great. My software used 100% of the CPU on the geode
and locked up the Linux side when the stepper motor would run, but on the
celeron it uses a negligible amount of the CPU. This is good for me to see
that the problem isn't with my code probably, but bad that Xenomai seems to
have issues on the Geode that RTAI/fusion did not.

Just giving you all a heads up. The geode sucks anyway.



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

end of thread, other threads:[~2008-02-28 14:53 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <C0244E4B.24F4%steve@domain.hid>
2006-02-24 14:59 ` [Xenomai-help] problems solved Philippe Gerum
2006-02-25  7:11   ` [Xenomai-help] Geode performance (Was: problems solved) Jim Cromie
2006-02-25  7:26     ` [Xenomai-core] " Jim Cromie
2006-02-25 17:03       ` Philippe Gerum
2008-02-28 14:53 [Xenomai-help] problems solved Steven Seeger
     [not found] <17407.11690.884325.678202@domain.hid>
2006-02-24 16:12 ` Steven Seeger
  -- strict thread matches above, loose matches on Subject: below --
2006-02-23 23:01 Steven Seeger
2006-02-23 23:44 ` Jan Kiszka
2006-02-24  8:01 ` Jeroen Van den Keybus
2006-02-24  9:37 ` Philippe Gerum
2006-02-24 13:57   ` Steven Seeger

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.