more craziness - pre-cache in init scripts.

Carsten Haitzler (The Rasterman) raster at openmoko.org
Thu May 15 12:50:02 CEST 2008


ok - new idea to punt more time during the boot splash and less time during the
int of x gui apps. let's pre-cache files needed during bringup of X. that means
spend the cycles reading from flash while the splashscreen is amusing the user
with something like:

$ cat /etc/init.d/precache-x
#!/bin/sh
# this is a precache file for x
cat \
/usr/bin/Xglamo \
/usr/lib/libX*.so.?

$cat /etc/init.d/precache-e17
#!/bin/sh
# this is a precache file for e17
cat \
/usr/bin/enlightenment* \
/usr/lib/modules/*/*/*.so \
/usr/lib/modules/*/*.edj \
/usr/lib/modules/*/*.desktop \
/usr/share/enlightenment/images/* \
/usr/share/enlightenment/themes/* \
/usr/share/enlightenment/init/* \
/usr/share/enlightenment/icons/* \
/usr/share/enlightenment/fonts/* \
/usr/lib/libecore*.so.? \
/usr/lib/libedbus*.so.? \
/usr/lib/libeet*.so.? \
/usr/lib/libefreet*.so.? \
/usr/lib/libedje*.so.? \
/usr/lib/libevas*.so.? \
/usr/lib/libehal*.so.? \
/usr/lib/evas/modules/*/*/*/*.so

...
(for example).

so we can brew a set of precache files to be run during boot before we bring
the more expensive gui land up and hopefully cover most of their
paging-off-disk needs and have everything they need - or most of it, paged into
ram and ready to go meaning things will come up MUCH faster once the pre-cache
is done (and that's done under the cover of a pretty bootsplash progress bar...
so it's less "noticeable" than sluggish starting apps).

of course don't do everything - just the things we want to come up asap to
improve the boot experience.

sound like a good idea?

-- 
Carsten Haitzler (The Rasterman) <raster at openmoko.org>



More information about the distro-devel mailing list