Interesting. It should definitely be built in something other than bash, but actually its a very simple fundamental idea, so could relatively easily be built in another language. If I was to do it, I would do it in scala. We would need a database to put the scan-durations in, which in my eyes complicates the setup quite a bit. I wonder if that's overengineering it a bit. I doubt many would access it, unless there's also a web-page to display the timings in some aggregate format.
I doubt I'll play more with it. I don't think its worth it, because in my experience tinkering with cache_dirs, it can never be really good. Linux will discard the cache when it wants, and we don't know whether or not it has discarded cache or system is otherwise busy. I think there are many other projects much more valuable to put my efforts into.
Actually I write to a csv-file which can be opened in excel. I've just added a 2.2.6 version that puts most or all the data in a csv-file. I think that might be useful to some.
Best Alex