From owner-freebsd-hackers Fri Nov 12 11:16:11 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from rover.village.org (rover.village.org [204.144.255.49]) by hub.freebsd.org (Postfix) with ESMTP id 7037D14C10 for ; Fri, 12 Nov 1999 11:16:02 -0800 (PST) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (harmony.village.org [10.0.0.6]) by rover.village.org (8.9.3/8.9.3) with ESMTP id MAA05317; Fri, 12 Nov 1999 12:16:00 -0700 (MST) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.9.3/8.8.3) with ESMTP id MAA18340; Fri, 12 Nov 1999 12:16:22 -0700 (MST) Message-Id: <199911121916.MAA18340@harmony.village.org> To: Ben Rosengart Subject: Re: make -jN world; how to determine optimal value of N? Cc: Assar Westerlund , hackers@FreeBSD.ORG In-reply-to: Your message of "Thu, 11 Nov 1999 18:16:42 EST." References: Date: Fri, 12 Nov 1999 12:16:22 -0700 From: Warner Losh Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message Ben Rosengart writes: : On what basis? I usually use larger values, like 12, on the theory that : I have more than enough memory, and if there's free CPU, there should : always be a process available to use it. People have measured things and found that the knee in the graph goes up after 4 on UP machines. This is usually due to increased context switch times, cache effects and sometimes thrashing of the disk cache. At least those are the usual suspects that have been trotted before the court of inquiry when -j 5 was a little slower than -j 4 and -j 30 was a whole lot slower. Additional processes aren't free. There is a cost for each one. Up to 4 the cost is less than the return. After 4 the return is less than the cost so there is a net loss for each new process. Put another way, 9 women can't get together and birth a baby in just 1 month.... Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message