Subject: shared vs. unshared libcc1: numbers for x86.
To: Scott Reynolds <>
From: Bill Sommerfeld <>
List: tech-toolchain
Date: 02/09/1999 23:48:36
Here are numbers for -current on x86 with compilers as of last night's


The benchmark I picked was a build of the GENERIC_TINY kernel
configuration in a freshly configured directory.

Runs were done on a PentiumII/266 with 64 meg of memory and all
relevant filesyustems on a single 4gig narrow SCSI disk, with /tmp in
an MFS.

I ran each case three times in sequence to see what kind of
variability in timing I'd get; I didn't get much, so I summed the
times and compared them.

shared libcc1:
(wall time within 0.8%; user cpu within 0.6%)

make: 429.55s user 34.97s sys 507.52s wall
make: 430.68s user 34.05s sys 509.56s wall
make: 431.87s user 33.63s sys 505.64s wall
total: 1292.10s user, 1522.72s wall

unshared libcc1:

(wall times times are within 0.4%; user cpu usage within 0.2%)
make: 377.36s user 33.34s sys 453.86s wall
make: 377.39s user 32.92s sys 452.24s wall
make: 376.86s user 33.14s sys 452.75s wall

total: 1131.61s user 1358.85s wall

For this benchmark on x86, shared libcc1 uses 12% more wall time, and
uses 14% more cpu time.

Disk Space:

shared library: file size
1464 -r--r--r--  1 root  wheel  1488658 Feb  9 22:11 /usr/lib/
 232 -r-xr-xr-x  1 root  wheel   229376 Feb  9 22:11 /usr/libexec/cc1
 304 -r-xr-xr-x  1 root  wheel   303104 Feb  9 22:11 /usr/libexec/cc1obj
 720 -r-xr-xr-x  1 root  wheel   729088 Feb  9 22:11 /usr/libexec/cc1plus
 664 -r-xr-xr-x  1 root  wheel   667648 Feb  9 22:11 /usr/libexec/f771
3384 blocks for shared libcc1

1408 -r-xr-xr-x  1 root  wheel  1429504 Feb  9 22:39 /usr/libexec/cc1
1472 -r-xr-xr-x  1 root  wheel  1499136 Feb  9 22:39 /usr/libexec/cc1obj
1864 -r-xr-xr-x  1 root  wheel  1900544 Feb  9 22:39 /usr/libexec/cc1plus
1832 -r-xr-xr-x  1 root  wheel  1867776 Feb  9 22:40 /usr/libexec/f771
6576 blocks for unshared libcc1

On x86, unshared libcc1 uses 94% more disk space than shared.

					- Bill