Date: Fri, 17 Mar 2000 09:38:13 +0100 (MET) From: Mats Lofkvist <mal@algonet.se> To: york@mediarack.com Cc: freebsd-smp@freebsd.org Subject: Re: *sigh* Message-ID: <200003170838.JAA22609@kairos.algonet.se> In-Reply-To: <000701bf8f9f$2b2859e0$5c5aca83@csd.unb.ca.acscience.com> (york@mediarack.com) References: <000701bf8f9f$2b2859e0$5c5aca83@csd.unb.ca.acscience.com>
next in thread | previous in thread | raw e-mail | index | archive | help
It has come to my attention that even with FreeBSD 3.3-RELEASE SMP support, I do not see two processes marked runnable at any given time. Since concurrent execution of _processes_ on different cpu's has worked since 3.0, there must either be something wrong in your setup, or the way you check it. One easy way to check if basic SMP works is to run two cpu-hogging processes at the same time and check with top that both of them get close to 100% cpu. (Note that 'RUN' in top doesn't mean running, it means runnable. 'CPUN' means it is running on cpu N.) My processors are both Intel (P3) and my motherboard is well supported (ASUS). It is my understanding that SMP support is not just to allow ping ponging of processes between multiple CPU's for tasking purposes, but to allow more than one concurrently running thread and or process on seperate CPU's. The support for executing separate threads in the same process on different CPU's is still not quite there. There is a port of the linux threads library to get that functionality, though. I have worked with many SMP-supporting OS's such as Linux (ugh), Solaris, Solaris X86 etc... All of which show more than one process marked as runnable at any given time, and yet I see only a single process marked runnable on this FreeBSD machine at any given point. Whats more, benchmarks and other information from MySQL show that threads are not executing concurrently accross the dual CPU architecture which I have. I'm quite sure I have the kernel options configured correctly, which is why Im so confused about this. Do you get the 'launching cpu 1' message at boot? So, without further ado, I ask a simple question, does FreeBSD 4.0-R fix this problem? Or is there some way I can fix it with 3.3-R such that the SMP is working properly and or most efficiently, and allowing threads to span CPU's and execute concurrently, and likewise with processes? AFAIK, the parallel scheduling of threads without the linux threads library port is under development. The reason it isn't done yet is (as always with FreeBSD :-) that it is being done the 'right way' with a hybrid between user level and kernel threads, more like in solaris than the 'all threads are kernel threads' solution in linux. The reason you don't want kernel threads only is that for an application that is not cpu-bound, the overhead of kernel threads is decreasing application performance. E.g. if you check the volano java benchmarks you can see that all linux numbers are with the java 'green threads' library and not with the linux (kernel) threads library. Thank you for your time. -- Brent York york@mediarack.com _ Mats Lofkvist mal@algonet.se To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-smp" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200003170838.JAA22609>