
6 Mar
2006
6 Mar
'06
6:17 p.m.
Nigel Stewart ha escrito:
Caching is one of the fundamental ways to achieve improved performance. I'm a bit surprised it hasn't been more of a topic in Boost discussions, or in computer science in general.
Here is an application for a C++ LRU datastructure in computer graphics: http://aim.adc.rmit.edu.au/phd/sgreuter/papers/graphite2003.pdf
In a nutshell, the datastructure is a fairly generic arrangement of std::list and std::map, but the replacement policy is fairly application-oriented.
Have you considered using Boost.MultiIndex as the core of your lru class? There's a MRU list class example in the same spirit at http://boost.org/libs/multi_index/doc/examples.html#example9 Joaquín M López Muñoz Telefónica, Investigación y Desarrollo