* Preempt of BKL and with tickless systems
@ 2007-05-08 21:06 Bill Davidsen
2007-05-09 0:01 ` Lee Revell
0 siblings, 1 reply; 4+ messages in thread
From: Bill Davidsen @ 2007-05-08 21:06 UTC (permalink / raw)
To: Linux Kernel mailing List
I think I have a reasonable grip on the voluntary and full preempt
models, can anyone give me any wisdom on the preempt of the BKL? I know
what it does, the question is where it might make a difference under
normal loads. Define normal as servers and desktops.
I've been running some sched tests, and it seems to make little
difference how that's set. Before I run a bunch of extra tests, I
thought I'd ask.
New topic: I have found preempt, both voluntary and forced, seems to
help more with response as the HZ gets smaller. How does that play with
tickless operation, or are you-all waiting for me to run my numbers with
all values of HZ and not, and tell the world what I found? ;-)
--
Bill Davidsen <davidsen@tmr.com>
"We have more to fear from the bungling of the incompetent than from
the machinations of the wicked." - from Slashdot
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Preempt of BKL and with tickless systems
2007-05-08 21:06 Preempt of BKL and with tickless systems Bill Davidsen
@ 2007-05-09 0:01 ` Lee Revell
2007-05-10 21:19 ` Bill Davidsen
0 siblings, 1 reply; 4+ messages in thread
From: Lee Revell @ 2007-05-09 0:01 UTC (permalink / raw)
To: Bill Davidsen; +Cc: Linux Kernel mailing List
On 5/8/07, Bill Davidsen <davidsen@tmr.com> wrote:
> I think I have a reasonable grip on the voluntary and full preempt
> models, can anyone give me any wisdom on the preempt of the BKL? I know
> what it does, the question is where it might make a difference under
> normal loads. Define normal as servers and desktops.
This was introduced by Ingo to solve a real problem that I found,
where some codepath would hold the BKL for long enough to introduce
excessive scheduling latencies - search list archive for details. But
I don't remember the code path (scrolling the FB console? VT
switching? reiser3? misc. ioctl()s?). Basically, taking the BKL
disabled preemption which caused long latencies.
It's certainly possible that whatever issue led to this was solved in
another way since.
Lee
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Preempt of BKL and with tickless systems
2007-05-09 0:01 ` Lee Revell
@ 2007-05-10 21:19 ` Bill Davidsen
2007-05-21 7:36 ` Ingo Molnar
0 siblings, 1 reply; 4+ messages in thread
From: Bill Davidsen @ 2007-05-10 21:19 UTC (permalink / raw)
To: Lee Revell; +Cc: Linux Kernel mailing List
Lee Revell wrote:
> On 5/8/07, Bill Davidsen <davidsen@tmr.com> wrote:
>> I think I have a reasonable grip on the voluntary and full preempt
>> models, can anyone give me any wisdom on the preempt of the BKL? I know
>> what it does, the question is where it might make a difference under
>> normal loads. Define normal as servers and desktops.
>
> This was introduced by Ingo to solve a real problem that I found,
> where some codepath would hold the BKL for long enough to introduce
> excessive scheduling latencies - search list archive for details. But
> I don't remember the code path (scrolling the FB console? VT
> switching? reiser3? misc. ioctl()s?). Basically, taking the BKL
> disabled preemption which caused long latencies.
>
> It's certainly possible that whatever issue led to this was solved in
> another way since.
>
Anything is possible. I feel that using voluntary + bkl is probably good
for most servers, forced preempt for desktop, although it really doesn't
seem to do much beyond voluntary.
Thanks for the clarification.
--
Bill Davidsen <davidsen@tmr.com>
"We have more to fear from the bungling of the incompetent than from
the machinations of the wicked." - from Slashdot
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Preempt of BKL and with tickless systems
2007-05-10 21:19 ` Bill Davidsen
@ 2007-05-21 7:36 ` Ingo Molnar
0 siblings, 0 replies; 4+ messages in thread
From: Ingo Molnar @ 2007-05-21 7:36 UTC (permalink / raw)
To: Bill Davidsen; +Cc: Lee Revell, Linux Kernel mailing List
* Bill Davidsen <davidsen@tmr.com> wrote:
> > This was introduced by Ingo to solve a real problem that I found,
> > where some codepath would hold the BKL for long enough to introduce
> > excessive scheduling latencies - search list archive for details.
> > But I don't remember the code path (scrolling the FB console? VT
> > switching? reiser3? misc. ioctl()s?). Basically, taking the BKL
> > disabled preemption which caused long latencies.
> >
> > It's certainly possible that whatever issue led to this was solved
> > in another way since.
>
> Anything is possible. I feel that using voluntary + bkl is probably
> good for most servers, forced preempt for desktop, although it really
> doesn't seem to do much beyond voluntary.
yeah - we default to PREEMPT_BKL on plain SMP kernels, so it's enabled
on the majority of enterprise distros and it's working pretty well in
practice.
even today there are a couple of bad BKL latencies still: Lee mentioned
ioctls and reiser3 - neither has been fixed since i wrote
CONFIG_PREEMPT_BKL two years ago. Turning the BKL into a semaphore does
not reduce BKL latencies itself, but it makes all _other_ workloads
schedule sanely and without delay. With PREEMPT_BKL disabled (which
turns on the big kernel spinlock again) any big BKL delay is immediately
felt by other tasks too, because we waste that CPU time spinning on the
big kernel spinlock.
Ingo
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2007-05-21 7:36 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-08 21:06 Preempt of BKL and with tickless systems Bill Davidsen
2007-05-09 0:01 ` Lee Revell
2007-05-10 21:19 ` Bill Davidsen
2007-05-21 7:36 ` Ingo Molnar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox