|
|
|
#1 |
|
Messages: n/a
Hébergeur: |
The Strinx library is a lightweight extension to the standard C++
template library, aimed to provide a set of highly efficient containers, by using different memory model then traditional STL containers, which is also less likely to cause memory fragmentations on long running applications. Performance benchmarks show that Strinx containers have better performance then STL containers (on Linux machine, GCC 4.1.2): http://strinx.sourceforge.net/docs/strinx.html ShacharS. |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
"shablool" <ssnail@gmail.com> wrote
> > The Strinx library is a lightweight extension to the standard C++ > template library, aimed to provide a set of highly efficient > containers, by using different memory model then traditional STL > containers, which is also less likely to cause memory fragmentations > on long running applications. > > Performance benchmarks show that Strinx containers have better > performance then STL containers (on Linux machine, GCC 4.1.2): > > http://strinx.sourceforge.net/docs/strinx.html > > ShacharS. I haven't tried it out yet but it sounds a good idea. But I would extend it, so that when the container gets full that it autom. tries to realloc() the memory with an additional x% (say 10%) room for new items. So, the user defines the initial size (ie. nelems) and by this how much memory to preallocate initally, plus a growing factor (here 10%). This way it has practically no limits in growing should the case occur for needing to add even more items then initially was planned by the user. It's IMO the most flexible solution. You can keep your design and just add the above feature of auto-growing of the buffer. You should also allow the user to change the growing factor anytime after the inital definition. You can try this concept out (benchmark) with say the set<T> type. |
|
![]() |
| Outils de la discussion | |
|
|