I think cachegrind , one of the tools in the valgrind package, may be what you are looking for. I did not use it myself, but, looking at this page, it creates an output file cachegrind.out.<pid> with information read by a person about access to the cache. Not sure if this will be as detailed as you need (maybe this is just a summary), but probably worth a look.
source share