J
jimxoch
Hi list,
Most STL containers are storing their data on the heap. (although some
std::string implementations are notable exceptions) Of course, using
the heap as storage increases flexibility and allows the handling of
much bigger amounts of data. However, there are cases where this turns
out to be inefficient for at least two reasons: A) Allocations and
deallocations on heap are much slower. B) Memory access on stack is
more cache friendly.
The above facts make me want to try using STL like containers which
are able to store their data on stack. Is anybody familiar with such
container implementations? Any opinions about them?
Thanks in advance,
Jim Xochellis
Most STL containers are storing their data on the heap. (although some
std::string implementations are notable exceptions) Of course, using
the heap as storage increases flexibility and allows the handling of
much bigger amounts of data. However, there are cases where this turns
out to be inefficient for at least two reasons: A) Allocations and
deallocations on heap are much slower. B) Memory access on stack is
more cache friendly.
The above facts make me want to try using STL like containers which
are able to store their data on stack. Is anybody familiar with such
container implementations? Any opinions about them?
Thanks in advance,
Jim Xochellis