GSOC 2013 project " Kernel Size Reduction for Embedded System "

Freddie Cash fjwcash at gmail.com
Tue Apr 9 18:06:03 UTC 2013


You have to look at the in-memory sizes, not the on-disk sizes.

Linux kernels are very barebones when it comes to what is compiled directly
into the kernel image on disk.  Everything else is loaded from modules at
boot time.  Especially if using distro-provided kernels.  They even use ram
disks / initrds to get around the "can't boot without drivers for Y, but Y
is a module and not loaded at boot", adding extra memory pressure that's
not shown in the on-disk size of the kernel image file.

FreeBSD kernels tend to be the opposite, with everything compiled directly
into the
kernel image on-disk, and very little actually being loaded via modules.
At least GENERIC, anyway.

You would need to manually compile kernels with the same sets of drivers on
each system, in order to do a proper comparison of on-disk sizes.  Or, look
at in-memory stats for the two, once the systems are booted, all modules
are loaded, and the system is ready for use.

Just comparing ls output of default FreeBSD/Linux installs isn't useful in
any way.
-- 
Freddie Cash
fjwcash at gmail.com


More information about the freebsd-hackers mailing list