Re: do_softirq() newbie question...

From: Brian Gerst (bgerst@quark.vpplus.com)
Date: Tue Jun 13 2000 - 12:48:12 EST


"J. Robert von Behren" wrote:
> My other question is w/ regard to coding style in schedule.c. I noticed
> that schedule() has a large number of constructs like this:
>
> if(condition)
> goto label;
> label_back:
>
> ....
>
> label: do_stuff()
> goto label_back;
>
> I'm probably showing my naivette as a C hacker, but why the gotos
> instead of just inline functions?

Because the scheduler is performance critical, the effort was made to
force GCC to move the uncommon code out of line (inline is bad in this
case). This improves the caching for the common case.

--

Brian Gerst

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Jun 15 2000 - 21:00:28 EST