Date: Fri, 4 Apr 1997 16:16:11 +0700 (OSD) From: Eugeny Kuzakov <kev@l321.omsk.net.ru> To: "Alexander V. Lukyanov" <lav@video.yars.free.net> Cc: bugs@freebsd.org Subject: Re: sscanf is slow on 2.2.1 Message-ID: <Pine.BSD.3.95.970404161401.26348B-100000@l321.omsk.net.ru> In-Reply-To: <199704031521.TAA03420@video.yars.free.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 3 Apr 1997, Alexander V. Lukyanov wrote: > The program below works awfully slowly on FreeBSD 2.2.1, and quite normally > on Solaris 2.5, Linux, Digital Unix etc. > > Linux on i586 100Mhz: > real 0m26.020s > user 0m24.240s > sys 0m0.400s > > FreeBSD 2.1.5 on i586 66Mhz: > 104.06 real 51.97 user 0.00 sys My machine: P100/32MB/FreeBSD 2.1/Proxy SQUID/router to ISP (33600Kb)/30 logined users: 30.65 real 29.33 user 0.02 sys 8-() > > FreeBSD 2.2.1 on i586 133Mhz: > 737.01 real 588.48 user 0.43 sys > > More than 10 times slower than 2.1.5 on a weaker system. > Obviously, that time is spent inside libc. > > --- > #include <stdio.h> > int main() > { > int i; > char str[256]; > for(i=0; i<1000000; i++) > sscanf("abcde","%255[a-zA-Z]",str); > return 0; > } > --- > Alexander. > Best wishes, Eugeny Kuzakov Laboratory 321 ( Omsk, Russia ) kev@l321.omsk.net.ru
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSD.3.95.970404161401.26348B-100000>