[cmake-developers] [PSA] API changes to use strings
Stephen Kelly
steveire at gmail.com
Thu Feb 6 17:44:51 EST 2014
Ben Boeckel wrote:
> - cmMakefile::Get{Source,Header}Extensions returns a std::set rather
> than a std::vector since it was never modified and is only iterated
> over and searched in other code.
The justification is strange. Generally, the guideline with C++ stl
containers is to use std::vector unless you have a good reason to use
something else.
> vec[vec.size()-1] (use *vec.rbegin())
vec.back() ?
> The goal of all of this? To make CMake faster by removing the chaff in
> callgrind runs. String allocations and strlen/memcmp in string/C string
> comparisons are way too high and hide other bottlenecks, so I'm whacking
> the vast majority of problems with a very large hammer here.
Thanks, I support it.
Steve.
More information about the cmake-developers
mailing list