間違いだらけの備忘録

このページの内容は無保証でありこのページの内容によって直接、または間接に損害を受けられたとしても私は責任を取りません。

kernelコンパイルテスト

@SC440

wget http://www.jp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.23.tar.gz
tar xvzf linux-2.6.23.tar.gz
cd linux-2.6.23
make defconfig


# make clean ; time make bzImage

Kernel: arch/i386/boot/bzImage is ready (#2)

real 6m8.948s
user 5m39.042s
sys 0m40.346s

#make clean ; time make bzImage
Kernel: arch/x86_64/boot/bzImage is ready (#2)

real 5m49.109s
user 5m33.023s
sys 0m44.597s

#make clean ; time make -j5 bzImage

Kernel: arch/x86_64/boot/bzImage is ready (#3)

real 3m26.600s
user 5m51.383s
sys 0m49.351s

# make clean ; time make -j5 bzImage
Kernel: arch/x86_64/boot/bzImage is ready (#4)

real 3m32.260s
user 5m51.106s
sys 0m49.407s

# make clean ; time make -j5 bzImage
Kernel: arch/x86_64/boot/bzImage is ready (#5)

real 3m29.143s
user 5m50.960s
sys 0m49.759s

微妙なずれはある

@x61@2CPU@VM
real 4m32.436s
user 4m58.067s
sys 3m15.952s
DebianVM01:~/linux-2.6.23# make clean ; time make -j5 bzImage

real 4m19.149s
user 4m54.454s
sys 3m11.228s
DebianVM01:~/linux-2.6.23# make clean ; time make -j5 bzImage

2.6.26

準備
wget http://www.jp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.26.tar.gz
tar xvzf linux-2.6.26.tar.gz
make defconfig

@sc440
$ make clean ; time make -j 5

Kernel: arch/x86/boot/bzImage is ready (#1)

real 3m54.454s
user 7m11.235s
sys 0m28.310s

Kernel: arch/x86/boot/bzImage is ready (#2)

real 3m55.705s
user 7m12.323s
sys 0m29.106s

Kernel: arch/x86/boot/bzImage is ready (#3)

real 3m52.430s
user 7m9.199s
sys 0m28.810s

Kernel: arch/x86/boot/bzImage is ready (#4)

real 3m53.012s
user 7m8.927s
sys 0m28.678s
[SC440 "Ubuntu 8.04.1" i686 01:45:13]

Kernel: arch/x86/boot/bzImage is ready (#5)

real 3m51.806s
user 7m9.343s
sys 0m27.902s

Kernel: arch/x86/boot/bzImage is ready (#6)

real 3m51.706s
user 7m9.375s
sys 0m27.938s

@X61
基本
[ linux-2.6.26]$ make clean ; time make

Kernel: arch/x86/boot/bzImage is ready (#29)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 5m46.964s
user 5m22.772s
sys 0m25.442s
[X61 "Ubuntu 8.04.1" i686 18:35:26]

Kernel: arch/x86/boot/bzImage is ready (#30)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 5m47.852s
user 5m22.608s
sys 0m25.710s
[X61 "Ubuntu 8.04.1" i686 18:48:40]

Kernel: arch/x86/boot/bzImage is ready (#32)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 5m46.547s
user 5m22.748s
sys 0m25.582s
[X61 "Ubuntu 8.04.1" i686 19:03:10]

5並列

[ linux-2.6.26]$ make clean ; time make -j 5
Kernel: arch/x86/boot/bzImage is ready (#33)

real 3m27.612s
user 6m12.851s
sys 0m27.494s

[X61 "Ubuntu 8.04.1" i686 19:07:30]
Kernel: arch/x86/boot/bzImage is ready (#34)

real 3m28.090s
user 6m12.755s
sys 0m27.402s

Kernel: arch/x86/boot/bzImage is ready (#35)

real 3m27.385s
user 6m12.507s
sys 0m27.494s

ccache

1回目
/tmp/linux-2.6.26$ make clean ; time make CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#2)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 6m20.151s
user 5m45.186s
sys 0m31.346s

$ccache -s
cache directory /home/user/.ccache
cache hit 0
cache miss 1162
called for link 4
not a C/C++ file 22
no input file 94
files in cache 2324
cache size 6.8 Mbytes
max cache size 976.6 Mbytes

2回目
$ make clean ; time make CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#3)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 1m28.926s
user 1m9.300s
sys 0m15.973s

$ccache -s
cache directory /home/user/.ccache
cache hit 1159
cache miss 1165
called for link 8
not a C/C++ file 44
no input file 188
files in cache 2330
cache size 6.8 Mbytes
max cache size 976.6 Mbytes

$ make clean ; time make CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#4)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 1m32.158s
user 1m9.608s
sys 0m16.421s

$ccache -s
cache directory /home/user/.ccache
cache hit 2318
cache miss 1168
called for link 12
not a C/C++ file 66
no input file 282
files in cache 2336
cache size 6.8 Mbytes
max cache size 976.6 Mbytes

4回目
$ make clean ; time make CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#5)
Building modules, stage 2.
MODPOST 1 modules
CC drivers/scsi/scsi_wait_scan.mod.o
LD [M] drivers/scsi/scsi_wait_scan.ko

real 1m26.887s
user 1m7.880s
sys 0m16.361s

$ccache -s
cache directory /home/user/.ccache
cache hit 3477
cache miss 1171
called for link 16
not a C/C++ file 88
no input file 376
files in cache 2342
cache size 6.8 Mbytes
max cache size 976.6 Mbytes

ccache+make -j5
1回目
$ make clean ; time make -j5 CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#6)

real 0m58.317s
user 1m17.993s
sys 0m17.625s

2回目
$ make clean ; time make -j5 CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#7)

real 0m55.052s
user 1m16.477s
sys 0m17.533s

3回目
$ make clean ; time make -j5 CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#8)

real 0m54.579s
user 1m16.681s
sys 0m17.433s

1回目
$ export DISTCC_HOSTS="distpc1 distpc2";export TMPDIR=/tmp/gcc ; make clean ; time make -j9 CCACHE_PREFIX="distcc" CC="ccache gcc"
Kernel: arch/x86/boot/bzImage is ready (#25)

real 2m3.530s
user 1m22.013s
sys 0m26.034sKernel: arch/x86/boot/bzImage is ready (#26)

2回目
$ export DISTCC_HOSTS="distpc1 distpc2";export TMPDIR=/tmp/gcc ; make clean ; time make -j9 CCACHE_PREFIX="distcc" CC="ccache gcc"
real 1m1.549s
user 1m17.613s
sys 0m18.945s

[X61 "Ubuntu 8.04.1" i686 20:32:26]
$ rm -rf /home/user/.ccache/* ;make clean ; time make -j5 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc1" CC="ccache gcc"

1.
Kernel: arch/x86/boot/bzImage is ready (#3)

real 7m39.355s
user 1m38.062s
sys 0m32.490s

2.
Kernel: arch/x86/boot/bzImage is ready (#4)

real 6m43.519s
user 1m37.218s
sys 0m31.850s

3.
Kernel: arch/x86/boot/bzImage is ready (#5)

real 7m26.353s
user 1m37.686s
sys 0m31.890s
[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j9 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost" CC="ccache gcc"


Kernel: arch/x86/boot/bzImage is ready (#10)

real 2m18.889s
user 3m30.965s
sys 0m29.682s
Kernel: arch/x86/boot/bzImage is ready (#12)

real 2m18.637s
user 3m29.765s
sys 0m29.558s

Kernel: arch/x86/boot/bzImage is ready (#11)

real 2m17.661s
user 3m33.489s
sys 0m29.810s

[X61 "Ubuntu 8.04.1" i686 21:34:57]
[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j9 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost distpc1" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#13)

real 2m2.604s
user 3m0.675s
sys 0m28.882s

Kernel: arch/x86/boot/bzImage is ready (#14)

real 2m2.534s
user 2m58.355s
sys 0m28.814s

Kernel: arch/x86/boot/bzImage is ready (#15)

real 2m2.112s
user 2m58.751s
sys 0m29.354s

[X61 "Ubuntu 8.04.1" i686 21:52:02]
[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j13 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost distpc1" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#16)

real 1m54.858s
user 2m45.398s
sys 0m29.702s

Kernel: arch/x86/boot/bzImage is ready (#17)

real 1m57.281s
user 2m50.483s
sys 0m28.786s


Kernel: arch/x86/boot/bzImage is ready (#18)

real 1m55.011s
user 2m46.194s
sys 0m28.850s

Kernel: arch/x86/boot/bzImage is ready (#19)

real 1m56.969s
user 2m54.611s
sys 0m28.790s
[X61 "Ubuntu 8.04.1" i686 22:16:09]
[linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j13 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc1 localhost distpc2" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#20)

real 2m0.856s
user 2m52.415s
sys 0m29.042s

Kernel: arch/x86/boot/bzImage is ready (#21)

real 2m0.128s
user 2m53.175s
sys 0m29.446s

Kernel: arch/x86/boot/bzImage is ready (#22)

real 2m0.678s
user 2m51.559s
sys 0m29.090s

Kernel: arch/x86/boot/bzImage is ready (#6)

real 3m38.601s
user 1m29.070s
sys 0m27.638s
[X61 "Ubuntu 8.04.1" i686 21:01:01]
[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j5 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#7)

real 3m40.319s
user 1m29.074s
sys 0m28.246s

Kernel: arch/x86/boot/bzImage is ready (#9)

real 3m38.985s
user 1m28.934s
sys 0m28.190s


[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j9 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost" CC="ccache gcc"


Kernel: arch/x86/boot/bzImage is ready (#10)

real 2m18.889s
user 3m30.965s
sys 0m29.682s
Kernel: arch/x86/boot/bzImage is ready (#12)

real 2m18.637s
user 3m29.765s
sys 0m29.558s

Kernel: arch/x86/boot/bzImage is ready (#11)

real 2m17.661s
user 3m33.489s
sys 0m29.810s

[X61 "Ubuntu 8.04.1" i686 21:34:57]
[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j9 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost distpc1" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#13)

real 2m2.604s
user 3m0.675s
sys 0m28.882s

Kernel: arch/x86/boot/bzImage is ready (#14)

real 2m2.534s
user 2m58.355s
sys 0m28.814s

Kernel: arch/x86/boot/bzImage is ready (#15)

real 2m2.112s
user 2m58.751s
sys 0m29.354s

[X61 "Ubuntu 8.04.1" i686 21:52:02]
[ linux-2.6.26]$ rm -rfKernel: arch/x86/boot/bzImage is ready (#47)

real 1m50.338s
user 2m48.503s
sys 0m25.654s
[X61 "Ubuntu 8.04.1" i686 22:36:26]
/home/user/.ccache/* ;make clean ; time make -j13 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost distpc1" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#16)

real 1m54.858s
user 2m45.398s
sys 0m29.702s

Kernel: arch/x86/boot/bzImage is ready (#17)

real 1m57.281s
user 2m50.483s
sys 0m28.786s


Kernel: arch/x86/boot/bzImage is ready (#18)

real 1m55.011s
user 2m46.194s
sys 0m28.850s

[X61 "Ubuntu 8.04.1" i686 22:54:23]
[ linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j5 CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#49)

real 3m58.393s
user 6m46.873s
sys 0m35.614s


Kernel: arch/x86/boot/bzImage is ready (#50)

real 3m56.175s
user 6m47.309s
sys 0m35.666s

Kernel: arch/x86/boot/bzImage is ready (#51)

real 3m54.718s
user 6m47.217s
sys 0m35.218s

[ linux-2.6.26]$ make clean ; time make -j13 DISTCC_HOSTS="distpc2 localhost distpc1" CC="distcc"

Kernel: arch/x86/boot/bzImage is ready (#36)

real 1m50.727s
user 2m40.262s
sys 0m25.322s
[X61 "Ubuntu 8.04.1" i686 21:05:56]
Kernel: arch/x86/boot/bzImage is ready (#37)

real 1m47.708s
user 2m42.422s
sys 0m24.846s

real 1m47.472s
user 2m42.742s
sys 0m25.346s

[ linux-2.6.26]$ make clean ; time make -j13 DISTCC_HOSTS="distpc1 distpc2 localhost" CC="distcc"

Kernel: arch/x86/boot/bzImage is ready (#39)

real 1m48.458s
user 2m39.750s
sys 0m25.994s
[X61 "Ubuntu 8.04.1" i686 21:21:15]
Kernel: arch/x86/boot/bzImage is ready (#40)

real 1m48.763s
user 2m40.130s
sys 0m25.110s

Kernel: arch/x86/boot/bzImage is ready (#42)

real 1m50.231s
user 2m42.990s
sys 0m24.686s
[X61 "Ubuntu 8.04.1" i686 22:09:53]

[ linux-2.6.26]$ make clean ; time make -j13 DISTCC_HOSTS="distpc2 localhost distpc1" CC="distcc"

Kernel: arch/x86/boot/bzImage is ready (#45)

real 1m48.686s
user 2m42.722s
sys 0m25.410s

Kernel: arch/x86/boot/bzImage is ready (#46)

real 1m47.243s
user 2m39.150s
sys 0m24.786s
[X61 "Ubuntu 8.04.1" i686 22:22:13]

Kernel: arch/x86/boot/bzImage is ready (#47)

real 1m50.338s
user 2m48.503s
sys 0m25.654s
[X61 "Ubuntu 8.04.1" i686 22:36:26]


Kernel: arch/x86/boot/bzImage is ready (#19)

real 1m56.969s
user 2m54.611s
sys 0m28.790s

[X61 "Ubuntu 8.04.1" i686 22:16:09]
[linux-2.6.26]$ rm -rf /home/user/.ccache/* ;make clean ; time make -j13 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc1 localhost distpc2" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#20)

real 2m0.856s
user 2m52.415s
sys 0m29.042s

Kernel: arch/x86/boot/bzImage is ready (#21)

real 2m0.128s
user 2m53.175s
sys 0m29.446s

Kernel: arch/x86/boot/bzImage is ready (#22)

real 2m0.678s
user 2m51.559s
sys 0m29.090s

[0]$ zcat 513ac7152ff49d92336b39f6a75d3d-387167 > /tmp/test1
[X61 "Ubuntu 8.04.1" i686 23:20:26]
[0]$ file /tmp/test1
/tmp/test1: ELF 32-bit LSB relocatable, Intel 80386, version 1 (SYSV), not stripped
[X61 "Ubuntu 8.04.1" i686 23:20:34]
[0]$ pwd
/home/user/.ccache/0/0
[X61 "Ubuntu 8.04.1" i686 23:23:15]


[linux-2.6.26]$ make clean ; time make -j13 CCACHE_PREFIX="distcc" DISTCC_HOSTS="distpc2 localhost distpc1" CC="ccache gcc"

Kernel: arch/x86/boot/bzImage is ready (#53)

real 1m1.250s
user 1m19.613s
sys 0m20.193s
[X61 "Ubuntu 8.04.1" i686 23:32:35]

Kernel: arch/x86/boot/bzImage is ready (#56)

real 1m0.677s
user 1m19.081s
sys 0m20.257s
Kernel: arch/x86/boot/bzImage is ready (#57)

real 1m1.774s
user 1m18.705s
sys 0m19.841s
[X61 "Ubuntu 8.04.1" i686 23:51:42]


[0]$ zcat 513ac7152ff49d92336b39f6a75d3d-387167 > /tmp/test1
[X61 "Ubuntu 8.04.1" i686 23:20:26]
[0]$ file /tmp/test1
/tmp/test1: ELF 32-bit LSB relocatable, Intel 80386, version 1 (SYSV), not stripped
[X61 "Ubuntu 8.04.1" i686 23:20:34]
[0]$ pwd
/home/user/.ccache/0/0
[X61 "Ubuntu 8.04.1" i686 23:23:15]


[sc440 linux-2.6.26]$ make clean ; time make -j 5

Kernel: arch/x86/boot/bzImage is ready (#1)

real 3m54.454s
user 7m11.235s
sys 0m28.310s

Kernel: arch/x86/boot/bzImage is ready (#2)

real 3m55.705s
user 7m12.323s
sys 0m29.106s

Kernel: arch/x86/boot/bzImage is ready (#3)

real 3m52.430s
user 7m9.199s
sys 0m28.810s

@X61 VM
Kernel: arch/x86/boot/bzImage is ready (#1)

real 6m16.033s
user 9m38.652s
sys 2m15.672s
user@user-desktop:/var/tmp/linux-2.6.26$ make clean ; time make -j5

ccontrol
1回目
[linux-2.6.26]$ rm -rf ~/.ccache/* ; make clean ; time make
Kernel: arch/x86/boot/bzImage is ready (#60)

real 2m5.404s
user 2m46.906s
sys 0m36.794s
[X61 "Ubuntu 8.04.1" i686 20:53:54]
Kernel: arch/x86/boot/bzImage is ready (#61)

real 2m9.258s
user 2m45.178s
sys 0m36.742s
[X61 "Ubuntu 8.04.1" i686 20:56:58]

Kernel: arch/x86/boot/bzImage is ready (#62)

real 2m8.794s
user 2m42.390s
sys 0m36.702s

2回め
real 1m4.852s
user 1m28.390s
sys 0m21.717s
[X61 "Ubuntu 8.04.1" i686 21:04:16]
[linux-2.6.26]$ make clean ; time make

Kernel: arch/x86/boot/bzImage is ready (#64)

real 1m7.156s
user 1m27.197s
sys 0m21.309s
[X61 "Ubuntu 8.04.1" i686 21:06:23]

Kernel: arch/x86/boot/bzImage is ready (#65)

real 1m6.297s
user 1m29.350s
sys 0m21.349s
[X61 "Ubuntu 8.04.1" i686 21:11:20]

キャッシュクリア1回目
[ linux-2.6.26]$ rm -rf ~/.ccache/* ; rm -rf debian/ ; make clean ; time CONCURRENCY_LEVEL=13 fakeroot make-kpkg -append_to_version -v1 -revision=1 -initrd kernel-image -config defconfig

This is kernel package version 11.001.

real 2m50.915s
user 3m23.613s
sys 0m51.491s
[X61 "Ubuntu 8.04.1" i686 21:50:50]

This is kernel package version 11.001.

real 2m49.035s
user 3m24.149s
sys 0m51.207s
[X61 "Ubuntu 8.04.1" i686 21:54:19]

This is kernel package version 11.001.

real 2m50.608s
user 3m22.833s
sys 0m51.751s

chace有効
This is kernel package version 11.001.

[ linux-2.6.26]$ rm -rf debian/ ; make clean ; time CONCURRENCY_LEVEL=13 fakeroot make-kpkg -append_to_version -v1 -revision=1 -initrd kernel-image -config defconfig

real 1m57.396s
user 1m40.330s
sys 0m39.834s
[X61 "Ubuntu 8.04.1" i686 22:01:28]
This is kernel package version 11.001

.

real 1m59.242s
user 1m40.598s
sys 0m40.159s
[X61 "Ubuntu 8.04.1" i686 22:08:30]

This is kernel package version 11.001.

real 1m57.762s
user 1m40.818s
sys 0m39.714s

[ linux-2.6.26]$ make clean ; time CONCURRENCY_LEVEL=13 fakeroot make-kpkg -append_to_version -v1 -revision=1 -initrd kernel-image -config defconfig


real 1m55.755s
user 1m38.998s
sys 0m38.838s

[X61 "Ubuntu 8.04.1" i686 22:14:37]

This is kernel package version 11.001.

real 1m55.974s
user 1m38.258s
sys 0m38.566s
[X61 "Ubuntu 8.04.1" i686 22:20:11]

====== making target kernel-image [new prereqs: stamp-configure stamp-build-kernel stamp-kernel-image]======
This is kernel package version 11.001.

real 1m55.777s
user 1m39.150s
sys 0m38.814s

This is kernel package version 11.001.

[ linux-2.6.26]$ time CONCURRENCY_LEVEL=13 fakeroot make-kpkg -append_to_version -v1 -revision=1 -initrd kernel-image -config defconfig

real 0m29.825s
user 0m21.501s
sys 0m9.501s
[X61 "Ubuntu 8.04.1" i686 22:24:28]

This is kernel package version 11.001.

real 0m29.849s
user 0m21.625s
sys 0m9.329s
[X61 "Ubuntu 8.04.1" i686 22:25:31]

This is kernel package version 11.001.

real 0m30.361s
user 0m21.661s
sys 0m9.777s

$ rm -rf debian/ ; make clean ; time fakeroot make-kpkg -append_to_version -v1 -revision=1 -initrd kernel-image -config defconfig

This is kernel package version 11.001.

real 6m54.528s
user 5m46.898s
sys 0m42.531s

This is kernel package version 11.001.

real 6m54.419s
user 5m47.118s
sys 0m42.123s

This is kernel package version 11.001.

real 6m53.834s
user 5m48.258s
sys 0m41.947s

このページにはhatena以外のサービスからのコンテンツが埋め込まれています。 hatenaによりGoogle AdSense 広告が埋め込まれています。