
On Mon, Sep 29, 2008 at 12:56 AM, <joaquin@tid.es> wrote:
Emil Dotchevski escribió:
On Sun, Sep 21, 2008 at 8:01 AM, Joaquin M Lopez Munoz <joaquin@tid.es> wrote:
Hi Emil, as promised, some profile results are shown at:
http://bannalia.blogspot.com/2008/09/profiling-stablevector.html
This is interesting, so basically the stable iterators/references are achieved by allocating each object in a separate node.
This got me thinking, from certain point of view the difference between std::list and your stable_vector is the ability of the latter to return elements by index in O(1). Isn't it possible to decouple this ability from the container itself? In other words, could your code be refactored to provide indexing over any type of "host container"?
Well, sort of. Basically, that's what you can achieve by adding a random access index (http://tinyurl.com/4ruu2c ) to a multi_index_container.
I wasn't trying to achieve anything, except to point out that perhaps it is possible to decouple the indexing functionality from the storage functionality, in principle. Emil Dotchevski Reverge Studios, Inc. http://www.revergestudios.com/reblog/index.php?n=ReCode