From: Mika Liljeberg <Mika.Liljeberg@welho.com>
To: mingo@elte.hu
Cc: Davide Libenzi <davidel@xmailserver.org>,
lkml <linux-kernel@vger.kernel.org>,
Linus Torvalds <torvalds@transmeta.com>,
Alan Cox <alan@lxorguk.ukuu.org.uk>
Subject: Re: [announce] [patch] ultra-scalable O(1) SMP and UP scheduler
Date: Sat, 05 Jan 2002 23:04:17 +0200 [thread overview]
Message-ID: <3C376A51.623258C9@welho.com> (raw)
In-Reply-To: <Pine.LNX.4.33.0201052247540.10321-100000@localhost.localdomain>
Ingo Molnar wrote:
> yes, we can do the following: instead of sending the broadcast IPI, we can
> skip CPUs that run a RT task that has a higher priority than the one that
> just got woken up. This way we send the IPI only to CPUs that have a
> chance to actually preempt their current task for the newly woken up task.
> We do this optimization for SCHED_OTHER tasks already, behavior like this
> is not something cast into stone.
>
> this way you can mark your RT task 'uninterruptible' by giving it a high
> RT priority.
This is sort of what I was thinking, although it makes it more expensive
to determine to IPI mask. A very light weight alternative could be to
make only the highest priority RT tasks uninterruptible. If a CPU is
busy with one of these it can simply be taken out of the global group
for the duration. If a task is worried about interruptions, it can boost
its prio to max for the critical part and the return it to normal
afterwards.
> i'd also like to note that Davide's description made the broadcast IPI
> solution sound more scary than it is in fact. A broadcast IPI's handler is
> pretty lightweight (it does a single APIC ACK and returns), and even a
> pointless trip into the O(1) scheduler wont take more time than say 10-20
> microseconds (pessimistic calculation), on a typical x86 system.
I guess the worry is that the overhead isn't bounded and the per-CPU
overhead increases with the number of CPUs. If the interrupts happen
come in a burst, a running task can experience a longer interruption.
> The reason i made the IPI a broadcast in the RT case is race avoidance:
> right now our IPIs are 'inexact', ie. if the scheduling situation changes
> while they are in flight (they can take 5-10 microseconds to get delivered
> to the target) then they might hit the wrong target. In case of RT/SMP,
> this might end up us missing to run a task that should be run. This was
> the major reason why i took the broadcast IPI solution.
I see your point. I may be getting off base here, but how does the cost
of making the IPIs exact compare to the cost of using broadcast IPIs on
an n-way machine (depends on n I suppose)?
Regards,
MikaL
next prev parent reply other threads:[~2002-01-05 21:05 UTC|newest]
Thread overview: 65+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-01-04 2:19 [announce] [patch] ultra-scalable O(1) SMP and UP scheduler Ingo Molnar
2002-01-04 4:27 ` Oliver Xymoron
2002-01-04 5:34 ` Ian Morgan
2002-01-04 10:30 ` Anton Blanchard
2002-01-04 12:53 ` Ingo Molnar
2002-01-04 14:18 ` Thomas Cataldo
2002-01-04 14:46 ` dan kelley
2002-01-04 17:07 ` Ingo Molnar
2002-01-04 15:22 ` Nikita Danilov
2002-01-05 4:33 ` Davide Libenzi
2002-01-05 20:24 ` Ingo Molnar
2002-01-05 19:49 ` Mika Liljeberg
2002-01-05 22:00 ` Ingo Molnar
2002-01-05 21:04 ` Mika Liljeberg [this message]
2002-01-05 23:04 ` Davide Libenzi
2002-01-05 23:41 ` Alan Cox
2002-01-05 23:46 ` Davide Libenzi
2002-01-06 0:47 ` Linus Torvalds
2002-01-06 2:57 ` Ingo Molnar
2002-01-06 1:27 ` Linus Torvalds
2002-01-06 1:45 ` Davide Libenzi
2002-01-06 3:55 ` Ingo Molnar
2002-01-06 2:16 ` Davide Libenzi
2002-01-06 3:41 ` Ingo Molnar
2002-01-06 2:02 ` Davide Libenzi
2002-01-06 2:13 ` Alan Cox
2002-01-06 2:12 ` Davide Libenzi
2002-01-06 2:20 ` Alan Cox
2002-01-06 2:17 ` Davide Libenzi
2002-01-06 3:30 ` 2.4.17 kernel without modules...was " Vikram
2002-01-06 4:07 ` [announce] [patch] ultra-scalable O(1) " Ingo Molnar
2002-01-06 2:23 ` Davide Libenzi
2002-01-06 2:30 ` Alan Cox
2002-01-06 4:19 ` Ingo Molnar
2002-01-07 3:08 ` Richard Henderson
2002-01-07 3:16 ` Linus Torvalds
2002-01-07 3:31 ` Davide Libenzi
2002-01-07 3:34 ` Linus Torvalds
2002-01-07 3:49 ` Davide Libenzi
2002-01-06 4:01 ` Ingo Molnar
2002-01-06 4:08 ` Ingo Molnar
2002-01-06 4:16 ` Ingo Molnar
2002-01-06 3:55 ` Luc Van Oostenryck
2002-01-07 8:00 ` Jens Axboe
2002-01-06 2:49 ` Ingo Molnar
2002-01-07 2:58 ` Rusty Russell
-- strict thread matches above, loose matches on Subject: below --
2002-01-04 3:56 Ed Tomlinson
2002-01-04 7:42 Dieter Nützel
2002-01-04 8:02 ` David Lang
2002-01-04 11:44 ` Ingo Molnar
2002-01-04 11:33 ` David Lang
2002-01-04 13:39 ` Andrea Arcangeli
2002-01-04 14:04 ` Ingo Molnar
2002-01-04 13:36 ` Andrea Arcangeli
2002-01-04 15:44 ` Ingo Molnar
2002-01-04 14:45 ` Andrea Arcangeli
2002-01-04 11:16 rwhron
2002-01-04 13:20 ` Ingo Molnar
[not found] <20020104074239.94E016DAA6@mail.elte.hu>
2002-01-04 11:42 ` Ingo Molnar
2002-01-05 0:28 ` Roger Larsson
2002-01-05 7:53 ` george anzinger
2002-01-05 16:54 ` Robert Love
2002-01-05 12:42 ` Ingo Molnar
2002-01-07 17:34 Rene Rebe
[not found] <20020107.191742.730580837.rene.rebe@gmx.net>
[not found] ` <Pine.LNX.4.33.0201072124380.14212-100000@localhost.localdomain>
2002-01-07 19:53 ` Rene Rebe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3C376A51.623258C9@welho.com \
--to=mika.liljeberg@welho.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=davidel@xmailserver.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.