Date: Sun, 23 May 2004 23:10:39 +0300 From: Petri Helenius <pete@he.iki.fi> To: Julian Elischer <julian@elischer.org> Cc: freebsd-threads@freebsd.org Subject: Re: Why is MySQL nearly twice as fast on Linux? Message-ID: <40B1053F.6080604@he.iki.fi> In-Reply-To: <Pine.BSF.4.21.0405231249110.7925-100000@InterJet.elischer.org> References: <Pine.BSF.4.21.0405231249110.7925-100000@InterJet.elischer.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Julian Elischer wrote: >you might also lile to run a profiled app and a profiled kernel >and use gprof and kgmon to get results. > > > I think profiling the application would be more useful. Is there a counter for syscalls per process? I know there is a context switch counter. >There is obviously a bottleneck, but it's very hard to tell what it is.. >My guess is that the scheduler(s) are not doing a very good job. and the >fact that GIANT is not removed from the kernel yet says that generally >syscalls will be a bottleneck. > > > While watching the top output, I saw a "logjam" to appear from time to time where all processes/threads were waiting for Giant. However I donīt feel that causes the large impact, it might contribute 10-20% but it does not feel frequent enough to cause 50% difference. >ULE should be able to do a better job at scheduling with >multiple CPUs but it is a work in progress. If threads all hit a GIANT >based logjam, there is not a lot the scheduler can do about it.. > > > I find it hard to believe that the threading stuff would be seriously broken since we do large processing with libkse and donīt have issues with the performance. However Iīm observing about 50000 context switches but only 5000 syscalls a second. (I know itīs a different application but also for 1500 queries a second 70000 syscalls sounds excessive). Pete
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?40B1053F.6080604>