Speeding up compile time?
It seems like I keep recompiling kernels because of new features (kvm, timer changes) that come come out, or bugs I run into (nvidia + paravirt_ops, libata vs old ata system), so I'm on my 5th kernel compile in about 4 weeks. Needless to say we all know they're slow. I haven't timed mine but I'd say its about 45 minutes?
What are my options for speeding that up? I have a Intel Core 2 Duo E6600, so 2 x 2.4ghz. On my most recent one I've stripped out a lot of the drivers I'm sure I will never need which should help a lot. But my main question is there a way for it to use both processors in parallel - or is it doing that already? My other machine is a Pentium 4 2.4ghz and it didn't seem to take any less time for that one to compile which makes me think it doesn't use both processors. I currently use the kpkg way of doing it since I'm using Debian Etch, but I used to use the standard make bzImage when I used Slackware so either way can work for me if its an option, I just want to speed it up because I like tweaking the kernel but I don't get much free time anymore, much less enough to wait an hour while it compiles and I'm not accomplishing anything. |
Count the number of processors your kernel sees (I suspect two), and add a -jN option to your make commands. Where N is the number of processors plus one. Almost halves the compile time of kernels on my AMD64 Turion X2.
Regards, Alunduil Sidenote: On a Sun E6500 with 19 Blackbirds and -j20 I can compile a clean kernel in under 5 minutes. |
All times are GMT -5. The time now is 01:00 AM. |