From owner-freebsd-hackers Sun Dec 5 19: 7:58 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from smtp03.primenet.com (smtp03.primenet.com [206.165.6.133]) by hub.freebsd.org (Postfix) with ESMTP id BCC7814A05 for ; Sun, 5 Dec 1999 19:07:56 -0800 (PST) (envelope-from rcarter@pinyon.org) Received: (from daemon@localhost) by smtp03.primenet.com (8.9.3/8.9.3) id UAA14254; Sun, 5 Dec 1999 20:07:16 -0700 (MST) Received: from ip-83-085.prc.primenet.com(207.218.83.85), claiming to be "pinyon.org" via SMTP by smtp03.primenet.com, id smtpdAAAeHaaZB; Sun Dec 5 20:07:08 1999 Received: from chomsky.Pinyon.ORG (localhost [127.0.0.1]) by pinyon.org (Postfix) with ESMTP id A376248; Sun, 5 Dec 1999 20:07:40 -0700 (MST) X-Mailer: exmh version 2.1.0 09/18/1999 To: Wes Peters Cc: Nick Hibma , Doug Barton , freebsd-hackers@FreeBSD.ORG, rcarter@pinyon.org Subject: Re: Basic question about threads and SMP In-Reply-To: Your message of "Sun, 05 Dec 1999 19:19:17 MST." <384B1D25.DFAF198E@softweyr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sun, 05 Dec 1999 20:07:40 -0700 From: "Russell L. Carter" Message-Id: <19991206030740.A376248@pinyon.org> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG %Nick Hibma wrote: %> %> Being multi-threaded has almost nothing to do with being %> multi-processor. Multi-threading means that your application has %> multiple threads of execution that are able to run simultaneously. %> %> The multi-processing capability of your box means that 2 threads of %> execution, be it a process or a thread within a process, are executed %> _literally_ at the same time, and not in simulated concurrency like it %> happens on a UP box. % %Note that this happens ONLY if both threads of execution are processor %mobile. If your system supports user-space threads as part of a %process and the process can't be split across CPUs, you might as well %have a UP system. (Except everything else can run on the other %processor, so SMP is still a small win.) % %This is the situation with threads and SMP in -current. % The LinuxThreads port is currently busted for SMP but when it is fixed it will indeed use multiple processors: last pid: 395; load averages: 0.50, 0.11, 0.04 up 0+00:13:00 20:00:40 37 processes: 6 running, 31 sleeping CPU states: 65.8% user, 0.0% nice, 0.0% system, 0.0% interrupt, 34.2% idle Mem: 8780K Active, 9116K Inact, 19M Wired, 68K Cache, 7000K Buf, 466M Free Swap: 1024M Total, 1024M Free PID USERNAME PRI NICE SIZE RES STATE C TIME WCPU CPU COMMAND 393 rcarter 31 0 876K 152K CPU1 1 0:01 17.16% 2.39% ex3 394 rcarter 29 0 876K 152K RUN 0 0:00 15.76% 2.20% ex3 391 rcarter 30 0 876K 152K RUN 1 0:01 14.71% 2.05% ex3 395 rcarter 30 0 876K 152K RUN 0 0:01 14.01% 1.95% ex3 392 rcarter 30 0 876K 152K RUN 0 0:00 13.66% 1.90% ex3 Russell %-- % "Where am I, and what am I doing in this handbasket?" % %Wes Peters Softweyr LLC %wes@softweyr.com http://softweyr.com/ % % %To Unsubscribe: send mail to majordomo@FreeBSD.org %with "unsubscribe freebsd-hackers" in the body of the message % To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message