swiftcoder, on 05 Feb 2013 - 00:40, said:
In almost all other cases, the standard library (used correctly) is going to be faster and more robust than a home-grown solution.
There was even a case on this forum when the Doom3 (or Quake3, I forget which) source code was released and someone tested the iD developed containers against the MS VS 2005 (iirc) implementation and found the latter beat the former by a considerable margin in many cases.
That's not to say that the containers as provided by the C++ Std. Lib are the perfect solution to everything, but don't go thinking you can beat them on speed without having a very specific set of requirements which a general solution can't be optimised towards.
In otherword; use the C++ Standard Library until proven otherwise.
(It still amuses me that C++ remains one of the only languages where people go out of their way to avoid the standard, library instead of learning how to use it properly, based on 10 year old hearsay and rumours...)
that would probably be Doom3, on account of Quake3 being plain C, whereas Doom3 was after id moved over to C++.
IMHO though, the bigger issue with the C++ standard-library, isn't so much the performance of the output code, but rather the hurt it often manages to put on the compile times, which can matter some when a person is left having to regularly recompile their project.
granted, I guess it could be argued that maybe these libraries offer more benefit to the project than the costs to their compile times.
admittedly, I am not much of a serious C++ developer though (I write considerably more C, and C++ is the 3rd-place language in my project, and most of this is in a "C with classes and operator overloading" style), admittedly at this point, mostly because a lot of my code-processing tools don't really understand C++, and those that do, only understand a subset. (the 2nd place language in my case is currently my scripting language, but if tools and misc are included, then C# is the second-place language, and C++ moves to 4th place).