lkml.org 
[lkml]   [2005]   [May]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: RT patch acceptance
Esben Nielsen wrote:
> On Tue, 24 May 2005, john cooper wrote:
>>I'd like to hear some technical arguments of why IRQ threads
>>are held with such suspicion...
>
> Performance! Even on RT systems you do NOT make all interrupts run in
> threads. Simple devices like UARTS run everything in interrupt context.
> Introducing a context switch for every character received on such a
> channel can be _very_ expensive.

The IRQ thread mechanism introduces a facility which offers
a benefit at an associated cost. For cases where the interrupt
payload processing is small in comparison to the associated
context switch, overhead in this case may be optimized
by running the payload processing in exception context.

But "performance" here is a vague term. It may in some cases
be preferable to incur an increased overhead of interrupt payload
processing in task context to improve overall CPU availability
or reduce interrupt lockout in code associated with the
interrupt. It is a system-wide issue depending on the system
goals.

I agree for simple devices which generate high frequency interrupts
and have trivial interrupt payload processing, the addition of
deferring the latter to task context may be unneeded overhead.
But even here it is a system-wide design issue and I don't see
a simple, universal right-way/wrong-way. In any case the choice
of either mechanisms is available.

As a data point, commercial OSes exist which strive to optimize
for non-RT throughput which by default defer all interrupt payload
processing into task context. Not that this is necessarily
conclusive here but it should offer reassurance this isn't as
radical a concept as it may seem.

-john

--
john.cooper@timesys.com
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-05-25 15:21    [W:0.268 / U:0.664 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site