I posted a separate thread that discussed using the cache effectively with respect to data structures. This raises a separate question. I've read a lot about the importance of using the cache effectively in software, and the performance hits of a "cold" cache.
I am not an engineer, rather I'm a computer scientist that usually concentrates on algorithmic complexity in implementations. I would like to learn more about using the cache effectively in my software programs. At this point I really know nothing about what cache-friendly software would even look like... I know what the cache is for from a high level architectural view, but really know nothing about the details.
Are there specific books or resources that I could learn from? I'm under the impression that different processors (i.e. AMD vs. Intel) have different cache designs. Would the resultant source code I generate normally be tuned for each cache design, or is there a general approach?
Perhaps more importantly, why should I care about the cache? Is it not the role of libraries like TBB and the compiler to care about this for me?
One resource I found, that I will be reading today, is here: http://lwn.net/Articles/250967/
Thanks a lot,