40% slowdown with dynamic /bin/sh

Michael Edenfield kutulu at kutulu.org
Wed Nov 26 06:35:36 PST 2003

* M. Warner Losh <imp at bsdimp.com> [031126 00:43]:
> In message: <20031126052626.GI15294 at wombat.localnet>
>             Michael Edenfield <kutulu at kutulu.org> writes:
> : * M. Warner Losh <imp at bsdimp.com> [031125 12:07]:
> : > In message: <00a701c3b33c$f798c5e0$b9844051 at insultant.net>
> : >             "boyd, rounin" <boyd at insultant.net> writes:
> : > : i see that there some doubt about whether running lots of
> : > : shell scripts ever happens.  what happens when you
> : > : use make?  lots of shells get run and they run small
> : > : (one line?) scripts.
> : > 
> : > make buildworld slows down < 1% when you switch from static /bin/sh to
> : > dynamic.
> : 
> : I'm all for dynamic / and dynamic /bin/sh, but this doesn't even come
> : close to what I observed on my systems.  I see anywhere from 15% to 20%
> : slowdown in buildworld, depending on how bad my hardware already is.  I
> : posted my most recent numbers earlier.
> My dual athlon make -j 4 buildworld differed by about 16-20 seconds on
> a 36 minute buildworld.
> : It's difficult to get lots of these numbers, unfortunately, because it
> : takes a good 6-8 hours just to complete one build.  But the numbers are
> : fairly consistant across the different degrees of old crappy hardware I
> : have.
> So you are seeing a about an hour slowdown (16% slowdown on 6 hours is
> 1 hour) from before/after?  Or are you seeing an hour slowdown from
> 4.x -> 5.2-beta?

I have two 5.x systems, both with dynamic / that were built within the
past month.  One's a bit older, probably a month or so, as I was waiting
for the statfs changes to settle before upgrading it.  The other was built
about 3 days ago.

The first one is pretty old, I only use it for a firewall because no one
will let me spring for a replacement:

CPU: Pentium II/Pentium II Xeon/Celeron (399.10-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0x665  Stepping = 5
real memory  = 66977792 (63 MB)
avail memory = 60477440 (57 MB)
ad0: 19470MB <QUANTUM FIREBALLlct20 20> [39560/16/63] at ata0-master UDMA33

This machine usually takes 10-12 hours to do a full buildworld with -j 3
(which somehow seems to be the fastest).  With static /bin/sh it was
took just about an hour and a half less, but again, I could only do one
pair since that took the whole day :)

The other is slightly better and is my personal FreeBSD workstation,
which I run -CURRENT on for test purposes and cuz I like it better :)

CPU: AMD-K7(tm) Processor (499.04-MHz 686-class CPU)
  Origin = "AuthenticAMD"  Id = 0x612  Stepping = 2
  AMD Features=0xc0400000<AMIE,DSP,3DNow!>
real memory  = 335478784 (319 MB)
avail memory = 316243968 (301 MB)
ad0: 16603MB <Maxtor 91731U4> [33735/16/63] at ata0-master UDMA66

This one completes a buildworld in about 7-8 hours, the static /bin/sh
run took about an hour less.  I posted those numbers here earlier.

I don't have any decent hardware running 5.x, all the new machines in
real user are still using 4.8, so these are the only numbers I can come
up with.  Again, I *like* the ability to have NSS in /bin/sh, and the
idea of dynamic linking in general appeals to me.  The hour to
hour-and-a-half slowdown might seem huge, but `make buildworld` really
is the worst case scenario I could come up with, and 15% slowdown in the
*worst* real-world case is certainly much better than 40%.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-current/attachments/20031126/46f60617/attachment-0001.bin

More information about the freebsd-current mailing list