|
From: Nicholas N. <nj...@cs...> - 2006-03-08 22:43:58
|
On Wed, 8 Mar 2006 val...@ce... wrote: > I am starting to use Valgrinds cachegrind to test my program for caches > performance. Once i do this, how can I improve the cache performance? that > is, how can I eliminate or reduce cache missies in my app? Are certain types > of programming techniques more prone to cache misses? For example, nested > loops? Certain data type declarations etc? Is there a good source of > information on the internet? There is no easy answer. Cachegrind points you in the right direction, but it can't tell you how directly how to fix your program. There is lots of information about caches on the internet, google for some. In general, try to make the crucial data structures smaller, and improve locality of accesses to them. Nick |