I do not plan to submit this patch to Linus/Marcelo. This patch applies an obvious technique to the kernel: increase the amount of code compiled in a single compilation unit, to increase the overall knowledge the compiler has of the code, to allow for better optimization and dead code removal. KDE does this, with definite success, though they definitely are not the first to do this. Simply, all ext2 files are #include'd into a single file, ext2_all.c, and all functions and data structures are declared static. This technique can be used in the kernel, userspace applications, and userspace libraries to decrease icache footprint and overall size of your applications. Results from 2.4.17-pre2 plus the attached patch: 1135 bytes saved in vmlinux, simply from making all the functions static. (*.orig is prior to my patch. kernel is P2 SMP-based) > [jgarzik@rum linux-e2all]$ ls -l vmlinux* arch/i386/boot/bzImage* > -rw-r--r-- 1 jgarzik jgarzik 1030259 Dec 2 06:18 arch/i386/boot/bzImage > -rw-r--r-- 1 jgarzik jgarzik 1030263 Dec 2 06:04 arch/i386/boot/bzImage.orig > -rwxr-xr-x 1 jgarzik jgarzik 2814631 Dec 2 06:18 vmlinux* > -rwxr-xr-x 1 jgarzik jgarzik 2815766 Dec 2 06:04 vmlinux.orig* I can only imagine the large amount of space savings if large drivers like ACPI or reiserfs or aic7xxx use this technique. Maybe a global CONFIG_FINAL flag could enable *_all.c compilation for various drivers and subsystems. Functions not unconditionally static would be marked KSTATIC. [obviously the size of the compilation unit must not be larger than a single driver or subsystem, due to potential namespace collisions] -- Jeff Garzik | Only so many songs can be sung Building 1024 | with two lips, two lungs, and one tongue. MandrakeSoft | - nomeansno