[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Why _ThreadProcessSignalsFromIrq() in new exception processing?



Joel Sherrill <joel.sherrill at OARcorp.com> writes:
> Sergei Organov wrote:
> > 
> > Valette Eric <eric.valette at free.fr> writes:
[...]
> > >
> > >       2) The path for software exception is not critical from a
> > >          performance point of view and having a context realy helps in a
> > >          lot of situation,
> > 
> > Here I don't agree. Who said that the particular path in which you are
> > inserting "software exception" code is infrequent? You already stated a
> > few times it is documented to be infrequent. Where? In the comments? Just
> > telling it's infrequent doesn't make it infrequent. From Joel's
> > explanations I've drawn a conclusion that it could be rather frequent if
> > application uses POSIX signals heavily. Am I mistaken?
> 
> Not if the signals are sent from ISR handlers.

Could you please explain why? I think it depends on application. An extreme
case is an application containing single thread to which ISR handler(s) send
signals. This is indeed rather unlikely case but it explains what I mean when
I doubt the path can be *guaranteed* to be infrequent.

-- 
Sergei.