LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
Search this Thread
Old 04-06-2012, 06:13 AM   #1
TheIndependentAquarius
Senior Member
 
Registered: Dec 2008
Posts: 4,622
Blog Entries: 29

Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
Disadvantages of preempt_rt


Quote:
the target hardware platform has limited horsepower, and/or you want the real-time job to put the smallest possible overhead on your system. This is where dual kernels are usually better than a native preemption system.
From here: http://www.xenomai.org/index.php/Xen...#Xenomai_3_FAQ

Preempt_rt does preempt the whole Linux. In what way does preempting Linux put load on the system?

The FAQ there talks about the preempt_rt as compared to Xenomai.
 
Old 04-07-2012, 12:50 AM   #2
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 327Reputation: 327Reputation: 327Reputation: 327
People have the mistaken belief that RT means faster. In fact, the opposite is true. RT simply means that responses are within a designated timeframe, and have a low jitter (variance in service time). Accomplishing that comes at the cost of throughput because work has to be stopped to meet the required timeframe; an RT system accomplishes less productive work than a non-RT system.
 
Old 04-07-2012, 06:39 AM   #3
TheIndependentAquarius
Senior Member
 
Registered: Dec 2008
Posts: 4,622
Blog Entries: 29

Original Poster
Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
I know that RT is about determinism, but this load thing isn't clear for me yet.

In Xenomai and RTAI, they say that when a real time task comes the Linux is sidelined
till the real time task gets over.

In preempt_rt they say that whole kernel is preempted. What does that mean?
In what way is that different from Xenomai in terms of load bearing?

I read this: http://www.eetimes.com/design/embedd...dded-GNU-Linux, but still things aren't crystal clear.
Please explain.

Last edited by TheIndependentAquarius; 04-07-2012 at 06:41 AM.
 
Old 04-07-2012, 09:45 AM   #4
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 327Reputation: 327Reputation: 327Reputation: 327
Quote:
Originally Posted by Anisha Kaul View Post
In preempt_rt they say that whole kernel is preempted. What does that mean?
In what way is that different from Xenomai in terms of load bearing?
Preempt_rt means that the kernel will interrupt an executing kernel task and stop dispatching work in order to meet a real-time deadline. Xenomai, from the description, is a realtime process, so it's just one of the hundreds of (mostly) non-real-time processes running on the system. Without preempt_rt the system will not interrupt its own work; it's softer real-time. As a result, there will be greater variability in the service time for processes (like Xenomai). That's the difference in load.

If your workload requires hard real-time (all deadlines need to be met), you need preempt_rt. If soft real-time is acceptable (some deadline misses OK), then Xenomai appears to perform that function. If you don't understand the differences, odds are you don't need real-time at all.
 
Old 04-07-2012, 10:33 AM   #5
TheIndependentAquarius
Senior Member
 
Registered: Dec 2008
Posts: 4,622
Blog Entries: 29

Original Poster
Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
Thanks for the explanation. I'll look more into both of them now.
Quote:
Originally Posted by macemoneta View Post
If you don't understand the differences, odds are you don't need real-time at all.
I didn't find Xenomai mentioning about "soft" real time on their website. I'll check once again.
 
Old 04-07-2012, 10:52 AM   #6
TheIndependentAquarius
Senior Member
 
Registered: Dec 2008
Posts: 4,622
Blog Entries: 29

Original Poster
Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
Quote:
Xenomai is a real-time development framework cooperating with the Linux kernel, in order to provide a pervasive, interface-agnostic, hard real-time support to user-space applications, seamlessly integrated into the GNU/Linux environment
From: http://www.xenomai.org/index.php/Main_Page

Doesn't this mean that Xenomai provides hard real time?
 
Old 04-07-2012, 11:22 AM   #7
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 327Reputation: 327Reputation: 327Reputation: 327
If Xenomai is going to provide hard real-time, you need preempt_rt.

Update: From reading their FAQ, they appear to have a kernel patch that provides RT support, distinct from the standard kernel preempt_rt support. This seems kludgy to me.

Last edited by macemoneta; 04-07-2012 at 11:27 AM.
 
Old 04-09-2012, 06:38 AM   #8
TheIndependentAquarius
Senior Member
 
Registered: Dec 2008
Posts: 4,622
Blog Entries: 29

Original Poster
Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
Finally, does the "load" here mean:

preempt_rt is bound to cause a reduction in the overall throughput of the system since there will be several context switches and also the lower priority tasks won't be getting much a chance to get through.

?
 
Old 04-09-2012, 07:27 AM   #9
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 327Reputation: 327Reputation: 327Reputation: 327
Load in this context refers to the work being performed by the kernel. While work performed by the kernel is in support of processes running on the system, it's not productive work; it's overhead. preempt_rt increases the amount of work the kernel must perform.
 
1 members found this post helpful.
Old 04-09-2012, 07:45 AM   #10
TheIndependentAquarius
Senior Member
 
Registered: Dec 2008
Posts: 4,622
Blog Entries: 29

Original Poster
Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
Quote:
Originally Posted by macemoneta View Post
While work performed by the kernel is in support of processes running on the system, it's not productive work
Which kind of work is that? Context switching? Or anything else?
 
Old 04-09-2012, 07:49 AM   #11
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 327Reputation: 327Reputation: 327Reputation: 327
Quote:
Originally Posted by Anisha Kaul View Post
Which kind of work is that? Context switching? Or anything else?
Context switching, memory management, scheduling, dispatching, queuing, interrupt handling... Context switching is not a standalone function that operates independently.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
PREEMPT_RT kernel (which linux distro ?) hitman009 Linux - Kernel 1 06-03-2011 11:55 AM
Is PREEMPT_RT already implemented? archieval Linux - Kernel 1 05-05-2011 02:46 PM
preemption vs preempt_rt as of 2.6.39 sammyb Linux - Kernel 1 05-03-2011 02:16 PM
PREEMPT_RT and Xenomai ranji Linux - General 1 09-11-2010 01:20 AM
Difference between chrt and nice with PREEMPT_RT kernel jaakkos Linux - Kernel 0 03-27-2009 07:33 AM


All times are GMT -5. The time now is 07:58 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration