Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 May 1998 15:20:56 +0800
From:      Joerg Micheel <joerg@krdl.org.sg>
To:        Greg Lehey <grog@lemis.com>
Cc:        John-Mark Gurney <gurney_j@resnet.uoregon.edu>, FreeBSD Hackers <hackers@FreeBSD.ORG>
Subject:   Re: Context switch time
Message-ID:  <19980504152056.47011@krdl.org.sg>
In-Reply-To: <19980504155242.P4777@freebie.lemis.com>; from Greg Lehey on Mon, May 04, 1998 at 03:52:42PM %2B0930
References:  <Pine.BSF.3.96.980425041329.28708A-100000@fledge.watson.org> <19980425034313.55993@hydrogen.nike.efn.org> <19980504143736.L4777@freebie.lemis.com> <19980503222303.36966@hydrogen.nike.efn.org> <19980504140442.52763@krdl.org.sg> <19980504155242.P4777@freebie.lemis.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Greg,

maybe, we should exchange our test programs :-).

On Mon, May 04, 1998 at 03:52:42PM +0930, Greg Lehey wrote:
> On Mon,  4 May 1998 at 14:04:42 +0800, Joerg Micheel wrote:
> > On Sun, May 03, 1998 at 10:23:03PM -0700, John-Mark Gurney wrote:
> >> Greg Lehey scribbled this message on May 4:
> >>> On Sat, 25 April 1998 at  3:43:13 -0700, John-Mark Gurney wrote:
> >>>
> >>> Strange.  This is what I get from a program that repeatedly calls
> >>> getpid() on my K6/233:
> >
> > These numbers might not that much depend on processor type/speed. What
> > about memory/cache speed ? Chipset ? Comments ?
> 
> I think they have quite a strong relationship with processor power.

> In particular, the P5/133 and your P5/200 seem to handle about 3500
> syscalls/MHz.  The P5/75 is presumably slower because of the missing
> cache, and I've noticed before that the K6 isn't as much faster at
> this sort of thing as I would expect--suggestions for the reasons are
> welcome.  One could be that it's an Inten TX board with 96 MB, of
> which only 64 MB are cached, but it seems to match up with John-Mark's
> observations.

Here is the Dell OptiPlex GXa, a 300 MHz PentiumPro:

CPU: Pentium Pro (298.00-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0x634  Stepping=4
  Features=0x80f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,<b11>,MTRR,PGE,MCA,CMOV>
real memory  = 67108864 (65536K bytes)
avail memory = 62709760 (61240K bytes)

procs   memory     page                    disks   faults      cpu
 r b w   avm   fre  flt  re  pi  po  fr  sr s0 c0   in   sy  cs us sy id
 1 0 0  3632 15368    1   0   0   0   0   0  0  0  260 802901  19 36 64  0
 1 0 0  3632 15368    1   0   0   0   0   0  0  0  235 730504  14 41 59  0
 1 0 0  3632 15368    1   0   0   0   0   0  0  0  235 730576  14 33 67  0
 1 0 0  3632 15368    1   0   0   0   0   0  0  0  237 730535  15 39 61  0
 1 0 0  3992 15368    1   0   0   0   0   0  0  0  238 730391  16 41 59  0
 1 0 0  3992 15368    1   0   0   0   0   0  0  0  238 730400  14 36 64  0
 1 0 0  3992 15368    1   0   0   0   0   0  0  0  255 729675  14 42 58  0

This trace was taken remotely by rlogin. I tried the same again by redirecting
stdout to a file on /tmp:

 procs   memory     page                    disks   faults      cpu
 r b w   avm   fre  flt  re  pi  po  fr  sr s0 c0   in   sy  cs us sy id
 1 0 0  4244 15360    1   0   0   0   0   0  0  0  234 694430  12 33 67  0
 1 0 0  4244 15360    1   0   0   0   0   0  0  0  234 695129  12 41 59  0
 1 0 0  4244 15360    1   0   0   0   0   0  0  0  235 695109  12 45 55  0
 1 0 0  4244 15360    1   0   0   0   0   0  0  0  232 695202  12 30 70  0
 1 0 0  4244 15360    1   0   0   0   0   0  0  0  234 695150  12 41 59  0
 1 0 0  4244 15360    1   0   0   0   0   0  0  0  231 698924  13 43 57  0

So - I wrote a program to get rid of IO dependencies and process interference.
Here is the result for:

P5/200:

1391351 usecs/1000000 calls, 718725 calls/sec
1390469 usecs/1000000 calls, 719181 calls/sec
1390228 usecs/1000000 calls, 719306 calls/sec
1390017 usecs/1000000 calls, 719415 calls/sec
1390116 usecs/1000000 calls, 719364 calls/sec
1411161 usecs/1000000 calls, 708636 calls/sec
1390442 usecs/1000000 calls, 719195 calls/sec
1397887 usecs/1000000 calls, 715365 calls/sec
1468439 usecs/1000000 calls, 680995 calls/sec
1397388 usecs/1000000 calls, 715620 calls/sec

PP6/300:

1378083 usecs/1000000 calls, 725645 calls/sec
1375760 usecs/1000000 calls, 726870 calls/sec
1582910 usecs/1000000 calls, 631747 calls/sec
1375810 usecs/1000000 calls, 726844 calls/sec
1375916 usecs/1000000 calls, 726788 calls/sec
1375900 usecs/1000000 calls, 726797 calls/sec
1375866 usecs/1000000 calls, 726814 calls/sec
1375858 usecs/1000000 calls, 726819 calls/sec
1375785 usecs/1000000 calls, 726857 calls/sec
1375755 usecs/1000000 calls, 726873 calls/sec

You seem to be right in some way, but the result does not directly suggest that
there is a 1:1 relationship with processor speed, at least not on the high-end machines.
The performance gain on the 300 MHz machine is VERY slight (around 1%).

Unfortunately, I currently don't have any slower machines around. I might
try on my 133MHz Pentium at home tonight.

	Joerg
-- 
Joerg B. Micheel			Email: <joerg@krdl.org.sg>
SingAREN Technology Center		Phone: +65 7705577
Kent Ridge Digital Labs			Fax:   +65 7795966
11 Science Park Road			Pager: +65 96016020
Singapore Science Park II		Plan:  Troubleshooting ATM
117685 Singapore			       Networks and Applications

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19980504152056.47011>