From: "Adam J. Richter" <adam@yggdrasil.com>
To: vonbrand@inf.utfsm.cl
Cc: linux-kernel@vger.kernel.org, torvalds@transmeta.com
Subject: Re: PATCH(?): linux-2.4.4-pre2: fork should run child first
Date: Thu, 12 Apr 2001 12:15:32 -0700 [thread overview]
Message-ID: <200104121915.MAA03715@baldur.yggdrasil.com> (raw)
>> = Adam J. Richter <adam@yggdrasil.com>
> = Horst von Brand <vonbrand@inf.utfsm.cl>
>> I suppose that running the child first also has a minor
>> advantage for clone() in that it should make programs that spawn lots
>> of threads to do little bits of work behave better on machines with a
>> small number of processors, since the threads that do so little work that
>> they accomplish they finish within their time slice will not pile up
>> before they have a chance to run. So, rather than give the parent's CPU
>> priority to the child only if CLONE_VFORK is not set, I have decided to
>> do a bit of machete surgery and have the child always inherit all of the
>> parent's CPU priority all of the time. It simplifies the code and
>> probably saves a few clock cycles (and before you say that this will
>> cost a context switch, consider that the child will almost always run
>> at least one time slice anyhow).
>And opens the system up to DoS attacks: You can't have a process fork(2)
>at will and so increase its (aggregate) CPU priority.
My change does not increase the aggregate priority of
parent+child. Perhaps I misunderstand your comment.
Adam J. Richter __ ______________ 4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com \ / San Jose, California 95129-1034
+1 408 261-6630 | g g d r a s i l United States of America
fax +1 408 261-6631 "Free Software For The Rest Of Us."
next reply other threads:[~2001-04-12 19:16 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-04-12 19:15 Adam J. Richter [this message]
-- strict thread matches above, loose matches on Subject: below --
2001-04-14 16:11 Adam J. Richter
2001-04-14 7:58 Adam J. Richter
2001-04-14 8:42 ` Michael O'Reilly
2001-04-14 9:00 ` Linus Torvalds
2001-04-14 15:06 ` Rik van Riel
2001-04-14 2:45 Adam J. Richter
2001-04-13 23:51 Adam J. Richter
2001-04-14 1:54 ` John Fremlin
2001-04-14 2:29 ` Linus Torvalds
2001-04-14 2:51 ` Alexander Viro
2001-04-14 2:52 ` Ulrich Drepper
2001-04-13 16:28 Hubertus Franke
2001-04-12 19:45 Adam J. Richter
2001-04-12 13:44 Hubertus Franke
2001-04-12 8:55 Adam J. Richter
2001-04-12 12:38 ` Horst von Brand
2001-04-17 9:15 ` Éric Brunet
2001-04-17 14:26 ` Jesse Pollard
2001-04-17 15:32 ` Éric Brunet
2001-04-13 21:08 ` John Fremlin
2001-04-14 3:53 ` Rik van Riel
2001-04-14 4:40 ` Linus Torvalds
2001-04-14 13:35 ` Rik van Riel
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=200104121915.MAA03715@baldur.yggdrasil.com \
--to=adam@yggdrasil.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
--cc=vonbrand@inf.utfsm.cl \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®