we're happy to announce a major rewrite of sreadahead, and the release of version1.0. This is a significant improvement in the way sreadahead works:

* sreadahead now will work on any filesystem;

Sreadahead used to use an ioctl to retreive inserted timestamps from ext3 inodes. This patch is now replaced with a generic open() syscall tracer, which will work on all filesystems.

* pack file generation is now integrated entirely in a single binary, and automatically done if the pack file is missing;

Sreadahead is now a single-binary two-purpose program that either reads in the content needed, or generates this content. This reduces the chance that sreadahead is called incorrectly, but also makes installation a lot easier. Sreadahead can now be added to the boot system by inserting a single line in a startup script.

* pack file generation is now significantly faster than the old method;

Sreadahead now uses a kernel tracer which provides with a sort-by-use list of all files opened. This removes the need for a special script to discover which files were opened at boot. This list is sorted and filtered in C code inside sreadahead which proves much faster. The old method took multiple seconds. New method sorts/filters 10k+ open trace calls in 0.16s on a regular desktop.

While sreadahead reads "used" data into memory, the kernel reports more memory in use than actually used due to the in-kernel readahead function. In order to read significantly less data, sreadahead temporarily reduces this amount, saving significant amount of total IO time. This saves as much as 8 out of 64Mb on a regular fedora core installation.

Sreadahead still depends on a kernel patch (posted in a followup). This patchimplements a global kernel tracer for sys_open() syscalls. The choice was made touse this method since userland tracing is slow, cumbersome (have to attach toevery process running), and hard to implement for system-wide tracing (we don'tcare about which process is doing something). A kernel tracer is extremelyefficient and added bonus is that we can leave the trace in memory until weactually need to process it.